diff --git a/src/courseware/course/sequence/Sequence.jsx b/src/courseware/course/sequence/Sequence.jsx index eacdeefd79..a65b1c5a3f 100644 --- a/src/courseware/course/sequence/Sequence.jsx +++ b/src/courseware/course/sequence/Sequence.jsx @@ -144,28 +144,30 @@ const Sequence = ({ const gated = sequence && sequence.gatedContent !== undefined && sequence.gatedContent.gated; const defaultContent = ( -
+
- { - logEvent('edx.ui.lms.sequence.next_selected', 'top'); - handleNext(); - }} - onNavigate={(destinationUnitId) => { - logEvent('edx.ui.lms.sequence.tab_selected', 'top', destinationUnitId); - handleNavigate(destinationUnitId); - }} - previousHandler={() => { - logEvent('edx.ui.lms.sequence.previous_selected', 'top'); - handlePrevious(); - }} - /> - {shouldDisplayNotificationTriggerInSequence && ( - enableNewSidebar === 'true' ? : - )} +
+ { + logEvent('edx.ui.lms.sequence.next_selected', 'top'); + handleNext(); + }} + onNavigate={(destinationUnitId) => { + logEvent('edx.ui.lms.sequence.tab_selected', 'top', destinationUnitId); + handleNavigate(destinationUnitId); + }} + previousHandler={() => { + logEvent('edx.ui.lms.sequence.previous_selected', 'top'); + handlePrevious(); + }} + /> + {shouldDisplayNotificationTriggerInSequence && ( + enableNewSidebar === 'true' ? : + )} +
+ ); }; diff --git a/src/courseware/course/sidebar/SidebarTriggers.jsx b/src/courseware/course/sidebar/SidebarTriggers.jsx index 9ef7b724bb..cdc255d52d 100644 --- a/src/courseware/course/sidebar/SidebarTriggers.jsx +++ b/src/courseware/course/sidebar/SidebarTriggers.jsx @@ -1,5 +1,6 @@ import classNames from 'classnames'; import React, { useContext } from 'react'; +import { breakpoints, useWindowSize } from '@edx/paragon'; import SidebarContext from './SidebarContext'; import { SIDEBAR_ORDER, SIDEBARS } from './sidebars'; @@ -8,6 +9,9 @@ const SidebarTriggers = () => { toggleSidebar, currentSidebar, } = useContext(SidebarContext); + + const isMobileView = useWindowSize().width < breakpoints.small.minWidth; + return (
{SIDEBAR_ORDER.map((sidebarId) => { @@ -15,7 +19,7 @@ const SidebarTriggers = () => { const isActive = sidebarId === currentSidebar; return (
diff --git a/src/courseware/course/sidebar/common/TriggerBase.jsx b/src/courseware/course/sidebar/common/TriggerBase.jsx index 16c2845041..5800fb55c8 100644 --- a/src/courseware/course/sidebar/common/TriggerBase.jsx +++ b/src/courseware/course/sidebar/common/TriggerBase.jsx @@ -8,7 +8,7 @@ const SidebarTriggerBase = ({ children, }) => (