diff --git a/app/pages/learn.vue b/app/pages/learn.vue index 0bb2153..d0834b2 100644 --- a/app/pages/learn.vue +++ b/app/pages/learn.vue @@ -2209,6 +2209,7 @@ function startLessonsForCurrent() { } function goToHub() { + stopAudio() panel.value = 'hub' moduleStage.value = 'lessons' current.value = null @@ -2437,7 +2438,9 @@ if (import.meta.client) { } watch([panel, moduleStage], ([panelValue, stage]) => { - if (panelValue !== 'module' || stage !== 'lessons') { + const inLesson = panelValue === 'module' && stage === 'lessons' + if (!inLesson) { + stopAudio() resetModuleOverviewExpansion() } }) @@ -2897,6 +2900,7 @@ watch(activeLesson, lesson => { }) } } else { + stopAudio() scenario.value = null } }) @@ -3130,6 +3134,7 @@ function attemptUnlockModule(modId: string) { } function openModule(id: string, options: { autoStart?: boolean } = {}) { + stopAudio() const module = modules.value.find(item => item.id === id) || null current.value = module manualErrors.value = []