Jump to content

From Noumenapedia

Template:Navy/doc

__EXPECTED_UNCONNECTED_PAGE__

Usage

Produces a flag icon attached to a wiki-linked "Xxxx National Navy" article, as appropriate for a given country.

Syntax

{{navy|nation|variant|size=optional|name=optional}}

Parameters

  • <syntaxhighlight lang="wikitext" inline style="display: none;" />|nation – Use either the name of the nation or the three-letter ISO 3166-1 alpha-3 country code.
  • <syntaxhighlight lang="wikitext" inline style="display: none;" />|variant (optional) – Specifies an alternate (historical) naval flag to use. This parameter is documented by the appropriate template in Category:Country data templates. Note that the standard behaviour of this template is to use the naval variant if present, so there is no need to specify this variant in the template call.
  • <syntaxhighlight lang="wikitext" inline style="display: none;" />|size= (optional) – Can be used to change the flag icon size.
  • <syntaxhighlight lang="wikitext" inline style="display: none;" />|name= (optional) – Can be used to change the wikilink display text.

Examples

Algeria

Argentina

Australia

Belgium

Canada

China

France

Georgia (country)

Germany

Iceland

India

Italy

Japan

Netherlands

New Zealand

Norway

Panama

Russia / Soviet Union

South Africa

Spain

Thailand

United Kingdom

United States

The {{flag icon}} template can be used to display the naval flag by itself, using the <syntaxhighlight lang="text" class="" style="" inline="1">naval</syntaxhighlight> variant as a template parameter:

Implementation notes

By default, this template shows the standard national flag for the selected country, following by a wikilink to "Country Navy". Both of these items can be changed by adding specific parameters to the appropriate <syntaxhighlight lang="text" class="" style="" inline="1">country_data</syntaxhighlight> template (complete set found in Category:Country data templates).

To use a different flag, such as the naval ensign for the nation, use:

<syntaxhighlight lang="wikitext" inline style="display: none;" />|flag alias-naval=image name of naval ensign

To use a different name for the wikilinked navy article, use:

<syntaxhighlight lang="wikitext" inline style="display: none;" />|link alias-naval=article name

TemplateData

This is the TemplateData for this template used by TemplateWizard, VisualEditor and other tools. See a monthly parameter usage report for Template:Navy in articles based on its TemplateData.

TemplateData for Navy

<templatedata> { "params": { "variant": { "aliases": [ "2" ], "label": "Variant", "description": "Specifies an alternate (historical) naval flag to use. This parameter is documented by the appropriate template in . Note that the standard behaviour of this template is to use the naval variant if present, so there is no need to specify this variant in the template call.", "example": "coast guard", "type": "string" }, "size": { "label": "Size", "description": "Can be used to change the flag icon size" }, "name": { "label": "Name", "description": "Can be used to change the wikilink display text" }, "nation": { "aliases": [ "1" ], "label": "Nation", "description": "The name of the nation or the three-letter ISO 3166-1 alpha-3 country code of the nation to which the navy in question belongs", "example": "USA", "type": "string", "required": true } }, "description": "Produces a flag icon attached to a wiki-linked \"Xxxx National Navy\" article, as appropriate for a given country. ", "paramOrder": [ "nation", "variant", "size", "name" ], "format": "inline" } </templatedata>

See also