Skip to content

Add support for a smaller non-square image size in the Largo Recent Posts widget, and other widgets that have images #1865

@benlk

Description

@benlk

Largo Recent Posts:

https://github.com/INN/largo/blob/590181982d22a5444eb3c5ccca58ea8b56db12f7/inc/widgets/largo-recent-posts.php#L204-L212

Largo Series Posts:

https://github.com/INN/largo/blob/590181982d22a5444eb3c5ccca58ea8b56db12f7/inc/widgets/largo-series-posts.php#L128-L136

Right now, there are four image sizes:

  • none
  • small 60x60
  • medium 140x140
  • large full

But Largo supports so many more:

https://github.com/INN/largo/blob/590181982d22a5444eb3c5ccca58ea8b56db12f7/functions.php#L262-L268

  • Provide a function that outputs a list of <options>s for each image size registered with Largo/WordPress (whichever is easier) and the associated image sizes (if possible) so that we can use images larger than 140x140 yet smaller than 771px or full.
  • (optional) Ensure that the option values are backwards-compatible with Largo versions prior to this release
  • Include appropriate srcsets in this area, if there's a solution to Apply a filter to the wp_calculate_image_sizes to enable sizes attribute for srcsets #1577. If not, punt.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions