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

Wrapped view momentarily duplicated on a swipe when it has a .contextMenu modifier attached #5

Open
bardigolriz opened this issue Apr 15, 2023 · 2 comments
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@bardigolriz
Copy link

When the control wrapped inside the SwipeView contains a .contextMenu modifier, swiping it will semi-occasionally momentarily result in a non-smooth duplication of the wrapped view:

RocketSim_Recording_iPhone_13_Pro_2023-04-15_10 39 01_pm

When I removed the contextMenu, it worked perfectly fine. I believe it is as simple as that, but if you need more information, please let me know.

@aheze
Copy link
Owner

aheze commented Apr 15, 2023

Hmm yeah I think it's because contextMenu creates a snapshot of the view for the scale effect. Try setting swipeMinimumDistance to a lower value (starts the swipe gesture earlier):

.swipeMinimumDistance(0.5)

@bardigolriz
Copy link
Author

bardigolriz commented Apr 15, 2023

Unfortunately this doesn’t help, also when reduced to an even lower value :( To be clear, it doesn’t appear to make any difference.

@aheze aheze added bug Something isn't working help wanted Extra attention is needed labels Apr 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants