Template:HeroHeader: Difference between revisions

From The Largs to Largs Grand Tour
Jump to navigation Jump to search
Created page with "<noinclude> {{Documentation}} ;Purpose :Provides a clean, Vector-friendly hero banner for the Main Page (or other hub pages), without requiring custom CSS. ;Usage :<nowiki>{{HeroHeader|image=|alt=|caption=|link=|width=}}</nowiki> ;Parameters :* <code>image</code> — File name only (e.g. <code>Caravan_Sunset.jpg</code>) :* <code>alt</code> — Alternative text (short) :* <code>caption</code> — Optional caption (short) :* <code>link</code> — Optional link target..."
 
No edit summary
 
(6 intermediate revisions by the same user not shown)
Line 1: Line 1:
<noinclude>
<noinclude>
{{Documentation}}
{{Documentation}}
;Purpose
:Provides a clean, Vector-friendly hero banner for the Main Page (or other hub pages), without requiring custom CSS.
;Usage
;Usage
:<nowiki>{{HeroHeader|image=|alt=|caption=|link=|width=}}</nowiki>
:<nowiki>{{HeroHeader|image=|alt=|caption=|link=|imgwidth=}}</nowiki>
 
 
;Parameters
;Parameters
:* <code>image</code> — File name only (e.g. <code>Caravan_Sunset.jpg</code>)
:* image — File name only (e.g. 1918_camel_caravan.jpg)
:* <code>alt</code> — Alternative text (short)
:* alt — Alternative text
:* <code>caption</code> — Optional caption (short)
:* caption — Optional caption
:* <code>link</code> — Optional link target (defaults to empty / no link)
:* link — Optional link target
:* <code>width</code> Optional display width (defaults to <code>1200px</code>)
:* imgwidth Source image width to request (default 2000px). Larger = higher quality.
 
</noinclude>
 
<includeonly>
</noinclude><includeonly>
<div style="
<div style="margin:0 0 1.0em 0; padding:0; border:1px solid #c8ccd1; background:#f8f9fa;">
  margin:0 0 1.0em 0;
<div style="padding:0; margin:0; line-height:0;">
  padding:4px;
[[File:{{{image|}}}|{{{width|1200px}}}|center|frameless|alt={{{alt|}}}|link={{{link|}}}]]
  border:1px solid #c8ccd1;
  background:#f8f9fa;
  width:100%;
  max-width:100%;
  box-sizing:border-box;
">
<div class="hero-header-image" style="padding:0; margin:0; line-height:0;">
[[File:{{{image|}}}|{{{imgwidth|2000px}}}|frameless|class=hero-img|alt={{{alt|}}}|link={{{link|}}}]]
</div>
</div>
{{#if:{{{caption|}}}|
{{#if:{{{caption|}}}|

Latest revision as of 04:46, 15 January 2026

Usage
{{HeroHeader|image=|alt=|caption=|link=|imgwidth=}}
Parameters
  • image — File name only (e.g. 1918_camel_caravan.jpg)
  • alt — Alternative text
  • caption — Optional caption
  • link — Optional link target
  • imgwidth — Source image width to request (default 2000px). Larger = higher quality.