Template:Navy/doc: Difference between revisions

m 1 revision imported
Examples: expand
 
Line 1: Line 1:
{{Documentation subpage}}<noinclude>{{for|the template documentation of the template that changes text color|Template:Navy (color)/doc}}</noinclude>
{{Documentation subpage}}<noinclude>{{for|the template documentation of the template that changes text color|Template:Navy (color)/doc}}</noinclude>
{{High-use}}


===Usage===
=== Usage ===
Produces a flag icon attached to a wiki-linked "{{Varserif|Xxxx}} National Navy" article, as appropriate for a given country.
Produces a flag icon attached to a wiki-linked "{{Varserif|Xxxx}} National Navy" article, as appropriate for a given country.


;Syntax
==== Syntax ====
:'''{{tlc|navy|nation|variant|size=optional|name=optional}}'''
:; {{tlc|navy|nation|variant|size=optional|name=optional}}


;Parameters
==== Parameters ====
:*{{para|nation}} –  Use either the name of the nation or the three-letter [[ISO 3166-1 alpha-3]] country code
:* {{para|nation}} –  Use either the name of the nation or the three-letter [[ISO 3166-1 alpha-3]] country code
:*{{para|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 <code>naval</code> variant if present, so there is no need to specify this variant in the template call.
:* {{para|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 <code>naval</code> variant if present, so there is no need to specify this variant in the template call.
:*{{para|size}} (optional) –  Can be used to change the flag icon size
:* {{para|size}} (optional) –  Can be used to change the flag icon size
:*{{para|name}} (optional) –  Can be used to change the wikilink display text
:* {{para|name}} (optional) –  Can be used to change the wikilink display text


===Examples===
=== Examples ===
;Algeria
*{{tlc|navy|Algeria}} → {{navy|Algeria}}


;Argentina
==== Algeria ====
*{{tlc|navy|Argentina}} → {{navy|Argentina}}
* {{tlc|navy|Algeria}} → {{navy|Algeria}}
*{{tlc|navy|Argentina|coast guard}} → {{navy|Argentina|coast guard}}


;Australia
==== Argentina ====
*{{tlc|navy|Australia|1913}} → {{navy|Australia|1913}}
* {{tlc|navy|Argentina}} → {{navy|Argentina}}
*{{tlc|navy|Australia}} → {{navy|Australia}}


;Belgium
==== Australia ====
*{{tlc|navy|Belgium|state}} → {{navy|Belgium|state}} (1831-1950)
* {{tlc|navy|Australia|naval-1913}} → {{navy|Australia|naval-1913}} ({{nowrap|1911–1967}})
*{{tlc|navy|Belgium}} → {{navy|Belgium}}
* {{tlc|navy|Australia}} → {{navy|Australia}} (since 1967)


;Canada
==== Belgium ====
*{{tlc|navy|Canada}} → {{navy|Canada}}
* {{tlc|navy|Belgium|state}} → {{navy|Belgium|state}} ({{nowrap|1831–1950}})
*{{tlc|navy|Canada|1921}} → {{navy|Canada|1921}}
* {{tlc|navy|Belgium}} → {{navy|Belgium}}


;China
==== Canada ====
*{{tlc|navy|Qing dynasty}} {{navy|Qing dynasty}}
* {{tlc|navy|Canada|naval-1868|<nowiki>name=Naval Service of Canada</nowiki>}} → {{navy|Canada|naval-1868|name=Naval Service of Canada}} ({{nowrap|1910–1911}})
*{{tlc|navy|CHN}} {{navy|CHN}}
* {{tlc|navy|Canada|naval-1911}} → {{navy|Canada|naval-1911}} ({{nowrap|1911–1965}})
* {{tlc|navy|Canada|naval-1965}} → {{navy|Canada|naval-1965}} ({{nowrap|1965–1968}} and {{nowrap|2011–2013}})
* {{tlc|navy|Canada|naval-1965|<nowiki>name=Canadian Maritime Command</nowiki>}} → {{navy|Canada|naval-1965|name=Canadian Maritime Command}} ({{nowrap|1968–2011}})
* {{tlc|navy|Canada}} → {{navy|Canada}} (since 2013)


;France
==== China ====
*{{tlc|navy|Kingdom of France}} → {{navy|Kingdom of France}}
* {{tlc|navy|Qing dynasty}} → {{navy|Qing dynasty}}
*{{tlc|navy|France|naval-1790}} → {{navy|France|naval-1790}} (1790-94)
* {{tlc|navy|China}} → {{navy|China}}
*{{tlc|navy|France}} → {{navy|France}}
*{{tlc|navy|France|name=Marine Nationale}} → {{navy|France|name=Marine Nationale}}
*{{tlc|navy|Free French}} → {{navy|Free French}}


;Georgia
==== France ====
*{{tlc|Navy|Georgia}} → {{Navy|Georgia}}
* {{tlc|navy|Kingdom of France}} → {{navy|Kingdom of France}}
*{{tlc|navy|Georgia|coast guard}} → {{navy|Georgia|coast guard}}
* {{tlc|navy|France|naval-1790}} → {{navy|France|naval-1790}} ({{nowrap|1790–1794}})
* {{tlc|navy|France}} → {{navy|France}}
* {{tlc|navy|France|<nowiki>name=Marine nationale</nowiki>}} → {{navy|France|name=Marine nationale}}
* {{tlc|navy|Free French}} → {{navy|Free French}}


;Germany
==== Georgia ====
*{{tlc|Navy|German Empire}} → {{Navy|German Empire}}
* {{tlc|naval|Georgia (country)|naval-1997}} → {{naval|Georgia (country)|naval-1997}} (1997 to 2004)
*{{tlc|navy|Weimar Republic}} → {{navy|Weimar Republic}}
* {{tlc|naval|Georgia (country)}} → {{naval|Georgia (country)}} (2004 to 2009)
*{{tlc|Navy|Nazi Germany}} → {{Navy|Nazi Germany}}
* {{tlc|navy|Georgia (country)|coast guard}} → {{navy|Georgia (country)|coast guard}}
*{{tlc|navy|East Germany}} → {{Navy|East Germany}}
* {{tlc|coast guard|Georgia (country)}} → {{coast guard|Georgia (country)}}
*{{tlc|navy|DEU}} → {{navy|DEU}}
*{{tlc|navy|DEU|name=Deutsche Marine}} → {{navy|DEU|name=Deutsche Marine}}


;Iceland
==== Germany ====
*{{tlc|navy|Iceland}} → {{navy|Iceland}}
* {{tlc|navy|German Empire}} → {{navy|German Empire}}
* {{tlc|navy|Weimar Republic}} → {{navy|Weimar Republic}}
* {{tlc|navy|Nazi Germany}} → {{navy|Nazi Germany}}
* {{tlc|navy|East Germany}} → {{navy|East Germany}}
* {{tlc|navy|West Germany}} → {{navy|West Germany}}
* {{tlc|navy|Germany}} → {{navy|Germany}}
* {{tlc|navy|DEU|<nowiki>name=Deutsche Marine</nowiki>}} → {{navy|DEU|name=Deutsche Marine}}


;India
==== Iceland ====
*{{tlc|navy|British Raj}} → {{navy|British Raj}}
* {{tlc|navy|Iceland}} → {{navy|Iceland}}
*{{tlc|navy|India}} → {{navy|India}}


;Italy
==== India ====
*{{tlc|navy|Kingdom of Italy}} {{navy|Kingdom of Italy}}
* {{tlc|navy|British Raj|<nowiki>name=Her Majesty's Indian Marine</nowiki>}} → {{navy|British Raj|name=Her Majesty's Indian Marine}} (1879 to 1892)
*{{tlc|navy|Italy}} → {{navy|Italy}}
* {{tlc|navy|British Raj|<nowiki>name=Royal Indian Marine</nowiki>}} → {{navy|British Raj|name=Royal Indian Marine}} (1892 to 1928)
* {{tlc|navy|British Raj|naval-1928|<nowiki>name=Royal Indian Marine</nowiki>}} → {{navy|British Raj|naval-1928|name=Royal Indian Marine}} (1928 to 1934)
* {{tlc|navy|British Raj|naval-1928}} → {{navy|British Raj|naval-1928}} (1934 to 1947)
* {{tlc|navy|Dominion of India}} → {{navy|Dominion of India}} (1947 to 1950)
* {{tlc|navy|India|naval-1950}} → {{navy|India|naval-1950}} (1950 to 2001)
* {{tlc|navy|India|naval-2001}} → {{navy|India|naval-2001}} (2001 to 2004)
* {{tlc|navy|India|naval-2004}} → {{navy|India|naval-2004}} (2004 to 2014)
* {{tlc|navy|India|naval-2014}} → {{navy|India|naval-2014}} (2014 to 2022)
* {{tlc|navy|India}} → {{navy|India}} (since 2022)


;Japan
==== Italy ====
*{{tlc|navy|Japan}} → {{navy|Japan}}
* {{tlc|navy|Kingdom of Italy}} → {{navy|Kingdom of Italy}}
*{{tlc|navy|Empire of Japan}} → {{navy|Empire of Japan}}
* {{tlc|navy|Italy}} → {{navy|Italy}}


;Netherlands
==== Japan ====
*{{tlc|navy|Netherlands}} → {{navy|Netherlands}}
* {{tlc|navy|Empire of Japan}} → {{navy|Empire of Japan}}
* {{tlc|navy|Japan}} → {{navy|Japan}}


;New Zealand
==== Netherlands ====
*{{tlc|navy|New Zealand|1941}} → {{navy|New Zealand|1941}}
* {{tlc|navy|Netherlands}} → {{navy|Netherlands}}
*{{tlc|navy|New Zealand}} → {{navy|New Zealand}}


;Norway
==== New Zealand ====
*{{tlc|navy|NOR}} → {{navy|NOR}}
* {{tlc|navy|New Zealand|naval-1941}} → {{navy|New Zealand|naval-1941}} (1941 to 1968)
* {{tlc|navy|New Zealand}} → {{navy|New Zealand}} (since 1968)


;Panama
==== Norway ====
*{{tlc|navy|Panama|1958}} → {{navy|Panama|1958}}
* {{tlc|navy|Norway}} → {{navy|Norway}}
*{{tlc|navy|Panama|1984}} → {{navy|Panama|1984}}
* {{tlc|coast guard|NOR}} → {{coast guard|NOR}}
*{{tlc|navy|Panama}} → {{navy|Panama}}


;Russia/Soviet Union
==== Panama ====
*{{tlc|navy|Russian Empire}} → {{navy|Russian Empire}}
* {{tlc|navy|Panama|1958}} → {{navy|Panama|1958}}
*{{tlc|navy|Soviet Union}} → {{navy|Soviet Union}}
* {{tlc|navy|Panama|1984}} → {{navy|Panama|1984}}
*{{tlc|navy|Soviet Union|1935}} → {{navy|Soviet Union|1935}}
* {{tlc|navy|Panama}} → {{navy|Panama}}
*{{tlc|navy|Russia}} → {{navy|Russia}}


;South Africa
==== Russia / Soviet Union ====
*{{tlc|navy|South Africa|1922}} → {{navy|South Africa|1922}} (1922 to 1946)
* {{tlc|navy|Russian Empire}} → {{navy|Russian Empire}} (1712 to 1917)
*{{tlc|navy|South Africa|1946}} → {{navy|South Africa|1946}} (1946 to 1952)
* {{tlc|navy|Russian Republic}} → {{navy|Russian Republic}} (1917 to 1918)
*{{tlc|navy|South Africa|1952}} → {{navy|South Africa|1952}} (1952 to 1981)
* {{tlc|navy|Russian Socialist Federative Soviet Republic|1918}} → {{navy|Russian Socialist Federative Soviet Republic|1918}} (1918 to 1920)
*{{tlc|navy|South Africa|1981}} → {{navy|South Africa|1981}} (1981 to 1994)
* {{tlc|navy|Russian Socialist Federative Soviet Republic}} → {{navy|Russian Socialist Federative Soviet Republic}} (1920 to 1923)
*{{tlc|navy|South Africa}} → {{navy|South Africa}} (since 1994)
* {{tlc|navy|Soviet Union|naval-1924}} → {{navy|Soviet Union|naval-1924}} (1923 to 1935)
* {{tlc|navy|Soviet Union|naval-1935}} → {{navy|Soviet Union|naval-1935}} (1935 to 1950)
* {{tlc|navy|Soviet Union}} → {{navy|Soviet Union}} (1950 to 1992)
* {{tlc|navy|Russia|navy-1992}} → {{navy|Russia|navy-1992}} (1992 to 2000)
* {{tlc|navy|Russia}} → {{navy|Russia}} (since January 1, 2001)


;Spain
==== South Africa ====
*{{tlc|navy|Spain|1506}} {{navy|Spain|1506}} (1506 to 1701)
* {{tlc|navy|Union of South Africa|naval-1922|<nowiki>name=South African Naval Service</nowiki>}} → {{navy|Union of South Africa|naval-1922|name=South African Naval Service}} (1922 to 1940)
*{{tlc|navy|Spain|1701}} {{navy|Spain|1701}} (1701 to 1748)
* {{tlc|navy|Union of South Africa|naval-1922|<nowiki>name=South African Seaward Defence Force</nowiki>}} → {{navy|Union of South Africa|naval-1922|name=South African Seaward Defence Force}} (1940 to 1942)
*{{tlc|navy|Spain|1748}} {{navy|Spain|1748}} (1748 to 1785)
* {{tlc|navy|Union of South Africa|naval-1922|<nowiki>name=South African Naval Forces</nowiki>}} → {{navy|Union of South Africa|naval-1922|name=South African Naval Forces}} (1942 to 1946)
*{{tlc|navy|Spain|1785}} {{navy|Spain|1785}} (1785 to 1873)
* {{tlc|navy|Union of South Africa|naval-1946|<nowiki>name=South African Naval Forces</nowiki>}} → {{navy|Union of South Africa|naval-1946|name=South African Naval Forces}} (1946 to 1951)
*{{tlc|navy|Spain|1873}} {{navy|Spain|1873}} (1873 to 1931)
* {{tlc|navy|Union of South Africa|naval-1946}} → {{navy|Union of South Africa|naval-1946}} (1951 to 1952)
*{{tlc|navy|Spanish Republic}} → {{navy|Spanish Republic}} (1931 to 1938)
* {{tlc|navy|Union of South Africa|naval}} → {{navy|Union of South Africa|naval}} (1952 to 1961)
*{{tlc|navy|Spain|1938}} → {{navy|Spain|1938}} (1938 to 1945)
* {{tlc|navy|South Africa|naval-1952}} → {{navy|South Africa|naval-1952}} (1961 to 1981)
*{{tlc|navy|Spain|1945}} {{navy|Spain|1945}} (1945 to 1977)
* {{tlc|navy|South Africa|naval-1981}} → {{navy|South Africa|naval-1981}} (1981 to 1994)
*{{tlc|navy|Spain|1977}} {{navy|Spain|1977}} (1977 to 1981)
* {{tlc|navy|South Africa}} → {{navy|South Africa}} (since 1994)
*{{tlc|navy|Spain}} {{navy|Spain}} (from 1981)


;Thailand
==== Spain ====
*{{tlc|navy|Thailand}} → {{navy|Thailand}}
* {{tlc|navy|Spain|1506}} → {{navy|Spain|1506}} (1506 to 1701)
* {{tlc|navy|Spain|1701}} → {{navy|Spain|1701}} (1701 to 1748)
* {{tlc|navy|Spain|1748}} → {{navy|Spain|1748}} (1748 to 1785)
* {{tlc|navy|Spain|1785}} → {{navy|Spain|1785}} (1785 to 1873)
* {{tlc|navy|Spain|1873}} → {{navy|Spain|1873}} (1873 to 1931)
* {{tlc|navy|Spanish Republic}} → {{navy|Spanish Republic}} (1931 to 1938)
* {{tlc|navy|Spain|1938}} → {{navy|Spain|1938}} (1938 to 1945)
* {{tlc|navy|Spain|1945}} → {{navy|Spain|1945}} (1945 to 1977)
* {{tlc|navy|Spain|1977}} → {{navy|Spain|1977}} (1977 to 1981)
* {{tlc|navy|Spain}} → {{navy|Spain}} (from 1981)


;United Kingdom
==== Thailand ====
*{{tlc|navy|England}} → {{navy|England}} (16th century to 1706)
* {{tlc|navy|Thailand|naval}} → {{navy|Thailand|naval}}
*{{tlc|navy|Kingdom of Great Britain}} → {{navy|Kingdom of Great Britain}} (1707-1800)
*{{tlc|navy|United Kingdom}} → {{navy|United Kingdom}} (since 1801)
*{{tlc|navy|United Kingdom|RFA}} → {{Navy|United Kingdom|RFA}}
*{{tlc|navy|United Kingdom|RMAS}} → {{Navy|United Kingdom|RMAS}}


;United States
==== United Kingdom ====
*{{tlc|navy|USA|navy}} → {{navy|USA}}
* {{tlc|navy|England}} → {{navy|England}} (16th century to 1706)
*{{tlc|navy|USA|1912}} → {{navy|USA|1912}}
* {{tlc|navy|Kingdom of Great Britain}} → {{navy|Kingdom of Great Britain}} ({{nowrap|1707–1800}})
*{{tlc|coast guard|USA|coast guard}} → {{coast guard|USA|coast guard}}
* {{tlc|navy|United Kingdom}} → {{navy|United Kingdom}} (since 1801)
* {{tlc|navy|United Kingdom|naval-RFA}} → {{navy|United Kingdom|naval-RFA}}
* {{tlc|navy|United Kingdom|naval-RMAS}} → {{navy|United Kingdom|naval-RMAS}}
 
==== United States ====
* {{tlc|navy|USA}} → {{navy|USA}}
* {{tlc|navy|USA|1912}} → {{navy|USA|1912}}
* {{tlc|coast guard|USA|coast guard-1953}} → {{coast guard|USA|coast guard-1953}}


===Related templates===
===Related templates===
The {{tl|flagicon}} template can be used to display the naval flag by itself, using the {{code|naval}} variant as a template parameter:
The {{tl|flagicon}} template can be used to display the naval flag by itself, using the {{code|naval}} variant as a template parameter:
*{{tlc|flagicon|UK|naval}} → {{flagicon|UK|naval}}
* {{tlc|flagicon|UK|naval}} → {{flagicon|UK|naval}}
*{{tlc|flagicon|CHN|naval}} → {{flagicon|CHN|naval}}
* {{tlc|flagicon|CHN|naval}} → {{flagicon|CHN|naval}}
*{{tlc|flagicon|Japan|naval}} → {{flagicon|Japan|naval}}
* {{tlc|flagicon|Japan|naval}} → {{flagicon|Japan|naval}}
*{{tlc|flagicon|Nazi Germany|naval}} → {{flagicon|Nazi Germany|naval}}
* {{tlc|flagicon|Nazi Germany|naval}} → {{flagicon|Nazi Germany|naval}}


===Implementation notes===
===Implementation notes===
Line 137: Line 162:


To use a different flag, such as the naval ensign for the nation, use:
To use a different flag, such as the naval ensign for the nation, use:
:{{para|flag alias-naval|{{Var|image name of naval ensign}}}}
: {{para|flag alias-naval|{{Var|image name of naval ensign}}}}
 
To use a different name for the wikilinked navy article, use:
To use a different name for the wikilinked navy article, use:
:{{para|link alias-naval|{{Var|article name}}}}
: {{para|link alias-naval|{{Var|article name}}}}


===TemplateData===
===TemplateData===
Line 190: Line 216:
*{{tl|Shipboxflag}}
*{{tl|Shipboxflag}}
*{{tl|USN flag}}, providing U.S. Navy flags for any given year.
*{{tl|USN flag}}, providing U.S. Navy flags for any given year.
*{{tl|Air force}}
*{{tl|Army}}


<includeonly>{{Sandbox other|
<includeonly>{{Sandbox other|