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

fix: DisappearingScaleBar do not disappear after specified visibilityDurationMillis #168

Merged
merged 1 commit into from Jul 11, 2022

Conversation

Priyankkjain
Copy link
Contributor

Addresses a fix for #166 where DisappearingScaleBar does not disappear after specified visibilityDurationMillis. I think it's good to remove the condition so that the visibility and delay will restart every time the zoom changes. This will make sure that after given visibilityDurationMillis the ScaleBar will disappear. Also, any zoom change will restart the LaunchedEffect again so that the old time-out will not be an issue.

I would love to hear the feedback if this is the correct way to address the issue or not. Any comments will be valuable.

Fixes #166

Copy link
Contributor

@barbeau barbeau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @Priyankkjain, LGTM. Seems like the existing implementation is getting hung up on the visible.isIdle being false and not triggering the hide animation, so this seems like a good fix.

@barbeau
Copy link
Contributor

barbeau commented Jul 11, 2022

I'm not sure why the tests are failing on CI as they pass for me locally. I'll merge this and address the failing CI separately if needed.

@barbeau barbeau merged commit 8d0b855 into googlemaps:main Jul 11, 2022
googlemaps-bot pushed a commit that referenced this pull request Jul 11, 2022
## [2.5.2](v2.5.1...v2.5.2) (2022-07-11)

### Bug Fixes

* DisappearingScaleBar do not disappear after specified visibilityDurationMillis ([#168](#168)) ([8d0b855](8d0b855))
@googlemaps-bot
Copy link
Contributor

🎉 This PR is included in version 2.5.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

DisappearingScaleBar do not disappear after specified visibilityDurationMillis
3 participants