Skip to content

Conversation

@PaulAdamDavis
Copy link
Member

If the first post has no feature_image, it was still incorrectly displayed as a large card.

This PR adds another conditional to check feature_image exists. With this, the large variation will only be used if:

  • is home page
  • feature_image exists
  • is the first newest post

Before:

1615480077927

After:

1615480135577

@JohnONolan
Copy link
Member

Does this break tag archives? They depend on this code too and look (intentionally) more like the "before" screenshot, in that context

@PaulAdamDavis
Copy link
Member Author

The tag archive has <header class="post-card post-card-large"> hard-coded into it, so is unaffected. This only affects posts within the loop.

Here's a screenshot of this PR in action, on a tag archive:

Screenshot 2021-03-11 at 18 38 39

@JohnONolan
Copy link
Member

aaah, awesome

@JohnONolan JohnONolan merged commit ca36c4f into main Mar 11, 2021
@JohnONolan JohnONolan deleted the fix-index-first-post-no-image branch March 11, 2021 18:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants