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

DON-1092 – refine post-search scroll behaviour #1773

Merged
merged 5 commits into from
Nov 26, 2024

Conversation

@NoelLH NoelLH self-assigned this Nov 26, 2024
Comment on lines 189 to 190
// 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.
Copy link
Contributor

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?

Suggested change
// 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

Copy link
Contributor Author

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

bdsl
bdsl previously approved these changes Nov 26, 2024
Copy link
Contributor

@bdsl bdsl left a 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.

@NoelLH NoelLH merged commit c5231ba into develop Nov 26, 2024
4 checks passed
@NoelLH NoelLH deleted the DON-1092-refine-post-search-scroll branch November 26, 2024 10:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants