Template:Deprecated parameters/doc: Difference between revisions

ArrowHead294 (talk | contribs)
mNo edit summary
ArrowHead294 (talk | contribs)
mNo edit summary
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
{{dochead}}
{{dochead}}{{substitute|no}}
The '''Deprecated parameters''' template notifies users that a template's parameters has been replaced by a different one or ones within the same template, or as part of a new template, or simply deprecated (advised to no longer be used) without a replacement.
The '''Deprecated parameters''' template notifies users that a template's parameters has been replaced by a different one or ones within the same template, or as part of a new template, or simply deprecated (advised to no longer be used) without a replacement.


Line 5: Line 5:
By default, the template will appear as such.
By default, the template will appear as such.
<pre>{{Deprecated parameters}}</pre>
<pre>{{Deprecated parameters}}</pre>
{{ {{ROOTPAGENAME}} }}
{{ {{ROOTPAGENAMEE}} }}


A template name and template parameter are passed in as unnamed parameters. This assumes that the parameters in question are deprecated and have no replacement parameters.
A template name and template parameter are passed in as unnamed parameters. This assumes that the parameters in question are deprecated and have no replacement parameters.
<pre>{{Deprecated parameters|Example Template|Scale Info}}</pre>
<pre>{{Deprecated parameters|Example Template|Scale Info}}</pre>
{{{{ROOTPAGENAME}}|Example Template|Scale Info}}
{{{{ROOTPAGENAMEE}}|Example Template|Scale Info}}


Multiple deprecated template parameters are passed into the second unnamed parameter.
Multiple deprecated template parameters are passed into the second unnamed parameter.
<pre>{{Deprecated parameters|Example Template|Scale Info, Key Signature}}</pre>
<pre>{{Deprecated parameters|Example Template|Scale Info, Key Signature}}</pre>
{{{{ROOTPAGENAME}}|Example Template|Scale Info, Key Signature}}
{{{{ROOTPAGENAMEE}}|Example Template|Scale Info, Key Signature}}


One or more replacement parameters can be passed in using the parameter <code>newparams</code>. This assumes the new parameters are part of the same template.
One or more replacement parameters can be passed in using the parameter <code>newparams</code>. This assumes the new parameters are part of the same template.
<pre>{{Deprecated parameters|Example Template|Scale Info|newparams=Step Pattern, Step Ratio}}</pre>
<pre>{{Deprecated parameters|Example Template|Scale Info|newparams=Step Pattern, Step Ratio}}</pre>
{{{{ROOTPAGENAME}}|Example Template|Scale Info|newparams=Step Pattern, Step Ratio}}
{{{{ROOTPAGENAMEE}}|Example Template|Scale Info|newparams=Step Pattern, Step Ratio}}


If the new parameter in question is part of a new template, such as when the functionality of a template is being split into a new template, it can be included using the parameter <code>newtemplate</code>.
If the new parameter in question is part of a new template, such as when the functionality of a template is being split into a new template, it can be included using the parameter <code>newtemplate</code>.
<pre>{{Deprecated parameters|Example Template|Scale Info|newparams=Step Pattern, Step Ratio|newtemplate=Scale Info}}</pre>
<pre>{{Deprecated parameters|Example Template|Scale Info|newparams=Step Pattern, Step Ratio|newtemplate=Scale Info}}</pre>
{{{{ROOTPAGENAME}}|Example Template|Scale Info|newparams=Step Pattern, Step Ratio|newtemplate=Scale Info}}
{{{{ROOTPAGENAMEE}}|Example Template|Scale Info|newparams=Step Pattern, Step Ratio|newtemplate=Scale Info}}


Further details can be given using the parameter <code><nowiki>details</nowiki></code>.
Further details can be given using the parameter <code><nowiki>details</nowiki></code>.
<pre>{{Deprecated parameters|Example Template|Scale Info|newparams=Scale Signature, Step Ratio|newtemplate=Scale Info|details=Editors, please remember to separate the step pattern from the step ratio; for example, "3331331" becomes "LLLsLLs" and "3:1"}}</pre>
<pre>{{Deprecated parameters|Example Template|Scale Info|newparams=Scale Signature, Step Ratio|newtemplate=Scale Info|details=Editors, please remember to separate the step pattern from the step ratio; for example, "3331331" becomes "LLLsLLs" and "3:1"}}</pre>
{{{{ROOTPAGENAME}}|Example Template|Scale Info|newparams=Scale Signature, Step Ratio|newtemplate=Scale Info|details=Editors, please remember to separate the step pattern from the step ratio; for example, "3331331" becomes "LLLsLLs" and "3:1"}}
{{{{ROOTPAGENAMEE}}|Example Template|Scale Info|newparams=Scale Signature, Step Ratio|newtemplate=Scale Info|details=Editors, please remember to separate the step pattern from the step ratio; for example, "3331331" becomes "LLLsLLs" and "3:1"}}


=== Usage ===
=== Usage ===