File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import * as React from 'react' ;
2- import { View , ViewStyle } from 'react-native' ;
2+ import { Platform , View , ViewStyle } from 'react-native' ;
33import { Spring } from 'react-spring' ;
44
55import { ITheme , withTheme } from '../../theme' ;
@@ -40,7 +40,7 @@ const ProgressBase = (props: IProgressProps) => {
4040 >
4141 < View
4242 // @ts -ignore
43- accessibilityRole = " progress"
43+ accessibilityRole = { Platform . OS === 'web' ? ' progress' : 'none' }
4444 style = { {
4545 width : `${ value } %` ,
4646 ...progressStyle ,
Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ const HeadingBase = (props: IHeadingProps & TextProps) => {
2828 return (
2929 < Text
3030 // @ts -ignore
31- accessibilityRole = { Platform . OS === 'web' ? 'heading' : 'header ' }
31+ accessibilityRole = { Platform . OS === 'web' ? 'heading' : 'none ' }
3232 aria-level = { accessibilityLevel } // Web
3333 style = { [ { textAlign } , headingStyle ] }
3434 { ...textProps }
Original file line number Diff line number Diff line change 11import * as React from 'react' ;
2+ import { Platform } from 'react-native' ;
23
34import withTheme from '../../theme/withTheme' ;
45import Text , { ITextProps } from './Text' ;
@@ -9,7 +10,7 @@ const LabelBase = (props: ITextProps) => {
910 return (
1011 < Text
1112 // @ts -ignore
12- accessibilityRole = " label" // Web
13+ accessibilityRole = { Platform . OS === 'web' ? ' label' : 'none' }
1314 { ...textProps }
1415 >
1516 { children }
Original file line number Diff line number Diff line change 11import * as React from 'react' ;
2- import { View } from 'react-native' ;
2+ import { Platform , View } from 'react-native' ;
33
44import { TextSize } from '../../theme/ThemeInterface' ;
55import { Spacing } from '../Layout' ;
@@ -34,7 +34,7 @@ export const List = (props: IListProps) => {
3434 return (
3535 < View
3636 // @ts -ignore
37- accessibilityRole = " list"
37+ accessibilityRole = { Platform . OS === 'web' ? ' list' : 'none' }
3838 >
3939 < Spacing margin = { 0 } marginLeft = { 1 } padding = { 0 } >
4040 { finalChildren }
Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ const ListItemBase = (props: ITextProps & IListItemProps) => {
3434
3535 return (
3636 // @ts -ignore
37- < View accessibilityRole = { Platform . OS === 'web' ? 'listitem' : undefined } >
37+ < View accessibilityRole = { Platform . OS === 'web' ? 'listitem' : 'none' } >
3838 < Spacing flexDirection = "row" alignItems = "center" marginY = { 1 } >
3939 < Spacing > { mark } </ Spacing >
4040 < Spacing width = "100%" paddingLeft = { paddingLeft } >
You can’t perform that action at this time.
0 commit comments