Template:Home/FeaturedArticle/Render
More actions
Inner render for {{Home/FeaturedArticle}}, called via SMW format=template.
Parameters (named args=yes):
- Page — article page name (mainlabel)
- HeroImage — File: name from Has image; may be empty
Image handling lives in {{Module:FeaturedExtract}}'s heroDiv function.
Prefers HeroImage when set, falls back to the first File:... found
in the page wikitext, then to the |image= parameter of the leading
infobox call. Returns empty when none yields an image so no broken
markup renders.
heroDiv detects landscape, square or portrait orientation and emits a
modifier class on the wrapper. CSS in {{Template:Home/Cards - styles/styles.css}}
sets the display width per orientation (400/320/280 px). The thumbnail
size hint is also derived from orientation so retina sharpness holds.
A 3rd argument may be passed to heroDiv to force a thumbnail size.
Markup matches the .home-featured layout in
Template:Home/Cards-styles/styles.css.