Jump to content

සැකිල්ල:Russia topic/doc

විකිපීඩියා වෙතින්

This template allows for the quick creation of a navigational template for any group of articles which contains the names of Russian federal subjects. It uses {{Navbox}} to create the navigation box.

Note that this template is NOT an alternative to {{Subdivisions of Russia}}. That template, as its title states, solely concerns subdivisions of Russia and elaborates on that topic in ways this template does not.

{{Russia topic
<!--passed through to Template:Navbox-->
|name       =
|state      = 
|title      = 
|titlestyle =
|bodystyle  = 
|groupstyle = 
<!--specific to Template:Russia topic-->
|prefix =
|suffix =
|exclude-rep =
|exclude-kri =
|exclude-obl =
|exclude-cit =
|exclude-aob =
|exclude-aok =
}}
name
Mandatory when creating a new template (i.e. Template:Hospitals in Russia), otherwise the "view · talk · edit" links will connect to Template:Russia topic. You can enter {{subst:PAGENAME}} for this value as a shortcut.

One of the following combinations is needed to create the links:

prefix
Places text before the state or territory name.
suffix
Places text after the state or territory name.
prefix and suffix
Places text before and after the state or territory name.
state
A navbox with autocollapse will start out collapsed if there are two or more tables on the same page that use collapsible. If set to collapsed, the navbox will always start out in a collapsed state. If set to blank or anything other than autocollapse or collapsed, the navbox will always start out in an expanded state.
Default is: autocollapse.
title
Text that appears centered in the titlebar (the top bar). This is optional because the use of either prefix, suffix or both will automatically generate a title if the title parameter is not supplied. This parameter is not automatically wiki-linked.
navbar*
Defaults to Tnavbar. If set to plain, the v • d • e links on the left side of the titlebar will not be displayed, and padding will be automatically used to keep the title centered. Use off to remove the v • d • e links, but not apply padding (this is for advanced use only; the "plain" option should suffice for most applications where a navbar is not desired). Note that it is highly recommended that one does not hide the navbar, in order to make it easier for users to edit the template, and to keep a standard style across pages.

Excluding groups

[සංස්කරණය]

In some instances, a category of federal subjects may not have their own articles on particular topics. To disable their inclusion in the template and avoid unnecessary red links, add any or all of the following parameters:

exclude-rep
Set to any value this excludes display of the group named Republics which links to Adygea and the other republics.
exclude-kri
Set to any value this excludes display of the group named Krais which links to Altai and the other krais.
exclude-obl
Set to any value this excludes display of the group named Oblasts which links to Amur and the other oblasts.
exclude-cit
Set to any value this excludes display of the group named Federal cities which links to Moscow and St. Petersburg.
exclude-aob
Set to any value this excludes display of the group named Autonomous oblasts which links to Jewish Autonomous Oblast.
exclude-aok
Set to any value this excludes display of the group named Autonomous okrugs which links to Chukotka and the other autonomous okrugs.

Adding groups and lists

[සංස්කරණය]

Some templates may require a list of links not already included in the template. These can be specified as follows:

group1
Header text displayed in cell to left of text specified in list1.
list1
Text or a list of links that is displayed above the ordinary federal subject links.
group8
Header text displayed in cell to left of text specified in list3.
list8
Text or a list of links that is displayed below the state and territory links.
above
A full-width cell (no group header) displayed above the template's body (between the title and state/territory links).
below
A full-width cell (no group header) displayed below the template's body.
titlestyle
Specifies CSS values to apply to the title. One use of this is to set the background color of the title:
titlestyle = background: #0000FF;
titlestyle = background: blue;
Default is: background: #ccccff;
bodystyle
Specifies CSS values to apply to the entire template. This will not override the following {{Navbox}} default styles:
abovestyle = background:#ddddff;
belowstyle = background:#ddddff;
groupstyle = background:#ddddff; text-align:right; white-space:nowrap;
liststyle = width:100%; font-size:95%;
abovestyle
belowstyle
Specifies CSS values to apply to the cell specified via the above and below parameters. For instance:
belowstyle = border-top: #ccccff 1px solid;
Default is: background: #ddddff;
groupstyle
Specifies CSS values to apply to the cells specified via the groupn cells. This option overrides any styles that are applied to the entire table. Example:
groupstyle = background:#6AFB92; vertical-align:top;
Default is: background: #ddddff; text-align:right; white-space:nowrap;
liststyle
Specifies CSS values to apply to the cells specified via the listn cells. This option overrides any styles that are applied to the entire table. Examples:
liststyle = padding: 5px 10px 5px 10px;
Default is: width:100%; font-size:95%;

Creating a new template

[සංස්කරණය]
{{Russia topic
<!--passed through to Template:Navbox-->
| name  = {{subst:PAGENAME}}
| title=History of Russia
<!--specific to Template:Russia topic-->
| prefix = History of
}}<noinclude>
[[Category:Russia topic navigational boxes|{{PAGENAME}}]]
</noinclude>

Note: {{subst:PAGENAME}} in the above example would be replaced by History of Russia when this code is saved in Template:History of Russia.

Result:

Templates implemented with Russia topic

[සංස්කරණය]


"https://si.wikipedia.org/w/index.php?title=සැකිල්ල:Russia_topic/doc&oldid=693953" වෙතින් සම්ප්‍රවේශනය කෙරිණි