RESOLVED FIXED 200776
IntersectionObserverEntry#intersectionRatio can be larger than 1
https://bugs.webkit.org/show_bug.cgi?id=200776
Summary IntersectionObserverEntry#intersectionRatio can be larger than 1
Tim Guan-tin Chien [:timdream]
Reported 2019-08-15 11:18:14 PDT
Created attachment 376398 [details] test case STR: Load the minimal test case. the callback will put the intersectionRatio on the page. Expected: The intersectionRatio should be exactly 1 in this case because the element is entirely in the viewport. Actual: It's 1.0270270109176636. The spec states it should be a number between 0 and 1. https://w3c.github.io/IntersectionObserver/#dom-intersectionobserverentry-intersectionratio This is also reproducible on Chrome but not Firefox.
Attachments
test case (657 bytes, text/html)
2019-08-15 11:18 PDT, Tim Guan-tin Chien [:timdream]
no flags
Patch (5.71 KB, patch)
2019-09-13 08:54 PDT, Ali Juma
no flags
Tim Guan-tin Chien [:timdream]
Comment 1 2019-08-15 11:19:41 PDT
Tested on Release 89 (Safari 13.1, WebKit 14609.1.1)
Tim Guan-tin Chien [:timdream]
Comment 2 2019-08-15 11:25:23 PDT
Tim Guan-tin Chien [:timdream]
Comment 3 2019-08-15 13:20:08 PDT
Still producible on WebKit Nightly Version 12.1.2 (14607.3.9, 609+)
Radar WebKit Bug Importer
Comment 4 2019-08-15 16:26:54 PDT
Ali Juma
Comment 5 2019-09-13 08:54:10 PDT
WebKit Commit Bot
Comment 6 2019-09-13 11:47:01 PDT
Comment on attachment 378731 [details] Patch Clearing flags on attachment: 378731 Committed r249845: <https://trac.webkit.org/changeset/249845>
WebKit Commit Bot
Comment 7 2019-09-13 11:47:03 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.