Skip to content

Embed Optimizer breaks loading of Post Embeds #1114

@westonruter

Description

@westonruter

Bug Description

When the Embed Optimizer plugin is active, it adds loading=lazy to a Post Embed iframe. Apparently because WordPress styles the initial iframe as pseudo-hidden with clip: rect(1px, 1px, 1px, 1px), Chrome (at least) is interpreting this to mean that the iframe is hidden and thus shouldn't be loaded yet. However, since the iframe never loads, the JS inside the iframe never fires and doesn't communicate with the parent window to show the iframe.

Steps to reproduce

  1. Enable Embed Optimizer
  2. Add a Post Embed
  3. View the post with the embed on the frontend

Screenshots

image

Metadata

Metadata

Labels

[Plugin] Embed OptimizerIssues for the Embed Optimizer plugin (formerly Auto Sizes)[Type] BugAn existing feature is broken

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions