Template:Portal bar/doc: Difference between revisions
Richardpruen (talk | contribs) m (1 revision imported) |
imported>Lemondoge (Added a pinch of template data.) |
||
Line 9: | Line 9: | ||
== Usage == | == Usage == | ||
{{xref|See {{section link|Module:Portal|Image}} on how to add, update, or remove portal images.}} | {{xref|See {{section link|Module:Portal|Image}} on how to add, update, or remove portal images.}} | ||
=== Border === | === Border === | ||
Line 23: | Line 16: | ||
=== No border === | === No border === | ||
For a version with no border | For a version with no border: | ||
: → <code><nowiki>{{Portal bar|Biology|Fungi|Plants|Science|border=n}}</nowiki></code> | : → <code><nowiki>{{Portal bar|Biology|Fungi|Plants|Science|border=n}}</nowiki></code> | ||
{{Portal bar|Biology|Fungi|Plants|Science|border=n}} | {{Portal bar|Biology|Fungi|Plants|Science|border=n}} | ||
Line 35: | Line 28: | ||
# Tracking is specially disabled for that usage. This is done by setting the optional parameter {{para|tracking}} to any the following values: <code><nowiki>no</nowiki></code>, <code><nowiki>n</nowiki></code>, <code><nowiki>false</nowiki></code> | # Tracking is specially disabled for that usage. This is done by setting the optional parameter {{para|tracking}} to any the following values: <code><nowiki>no</nowiki></code>, <code><nowiki>n</nowiki></code>, <code><nowiki>false</nowiki></code> | ||
# The template is used on a page in any of these namespaces: Talk, User, User talk, Wikipedia talk, File talk, Template talk, Category talk, Portal talk, Draft, Draft talk, Module talk | # The template is used on a page in any of these namespaces: Talk, User, User talk, Wikipedia talk, File talk, Template talk, Category talk, Portal talk, Draft, Draft talk, Module talk | ||
# The title page on which the template is used includes any of the following case-insensitive strings: "/archive", "/doc", "/test" | # The title page on which the template is used includes any of the following case-insensitive strings: "/archive", "/doc", "/test", "/sandbox" | ||
* {{clc|Portal templates with too few portals}} | |||
* | * {{clc|Portal templates with redlinked portals}} | ||
* | * {{clc|Pages with empty portal template}} | ||
* | |||
:{{Purge page|''Purge page to update totals''}} | :{{Purge page|''Purge page to update totals''}} | ||
Line 70: | Line 62: | ||
}, | }, | ||
"border": { | "border": { | ||
"type": " | "type": "boolean", | ||
"description": "Set this to \"no\" if you do not want to display a border around the portals. You can also use \"n\", \"false\", or \"0\"." | "description": "Set this to \"no\" if you do not want to display a border around the portals. You can also use \"n\", \"false\", or \"0\".", | ||
"default": "Yes" | |||
} | } | ||
}, | }, | ||
Line 80: | Line 73: | ||
== See also == | == See also == | ||
* {{tl|Order}} | |||
* {{tl|Portal}} | * {{tl|Portal}} | ||
* {{tl|Portal-inline}} | * {{tl|Portal-inline}} | ||
* {{tl|Subject bar}} | * {{tl|Subject bar}} | ||
<includeonly>{{Sandbox other|| | <includeonly>{{Sandbox other|| | ||
[[Category:Internal link templates]] | [[Category:Internal link templates]] | ||
[[Category:Wikipedia Portal navflags]] | [[Category:Wikipedia Portal navflags]] | ||
}}</includeonly> | }}</includeonly> |
Latest revision as of 16:05, 13 April 2023
This is a documentation subpage for Template:Portal bar. It may contain usage information, categories and other content that is not part of the original template page. |
This template is used on approximately 110,000 pages. To avoid major disruption and server load, any changes should be tested in the template's /sandbox or /testcases subpages, or in your own user subpage. The tested changes can be added to this page in a single edit. Consider discussing changes on the talk page before implementing them. |
This template does not belong in the "See also" section. Per MOS:SECTIONORDER, this template is bottom matter and goes below standard navigation templates, and above geographical coordinates and authority control templates. |
The primary purpose of this template is for when using {{portal}} would cause formatting problems. This template forms a horizontal bar instead of a vertical, sidebar-like template. Please note that this template does not belong in the "See also" section.
This template uses Lua: |
Usage
Border
To add the template to a page:
- →
{{Portal bar|Biology|Fungi|Plants|Science}}
Lua error in mw.title.lua at line 318: bad argument #2 to 'title.new' (unrecognized namespace name 'Portal').
No border
For a version with no border:
- →
{{Portal bar|Biology|Fungi|Plants|Science|border=n}}
Lua error in mw.title.lua at line 318: bad argument #2 to 'title.new' (unrecognized namespace name 'Portal').
Portal bar with border extends to the full width of the article, and that can be a problem with right-floating items. To use space better, remove the border.
Error tracking
If the template is used incorrectly, the page will be added to a tracking category.
The tracking categories are not applied if any of the following is true:
- Tracking is specially disabled for that usage. This is done by setting the optional parameter
|tracking=
to any the following values:no
,n
,false
- The template is used on a page in any of these namespaces: Talk, User, User talk, Wikipedia talk, File talk, Template talk, Category talk, Portal talk, Draft, Draft talk, Module talk
- The title page on which the template is used includes any of the following case-insensitive strings: "/archive", "/doc", "/test", "/sandbox"
- Category:Portal templates with too few portals (0)
- Category:Portal templates with redlinked portals (0)
- Category:Pages with empty portal template (0)
TemplateData
TemplateData documentation used by VisualEditor and other tools
| |||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
This template adds a bar of portals. It is usually used just above an article's navboxes or in its "See also" section when using [[Template:Portal]] would cause formatting problems.
|
See also
- {{Order}}
- {{Portal}}
- {{Portal-inline}}
- {{Subject bar}}