Template:ArticleCard: Difference between revisions

From AbhiprayaVedi
mNo edit summary
Tags: Reverted 2017 source edit
mNo edit summary
Tag: 2017 source edit
 
(21 intermediate revisions by the same user not shown)
Line 1: Line 1:
<templatestyles src="Template:ArticleCard/styles.css" />
<templatestyles src="Template:ArticleCard/styles.css" />
<div class="article-card">
<div class="article-card">
  <!-- Check if Image1 is provided via named args -->
<!-- 1. Image explicitly at the top --> {{#if: {{{Image1|}}} | <div class="article-thumbnail"> {{{Image1}}} </div> }}
  {{#if: {{{Image1|}}} |  
<!-- 2. Content block below the image -->
    <div class="article-thumbnail">
<div class="article-info">
      {{{Image1|}}}|200px|link={{{1|}}}
<!-- Displayname directly under the image -->
    </div>
<h3 class="article-title">[[{{{ArticlePage|}}}|{{{Displayname|{{{1}}}}}}]]</h3>
  }}
<!-- Intro container using standard CSS clipping mechanics -->
 
{{#if: {{{Intro|}}} |
  <div class="article-info">
<div class="article-intro-wrapper">
    <!-- Displays the Displayname, linked to the real page title ({{{1}}}) -->
<p class="article-intro">{{{Intro|}}}</p>
    <h3 class="article-title">{{{1|}}}|{{{Displayname|{{{1}}}}}}</h3>
</div>
   
}}
    <!-- Show author if it exists -->
<!-- Optional Author photo placeholder -->
    {{#if: {{{Author|}}} | <p class="article-author">{{{Author|}}}</p> }}
{{#if: {{{Authorphoto|}}} | <div class="author-photo-hidden">[[File:{{{Authorphoto}}}|20px]]</div> }}
   
<!-- 3. Author name and date paired in a single bottom row -->
    <!-- Show date if it exists -->
<div class="article-meta-row">
    {{#if: {{{Published date|}}} |  
{{#if: {{{Author|}}} | <span class="article-author">{{{Author|}}}</span> }}
      <p class="article-date">{{#time: j F Y | {{{Published date|}}} | ml }}</p>  
{{#if: {{{Published date|}}} |
    }}
<span class="article-date">{{#time: j F Y | {{{Published date|}}} | ml }}</span>
   
}}
    <!-- Show intro text if it exists -->
</div>
    {{#if: {{{Intro|}}} | <p class="article-intro">{{{Intro|}}}</p> }}
</div>
  </div>
</div>
</div>

Latest revision as of 18:15, 9 June 2026