-
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 – fix campaign card grid input focus breaking Safari scroll positions #1780
Conversation
@@ -124,6 +130,16 @@ export class ExploreComponent implements OnDestroy, OnInit { | |||
} | |||
|
|||
onScroll() { | |||
if (this.scroller.getScrollPosition()[1] < this.smallestSignificantScrollPx) { | |||
this.blurredSinceLastMajorScroll = false; | |||
return; |
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.
This early return may stop some more()
calls, but since we do the equivalent on meta-campaign already I can't see that causing major problems.
Co-authored-by: Barney Laurance <[email protected]>
Co-authored-by: Barney Laurance <[email protected]>
@@ -124,6 +130,16 @@ export class ExploreComponent implements OnDestroy, OnInit { | |||
} | |||
|
|||
onScroll() { | |||
if (this.scroller.getScrollPosition()[1] < this.smallestSignificantScrollPx) { | |||
this.blurredSinceLastMajorScroll = false; |
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 don't think I'm following the logic here. This has a small scroll position so I guess is a minor scroll? So why does it affect the state of blurredSinceLastMajorScroll
?
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.
@bdsl The idea is that if you go back to the top, you are more likely to be about to interact with the search fields. So there's a reasonable chance that it will be useful to blur afresh when you're done. I'll add a comment.
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.
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
No description provided.