Difference between revisions of "Template:Infobox constituency/doc"
Jump to navigation
Jump to search
imported>AquaDTRS (added basic blank version, update some param descriptions) |
imported>AquaDTRS (updated documentation) |
||
| Line 1: | Line 1: | ||
{{Documentation subpage}} | {{Documentation subpage}} | ||
<!-- Categories and interwikis go at the bottom of this page. --> | <!-- Categories and interwikis go at the bottom of this page. --> | ||
| − | |||
| − | This template is used to provide an infobox for electoral | + | This template is used to provide an infobox for [[electoral district]]s. |
== Usage == | == Usage == | ||
| Line 16: | Line 15: | ||
|map_size | |map_size | ||
|image | |image | ||
| + | |image_size | ||
|map_entity | |map_entity | ||
|map_year | |map_year | ||
| Line 45: | Line 45: | ||
|map_size = | |map_size = | ||
|image = | |image = | ||
| + | |image_size = | ||
|map_entity = | |map_entity = | ||
|map_year = | |map_year = | ||
| Line 77: | Line 78: | ||
|map_size | |map_size | ||
|image | |image | ||
| + | |image_size | ||
|map_entity | |map_entity | ||
|map_year | |map_year | ||
| Line 129: | Line 131: | ||
|map_size = | |map_size = | ||
|image = | |image = | ||
| + | |image_size = | ||
|map_entity = | |map_entity = | ||
|map_year = | |map_year = | ||
| Line 174: | Line 177: | ||
== Parameters == | == Parameters == | ||
| − | + | The following are parameters used in the infobox: | |
{| class="wikitable" | {| class="wikitable" | ||
|- | |- | ||
| Line 183: | Line 186: | ||
|<code>type</code>|| The type of electoral district. | |<code>type</code>|| The type of electoral district. | ||
|- | |- | ||
| − | |<code>constituency_link</code>|| The wikilink to the | + | |<code>constituency_link</code>|| The wikilink to the constituency. |
|- | |- | ||
|<code>parl_name</code>|| The wikilinked name of the Parliament. | |<code>parl_name</code>|| The wikilinked name of the Parliament. | ||
|- | |- | ||
| − | |<code>map1, map2, map3 | + | |<code>map1, map2, map3, map4</code> |
| Filename of map images. Up to 4 maps can be displayed. | | Filename of map images. Up to 4 maps can be displayed. | ||
|- | |- | ||
|<code>map_size</code>|| The map size in pixels. | |<code>map_size</code>|| The map size in pixels. | ||
|- | |- | ||
| − | |<code>map_year</code>|| The year the map boundaries were drawn for a general election | + | |<code>map_year</code>|| The year the map boundaries were drawn for a general election. |
|- | |- | ||
| − | |<code>image, image2, | + | |<code>image, image2, image3, image4</code> |
| Filename of images. Up to 4 images can be displayed. | | Filename of images. Up to 4 images can be displayed. | ||
|- | |- | ||
| − | |<code> | + | |<code>image_size</code>|| The image size in pixels. |
| + | |- | ||
| + | |<code>caption, caption2, caption3, caption4</code> | ||
| Caption for the displayed images. | | Caption for the displayed images. | ||
|- | |- | ||
| − | |<code>district_label</code>|| | + | |<code>district_label</code>||(optional) A replacement label for the <code>district</code> parameter, otherwise shows as 'District'. |
|- | |- | ||
|<code>district</code> | |<code>district</code> | ||
| − | | | + | | The district(s) in which the constituency is located at. |
|- | |- | ||
|<code>region_label</code> | |<code>region_label</code> | ||
| − | | | + | | (optional) A replacement label for the <code>region</code> parameter, otherwise shows as 'Region'. |
|- | |- | ||
| − | |<code>region</code>|| | + | |<code>region</code>|| The region, state or province in which the constituency is located at. |
|- | |- | ||
|<code>population</code> | |<code>population</code> | ||
| − | | | + | | The total population within the constituency. |
|- | |- | ||
|<code>electorate</code> | |<code>electorate</code> | ||
| − | | | + | | The number of eligible voters within the constituency. |
|- | |- | ||
| − | |<code>towns</code>|| | + | |<code>towns</code>|| A list of towns within the constituency. |
|- | |- | ||
|<code>future</code> | |<code>future</code> | ||
| − | | (optional) If set to any value, the sub-header will display as 'Future constituency' | + | | (optional) If set to any value, the sub-header will display as 'Future constituency'. |
|- | |- | ||
|<code>year</code> | |<code>year</code> | ||
| The year the constituency was first established. | | The year the constituency was first established. | ||
|- | |- | ||
| − | |<code>abolished_label</code>|| | + | |<code>abolished_label</code>|| (optional) A replacement label for the <code>abolished</code> parameter, otherwise shows as 'Abolished'. |
|- | |- | ||
|<code>abolished</code> | |<code>abolished</code> | ||
| Line 230: | Line 235: | ||
|- | |- | ||
|<code>members_label</code> | |<code>members_label</code> | ||
| − | | | + | | (optional) A replacement label for the <code>members</code> parameter, otherwise shows as 'Member(s)'. |
|- | |- | ||
| − | |<code>members</code>|| | + | |<code>members</code>|| The number of people governing the constituency. |
|- | |- | ||
|<code>seats</code> | |<code>seats</code> | ||
| − | | | + | | The number of seats in Parliament represented by the constituency. |
|- | |- | ||
|<code>elects_howmany</code> | |<code>elects_howmany</code> | ||
| − | | | + | | The number of people elected to Parliament by the constituency. |
|- | |- | ||
|<code>party_label</code> | |<code>party_label</code> | ||
| − | | | + | |(optional) A replacement label for the <code>party</code> parameter, otherwise shows as 'Party'. |
|- | |- | ||
|<code>party</code> | |<code>party</code> | ||
| Line 247: | Line 252: | ||
|- | |- | ||
|<code>local_council_label</code> | |<code>local_council_label</code> | ||
| − | | | + | | (optional) A replacement label for the <code>local_council</code> parameter, otherwise shows as 'Local council'. |
| + | |- | ||
| + | |<code>local_council</code>|| The name of the local council or office in charge of the constituency. | ||
|- | |- | ||
| − | |<code> | + | |<code>previous</code> |
| + | | The name of the previous electoral district in which the current electoral district was carved out or merged from. | ||
|- | |- | ||
|<code>next</code> | |<code>next</code> | ||
| The name of the new electoral district carved out or merged from the current electoral district. | | The name of the new electoral district carved out or merged from the current electoral district. | ||
|- | |- | ||
| − | + | |<code>blank1_name, blank2_name, blank3_name, blank4_name</code>|| (optional) Labels for the extra parameters. | |
| − | |||
| − | |||
| − | |<code>blank1_name, blank2_name, blank3_name, blank4_name</code>|| | ||
|- | |- | ||
| − | |<code>blank1_info, blank2_info, blank3_info, blank4_info</code>|| | + | |<code>blank1_info, blank2_info, blank3_info, blank4_info</code>|| (optional) Extra parameters. |
|- | |- | ||
|} | |} | ||
| + | |||
| + | == Example == | ||
<includeonly>{{Sandbox other|| | <includeonly>{{Sandbox other|| | ||
Revision as of 17:40, 3 July 2020
| 40px | This is a documentation subpage for Template:Infobox constituency. It contains usage information, categories and other content that is not part of the original template page. |
This template is used to provide an infobox for electoral districts.
Usage
Basic Version
This is a basic version of the template that is suitable for general use; most optional parameters have been removed. Template:Parameter names example
{{Infobox constituency
|name =
|type =
|constituency_link =
|parl_name = <!-- name of the law making body -->
|map1 =
|map_size =
|image =
|image_size =
|map_entity =
|map_year =
|caption =
|district =
|region =
|population =
|electorate =
|towns =
|future =
|year = <!-- year of establishment -->
|abolished =
|members =
|seats =
|elects_howmany =
|party =
|local_council =
|next =
|previous =
}}
Full Blank Template
This is the full version of the template with all its optional parameters displayed. Template:Parameter names example
{{Infobox constituency
|name =
|type =
|constituency_link =
|parl_name = <!-- name of the law making body -->
|map1 =
|map_size =
|image =
|image_size =
|map_entity =
|map_year =
|caption =
|map2 =
|image2 =
|caption2 =
|map3 =
|image3 =
|caption3 =
|map4 =
|image4 =
|caption4 =
|district_label = <!-- can be State/Province, region, county -->
|district =
|region_label = <!-- can be State/Province, region, county -->
|region =
|population =
|electorate =
|towns =
|future =
|year = <!-- year of establishment -->
|abolished_label =
|abolished =
|members_label =
|members =
|seats =
|elects_howmany =
|party_label = <!-- defaults to "Party" -->
|party =
|local_council_label =
|local_council =
|next =
|previous =
|blank1_name =
|blank1_info =
|blank2_name =
|blank2_info =
|blank3_name =
|blank3_info =
|blank4_name =
|blank4_info =
}}
Parameters
The following are parameters used in the infobox:
| Parameter | Description |
|---|---|
name |
The name of the electoral district. |
type |
The type of electoral district. |
constituency_link |
The wikilink to the constituency. |
parl_name |
The wikilinked name of the Parliament. |
map1, map2, map3, map4
|
Filename of map images. Up to 4 maps can be displayed. |
map_size |
The map size in pixels. |
map_year |
The year the map boundaries were drawn for a general election. |
image, image2, image3, image4
|
Filename of images. Up to 4 images can be displayed. |
image_size |
The image size in pixels. |
caption, caption2, caption3, caption4
|
Caption for the displayed images. |
district_label |
(optional) A replacement label for the district parameter, otherwise shows as 'District'.
|
district
|
The district(s) in which the constituency is located at. |
region_label
|
(optional) A replacement label for the region parameter, otherwise shows as 'Region'.
|
region |
The region, state or province in which the constituency is located at. |
population
|
The total population within the constituency. |
electorate
|
The number of eligible voters within the constituency. |
towns |
A list of towns within the constituency. |
future
|
(optional) If set to any value, the sub-header will display as 'Future constituency'. |
year
|
The year the constituency was first established. |
abolished_label |
(optional) A replacement label for the abolished parameter, otherwise shows as 'Abolished'.
|
abolished
|
The year the constituency was abolished. If the parameter is used, the infobox header will include the word 'Former'. |
members_label
|
(optional) A replacement label for the members parameter, otherwise shows as 'Member(s)'.
|
members |
The number of people governing the constituency. |
seats
|
The number of seats in Parliament represented by the constituency. |
elects_howmany
|
The number of people elected to Parliament by the constituency. |
party_label
|
(optional) A replacement label for the party parameter, otherwise shows as 'Party'.
|
party
|
The governing party of the electoral district. |
local_council_label
|
(optional) A replacement label for the local_council parameter, otherwise shows as 'Local council'.
|
local_council |
The name of the local council or office in charge of the constituency. |
previous
|
The name of the previous electoral district in which the current electoral district was carved out or merged from. |
next
|
The name of the new electoral district carved out or merged from the current electoral district. |
blank1_name, blank2_name, blank3_name, blank4_name |
(optional) Labels for the extra parameters. |
blank1_info, blank2_info, blank3_info, blank4_info |
(optional) Extra parameters. |