Discourse doesn't load rest of topic list in tall window
-
I opened up the front page of Discourse, and it loaded the topic list:
However, note that it only loads part. And where it should be loading more topics because it's at the bottom of the page, it doesn't. (Resolution: 1200x1920.)
If I load it in a shorter window, then when I scroll down, it loads more topics. My suspicion is that it waits until some point scrolls onto the view without regard to the fact that it might start on the view. I am also 99% sure that this is new behavior and it hasn't behaved this way for long.
(I guess I shouldn't be so surprised, considering that just scrolling with page down doesn't do the right thing with high frequency in a tall window because it doesn't take into account the window size when determining to load more posts. But at least that's just annoying and doesn't make Discourse completely break.)
-
Knowing Jeff, we can probably assume something to do with "not 16:9" and "insufficient market share", with a side of "that's different".
Because they probably haven't considered portrait monitors. I assume it works on 3:4, though, because iPad.
-
Have you tried a "Restore Down" as a workaround?
Note: can't tell if that's a maximized screen you have posted.
-
It was, and of course that works. If you resize it smaller and scroll down before maximizing again. Just making it smaller then maximizing again
won'tsometimes will and sometimes won't cause it to load (when it gets bigger again), depending on where you're scrolled to when smaller.(Technically I can't restore down, because I'm using a tiling window manager. But I can still make it be smaller.)
-
it's been reported before on meta.d
it was acknowledged as a bug and as i recall that's the last we heard of it. someone who isn't on her lunch break like me might even look that thread up and link it for you, or maybe i will once my lunch break ends.
(i don't like visiting meta.d, that makes it work related, right?)
-
-
that's the ones! thanks PJH!
-
here u go
-
The fact that atleast one of the guys behind Discourse is considering 'issuing a fake scroll event' as the fix should tell you all you need to know.
The way you fix this properly is ofcourse to check the bounding client rectangle using the
getBoundingClientRect
function. The bounding rectangle is given in window space coordinates meaning you need only compare the bottom of the last item in the list to the window height to figure out if you've scrolled 'beyond the end of the list'...
-
That's the wonder of InfinniScroll!*
*not actually infinite. Results may vary. Offer void in Nebraska. Before using InfinniScroll, consult your physician or other qualified health care personell.