-
Notifications
You must be signed in to change notification settings - Fork 3
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
DON-1092 – refine post-search scroll behaviour #1773
Conversation
NoelLH
commented
Nov 26, 2024
- give post-search scroll position change enough time to go to the right place
- fix no-op navigation with scroll position impact
// Angular scrolls automatically, using setTimeout to delay this scroll to a later task so this gets to | ||
// set the position the page is left in. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
probably worth changing this comment, "later task" made sense when delay was set at zero, now we're delaying it more than that. Not sure exactly what it is that we're waiting the 200ms for. Maybe something like this?
// Angular scrolls automatically, using setTimeout to delay this scroll to a later task so this gets to | |
// set the position the page is left in. | |
// Angular scrolls automatically, using setTimeout to delay this scroll to happen after the automatic scroll |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm also not sure exactly, but think it's connected to the router action and possibly to its scrollPositionRestoration
feature which we have set to true.
Updated the comments to match my understanding better at 1bec863
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, added a minor non-blocking suggestion inline.