-
Notifications
You must be signed in to change notification settings - Fork 4.6k
Simplify editor.canvas by removing hasIframe
#46986
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
Conversation
|
Size Change: 0 B Total Size: 1.32 MB ℹ️ View Unchanged
|
|
Flaky tests detected in deb36c6. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/3878478325
|
bc1fcc2 to
de99acd
Compare
de99acd to
deb36c6
Compare
talldan
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice improvement 👍
What?
Inspired by #40815 (comment). Simplify
editor.canvasby removing thehasIframeoption and checking the existence of the frame automatically.Why?
It's difficult to reason with when the developer has no experience with it before (#45070 (comment)).
How?
We can just return
this.page.frame( 'editor-canvas' ) || this.pageand expect the same result. As per the doc,editor-canvaswill only match thenameof the frame. So it won't match otherdivs with the same class.Testing Instructions
CI should pass.