Content deleted Content added
SMcCandlish (talk | contribs) m →Advanced features: ditto |
m Typo fixing, replaced: featue → feature, assesments → assessments |
||
(26 intermediate revisions by 9 users not shown) | |||
Line 1:
{{Module rating|protected}}
{{WikiProject banner related}}
{{
{{Uses TemplateStyles|Module:WikiProject banner/styles.css|Module:Message box/tmbox.css}}
{{Lua|Module:Arguments|Module:Check for unknown parameters|Module:Message box|Module:Pagetype|Module:Template parameter value|Module:WikiProject banner/config|Module:WikiProject banner/templatepage|Module:Wikitext Parsing|Module:Yesno|noprotcat=yes}}
{{
}}▼
[[Module:WikiProject banner]] can be used to create [[:Category:WikiProject banner templates|WikiProject banners]], enabling new projects to easily create a banner to place on article [[WP:TALK|talk pages]], ensuring standardisation between projects. A list of all WikiProject banners using this meta-template can be found [https://en.wikipedia.org/w/index.php?title=Special:WhatLinksHere/Module:WikiProject_banner&namespace=10&hidelinks=1&hideredirs=1&limit=250 here].
As this is a [[Wikipedia:Meta|meta]] template, it should not be transcluded directly on to talk pages when you want to tag a page. Instead, use the template provided by the WikiProject.
==Syntax==
Line 25 ⟶ 27:
|PROJECT =
|substcheck=<includeonly>{{subst:</includeonly><includeonly>substcheck}}</includeonly>
|listas={{{listas|}}}
|DOC = auto
Line 58 ⟶ 59:
**{{para|DOC|none}} – (or left blank) will not include any documentation.-->
*<code>'''substcheck'''</code> – this allows the template to detect if it has been substituted instead of transcluded and give an error message. '''''<syntaxhighlight lang="wikitext" inline>substcheck=<includeonly>{{subst:</includeonly><includeonly>substcheck}}</includeonly></syntaxhighlight>'''''
*<code>'''listas'''</code> ''(Required)'' – the 'listas' parameter ''must'' be passed through the template. {{nowrap|''Eg: '''<code><nowiki>listas={{{listas|}}}</nowiki></code>'''''}}
*<code>'''IMAGE_LEFT'''</code> – the ___location of an image to use in the top-left corner of the banner. '''''Do not''''' include the "''File:''" prefix. Images used on WikiProject banners '''''must''''' be free images – [[WP:FU|fair use]] images are '''''not''''' permitted. {{nowrap|''Eg: '''<code>[[:File:Tulipa suaveolens floriade to Canberra.jpg|Tulipa suaveolens floriade to Canberra.jpg]]</code>'''''}}
Line 68:
*<code>'''PORTAL'''</code> – if the WikiProject maintains a [[WP:Portal|portal]], define this parameter with the portal name. The associated image is held centrally at [[Module:Portal/images]]. {{nowrap|''Eg: '''<code><nowiki>Tulips</nowiki></code>'''''}}
*<code>'''MAIN_CAT'''</code> – the default is ''no'' main category created; if defined, all pages displaying the template will be sorted into [[:Category:MAIN_CAT|Category:<code>MAIN_CAT</code>]]. {{nowrap|''Eg: '''<code><nowiki>WikiProject Tulips articles</nowiki></code>''' → [[:Category:WikiProject Tulips articles]]''}}
*<code>'''BOTTOM_TEXT'''</code> – if defined, contains text that will appear across the bottom of the banner and above the [[#Collapsed|collapsed section]] (if one is present)
{{-}}
Line 77:
|PROJECT = Tulips
|substcheck=<includeonly>{{subst:</includeonly><includeonly>substcheck}}</includeonly>
|listas={{{listas|}}}
|PROJECT_LINK = Wikipedia:Somewhere about tulips
Line 90 ⟶ 89:
|PROJECT_LINK = Wikipedia:Somewhere about tulips
|IMAGE_LEFT = Tulipa suaveolens floriade to Canberra.jpg
|IMAGE_LEFT_SIZE = 50px
|MAIN_ARTICLE = [[tulip]]s, [[liliaceae]] and related articles
|category=no
Line 118 ⟶ 117:
|PROJECT = Tulips
|substcheck=<includeonly>{{subst:</includeonly><includeonly>substcheck}}</includeonly>
|listas={{{listas|}}}
|IMAGE_LEFT = Tulipa suaveolens floriade to Canberra.jpg
Line 164 ⟶ 162:
|PROJECT = Tulips
|substcheck=<includeonly>{{subst:</includeonly><includeonly>substcheck}}</includeonly>
|listas={{{listas|}}}
|IMAGE_LEFT = Tulipa suaveolens floriade to Canberra.jpg
Line 227 ⟶ 224:
|PROJECT = Tulips
|substcheck=<includeonly>{{subst:</includeonly><includeonly>substcheck}}</includeonly>
|listas={{{listas|}}}
|IMAGE_LEFT = Tulipa suaveolens floriade to Canberra.jpg
Line 233 ⟶ 229:
|class={{{class|}}}
|tf 1={{{floridiae|}}}
|TF_1_LINK = Wikipedia:
|TF_1_NAME = the Floridiae task force
|TF_1_NESTED = Floridiae
Line 250 ⟶ 246:
|class = FA
|tf 1 = yes
|TF_1_LINK = Wikipedia:
|TF_1_NAME = the Floridiae task force
|TF_1_NESTED = Floridiae
Line 260 ⟶ 256:
|category=no
}}
====Inactive task force====
If a task force has been deemed inactive, then the following parameter and text can be used:
|TF_{{red|''N''}}_TEXT = This _PAGETYPE_ is within the scope of the <nowiki>[[Wikipedia:WikiProject</nowiki> {{red|(name of project)}}/{{red|(name of task force)}}|{{red|(name of task force)}}]], a task force which is currently considered to be <nowiki>'''[[Wikipedia:WikiProject Council/Guide#Dealing with inactive WikiProjects|inactive]]'''</nowiki>.
:where "{{red|''N''}}{{thin space}}" is the number of the task force, and the project and task force names are included where indicated.
==Advanced features==
Line 311 ⟶ 314:
|TODO_TEXT =
|TODO_TITLE =
|TODO_EDITLINKS =
</syntaxhighlight>
|}
There are two main parameters, {{para|TODO_LINK}} and {{para|TODO_TEXT}}. Only one should be used at any time. If the to-do list is located on a different page then <code>TODO_LINK</code> should be used. However, if you've just got some text to include then you can use the <code>TODO_TEXT</code> option instead.
If you are using {{para|TODO_LINK}} and don't want to see the edit links at the top of the textbox, set <code>TODO_EDITLINKS=no</code>.
Line 327 ⟶ 326:
{{#invoke:WikiProject banner|main
|PROJECT = Tulips
|listas={{{listas|}}}
|NAME = The Tulip taskforce
Line 386 ⟶ 384:
==== Optional parameters ====
* <code>'''IM_IMAGE'''</code> – specifies the icon to be used (without the File namespace prefix); the default is [[File:Camera-photo.svg|20px]] (<code><nowiki>[[File:Camera-photo.svg|20px]]</nowiki></code>).
* <code>'''image-type'''</code> – pass through the type which can be used to accommodate other components that are needed, e.g. diagram, equation, map, etc. If this is not specified then "'''image''' or '''photograph'''" is used. E.g. {{para|image-type|<nowiki>{{{type|}}}</nowiki>}}.
* <code>'''image-details'''</code> – to allow an editor to pass more details about the required image, e.g. {{para|image-details|<nowiki>{{{details|}}}</nowiki>}}.
Line 410 ⟶ 408:
</syntaxhighlight>
|}
This
==== Required parameters ====
Line 431 ⟶ 429:
|<syntaxhighlight lang="wikitext">
|a class={{{**PARAMETER**|}}}
|ACR_SUBPAGE_LINK =
|ACR_REVIEW_LINK =
Line 437 ⟶ 434:
|ACR_FAIL_CAT =
|ACR_CURRENT_CAT =
|ACR_PRELOAD =
</syntaxhighlight>
|}
Line 453 ⟶ 451:
*<code>'''ACR_SIZE'''</code> – a custom image size can be set, using the usual note syntax. {{nowrap|''Eg: '''<code><nowiki>20x20px</nowiki></code>''' ''}}
*<code>'''ACR_INVALID_CAT'''</code> – pages specifying the A Class parameter without a valid SUBPAGE_LINK page existing will be categorised into this category.
*<code>'''ACR_PRELOAD'''</code> – preload template, to be used when creating a new A-class review discussion page ([[Wikipedia:WikiProject Military history/Review/A-Class review preload boilerplate|example]]).
=== Additional task force categories ===
Line 501 ⟶ 500:
*<code>'''peer review title'''</code> – If the page has been moved since it was reviewed, pass this parameter to specify the old page title (the one the review was archived under) to make the link point correctly to the review.
*<code>'''PR_INVALID_CAT'''</code> – if defined, pages without a valid existing peer review page will be categorised into this category.
===Custom masks===
{{selfref|For further details, see: [[Template:Class mask/doc]]}}
The module uses a [[mask (computing)|mask]] to normalise the values given to the {{para|class}} parameter, to ensure that invalid inputs are discarded (e.g. {{para|class|cheesecake}}) and that equivalent inputs appear the same (e.g. {{para|class|FA}} and {{para|class|fA}}). This mask effectively controls which extended assessment scale values are accepted by the template (e.g. "Template-Class", "Redirect-Class", etc.). Projects which want to use more obscure assessment classes (e.g. "Future-Class", "Bplus-Class", etc.) or to ''not'' use all of the standard classes (e.g. not using "C-Class") can define their own custom mask, which will override the default. To achieve this, create the mask template in the /class subpage of your project banner template and set {{para|QUALITY_CRITERIA|custom}}. Note that this will remove the project from [[WP:PIQA|project-independent quality
== Inactive WikiProject banners ==
A number of WikiProjects have been identified as ''inactive'' or ''defunct'' (see {{cl|Inactive WikiProjects}}). In this case, the project banner can be given a less prominent form. Keeping an inactive project's template on relevant talkpages helps any group of users who later wishes to revive the project. This template will auto-categorize the project banner into {{cl|Inactive WikiProject banners}}.
▲This meta-template ''automatically'' categorises all instances (i.e. specific project banners) into a subcategory of [[:Category:WikiProject banner templates]]. It is not necessary to include a category link in the documentation for each project banner. Any project banners with errors are automatically added to [[:Category:WikiProject banners with formatting errors]].
The easiest way to convert a banner template to an inactive state, is to replace '''main''' with '''inactive'''.
===Parameters===
* The only required parameter is {{para|PROJECT}} - the name of the WikiProject (but without the word "WikiProject")
* An additional parameter {{para|PROJECT_STATUS}} can be used to identify the status of the inactive project. Currently recognised values are ''inactive'' and ''defunct''. The default is inactive.
* All the other parameters can and should be retained, as this will make it easier to "revive" the project in the future.
==Examples==
<syntaxhighlight lang="wikitext">{{#invoke:WikiProject banner|inactive
|PROJECT = Extreme sports
}}</syntaxhighlight>
:produces:
{{#invoke:WikiProject banner|inactive|PROJECT=Extreme sports|category=no}}
:When inside a banner shell the result is:
{{WikiProject banner shell|
{{#invoke:WikiProject banner|inactive|PROJECT=Extreme sports|category=no}}
▲}}
<syntaxhighlight lang="wikitext">{{#invoke:WikiProject banner|inactive
|PROJECT = Policy and Guidelines
|PROJECT_STATUS = defunct
}}</syntaxhighlight>
:produces:
{{#invoke:WikiProject banner|inactive|PROJECT=Policy and Guidelines|PROJECT_STATUS=defunct|category=no}}
:When inside a banner shell the result is:
{{WikiProject banner shell|
{{#invoke:WikiProject banner|inactive|PROJECT=Policy and Guidelines|PROJECT_STATUS=defunct|category=no}}
}}
==See also==
* {{tl|WikiProject banner shell}} – template to combine multiple WikiProject Banners
* {{tl|WPBannerDoc}} – convenience template that generates standardised parameter documentation for use on the /doc page
Line 524 ⟶ 546:
{{Wikipedia templates}}
<includeonly>{{Sandbox other||
[[Category:Pages related to the WikiProject meta banner|*]]▼
[[Category:WikiProject banner templates|*]]
[[Category:
▲[[Category:Pages related to the WikiProject meta banner|*]]
}}</includeonly>
|