]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/shared/shared-main/angular/infinite-scroller.directive.ts
Increase theme compatibility
[github/Chocobozzz/PeerTube.git] / client / src / app / shared / shared-main / angular / infinite-scroller.directive.ts
index bebc6efa7d06f4fc8809c9de81a4f7d6454eebea..c247cfde2d92f39d0a1a7dced6728a188960d5cf 100644 (file)
@@ -13,6 +13,7 @@ export class InfiniteScrollerDirective implements OnInit, OnDestroy, AfterViewCh
 
   // Add angular state in query params to reuse the routed component
   @Input() setAngularState: boolean
+  @Input() parentDisabled = false
 
   @Output() nearOfBottom = new EventEmitter<void>()
 
@@ -74,7 +75,7 @@ export class InfiniteScrollerDirective implements OnInit, OnDestroy, AfterViewCh
         filter(({ current, maximumScroll }) => (current / maximumScroll) > this.decimalLimit)
       )
       .subscribe(() => {
-        if (this.setAngularState) this.setScrollRouteParams()
+        if (this.setAngularState && !this.parentDisabled) this.setScrollRouteParams()
 
         this.nearOfBottom.emit()
       })