Permalink
Browse files

removed tabbar for iOS 9 compatibility issues

Summary: Removed Accessibility Trait TabBar for iOS compatibility Issues, since tabbar is only available on iOS 10+

Reviewed By: PeteTheHeat

Differential Revision: D8822469

fbshipit-source-id: 34bf00eb930f631a5a4effa0a4159da07c1573f6
  • Loading branch information...
ziqichen6 authored and facebook-github-bot committed Jul 12, 2018
1 parent 934c50f commit f39d0923c78686118a5d268c0e659d2608d28df0
@@ -44,8 +44,7 @@ export type AccessibilityRole =
| 'button'
| 'image'
| 'keyboardkey'
| 'text'
| 'tabbar';
| 'text';
module.exports = {
AccessibilityTraits: [
@@ -79,6 +78,5 @@ module.exports = {
'image',
'keyboardkey',
'text',
'tabbar',
],
};
@@ -33,7 +33,6 @@ @implementation RCTConvert(UIAccessibilityTraits)
@"header": @(UIAccessibilityTraitHeader),
@"search": @(UIAccessibilityTraitSearchField),
@"image": @(UIAccessibilityTraitImage),
@"tabbar": @(UIAccessibilityTraitTabBar),
@"selected": @(UIAccessibilityTraitSelected),
@"plays": @(UIAccessibilityTraitPlaysSound),
@"key": @(UIAccessibilityTraitKeyboardKey),
@@ -33,8 +33,7 @@
BUTTON("android.widget.Button"),
IMAGE("android.widget.ImageView"),
KEYBOARD_KEY("android.inputmethodservice.Keyboard$Key"),
TEXT("android.widget.ViewGroup"),
TAB_BAR("android.widget.TabWidget");
TEXT("android.widget.ViewGroup");
@Nullable private final String mValue;
@@ -90,7 +89,6 @@ public static void setRole(AccessibilityNodeInfoCompat nodeInfo, final Accessibi
private static final String IMAGE = "image";
private static final String KEYBOARDKEY = "keyboardkey";
private static final String TEXT = "text";
private static final String TABBAR = "tabbar";
public static void updateAccessibilityRole(View view, String role) {
if (role == null) {
@@ -111,9 +109,6 @@ public static void updateAccessibilityRole(View view, String role) {
case TEXT:
setRole(view, AccessibilityRoleUtil.AccessibilityRole.TEXT);
break;
case TABBAR:
setRole(view, AccessibilityRoleUtil.AccessibilityRole.TAB_BAR);
break;
default:
view.setAccessibilityDelegate(null);
}

0 comments on commit f39d092

Please sign in to comment.