diff --git a/apps/web/components/Pages/Courses/ActivityIndicators.tsx b/apps/web/components/Pages/Courses/ActivityIndicators.tsx index 8d37d0e4..4eef89c9 100644 --- a/apps/web/components/Pages/Courses/ActivityIndicators.tsx +++ b/apps/web/components/Pages/Courses/ActivityIndicators.tsx @@ -235,7 +235,13 @@ function ActivityIndicators(props: Props) { {course.chapters.map((chapter: any, chapterIndex: number) => { const completedActivities = getChapterProgress(chapter.activities); const isChapterComplete = completedActivities === chapter.activities.length; - + const firstActivity = chapter.activities[0]; + const firstActivityId = firstActivity?.activity_uuid?.replace('activity_', ''); + const chapterLinkHref = + firstActivityId + ? getUriWithOrg(orgslug, '') + `/course/${courseid}/activity/${firstActivityId}` + : undefined; + return ( } > -
-
- {chapterIndex + 1} + {chapterLinkHref ? ( + +
+ {chapterIndex + 1} +
+ + ) : ( +
+
+ {chapterIndex + 1} +
-
+ )}
{chapter.activities.map((activity: any) => {