Skip to content
This repository was archived by the owner on Oct 1, 2018. It is now read-only.

Commit 5d2eb98

Browse files
authored
Merge branch 'master' into doc-do-branch
2 parents f7ac77c + 1ed1390 commit 5d2eb98

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/app/operators/components/operator/operator.component.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ export class OperatorComponent implements OnInit {
4141
.subscribe((name: string) => {
4242
if (this.operatorsMap.has(name)) {
4343
this.operator = this.operatorsMap.get(name);
44+
this.scrollToTop();
4445
} else {
4546
this.notfound();
4647
return;
@@ -54,6 +55,14 @@ export class OperatorComponent implements OnInit {
5455
});
5556
}
5657

58+
scrollToTop() {
59+
const content = document.querySelector('.mat-drawer-content');
60+
61+
if (content) {
62+
content.scrollTop = 0;
63+
}
64+
}
65+
5766
get operatorName() {
5867
return this.operator.name;
5968
}

0 commit comments

Comments
 (0)