Fix for glitch when resizing window

This commit is contained in:
ernstmul
2025-05-16 16:34:40 +02:00
parent df8425828f
commit 346301eaac
@@ -60,13 +60,16 @@
}
});
$effect(() => {
function recalculateHeights() {
if (terminalOpen === false) {
editorHeight = layoutElement.offsetHeight - 46;
} else if (terminalOpen) {
editorHeight = resizerTopPosition + 1;
terminalHeight = layoutElement.offsetHeight - resizerTopPosition - terminalTabsHeight;
}
}
$effect(() => {
recalculateHeights();
});
function startResize() {
@@ -136,7 +139,7 @@
});
function onViewportResize() {
resizerTopPosition--;
recalculateHeights();
}
</script>