mirror of
https://github.com/Ranchero-Software/NetNewsWire
synced 2026-11-28 16:26:04 +00:00
Make negative side margins zero on tables in the overflow wrapper. Fixes #4266.
This commit is contained in:
1 parent
f8126db102
commit
eab6a596e6
1 file changed
+9
@@ -64,6 +64,15 @@ function wrapTables() {
|
||||
wrapper.className = "nnw-overflow";
|
||||
table.parentNode.insertBefore(wrapper, table);
|
||||
wrapper.appendChild(table);
|
||||
|
||||
// A negative side margin — usually from the site's own page layout —
|
||||
// would put part of the table where the wrapper can't scroll to it.
|
||||
if (parseFloat(getComputedStyle(table).marginLeft) < 0) {
|
||||
table.style.marginLeft = "0";
|
||||
}
|
||||
if (parseFloat(getComputedStyle(table).marginRight) < 0) {
|
||||
table.style.marginRight = "0";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user