Template:Scalable image



From Wikimedia Commons, the free media repository



Jump to navigation  Jump to search  
Template documentationview · edit · history · purge ]
This documentation is transcluded from Template:Scalable image/doc.

This template allows you to include a big image. If the image is too wide, the size of thumbnail frame will be smaller.

Usage

[edit]
{{Scalable image|name|image width|caption|box width|alignment|alt=alt text}}

To hide the tooltip, use |tooltip=no.

To align the caption, use |align-cap=.

To remove the outer frame, use |frame=no.

Example

[edit]

Without caption

[edit]
{{scalable image|Dew on grass Luc Viatour.jpg|2500px|
|alt=Dews on grass}}
Dews on grass

smaller

[edit]
{{scalable image|Dew on grass Luc Viatour.jpg|500px|
|alt=Dews on grass}}
Dews on grass

With caption

[edit]
{{scalable image|Dew on grass Luc Viatour.jpg|2500px|Dews on grass
|alt=Dews on grass}}
Dews on grass
Dews on grass

Without tooltip

[edit]
{{scalable image|Dew on grass Luc Viatour.jpg|2500px|Dews on grass
|alt=Dews on grass
|tooltip=no}}
Dews on grass
Dews on grass

TemplateData

[edit]
 Parameter text is empty
<templatedata>JSON</templatedata> ./. {{TemplateBox}}
TemplateData

TemplateData is a way to store information about template parameters (the description of those and of the whole template) for both humans and machines. It is used by VisualEditor and possibly other tools like Upload Wizard.


Existing template documentation
At Wikimedia Commons, it is recommended to use {{TemplateBox}} with either ‎useTemplateData=1or‎useTemplateData=only on the ‎/doc subpage and transcluding it with {{Documentation}} into the template. ‎<nowiki>-tags can be wrapped around the arguments, if required, to avoid templates being expanded.

Newly created template documentation and imports
Another option, especially for imported templates, or for users with JSON experience, is placing raw ‎<templatedata>-tags into the Wikitext of the template, as described in various Wikipediae.

Discussion
There is an ongoing discussion about that matter. Feel invited to comment if you are experienced in either way, your time permits and if you like to share your opinion or to make a suggestion.


Wikipedia's help about TemplateDataCommons-specific information

Allows you to include a big image. If the image is too wide, the size of thumbnail frame will be smaller.

Template parameters[Edit template data]

ParameterDescriptionTypeStatus
Filename1

Name of the file to display. Example: Dew on grass Luc Viatour.jpg

Stringrequired
Image width2

Give the width in pixels (like: 1600px) that you want the included image to be

Stringrequired
Caption3

A caption for the image that will be shown below image

Stringoptional
Width of frame4

Limit the width of the frame enclosing the picture. Example: "400px" or "40%"

Stringoptional
Frame alignment5 align

Either of: left, right, center or none.

Default
center
Stringoptional
Textual alternativealt

Describes the image's visual appearance to visually disabled readers. Please see WP:ALT for details

Stringoptional
Show tooltiptooltip

Use the value 'no' to make the tooltip of the image not shown inside the frame

Default
yes
Stringoptional

See also

[edit]
Retrieved from "https://commons.wikimedia.org/w/index.php?title=Template:Scalable_image&oldid=765915453"

Categories: 
Templates using TemplateStyles
Templates using TemplateData
Image formatting templates
 


Navigation menu


Personal tools  




English
Not logged in
Talk
Contributions
Create account
Log in
 


Namespaces  




Template
Discussion