sroze / ngInfiniteScroll

Infinite Scrolling for AngularJS
http://sroze.github.com/ngInfiniteScroll/
MIT License
2.89k stars 723 forks source link

InfiniteScroll inside a container is not working if that container has ng-scrollbars atached #264

Open mzzovko opened 8 years ago

mzzovko commented 8 years ago

Hi, so I have a page that has div (in the code below that's the one with grid class) that has attached ngscrollbars, and infinite scrolls works in the container as it should only if the container div bottom is below or really close to the bottom border of the window. When I scroll the window down completely, and the bottom of the container is higher than bottom of the window, the loading function isn't called anymore (getNextNews()).

<div ng-scrollbars class="grid">
    <div infinite-scroll="getNextNews()" infinite-scroll-distance="0"
         infinite-scroll-disabled='isBusy()' infinite-scroll-container='".grid"'>
        <div ng-repeat="n in news">
          ....
        </div> 
     </div>
</div>  

So I tried the obvious one, disabling the ng-scrollbars, and then it works like it should, but I have to use that awful default scrollbar inside the container, which is kinda bad. I'm probably missing something obvious, but I can't for the life of me figure it out right now.

mackelito commented 8 years ago

I´m having a similar issue.. did you ever find a solution?

mzzovko commented 8 years ago

Hey, I'm not sure since it was months ago, but I think I resolved it by not using scrollbars, since that was the reason it didn't work.