Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Images in posts can throw off PostStream scroll #395

Open
Fastidious opened this issue Aug 31, 2015 · 10 comments
Open

Images in posts can throw off PostStream scroll #395

Fastidious opened this issue Aug 31, 2015 · 10 comments

Comments

@Fastidious
Copy link

I posted this on Gitter. I can't really express with words what's going on, other than to say that clicking on topics will not take me to the last comment in it, and that trying to go to the most recent comment takes clicking twice. Screen cap follows:

Navigation bug

@tobyzerner
Copy link

I've noticed this at times too, but it's one of those ones that are difficult to reproduce consistently. We'll get to the bottom of it eventually though!

@franzliedke
Copy link

I often see a jump with the result of not seeing the first unread post when the discussion contains images (which seem to be loaded after jumping to the correct place in the discussion).

@tobyzerner
Copy link

@franzliedke That is indeed another issue (but I don't think it's the cause of the problems in the screencap above). How would we fix that, though? Maybe we could set an onload handler to anchor the scroll position when we render the posts?

@franzliedke
Copy link

Yep, sounds like the only solution.

@franzliedke
Copy link

I just stumbled across this library, that should fix the image load scrolling behavior: https://github.com/changbenny/scrollbear

@askvortsov1
Copy link
Sponsor Member

Possible duplicate of flarum/framework#285?

@askvortsov1
Copy link
Sponsor Member

Fixed in flarum/framework#2160

@askvortsov1 askvortsov1 changed the title Navigation bug Images in posts can throw off PostStream scroll Oct 2, 2020
@askvortsov1
Copy link
Sponsor Member

Actually, I'll reopen this for now as afaik we haven't tested the effects of the new changes on posts with images that load after the posts have loaded.

@askvortsov1 askvortsov1 reopened this Oct 2, 2020
@matteocontrini
Copy link

This is related to #261 as well.

Also: since this issue was created, Chrome and Firefox introduced scroll anchoring, which should have reduced this issue a lot.

@matteocontrini
Copy link

matteocontrini commented Feb 28, 2021

I'm posting here because I think this isn't actually related to images. I have a user reporting that this is still happening to him even in discussions where there are no recent images, and the behaviour he's seeing is exactly the one of the GIF in the first post (where I see no images, anyway). He clicks a discussion with unread posts and he's brought to 20-30 messages above the actual message he should be pointed to.

I'm running beta.15 with commits d59a5922609c012d3cba2148e498d78737ed4b07 and 30c4c139eb15c1f9bf809b58be5a2d4c918cc6ae cherry-picked, which have to do with the PostStream. The user is using Chrome on Android/desktop. I haven't personally seen this issue recently, but apparently it's still there even after recent improvements.

@askvortsov1 askvortsov1 transferred this issue from flarum/framework Mar 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants