diff --git a/src/courseware/course/sidebar/sidebars/outline/OutlineSidebar.jsx b/src/courseware/course/sidebar/sidebars/outline/OutlineSidebar.jsx index ee0660c514..304fef863f 100644 --- a/src/courseware/course/sidebar/sidebars/outline/OutlineSidebar.jsx +++ b/src/courseware/course/sidebar/sidebars/outline/OutlineSidebar.jsx @@ -17,6 +17,15 @@ function OutlineSidebar({ unitId, } = useContext(SidebarContext); const outlineUrl = `${getConfig().SIDEBAR_MFE_BASE_URL}/${courseId}/${unitId}`; + const savedScrollPosition = window.scrollY; + let allowScroll = true; + window.addEventListener('scroll', () => { + if (allowScroll) { + window.scrollTo(0, savedScrollPosition); + } + allowScroll = false; + }); + return (