Fix extra vertical scrollbar due to tab padding

This commit is contained in:
nathan 2022-08-03 10:35:53 -06:00
parent e689d0c49d
commit 054ac0fa62

View File

@ -733,13 +733,14 @@ export class et2_historylog extends et2_valueWidget implements et2_IDataProvider
let tab = this.get_tab_info();
if(this.dataview)
{
const style = getComputedStyle(tab.contentDiv);
// -# to avoid scrollbars
this.dataview.resize(
Math.min(
window.innerWidth - 15,
parseInt(getComputedStyle(tab.contentDiv).width)
parseInt(style.width)
) - 5,
parseInt(getComputedStyle(tab.contentDiv).height) - 5
parseInt(style.height) - parseInt(style.paddingTop) - parseInt(style.paddingBottom) - 5
);
}
}