diff --git a/src/core/course/pages/section/section.html b/src/core/course/pages/section/section.html index 63a0a5553..6c2eac5a3 100644 --- a/src/core/course/pages/section/section.html +++ b/src/core/course/pages/section/section.html @@ -17,7 +17,7 @@ - + diff --git a/src/core/course/pages/section/section.ts b/src/core/course/pages/section/section.ts index f236ae11f..020741e74 100644 --- a/src/core/course/pages/section/section.ts +++ b/src/core/course/pages/section/section.ts @@ -37,7 +37,7 @@ import { CoreTabsComponent } from '@components/tabs/tabs'; templateUrl: 'section.html', }) export class CoreCourseSectionPage implements OnDestroy { - @ViewChild(Content) content: Content; + @ViewChild('courseSectionContent') content: Content; @ViewChild(CoreCourseFormatComponent) formatComponent: CoreCourseFormatComponent; @ViewChild(CoreTabsComponent) tabsComponent: CoreTabsComponent; @@ -304,7 +304,11 @@ export class CoreCourseSectionPage implements OnDestroy { this.loadData().finally(() => { this.dataLoaded = true; - this.content.scrollTo(scrollLeft, scrollTop); + + // Wait for new content height to be calculated and scroll without animation. + setTimeout(() => { + this.content.scrollTo(scrollLeft, scrollTop, 0); + }); }); }