Jump to content

Template:Wn/shn/Infobox table

From Wikimedia Incubator
field value
[edit] ၽိုၼ်ၵႅမ်မိုဝ်း ထႅမ်းပလဵတ်ႉ

လွင်ႈၸႂ်ႉတိုဝ်း

This template generates a wikitable of data for customizing the infobox for a give category, as generated by template {{Wn/shn/Infobox}}. The customizing table for a category Foobar should be placed in a page called Template:Infobox/lookup/Foobar.

Format the call to this template like this:

{{infobox table|
|image=Example.svg
|image heading=An example image.  {{Image|[[Commons:User:Nethac DIU|Nethac DIU]]}}
}}

specifying whichever of the customizing parameters you want (in this example, image and image heading). Following is a list of the recognized customizing parameters, as of this writing, with their meanings and default values. Caveat: these default values apply to fields not specified by a table; not to be confused with the behavior of {{Wn/shn/Infobox}} when there is no table specific to the category of the infobox.

parameter default what it does
label If non-blank, the label on the category link at the top of the infobox.
list heading Related articles Appears just above the list of recently published articles in the category.
list dates If non-blank, publication dates are listed for the listed articles.
list length 5 How many articles to list.
image heading If non-blank, this heading is placed just above the main image.
image If not=blank, the main image.
image size available width The width for display of the main image. Available width is 200px if unpadded, 196px if padded (irregular or with heading).
image caption The caption for the image, visible as a mouseover.
image irregular If non-blank, the image is non-rectangular, so a little extra space should be left around it to avoid odd appearance.
image padding If non-blank, the specified amount of extra space is left around the image; supersedes image irregular.
image at top If non-blank, the main image is placed above the article list rather than below. Leave this blank if there is no main image.
bottom image If non-blank, an image to display at the very bottom of the infobox.
bottom image size 60px The width for display of the bottom image.
image n
  for 2≤n≤12
If non-blank, an alternative main image; selected by rotation via {{Wn/shn/Infobox/select}}.

Ordinarily, the page that calls {{Wn/shn/Infobox table}} is automatically added to Category:Infobox tables. Passing a non-blank value to template parameter nocat suppressed this categorization.

Internals

This template generates a wikitable, which is parsed by {{Wn/shn/Infobox}}; but {{Wn/shn/Infobox}} does not itself interpret the parameters or even validate them, it just passes whatever it finds to {{Wn/shn/Infobox/p1}}, as an S-exression. {{Wn/shn/Infobox/p1}} validates the parameters and passes them as template parameters to {{Wn/shn/Infobox/p2}}, which is responsible for using them to build the infobox. If it becomes needful to add to or otherwise change the set of valid parameters, the following templates are the ones that need to be modified: {{Wn/shn/Infobox table}} (and its documentation, above); {{Wn/shn/Infobox/p1}}; {{Wn/shn/Infobox/p2}}; and, if the number of selectable images changes, {{Wn/shn/Infobox/select}}.

တူၺ်းပႃး