Difference between revisions of "Template:Maths rating/doc"
imported>MSGJ (→Standard template syntax: update) |
imported>MSGJ (→Usage: simplify/update) |
||
| Line 9: | Line 9: | ||
===Syntax overview=== | ===Syntax overview=== | ||
| − | |||
When using the maths rating template, please set each of the three following parameters: | When using the maths rating template, please set each of the three following parameters: | ||
* Class: choose one: FA, FL, GA, A, B, C, Start, Stub, List, e.g. {{para|class|B}} | * Class: choose one: FA, FL, GA, A, B, C, Start, Stub, List, e.g. {{para|class|B}} | ||
* Priority: choose one: Top, High, Mid, Low, e.g. {{para|priority|high}} | * Priority: choose one: Top, High, Mid, Low, e.g. {{para|priority|high}} | ||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
The following parameters are also available. In general, if you don't know what they mean then you don't need them. | The following parameters are also available. In general, if you don't know what they mean then you don't need them. | ||
* {{para|historical|Y}} for an article on a topic with historical interest. | * {{para|historical|Y}} for an article on a topic with historical interest. | ||
| − | |||
* {{para|vital|Y}} for an article that is in the Vital articles collection. | * {{para|vital|Y}} for an article that is in the Vital articles collection. | ||
* {{para|portal|Y}} for an article that is a [[Portal:Mathematics/Selected article archive|selected article]] on [[Portal:Mathematics]]. | * {{para|portal|Y}} for an article that is a [[Portal:Mathematics/Selected article archive|selected article]] on [[Portal:Mathematics]]. | ||
| − | |||
| − | |||
* {{para|category|no}} if the template is being used as a demonstration and you do not want the page it is on to be added to any categories. | * {{para|category|no}} if the template is being used as a demonstration and you do not want the page it is on to be added to any categories. | ||
| Line 44: | Line 24: | ||
| class= <!--FA, FL, GA, A, B, Start, Stub, List--> | | class= <!--FA, FL, GA, A, B, Start, Stub, List--> | ||
| priority = <!--Top, High, Mid, Low--> | | priority = <!--Top, High, Mid, Low--> | ||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
<!--optional or special purpose--> | <!--optional or special purpose--> | ||
| historical= <!--set to Y for articles on a topic with historical interest--> | | historical= <!--set to Y for articles on a topic with historical interest--> | ||
| − | |||
| vital= <!--set to Y for articles that are in the Vital articles collection; be sure of consensus before setting--> | | vital= <!--set to Y for articles that are in the Vital articles collection; be sure of consensus before setting--> | ||
| portal= <!--set to Y to place the article in Category:Featured articles on Mathematics Portal--> | | portal= <!--set to Y to place the article in Category:Featured articles on Mathematics Portal--> | ||
| − | |||
| − | |||
| category= <!--set to "no" to prevent the template from adding categories to a page--> | | category= <!--set to "no" to prevent the template from adding categories to a page--> | ||
}} | }} | ||
| Line 71: | Line 34: | ||
===Syntax details=== | ===Syntax details=== | ||
The main purpose of this template is to show the classifications of articles on their talk pages, as well as to place talk pages in the appropriate categories. Only the first three parameters are required for this. However, other flags can be used to show additional information and categorize the page further. | The main purpose of this template is to show the classifications of articles on their talk pages, as well as to place talk pages in the appropriate categories. Only the first three parameters are required for this. However, other flags can be used to show additional information and categorize the page further. | ||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
The template also supports a <code>importance</code> parameter which functions identically to <code>priority</code> except for where the template displays the word 'priority' it will instead say 'importance.' Beyond that, there is no reason to use one over the other and no reason to use both together. If they are both used, the <code>importance</code> parameter will be ignored. If the <code>priority</code> parameter is set to blank - if <code>{{!}}priority=</code> appears with no argument - then the code considers this a use of <code>priority</code> and ignores <code>importance</code>, except when assigning categories. | The template also supports a <code>importance</code> parameter which functions identically to <code>priority</code> except for where the template displays the word 'priority' it will instead say 'importance.' Beyond that, there is no reason to use one over the other and no reason to use both together. If they are both used, the <code>importance</code> parameter will be ignored. If the <code>priority</code> parameter is set to blank - if <code>{{!}}priority=</code> appears with no argument - then the code considers this a use of <code>priority</code> and ignores <code>importance</code>, except when assigning categories. | ||
| − | |||
| − | |||
| − | |||
| − | |||
==Notes for editors== | ==Notes for editors== | ||
Revision as of 08:11, 30 October 2020
| 40px | This is a documentation subpage for Template:Maths rating. It contains usage information, categories and other content that is not part of the original template page. |
Contents
Usage
This template is used to categorize and assess articles within WikiProject Mathematics. To classify an article, place the template {{maths rating}} on the article's talk page and fill in the class, priority, and field parameters.
Please do not simply add this template without filling in the parameters. The purpose of this template is to carry article assessment data.
Anyone can add a maths rating or change an existing rating. These parameters will place the article in the appropriate subcategories of Category:Mathematics articles by priority, Category:Mathematics articles by quality and Category:Mathematics articles by field.
Syntax overview
When using the maths rating template, please set each of the three following parameters:
- Class: choose one: FA, FL, GA, A, B, C, Start, Stub, List, e.g.
|class=B - Priority: choose one: Top, High, Mid, Low, e.g.
|priority=high
The following parameters are also available. In general, if you don't know what they mean then you don't need them.
|historical=Yfor an article on a topic with historical interest.|vital=Yfor an article that is in the Vital articles collection.|portal=Yfor an article that is a selected article on Portal:Mathematics.|category=noif the template is being used as a demonstration and you do not want the page it is on to be added to any categories.
Standard template syntax
{{maths rating
| class= <!--FA, FL, GA, A, B, Start, Stub, List-->
| priority = <!--Top, High, Mid, Low-->
<!--optional or special purpose-->
| historical= <!--set to Y for articles on a topic with historical interest-->
| vital= <!--set to Y for articles that are in the Vital articles collection; be sure of consensus before setting-->
| portal= <!--set to Y to place the article in Category:Featured articles on Mathematics Portal-->
| category= <!--set to "no" to prevent the template from adding categories to a page-->
}}
Syntax details
The main purpose of this template is to show the classifications of articles on their talk pages, as well as to place talk pages in the appropriate categories. Only the first three parameters are required for this. However, other flags can be used to show additional information and categorize the page further.
The template also supports a importance parameter which functions identically to priority except for where the template displays the word 'priority' it will instead say 'importance.' Beyond that, there is no reason to use one over the other and no reason to use both together. If they are both used, the importance parameter will be ignored. If the priority parameter is set to blank - if |priority= appears with no argument - then the code considers this a use of priority and ignores importance, except when assigning categories.
Notes for editors
Categories
The |category=no parameter works by surrounding each category with code so that it is only added if the parameter is not set. To add a category somewhere, use
{{#ifeq:{{lc:{{{category|}}} }}|no||<!-- Category added here -->}}
or add it inside the large, already existing section wrapped in the ifeq parser function near the end, where the code for the vital, portal, and historical categories is.
Case-sensitivity
The case-insensitivity for the class and priority is somewhat sensitive. For class, it is assumed that any parameter two or fewer characters long is "intended" to be in all caps (FA, FL, GA), or that the relevant pages and categories linked to have these in their names - for example, Category:FA-Class mathematics articles. It assumes that any longer values are intended to have only the first letter capitalized. For priority, any value except for 'NA' is supposed to have the first letter only capitalized. If adding other values for these parameters, make sure they fit into this scheme or edit the code as needed.
Tables, whitespace, and newlines
The tables in the template have been mostly converted to html-style since the readability benefits of wiki table style are lost when there is so much complexity inside and around the cells, especially since pipes (|) must be replaced with {{!}} inside parser functions and templates. However, two cells require wiki tables inside them. Please be aware that introducing or removing newlines in those areas can break the template, so be careful and test your edits somewhere else first. Also, introducing newlines within <td> tags or outside the <table> tags can change spacing as well. If a particular newline is causing a problem but removing it would make the code much less readable, the newline can be commented out by placing <!-- at the end of the upper line and --> at the beginning of the lower one. You may also wish to view Help:Table and Wikipedia:Line‑break handling for more information.
Categories
The following categories are populated by the field parameter:
- Category:Mathematics articles related to analysis
- Category:Mathematics articles related to algebra
- Category:Mathematics articles related to applied mathematics
- Category:Mathematics articles related to basic mathematics
- Category:Mathematics articles related to discrete mathematics
- Category:Mathematics articles related to foundations, logic, and set theory
- Category:Mathematics articles related to general mathematics
- Category:Mathematics articles related to geometry
- Category:Mathematics articles related to history of mathematics
- Category:Mathematics articles related to mathematical physics
- Category:Mathematics articles related to mathematicians
- Category:Mathematics articles related to number theory
- Category:Mathematics articles related to probability and statistics
- Category:Mathematics articles related to topology
See also
- {{maths banner}}