Skip to content

Instantly share code, notes, and snippets.

@sturdysturge
Last active July 10, 2020 11:01
Show Gist options
  • Save sturdysturge/4276d6cfbb190d05bec6ff5e21d8731a to your computer and use it in GitHub Desktop.
Save sturdysturge/4276d6cfbb190d05bec6ff5e21d8731a to your computer and use it in GitHub Desktop.
RevDoc help
import SwiftUI
struct ContentView: View {
var body: some View {
List {
//VoiceOver: Label 1, Help 1
Text("Help 1 overrides Hint 1")
.accessibility(hint: Text("Hint 1"))
.help(Text("Help 1"))
.accessibility(label: Text("Label 1"))
//VoiceOver: Label 2, Hint 2
Text("Hint 2 overrides Help 2")
.help(Text("Help 2"))
.accessibility(hint: Text("Hint 2"))
.accessibility(label: Text("Label 2"))
}
.frame(minWidth: 200, minHeight: 200)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment