Skip to content
This repository was archived by the owner on May 1, 2024. It is now read-only.
This repository was archived by the owner on May 1, 2024. It is now read-only.

[Enhancement] ToolbarItem A11y #1742

@samhouts

Description

@samhouts

Rationale

Building on #713, this would add VoiceOver/TalkBack/Narrator capability to ToolBarItems. Included in this change would be limited support for setting accessibility properties on the MasterDetailPage toggle button and the NavigationBar back button.

Can take most of the changes from #889 now that #1199 is merged.

Implementation

ToolbarItems

  • [All] ToolbarItems with Text will already read the Text if no Accessibility.Name or .Hint are supplied. No change.
  • [iOS/UWP] Accessibility.Name will replace the Text that is read aloud on iOS and UWP. This is consistent with the platforms.
  • [Android] Accessibility.Name and/or Accessibility.Hint will completely replace the Text that is both visible and read aloud on Android. This is a limitation of API<26 and may be resolved later to be consistent with iOS and UWP.

MasterDetailPage Toggle Button

  • [iOS/UWP] Set Accessibility.Name and Accessibility.Hint on a MasterDetailPage to set the text that is read aloud on the toggle button. Setting these properties will have no effect on Android.
  • [Android] Add string resources to the Android project to set the text that is read aloud on the MasterDetailPage toggle button.
 <string name="mdp_open_a11y_name">Show Master Page</string>
 <string name="mdp_close_a11y_name">Hide Master Page</string>

NavigationPage Back Button

  • [Android] Set Accessibility.Name and Accessibility.Hint on a Page to set the text that is read aloud on the Back arrow in the Action Bar. This will have no effect on OS back buttons.
  • [UWP] Not applicable.
  • [iOS] Not supported; will read the title of the page as usual.

See https://forums.xamarin.com/discussion/94289/basic-accessibility-support-toolbaritems.
See Bug 52656 - ToolbarItem needs accessibility support

Difficulty: Medium

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions