mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-26 09:45:06 +02:00
LibWeb: Fix document element's .scrollHeight and .scrollWidth
We were using the viewport's size as the viewport scrolling area, but those are completely different things.
This commit is contained in:
committed by
Tim Ledbetter
parent
8f139d065c
commit
e8e6dbcee0
Notes:
github-actions[bot]
2025-06-17 16:18:46 +00:00
Author: https://github.com/gmta Commit: https://github.com/LadybirdBrowser/ladybird/commit/e8e6dbcee06 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5121 Reviewed-by: https://github.com/tcl3 ✅
@@ -0,0 +1,16 @@
|
||||
<!DOCTYPE html>
|
||||
<style>
|
||||
#a {
|
||||
background: red;
|
||||
height: 1432px;
|
||||
width: 1234px;
|
||||
}
|
||||
</style>
|
||||
<div id="a"></div>
|
||||
<script src="../include.js"></script>
|
||||
<script>
|
||||
test(() => {
|
||||
println(`document.documentElement.scrollWidth: ${document.documentElement.scrollWidth}`);
|
||||
println(`document.documentElement.scrollHeight: ${document.documentElement.scrollHeight}`);
|
||||
});
|
||||
</script>
|
||||
Reference in New Issue
Block a user