mirror of
git://jb55.com/damus
synced 2024-10-06 19:53:22 +00:00
Add accessibility labels to EventActionBar
Changelog-Added: Add accessibility labels to action bar Closes: #530
This commit is contained in:
parent
45f8c37498
commit
638052492d
@ -108,6 +108,7 @@ struct ZapButton: View {
|
||||
send_zap()
|
||||
}
|
||||
}
|
||||
.accessibilityLabel(NSLocalizedString("Zap", comment: "Accessibility label for zap button"))
|
||||
|
||||
Text("\(bar.zap_total > 0 ? "\(format_msats_abbrev(bar.zap_total))" : "")")
|
||||
.offset(x: 22)
|
||||
|
@ -47,6 +47,7 @@ struct EventActionBar: View {
|
||||
EventActionButton(img: "bubble.left", col: nil) {
|
||||
notify(.reply, event)
|
||||
}
|
||||
.accessibilityLabel(NSLocalizedString("Reply", comment: "Accessibility label for reply button"))
|
||||
}
|
||||
Spacer()
|
||||
ZStack {
|
||||
@ -58,6 +59,7 @@ struct EventActionBar: View {
|
||||
self.confirm_boost = true
|
||||
}
|
||||
}
|
||||
.accessibilityLabel(NSLocalizedString("Boosts", comment: "Accessibility label for boosts button"))
|
||||
Text("\(bar.boosts > 0 ? "\(bar.boosts)" : "")")
|
||||
.offset(x: 18)
|
||||
.font(.footnote.weight(.medium))
|
||||
@ -89,6 +91,7 @@ struct EventActionBar: View {
|
||||
EventActionButton(img: "square.and.arrow.up", col: Color.gray) {
|
||||
show_share_sheet = true
|
||||
}
|
||||
.accessibilityLabel(NSLocalizedString("Share", comment: "Button to share a post"))
|
||||
}
|
||||
.sheet(isPresented: $show_share_sheet) {
|
||||
if let note_id = bech32_note_id(event.id) {
|
||||
@ -166,6 +169,7 @@ struct LikeButton: View {
|
||||
Image(liked ? "shaka-full" : "shaka-line")
|
||||
.foregroundColor(liked ? .accentColor : .gray)
|
||||
}
|
||||
.accessibilityLabel(NSLocalizedString("Like", comment: "Accessibility Label for Like button"))
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user