-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix embeds in Chrome #384
Fix embeds in Chrome #384
Conversation
Size Change: +147 B (0%) Total Size: 3.04 MB
ℹ️ View Unchanged
|
Unfortunately Twitter embeds don't work yet,
|
Explanation from the Chrome issues tab:
Unfortunately it does not make the Twitter embed work. There is this |
WICG/anonymous-iframe#14 gave me the right idea: The sandbox iframe should be credentialless, but the tweet script itself should not be modified. Tweet embeds are working now! |
Just to clarify: this is only for Chrome and browsers that support |
Good explorations here @swissspidy! TIL about |
See #383 — this only fixes YouTube embeds but not Twitter embeds for example
Props @adamziel for the hint
Updates the
MutationObserver
instance to work inside theeditor-canvas__iframe
iframe and apply attributes to the.components-sandbox
iframe as well.Attributes do not need to be added to the YouTube iframe itself apparently.
All I had to do was ensure the
.components-sandbox
iframe has asrc
attribute set, even if it's empty.To-do:
Demo: