Summary: Implement StaticRange and makes it and Range inherits AbstractRange
Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1444847
Link to Standards: https://dom.spec.whatwg.org/#abstractrange
https://dom.spec.whatwg.org/#staticrange
Platform coverage: all
Estimated or target release: 69 (or later if we'd meet web-comoat issue)
Preference behind which this will be implemented: none
Is this feature enabled by default in sandboxed iframes? Yes
DevTools bug: N/A
Do other browser engines implement this? a little bit complicated, see
below.
web-platform-tests: Only interface existence is tested.
Is this feature restricted to secure contexts? No
StaticRange is simpler range than Range (nsRange internally). Different
from Range, StaticRange does not modify its start boundary nor end
boundary when the DOM tree is modified. In other words, StaticRange
keeps storing start and end boundaries when it's created. This is
currently implemented by Chrome, Safari and Edge. This was declared
with constructor but current it's explicitly removed.
AbstractRange is common interface of Range and StaticRange. This also
does not have constructor. Chrome supports this interface.
Both of them cannot be created from WebAPI for now. StaticRange will be
used as result of InputEvent.getTargetRanges().
https://w3c.github.io/input-events/#dom-inputevent-gettargetranges
So, we just exposes the interfaces for now, but I think that nobody uses
this for feature detection.
--
Masayuki Nakano <masay...@d-toybox.com>
Working on DOM, Events, editor and IME handling at Mozilla
_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform