From 10b603fdd34919f72304720c25d1420668a6213a Mon Sep 17 00:00:00 2001 From: Ziqi Chen Date: Mon, 16 Jul 2018 18:38:37 -0700 Subject: [PATCH] added image button as option for accessibility role Summary: Because we're now separating accessibilityTraits into accessibilityRole and accessibilityState, we're going to only allow one role to be set, and allow one preset combinations of roles that make sense. This diff adds image button as a role. Reviewed By: PeteTheHeat Differential Revision: D8846958 fbshipit-source-id: dad3783654b20abeb29767cdad7450d1896058c2 --- Libraries/Components/View/ViewAccessibility.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Libraries/Components/View/ViewAccessibility.js b/Libraries/Components/View/ViewAccessibility.js index 410994b2b20829..66988382a205c1 100644 --- a/Libraries/Components/View/ViewAccessibility.js +++ b/Libraries/Components/View/ViewAccessibility.js @@ -47,7 +47,8 @@ export type AccessibilityRole = | 'image' | 'keyboardkey' | 'text' - | 'adjustable'; + | 'adjustable' + | 'imagebutton'; module.exports = { AccessibilityTraits: [ @@ -84,5 +85,6 @@ module.exports = { 'keyboardkey', 'text', 'adjustable', + 'imagebutton', ], };