Template:CatWeightInfo/doc: Difference between revisions
m (Finalized the documentation for the CatWeightInfo template.) |
m (Syntax ... update more <type> options added, i.e. special text for the section application.) |
||
Line 18: | Line 18: | ||
#'''<tt><nowiki>{{catWeightInfo|<type>|<align>}}</nowiki></tt>''' - Define alignment via <align> parameter. | #'''<tt><nowiki>{{catWeightInfo|<type>|<align>}}</nowiki></tt>''' - Define alignment via <align> parameter. | ||
'''<type>''' = Define the type of weight info box you require: | '''<type>''' = Define the type of weight info box you require: | ||
'''onoff''' | '''onoff''' = The category weight is simply used as an on/off switch | ||
'''worstcase''' = The worst case of category occurrence defines weight. | '''onoffSec''' = Same as onoff, but referring to the complete page/section. | ||
'''amount''' | '''worstcase''' = The worst case of category occurrence defines weight. | ||
'''worstcaseSec''' = Same as worstcase, but referring to the complete page/section. | |||
'''amount''' = The category weight is defined by the occurrence amount (default). | |||
'''amountSec''' = Same as amount, but referring to the complete page/section. | |||
'''<align>''' = Should the info box be aligned? By default it is not a "float". | '''<align>''' = Should the info box be aligned? By default it is not a "float". | ||
Line 27: | Line 30: | ||
'''none / ''' = No entry, or any other entry will *not* align the info box. | '''none / ''' = No entry, or any other entry will *not* align the info box. | ||
{{eyecatch|1|Note|Any <type> entry other than "onoff" or "worstcase" defaults to '''"amount"'''!<br>Any <align> entry other than "left" or "right" defaults to '''no''' alignment!}} | {{eyecatch|1|Note|Any <type> entry other than "onoff" or "worstcase" defaults to '''"amount"'''!<br>Any <align> entry other than "left" or "right" defaults to '''no''' alignment!}} | ||
==Example Category Weight Info Boxes== | ==Example Category Weight Info Boxes== |
Revision as of 08:39, 2 May 2009
Documentation for this template
This template creates three different info boxes explaining how the weights for the current category should be interpreted.
New Choose between the three <type>s, and optionally <align> them.
Alternative names
- {{catWeightInfo|<type>}}
- {{CatWeightInfo|<type>}} - alternate spelling of template
- {{catWeightInfo|<type>|<align>}}
- {{CatWeightInfo|<type>|<align>}} - alternate spelling of template
Syntax
The template can have 1 or 2 parameters:
- {{catWeightInfo|<type>}} - Default mode, no alignment!
- {{catWeightInfo|<type>|<align>}} - Define alignment via <align> parameter.
<type> = Define the type of weight info box you require: onoff = The category weight is simply used as an on/off switch onoffSec = Same as onoff, but referring to the complete page/section. worstcase = The worst case of category occurrence defines weight. worstcaseSec = Same as worstcase, but referring to the complete page/section. amount = The category weight is defined by the occurrence amount (default). amountSec = Same as amount, but referring to the complete page/section. <align> = Should the info box be aligned? By default it is not a "float". left = Aligns the info box to the left of the text. right = Aligns the info box to the right of the text. none / = No entry, or any other entry will *not* align the info box.
Note Any <type> entry other than "onoff" or "worstcase" defaults to "amount"!
Any <align> entry other than "left" or "right" defaults to no alignment!
Example Category Weight Info Boxes
The three <type>s of info boxes
{{CatWeightInfo|onoff}}
|
{{CatWeightInfo|amount}} (this is the default)
|
{{CatWeightInfo|worstcase}} (default align is NONE!)
|
The <align>ment of the info boxes
{{CatWeightInfo|onoff|right}}
|
blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah...
{{CatWeightInfo|amount|left}}
|
blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah...