Template:Meta banner: Difference between revisions
Appearance
vikidiaen>Klipe correction doc |
m 1 revision imported |
(No difference)
|
Latest revision as of 14:02, 11 September 2024
This meta template can be used to harmonise banners. It is meant to build more specialised banner templates. It should not be used directly in articles.
Full syntax
{{Meta banner | print = <!-- value "no" means the banner should not be displayed when printing the page (by default: it should be displayed) --> | mobile = <!-- What gets displayed on mobile view: "no" = nothing, "title" = the title only, "main" = everything except moreTitle and moreContent, "main2" = everything except moreContent (by default: everything) --> | backgroundColour= <!-- Colour of the banner background. Examples: white ; #FFFFFF. See [[Help:Colours]]. Default: transparent. --> | borderColour = <!-- Colour of the banner border. Examples: green ; #008000. See [[Help:Colours]]. Default: transparent. --> | textColour = <!-- Colour of the banner text. Examples: purple ; #800080. See [[Help:Colours]]. --> | bannerStyle = <!-- Additional CSS style for the banner --> | icon = <!-- Name of the image to be used as icon for the banner (without "Image:" or "File:" prefix) --> | iconSize = <!-- The size of the image, in pixels. Example: 50 --> | iconAltText = <!-- Alternate text for the icon image (will be used by screen readers etc.) --> | textUnderIcon = <!-- Text to be displayed under the icon (keep it short!) --> | title = <!-- Text of the banner title --> | titleStyle = <!-- Additional CSS style for the banner title --> | date = <!-- Date when the banner was put on the page. Example: 22 February 2014 --> | text = <!-- Banner text, displayed under the banner title --> | textStyle = <!-- Additional CSS style for the banner text --> | rightContent = <!-- Content to be displayed on the right side of the banner (could be some short text or a second image) --> | moreTitle = <!-- Title of an expandable section at the end --> | moreContent = <!-- Content of an expandable section at the end --> | moreTitleStyle = <!-- Additional CSS style for the title of the expandable section --> | moreContentStyle= <!-- Additional CSS style for the content of the expandable section --> }}
For information on how to specify the colours, see Help:Colours.
Example
This code:
{{Meta banner | mobile =title | backgroundColour= #A277D7 | borderColour = #921496 | icon = VikidiaLogo50px.png | iconAltText = Vikidia | title = You are on [[Vikidia]]. | date = {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}} | text = The encyclopedia for 8 to 13-years-old! }}
...produces this result (switch to Mobile view to see the effect of the parameter "mobile"):
You are on Vikidia. (11 September 2025)
The encyclopedia for 8 to 13-years-old! |