How do I add a tap gesture to a SwiftUI button?
I’m new to SwiftUI and trying to set a specific font size for the text in a TextField. I’ve tried using the font() modifier, but it doesn’t seem to be working. Here is the relevant code: … TextField("Enter your name", text: $name) .font(.system(size: 16)) .padding() .background(Color.gray.opacity(0.2)) .cornerRadius(8) … I’ve also tried setting the font size… Read More How do I add a tap gesture to a SwiftUI button?