Skip to content
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

Workaround for Firefox bug: clear viewbox later #242

Merged
merged 2 commits into from May 28, 2022

Conversation

itamarst
Copy link
Contributor

Fixes #241

@codecov
Copy link

codecov bot commented May 15, 2022

Codecov Report

Merging #242 (fe57e16) into master (e7b8d1e) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #242   +/-   ##
=======================================
  Coverage   87.21%   87.21%           
=======================================
  Files          18       18           
  Lines        2527     2527           
=======================================
  Hits         2204     2204           
  Misses        323      323           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e7b8d1e...fe57e16. Read the comment docs.

@jonhoo
Copy link
Owner

jonhoo commented May 21, 2022

Huh, very interesting. I wonder if this'd be better suited to go in the setTimeout(function() { block slightly lower down, just so it doesn't run on every resize (after all, it doesn't do anything after the first time it's invoked). What do you think?

@itamarst
Copy link
Contributor Author

Other points, beyond the location:

  • Someone pointed out my HTML was in quirks mode, so need to check if fixing that solves this problem.
  • Need to test in Safari now that my new Mac is set up.

I'm trying to remember if I tried it in setTimeout. Possibly not. But there are definitely some rendering race conditions in there that mean setTimeout might not work, will try.

@itamarst
Copy link
Contributor Author

Just validated that disabling quirks mode in my HTML page does not fix the original bug.

@itamarst
Copy link
Contributor Author

And Safari seems happy regardless, both with and without the fix.

@itamarst
Copy link
Contributor Author

Moving to setTimeout seems to also fix the Firefox problem, so I will update PR.

@itamarst
Copy link
Contributor Author

(Going to do a bit more manual testing even after I push the change, I'll let you know when I'm completely convinced.)

Copy link
Owner

@jonhoo jonhoo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent, thank you!

@jonhoo jonhoo merged commit 5148a83 into jonhoo:master May 28, 2022
jonhoo added a commit that referenced this pull request May 28, 2022
@jonhoo
Copy link
Owner

jonhoo commented May 28, 2022

Release in 0.11.4 🎉

itamarst pushed a commit to itamarst/inferno that referenced this pull request Sep 27, 2022
jonhoo added a commit that referenced this pull request Sep 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Firefox rendering bug for SVGs
2 participants