Hi! I have this code, and when I do it according to the documentation, it doesn't let me swipe. Please Help!
Swipe Gestures
Add a Comment
Hi! I have this code, and when I do it according to the documentation, it doesn't let me swipe. Please Help!
Update: It's working, just doesn't really work well in the simulator
Example in Apple's doc is different : https://developer.apple.com/documentation/SwiftUI/View/swipeActions(edge:allowsFullSwipe:content:)
Instead of:
.swipeActions(edge: .trailing, allowsFullSwipe: true) {
Button {
moveRest(buisness: buisness)
} label: {
VStack {
Image(systemName: "hand.thumbsup")
Text("Move to No List")
}
.foregroundColor(.white)
}
.background(.red)
It reads:
.swipeActions(edge: .trailing, allowsFullSwipe: true) {
Button {moveRest(buisness: buisness)
} label: {
Label("Move to No List", systemImage: "envelope.open")
.foregroundColor(.white)
}
.tint(.red)
Could you test the change ?
Unfortunately, it did not work.
Could you post the full code so that we can try ?
Here you go:
Thanks, but I cannot test, there are too many libraries to install. Have you a minimal code to test ?
Update: It's working, just doesn't really work well in the simulator