Template:Infobox tree/doc: Difference between revisions

Content deleted Content added
Template Data: add descriptions
documenting module param i added
 
(19 intermediate revisions by 10 users not shown)
Line 1:
{{Documentation subpage}}
<!-- Categories go at the bottom of this page and interwikis go in Wikidata. -->
{{Lua|Module:Infobox|Module:InfoboxImage|Module:Check for unknown parameters}}
 
For ''individual'' trees.
{{Infobox tree
|name = General Sherman
|image = United States - California - Sequoia National Park - General Sherman Tree - Panorama.jpg
|image_caption = A view of the General Sherman, the largest single stem tree in the world
|image_size = 128
|map = California
|map_size = 160
|relief = 1
|species = Giant sequoia
|binomial = ''[[Sequoiadendron giganteum]]''
|coordinates = {{coord|36|34|54|N|118|45|05.5|W|region:US_type:landmark|display=inline|format=dms}}
|height = {{Convert|83.8|m|ft|abbr=on}}
|diameter = {{Convert|7.7|m|ft|abbr=on}}
|volume = {{Convert|1487|m3|ft3|abbr=on}}
|seeded = 700–300 BC
}}
 
== Blank template ==
<presyntaxhighlight lang="wikitext" style="width: 48em;">
{{Infobox tree
| name=
Line 19 ⟶ 36:
| label_position=
| map_image=
| native_name=<!-- {{native name}} or {{native name list}} -->
| native_name_lang=
| species=
| binomial=
| ___location=
| height=
| girth=
| diameter=
| volume=
| coordinates=<!-- {{coord|LAT|LON|type:landmark_region:XX|display=inline,title}} -->
| seeded=<!-- {{Start date|YYYY|MM|DD|df=y}} if after XXXX -->
Line 29 ⟶ 49:
| custodian=
| website=<!-- {{URL|example.com}} -->
| module=<!-- Other templates can be embedded here -->
}}
</syntaxhighlight>
</pre>
 
== Parameters ==
; name : Name of the tree
; image : Image of the tree, omitting the [[Help:Link|wikilink brackets]] and the "file:" or "image:"
; image_size : Specify a pixel width for the image.<br /> Example: <code>map_size=230</code> (not <code>map_size=230px</code>).
; alt : [[WP:ALT|Alt text]] for image, for people who can't see the image
; image_caption : Image caption
; map : The name of the map template used to construct ___location map, see [[Template:Location map#Available map templates]] <br /> Example: [[Module:Location map/data/USA Alabama|USA Alabama]].
; map_alt : [[WP:ALT|Alt text]] for image.
; map_size : Specify a pixel width for the map image.<br /> Example: <code>map_size=230</code> (not <code>map_size=230px</code>).
; map_caption : Text displayed below the map image. <br /> Example: FooTown
; relief : Set this to <code>y</code> or any non-blank value to use a [[relief mapping (computer graphics)|relief map]] image provided by the selected ___location map template (if a relief map is available). For additional information, see [[Template:Location map#Relief parameter]].
; label_position : The position of the label on the pushpin ___location map relative to the pushpin mark. Valid values are left, right, top and bottom. This defaults to either left or right, depending on the coordinates of the marker and its position relative to the right border of the map image.
; map_image : Image of a map of the tree, omitting the [[Help:Link|wikilink brackets]] and the "file:" or "image:"
; native_name : Name of the tree in the local language, if different from '''name''' – use {{tl|native name}} or, for multiple names, use {{tl|native name list}}
; species : The common name of the [[List of trees and shrubs by taxonomic family|tree's species]]<br /> Example: "Giant sequoia"
; binomial : The scientific name of the tree's species. Please also include ''italic'' wiki markup and wikilink brackets<br /> Example: <code><nowiki>''[[Sequoiadendron giganteum]]''</nowiki></code>
; ___location : Location of the tree
; height : The [[tree height measurement]]. Use {{Tl|Convert}} to list both metres and feet<br /> Example: <code><nowiki>{{convert|10|m|ft|abbr=on}}</nowiki></code>
; girth : The [[tree girth measurement]]<br/>Example: <code><nowiki>{{convert|10|m|ft|abbr=on}}</nowiki></code>
; diameter : The diameter<br /> Example: <code><nowiki>{{convert|10|m|ft|abbr=on}}</nowiki></code>
; volume : The [[tree volume measurement]]. Use {{Tl|Convert}} to list both cubic metres and cubic feet<br /> Example: <code><nowiki>{{Convert|10|m3|ft3|abbr=on}}</nowiki></code>
; coordinates : Latitude and longitude. Use {{Tl|Coord}}; see that template's documentation for usage information.
; seeded : Date seeded. Use {{Tl|Start date}} if after XXXX
; felled : Date felled, if applicable
; custodian : Custodian of the tree
; website : Official or primary website. Use the template {{tl|URL}}. <br /> Example: <nowiki>{{URL|example.org}}</nowiki>
; module : Other templates can be embedded here.
 
===Mapframe map===
== Microformats ==
A [[Template:Mapframe|Mapframe]] map is automatically included if:
{{UF-hcard-geo}}
* There are coordinates specified on the page's Wikidata item
{{UF-species}}
* It has not been turned off by setting {{para|mapframe|no}}
* Either another type of map has not been set, or {{para|mapframe|yes}} is set
The following parameters are available for adjusting the mapframe map:
{{Infobox mapframe/doc/parameters
|mapframe={{kbd|no}} if a pushpin map or map image is specified, {{kbd|yes}} otherwise
|mapframe-marker={{kbd|museum}}
}}
 
==Template DataTemplateData==
{{TemplateData header}}
<templatedata>
{
"params": {
"name": {},
"image": {"type": "wiki-file-name"},
"description": "Name of tree",
"typeimage_caption": "string"{},
"requiredimage_size": true{},
"map": {},
"imagemap_size": {},
"species": {},
"description": "Image file name (no File: prefix)",
"typebinomial": "wiki-file-name"{},
"suggestedheight": true{},
"diameter": {},
"volume": {},
"image_size": {
"seeded": {
"description": "Width of image (no px required)",
"example": "{{Start date|YYYY|MM|DD|df=y}}"
"type": "string"
},
"alt": {
"description": "Alt string for image",
"type": "string"
},
"image_caption": {
"description": "Caption for image",
"type": "string"
},
"map": {
"description": "Location map for display (e.g., 'Indiana' or 'Russia)",
"type": "string"
},
"map_alt": {
"description": "Alt string for map",
"type": "string"
},
"map_size": {
"description": "Width of map (no px required)",
"type": "string"
},
"map_caption": {
"description": "Caption for map",
"type": "string"
},
"relief": {
"description": "Use relief map (1 for yes)",
"type": "string"
},
"label_position": {
"description": "Position of label near map dot (e.g., 'upper right')",
"type": "string"
},
"map_image": {
"description": "If locator map not used, file name for map image",
"type": "wiki-file-name"
},
"native_name": {
"description": "Native (non-English) name of tree",
"type": "string"
},
"native_name_lang": {
"description": "ISO 639 language code for non-native name (e.g., 'es' for Spanish)",
"type": "string"
},
"species": {
"description": "Vernacular name for species",
"type": "string",
"suggested": true
},
"binomial": {
"description": "Latin name for genus+species",
"type": "string"
},
"___location": {
"description": "Location of tree",
"type": "string"
},
"relief": {},
"coordinates": {
"example": "{{coord|LAT|LON|type:landmark_region:XX|display=inline,title}}"
"description": "coordinate template for ___location",
"type": "wiki-template-name",
"suggested": true
},
"seeded": {
"description": "date of tree germination",
"type": "wiki-template-name"
},
"felled": {
"example": "{{End date|YYYY|MM|DD|df=y}}"
"description": "date of tree felling",
"type": "wiki-template-name"
},
"custodian": {
"description": "custodial organization for tree",
"type": "string"
},
"custodian": {},
"website": {
"example": "{{URL|example.com}}"
"description": "website URL template",
},
"type": "wiki-template-name"
"map_alt": {},
},
"map_caption": {},
"alt": {},
"native_name": {},
"___location": {},
"girth": {},
"label": {},
"label_position": {},
"map_image": {}
},
"paramOrderformat": ["block"
"name",
"image",
"image_size",
"alt",
"image_caption",
"map",
"map_alt",
"map_size",
"map_caption",
"relief",
"label_position",
"map_image",
"native_name",
"native_name_lang",
"species",
"binomial",
"___location",
"coordinates",
"seeded",
"felled",
"custodian",
"website"
]
}
</templatedata>
 
== Microformats ==
{{UF-hcard-geo}}
{{UF-species}}
 
== Tracking category ==
<includeonly>
* {{clc|Pages using infobox tree with unknown parameters}}
<!-- Categories go here, and interwikis go in Wikidata -->
 
</includeonly>{{Sandbox other||
<!-- Categories go here, and interwikis go in Wikidata -->
[[Category:Templates that add a tracking category]]
}}</includeonly>