Ask Your Question
3

How can the focus border for Pickers be hidden on watchOS using SwiftUI?

asked 2022-02-22 11:00:00 +0000

scrum gravatar image

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2021-04-12 10:00:00 +0000

bukephalos gravatar image

You can hide the focus border for Pickers on watchOS using SwiftUI by applying the .focusable(false) modifier to the Picker element. For example:

Picker("Options", selection: $selectedOption) {
   Text("Option 1").tag(1)
   Text("Option 2").tag(2)
}
.focusable(false)

This will disable the focus border for the Picker element.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss

Add Answer


Question Tools

Stats

Asked: 2022-02-22 11:00:00 +0000

Seen: 17 times

Last updated: Apr 12 '21