Scrolled doesn't work on Fullscreen md-sidenav-container
See original GitHub issueHello, I’m trying to use scroll using the angular material with the md-sidenav-container element with the fullscreen attribute, but the scrolled method is not invoked. Code:
<md-sidenav-container fullscreen>
<div infiniteScroll
[infiniteScrollDistance]="2"
[infiniteScrollUpDistance]="1.5"
[infiniteScrollThrottle]="500"
(scrolled)="onScrolled()">
<router-outlet></router-outlet>
</div>
</md-sidenav-container>
Any idea where I am wrong?
Thanks.
Issue Analytics
- State:
- Created 6 years ago
- Reactions:6
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Router anchorScrolling does not work with Material's mat ...
For the mat-side-nav-container, instead of setting 'height', I set 'min-height' as 100%, so that the scrollable element is the body, and not the ......
Read more >Scrolled doesn't work on Fullscreen md-sidenav-container
Hello, I'm trying to use scroll using the angular material with the md-sidenav-container element with the fullscreen attribute, but the scrolled method is ......
Read more >Sidenav - Angular Material
Reacting to scroll events inside the sidenav container To react to scrolling inside the <mat-sidenav-container> , you can get a hold of the...
Read more >Offcanvas · Bootstrap v5.0
Scrolling the <body> element is disabled when an offcanvas and its backdrop are visible. Use the data-bs-scroll attribute to toggle <body> scrolling and...
Read more >Fix sidenav on large screens not working - MDBootstrap
Double Navigation with a hidden SideNav & fixed Navbar not showing on full screen <ul class="custom-scrollbar list-unstyled" style="max-height:100vh;"> <!
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
hi @orizens i have a similar issue. My setup is a navbar component with mat-sidenav-container and a different component newtask with a table mat-table. I’d like to use inside newtask the infiniteScroll cause the services is inside that component. I tried infiniteScrollContainer in newtask with .sidenav-grid-container (the scrollable div container which is outside newtask.ts). but i got error
The css property overflow only works on display: block with a specified size. I think you’re implementation of md-sidenav-container fullscreen makes use flexbox; consequently, an unspecified height in this case does not allow overflow scroll to work. I just implemented a combination of
<div class="infinite-scroll-shell" onmouseover="document.body.style.overflow='hidden';" onmouseout="document.body.style.overflow='auto';"><router-outlet></router-outlet></div>
I specified a height for the class infinite-scroll-shell. The child component initialized in the router-outlet has the div containing the infiniteScroll directive similar to your code. I would suggest doing a search on “flexbox scroll” for more information.