Browse Source

WebUI: Fix duplicate scrollbar on Transfer List

The overlay scrollbars introduced in Firefox 100 take up no space,
breaking the existing overflow detection.
Add an extra check for `scrollHeight != clientHeight` which is able to
detect an overflow independent of scrollbar style.

PR #19779.

---------

Co-authored-by: Chocobo1 <Chocobo1@users.noreply.github.com>
adaptive-webui-19844
AgentConDier 1 year ago committed by GitHub
parent
commit
bf95eb50da
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      src/webui/www/private/scripts/dynamicTable.js

3
src/webui/www/private/scripts/dynamicTable.js

@ -111,7 +111,8 @@ window.qBittorrent.DynamicTable = (function() { @@ -111,7 +111,8 @@ window.qBittorrent.DynamicTable = (function() {
let n = 2;
while (panel.clientWidth != panel.offsetWidth && n > 0) { // is panel vertical scrollbar visible ?
// is panel vertical scrollbar visible or does panel content not fit?
while (((panel.clientWidth != panel.offsetWidth) || (panel.clientHeight != panel.scrollHeight)) && (n > 0)) {
--n;
h -= 0.5;
$(this.dynamicTableDivId).style.height = h + 'px';

Loading…
Cancel
Save