Page MenuHomePhabricator

Thumbnails are too small due to background-size for an icon
Closed, ResolvedPublic

Description

Due to background-size: 40px 40px; being set in RelatedArticles styles, thumbnails get displayed at a significantly smaller size than they should be. background-size: 40px 40px; was set so that an icon when a thumbnail doesn’t get loaded was displayed at 2× size, but it unintentionally affected the thumbnails.

Demo / steps to reproduce:

  1. Go to https://ru.wikipedia.org/wiki/Варга-Катарылькы#footer
  2. Wait for RelatedArticles to load
  3. See this:

Event Timeline

Change 527613 had a related patch set uploaded (by Saint Johann; owner: Saint Johann):
[mediawiki/extensions/RelatedArticles@master] Fix background-size on thumbnails

https://gerrit.wikimedia.org/r/527613

@stjn the proposed solution works, but on pages like Barack Obama it makes thumbnails bit too big, thumbnails get cropped, thus sometimes people faces do not fit into the thumbnail div.

Example before:


After:

Merge is still pending and is not ready for QA.

Change 527613 merged by jenkins-bot:
[mediawiki/extensions/RelatedArticles@master] Fix background-size on thumbnails

https://gerrit.wikimedia.org/r/527613