Difference between revisions of "Template:High-risk"

From "PTTLink Wiki"
Jump to navigation Jump to search
Mediawiki>MusikAnimal
m (1 revision imported)
 
m (1 revision imported)
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
#REDIRECT [[Template:High-use]]
+
<noinclude>
 +
<languages/>
 +
</noinclude>{{#switch:<translate></translate>
 +
| =
 +
{{ombox
 +
| type = content
 +
| image = [[File:OOjs UI icon alert-warning.svg|40px|alt=]]
 +
| imageright =
 +
| text = {{#switch:{{NAMESPACE}}
 +
  |Module={{#if:{{{1|}}}
 +
    |'''<translate><!--T:3--> This Lua module is used on approximately <tvar name=5>{{formatnum:{{{1}}}}}</tvar> pages.</translate>'''
 +
    |'''<translate><!--T:9--> This Lua module is used on many pages.</translate>'''
 +
    }}<!--/#if-->
 +
  |#default={{#if:{{{1|}}}
 +
    |'''<translate><!--T:10--> This template is used on approximately <tvar name=5>{{formatnum:{{{1}}}}}</tvar> pages.</translate>'''
 +
    |'''<translate><!--T:11--> This template is used on many pages.</translate>'''
 +
    }}<!--/#if-->
 +
  }}<!--/#switch--><br />
 +
{{#switch:{{NAMESPACE}}
 +
  |Module=<translate><!--T:2--> To avoid large-scale disruption and unnecessary server load, any changes to this module should first be tested in its [[<tvar name=4>{{#switch:{{SUBPAGENAME}}|doc|sandbox={{SUBJECTSPACE}}:{{BASEPAGENAME}}|#default={{SUBJECTPAGENAME}}}}/sandbox</tvar>|/sandbox]] or [[<tvar name=5>{{#switch:{{SUBPAGENAME}}|doc|sandbox={{SUBJECTSPACE}}:{{BASEPAGENAME}}|#default={{SUBJECTPAGENAME}}}}/testcases</tvar>|/testcases]] subpages.</translate>
 +
  |#default=<translate><!--T:12--> To avoid large-scale disruption and unnecessary server load, any changes to this template should first be tested in its [[<tvar name=4>{{#switch:{{SUBPAGENAME}}|doc|sandbox={{SUBJECTSPACE}}:{{BASEPAGENAME}}|#default={{SUBJECTPAGENAME}}}}/sandbox</tvar>|/sandbox]] or [[<tvar name=5>{{#switch:{{SUBPAGENAME}}|doc|sandbox={{SUBJECTSPACE}}:{{BASEPAGENAME}}|#default={{SUBJECTPAGENAME}}}}/testcases</tvar>|/testcases]] subpages or in your own [[<tvar name=9>Special:MyLanguage/Help:Subpages#Use of subpages</tvar>|user subpage]].</translate>
 +
}}<!--/#switch-->
 +
<translate><!--T:1--> The tested changes can then be added to this page in one single edit.</translate>
 +
{{#if:{{{2|}}}
 +
  |<translate><!--T:4--> Please consider discussing any changes at <tvar name=2>[[{{trim|{{{2}}}}}]]</tvar> before implementing them.</translate>
 +
  |<translate><!--T:13--> Please consider discussing any changes on the [[<tvar name=3>{{#switch:{{SUBPAGENAME}}|doc|sandbox={{TALKSPACE}}:{{BASEPAGENAME}}|#default={{TALKPAGENAME}}}}</tvar>|talk page]] before implementing them.</translate>
 +
  }}<!--/#if-->
 +
}}<!--/ombox-->
 +
| #default=
 +
  {{#invoke:Template translation|renderTranslatedTemplate|template=Template:High-risk|noshift=1|uselang={{int:lang}}}}
 +
}}<noinclude>
 +
{{Documentation|content=
 +
 
 +
This is the {{tl|high-risk}} message box. It is meant to be put at the top of the documentation page on the most high-use (high-risk) templates and Lua modules (the template detects the name space), i.e., for templates used on a large number of pages
 +
 
 +
'''''Note:''''' It is normal that some of the links in the message box are red.
 +
<translate>
 +
=== Usage === <!--T:5-->
 +
</translate>
 +
The template can be used as is. But it can also take some parameters:
 +
 
 +
* First parameter is the number of pages.
 +
* Second parameter is the name of some other talk page if you want discussion to be made there instead. But a better option might be to redirect the talkpage of your template to that other talkpage.
 +
 
 +
<translate>
 +
===Examples=== <!--T:6-->
 +
</translate>
 +
<pre>
 +
{{high-risk| 30,000+ | Project:Village Pump}}
 +
</pre>
 +
 
 +
{{high-risk| 30,000+ | Project:Village Pump}}
 +
 
 +
<pre>
 +
{{high-risk| 30,000+ }}
 +
</pre>
 +
 
 +
{{high-risk| 30,000+ }}
 +
 
 +
<pre>
 +
{{high-risk| | Project:Village Pump}}
 +
</pre>
 +
 
 +
{{high-risk| | Project:Village Pump}}
 +
 
 +
The full code for a /doc page top may look like this:
 +
 
 +
<pre>
 +
{{documentation subpage}}
 +
<!-- Categories go where indicated at the bottom of this page, please; interwikis go to Wikidata (see also: [[Wikipedia:Wikidata]]). -->
 +
{{high-risk| 30,000+ }}
 +
</pre>
 +
 
 +
<translate>
 +
=== Technical details === <!--T:7-->
 +
</translate>
 +
The [[{{translatable}}/sandbox|/sandbox]] and [[{{translatable}}/testcases|/testcases]] links are the standard names for such subpages. If those pages are created then the green /doc box for the template will detect them and link to them in its heading. For instance see the top of this documentation.
 +
 
 +
<translate>
 +
=== See also === <!--T:8-->
 +
</translate>
 +
* {{tl|intricate template}} – For the intricate, i.e., complex templates.
 +
* {{tl|pp-template}} – The protection template that usually is put on high-risk templates.
 +
* {{tl|used in system}} – For templates used in the user interface.
  
{{Rcat shell|
 
{{Wikidata redirect}}
 
{{R from merge}}
 
{{R from template shortcut}}
 
 
}}
 
}}
 +
</noinclude>

Latest revision as of 23:14, 5 September 2021

<languages/>

Template documentationpurge ]

This is the {{high-risk}} message box. It is meant to be put at the top of the documentation page on the most high-use (high-risk) templates and Lua modules (the template detects the name space), i.e., for templates used on a large number of pages

Note: It is normal that some of the links in the message box are red. <translate>

Usage

</translate> The template can be used as is. But it can also take some parameters:

  • First parameter is the number of pages.
  • Second parameter is the name of some other talk page if you want discussion to be made there instead. But a better option might be to redirect the talkpage of your template to that other talkpage.

<translate>

Examples

</translate>

{{high-risk| 30,000+ | Project:Village Pump}}
{{high-risk| 30,000+ }}
{{high-risk| | Project:Village Pump}}

The full code for a /doc page top may look like this:

{{documentation subpage}}
<!-- Categories go where indicated at the bottom of this page, please; interwikis go to Wikidata (see also: [[Wikipedia:Wikidata]]). -->
{{high-risk| 30,000+ }}

<translate>

Technical details

</translate> The [[

Translate this file This SVG file contains embedded text that can be translated into your language, using any capable SVG editor, text editor or the SVG Translate tool. For more information see: About translating SVG files.
/sandbox|/sandbox]] and [[
Translate this file This SVG file contains embedded text that can be translated into your language, using any capable SVG editor, text editor or the SVG Translate tool. For more information see: About translating SVG files.
/testcases|/testcases]] links are the standard names for such subpages. If those pages are created then the green /doc box for the template will detect them and link to them in its heading. For instance see the top of this documentation.

<translate>

See also

</translate>

  • {{intricate template}} – For the intricate, i.e., complex templates.
  • {{pp-template}} – The protection template that usually is put on high-risk templates.
  • {{used in system}} – For templates used in the user interface.