mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-03 15:45:11 +00:00
improve a11y in room change role selection screen
This commit is contained in:
+10
@@ -21,6 +21,10 @@ struct RoomChangeRolesScreenSelectedItem: View {
|
|||||||
.foregroundColor(.compound.textPrimary)
|
.foregroundColor(.compound.textPrimary)
|
||||||
.lineLimit(1)
|
.lineLimit(1)
|
||||||
}
|
}
|
||||||
|
.accessibilityElement(children: .combine)
|
||||||
|
.accessibilityAction(named: L10n.actionDismiss) {
|
||||||
|
dismissAction()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// MARK: - Private
|
// MARK: - Private
|
||||||
@@ -31,6 +35,7 @@ struct RoomChangeRolesScreenSelectedItem: View {
|
|||||||
contentID: member.id,
|
contentID: member.id,
|
||||||
avatarSize: .user(on: .inviteUsers),
|
avatarSize: .user(on: .inviteUsers),
|
||||||
mediaProvider: mediaProvider)
|
mediaProvider: mediaProvider)
|
||||||
|
.accessibilityHidden(true)
|
||||||
.overlay(alignment: .topTrailing) {
|
.overlay(alignment: .topTrailing) {
|
||||||
if member.role != .administrator {
|
if member.role != .administrator {
|
||||||
Button(action: dismissAction) {
|
Button(action: dismissAction) {
|
||||||
@@ -39,7 +44,12 @@ struct RoomChangeRolesScreenSelectedItem: View {
|
|||||||
.scaledFrame(size: 20)
|
.scaledFrame(size: 20)
|
||||||
.symbolRenderingMode(.palette)
|
.symbolRenderingMode(.palette)
|
||||||
.foregroundStyle(Color.compound.iconOnSolidPrimary, Color.compound.iconPrimary)
|
.foregroundStyle(Color.compound.iconOnSolidPrimary, Color.compound.iconPrimary)
|
||||||
|
// Increase hit area
|
||||||
|
.padding(.leading, 5)
|
||||||
|
.padding(.bottom, 5)
|
||||||
}
|
}
|
||||||
|
// We will use the accessibility action
|
||||||
|
.accessibilityHidden(true)
|
||||||
.offset(x: 4)
|
.offset(x: 4)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user