I followed the QA steps and found these:
Step 4: After updating WP Rocket to the 3.4.2-alpha 1
our lazyload option was greyed out but still enabled: https://i.vgy.me/aqcIpV.jpg
Step 6: There wasn't any notice in the UI about WP Smush.
WP Smush has a lazyload functionality: https://premium.wpmudev.org/blog/smush-image-lazy-load-free/
When that's enabled in combination to WP Rocket's lazyload, images aren't displayed because of these CSS rules which WP Smuch adds:
CSS
<style>.no-js img.lazyload {
display: none
}
figure.wp-block-image img.lazyloading {
min-width: 150px
}
.lazyload,
.lazyloading {
opacity: 0
}
.lazyloaded {
opacity: 1;
transition: opacity 400ms;
transition-delay: 0ms
}
</style>
Proposed compatibility solution:
Detect if WP Smush is installed and the lazyload feature is activated, and display a notification and/or prevent WP Rocket's lazyload from being activated.
Related ticket: https://secure.helpscout.net/conversation/948513882/121859/
该提问来源于开源项目:wp-media/wp-rocket