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

scroll event ignored if the carousel view in the TabView and item view have tap gesture #15

Open
fso-msrl opened this issue Jul 8, 2022 · 3 comments

Comments

@fso-msrl
Copy link

fso-msrl commented Jul 8, 2022

This is the sample structure:

TabView {
VStack {
ACarousel(items) { item in
ItemView(item)
.onTapGesture { "do something" }
}
}

VStack {...}
VStack {...}
VStack {...}
}
.tabViewStyle(.page(indexDisplayMode: .never))

I want to swipe the carousel item if i drag inside

@trantran8
Copy link

Hi, I had this issue too, did you fix it?

@fso-msrl
Copy link
Author

Hi, I had this issue too, did you fix it?

I cant fix it because the gesture is private, I cant set it to higher priority.
Now I used another one ACarousel instead of TabView

like this:
ACarousel(pages) { page in
VStack {
...some views
ACarousel(items) { item in
ItemView(item)
.onTapGesture { "do something" }
}
}
}

Seem works! hope it can help you first

@trantran8
Copy link

Thank you, let me try

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

No branches or pull requests

2 participants