From 4467fab2a8685d9e70d9e701f719be4c8518e01c Mon Sep 17 00:00:00 2001 From: Simon Rozman Date: Mon, 10 Jun 2024 15:01:10 +0200 Subject: [PATCH] Put back horizontal scrolling option again DOM document is 2-dimensional! What applies to one dimension, may apply to another too. Never assume we're scrolling texts vertically only. --- service2.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/service2.js b/service2.js index c4f35e1..f7607ba 100644 --- a/service2.js +++ b/service2.js @@ -319,7 +319,11 @@ class BesService { this.statusDiv.style.left = `${ rect.right - parentRect.left - 40 - scrollbarWidth }px` - this.statusDiv.style.top = `${rect.bottom - parentRect.top - 30}px` + const scrollbarHeight = + this.hostElement.offsetHeight - this.hostElement.clientHeight + this.statusDiv.style.top = `${ + rect.bottom - parentRect.top - 30 - scrollbarHeight + }px` } /**