Skip to content

Background images set with CSS do not uses the *.webp version if present #414

@masteradhoc

Description

@masteradhoc

Bug Description

We already got a fix at #288 by @mitogh for the featured images - thanks for that! Some time ago i developed a small simple website with gutenberg & generatepress. i tried to use as many default blocks as possible. Some elements are working with the webp replacement as expected - some not yet.

generatepress offers a container block. it allows to choose a image from the library and sets its url into the field
image

the background image is set over css and currently not replaced by a webp image - although one would be available
image

This currently seems to be the only issue left on my testpage where webp images dont get automatically choosen.

Steps to reproduce

  1. Upload jpeg images - implement them as background images over css
  2. install performance plugin, activate webp
  3. use Regenerate Thumbnails plugin to generate the web
  4. See on frontend if they get used as webp or still jpg

Additional Context

  • PHP Version: 8.0
  • OS: Windows
  • Browser: MS Edge
  • Plugin Version: Version 1.2.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    [Plugin] Modern Image FormatsIssues for the Modern Image Formats plugin (formerly WebP Uploads)[Type] BugAn existing feature is brokenmaybelaterIssues to possibly be worked on long-term

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions