diff --git a/src/components/lab-notebook/DoubleColumn.vue b/src/components/lab-notebook/DoubleColumn.vue index d041949..4f22574 100644 --- a/src/components/lab-notebook/DoubleColumn.vue +++ b/src/components/lab-notebook/DoubleColumn.vue @@ -14,8 +14,9 @@ onMounted(() => { }) const onScroll = () => { + const maxWidth = scrollWindow.value ? (scrollWindow.value?.scrollWidth - scrollWindow.value?.clientWidth) : 0 if (scrollWindow.value?.scrollLeft == 0) scrollPos.value = 0 - if (scrollWindow.value?.scrollLeft == 247) scrollPos.value = 247 + if (scrollWindow.value?.scrollLeft == maxWidth) scrollPos.value = maxWidth }