Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Template:GrowingRegionCard: Difference between revisions

Template page
No edit summary
Tag: Reverted
Undo revision 378 by Eloise Zomia (talk)
Tag: Undo
Line 1: Line 1:
<templatestyles src="Template:GrowingRegionCard/styles.css" />
<templatestyles src="Template:GrowingRegionCard/styles.css" />
<!--
Params:
  Page=            (target page for the region)
  RegionName=      (display title; falls back to Page)
  HeroImage=        (File:Name.jpg without the "File:" prefix)
  HeroAlt=          (alt text; falls back to RegionName/Page)
  GPName=          (Gene pool label)
  Basin=            (Basin/landform label)
  Status=          (e.g., Critical / Endangered / Vulnerable / Data Deficient)
  Hook=            (1–2 sentence teaser)
  Areas=            (manual number of growing areas; if omitted, auto-counts a category)
  Accessions=      (manual number of accessions; if omitted, auto-counts a category)
Auto-count conventions (only used when Areas/Accessions are omitted):
  Category:Growing areas in {RegionName}
  Category:Accessions from {RegionName}
-->


<div class="gr-card">
<div class="gr-card">
Line 23: Line 5:
     {{#if:{{{HeroImage|}}}|
     {{#if:{{{HeroImage|}}}|
       {{#ifexist:File:{{{HeroImage}}}|
       {{#ifexist:File:{{{HeroImage}}}|
         <span class="gr-img">[[File:{{{HeroImage}}}|link={{{Page|}}}|alt={{{HeroAlt|{{{RegionName|{{{Page|Untitled region}}}}}}}}}]]</span>
         <span class="gr-img">[[File:{{{HeroImage}}}|link={{{Page|}}}|alt={{{HeroAlt|{{{RegionName|}}}}}}]]</span>
       | <span class="gr-img gr-img--placeholder"></span>}}
       | <span class="gr-img gr-img--placeholder"></span>}}
     | <span class="gr-img gr-img--placeholder"></span>}}
     | <span class="gr-img gr-img--placeholder"></span>}}
Line 34: Line 16:


     <div class="gr-meta">
     <div class="gr-meta">
       {{#if:{{{GPName|}}}|<span class="gr-meta__gp">{{{GPName}}}</span>|}}
       <span class="gr-meta__gp">{{{GPName|}}}</span>
       {{#if:{{{Basin|}}}|<span class="gr-dot">•</span> <span class="gr-meta__basin">{{{Basin}}}</span>|}}
       {{#if:{{{Basin|}}}|<span class="gr-dot">•</span> <span class="gr-meta__basin">{{{Basin}}}</span>|}}
     </div>
     </div>
Line 42: Line 24:
     <div class="gr-pills">
     <div class="gr-pills">
       {{#if:{{{Status|}}}|<span class="pill pill--status">{{{Status}}}</span>|}}
       {{#if:{{{Status|}}}|<span class="pill pill--status">{{{Status}}}</span>|}}
 
       {{#if:{{{Populations|}}}|<span class="pill">Populations: {{{Populations}}}</span>|}}
      <!-- Growing areas -->
      {{#if:{{{Accessions|}}}|<span class="pill">Accessions: {{{Accessions}}}</span>|}}
       <span class="pill">
        Growing areas:
        {{#if:{{{Areas|}}}
          | {{{Areas}}}
          | {{#ifexist:Category:Growing areas in {{{RegionName|{{{Page}}}}}}
              | {{PAGESINCATEGORY:Growing areas in {{{RegionName|{{{Page}}}}}}}}
              | — }} }}
      </span>
 
      <!-- Accessions -->
      <span class="pill">
        Accessions:
        {{#if:{{{Accessions|}}}
          | {{{Accessions}}}
          | {{#ifexist:Category:Accessions from {{{RegionName|{{{Page}}}}}}
              | {{PAGESINCATEGORY:Accessions from {{{RegionName|{{{Page}}}}}}}}
              | — }} }}
      </span>
     </div>
     </div>
   </div>
   </div>
</div>
</div>

Revision as of 11:27, 28 August 2025

   

Untitled region