See: https://www.software.hixie.ch/utilities/js/live-dom-viewer/?saved=13680
<!DOCTYPE html>
<div id=outer style="overflow: scroll; width: 100px; height: 100px;">
<div id=inner style="height: 0px; padding-bottom: 30px;">
<div style="height: 200px;">
</div>
<script>
console.log(outer.scrollHeight);
console.log(inner.scrollHeight);
</script>
Blink/WebKit will report the same value of scrollHeight for both inner & outer (the reason being this is what inner contributes to outer). Firefox is attempting to follow the spec in: https://drafts.csswg.org/cssom-view/#scrolling-area
The "scrolling-area" definition doesn't match the definition in "css-overflow-3" here: https://drafts.csswg.org/css-overflow-3/#scrollable-overflow-region
This is bad :).
Tests affected are:
- external/wpt/css/cssom-view/scrollWidthHeight-contain-layout.html
- external/wpt/css/cssom-view/scrollWidthHeightWhenNotScrollable.xht
Tests were modified in: https://phabricator.services.mozilla.com/D231087 by @emilio
IMO the definition of "scrolling-area" in cssom-view should be removed and point to css-overflow-3.
Ian