Merge pull request #2277 from dpalou/MOBILE-3284

MOBILE-3284 tabs: Fix tslint error in isInTransition
main
Dani Palou 2020-02-11 10:19:02 +01:00 committed by GitHub
commit 1411ef0697
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 2 deletions

View File

@ -414,8 +414,9 @@ export class CoreTabsComponent implements OnInit, AfterViewInit, OnChanges, OnDe
slideNext(): void { slideNext(): void {
if (this.showNextButton) { if (this.showNextButton) {
// Stop if slides are in transition. // Stop if slides are in transition.
if (this.isInTransition) if (this.isInTransition) {
return; return;
}
if (this.slides.isBeginning()) { if (this.slides.isBeginning()) {
// Slide to the second page. // Slide to the second page.
@ -444,8 +445,9 @@ export class CoreTabsComponent implements OnInit, AfterViewInit, OnChanges, OnDe
slidePrev(): void { slidePrev(): void {
if (this.showPrevButton) { if (this.showPrevButton) {
// Stop if slides are in transition. // Stop if slides are in transition.
if (this.isInTransition) if (this.isInTransition) {
return; return;
}
if (this.slides.isEnd()) { if (this.slides.isEnd()) {
this.slides.slideTo(this.numTabsShown - this.maxSlides * 2); this.slides.slideTo(this.numTabsShown - this.maxSlides * 2);