Update src/pages/course/[slug]/index.js

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
This commit is contained in:
Austin Kelsay 2025-04-24 13:53:24 -05:00 committed by austinkelsay
parent 176a58d42d
commit f3d667a0ba
No known key found for this signature in database
GPG Key ID: 5A763922E5BA08EE

View File

@ -604,9 +604,12 @@ const Course = () => {
activeIndex={activeIndex}
onLessonSelect={(index) => {
handleLessonSelect(index);
if (isMobileView) {
toggleTab(getTabItems().findIndex(item => item.label === 'Content'));
}
onLessonSelect={(index) => {
handleLessonSelect(index);
if (isMobileView) {
setActiveTab('content'); // Use the tab name directly
}
}}
}}
completedLessons={completedLessons}
isMobileView={isMobileView}