WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
38394
Range.getClientRects should work with a collapsed range in an empty text node
https://bugs.webkit.org/show_bug.cgi?id=38394
Summary
Range.getClientRects should work with a collapsed range in an empty text node
Ojan Vafai
Reported
2010-04-30 11:11:52 PDT
Created
attachment 54813
[details]
test case The test case works in Firefox nightlies and as best I can tell, matches the spec:
http://www.w3.org/TR/cssom-view/#dom-range-getclientrects
. Personally, I think we should make this case work even without the text node. It matches IE and fits what developers actually want in practice. The pushback it's gotten has all be that it's complicated to spec. See:
http://lists.w3.org/Archives/Public/www-style/2010Feb/0062.html
In either case, we should start with matching the spec.
Attachments
test case
(603 bytes, text/html)
2010-04-30 11:11 PDT
,
Ojan Vafai
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Benjamin San Souci
Comment 1
2018-01-26 12:43:38 PST
I can repro this bug on safari 11.0.2. And actually I just filed another bug that might be related or be the same bug:
https://bugs.webkit.org/show_bug.cgi?id=182181
Ahmad Saleem
Comment 2
2022-07-27 04:00:07 PDT
I am not sure on web-spec but in attached test case, I get following results across all browsers: *** Safari 15.6 on macOS 12.5 & Chrome Canary 106 *** No clientRects returned from range.getClientRects() *** Firefox Nightly 105 *** top: 21.600006103515625 bottom: 21.600006103515625 left: 8 right: 8 width: 0 height: 0
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug