[fix] View: guard against browser flexbox bugs

There are various flexbox bugs that can cause views to grow beyond the
vertical or horizontal bounds of their container. The width and height
styles avoid most of them manifesting.
This commit is contained in:
Nicolas Gallagher
2016-03-15 13:43:25 -07:00
parent 5f795dfc6c
commit ad4a6c5be7

View File

@@ -105,16 +105,21 @@ const styles = StyleSheet.create({
flexBasis: 'auto',
flexDirection: 'column',
flexShrink: 0,
listStyle: 'none',
margin: 0,
padding: 0,
position: 'relative',
textDecoration: 'none',
// button reset
// button and anchor reset
backgroundColor: 'transparent',
color: 'inherit',
font: 'inherit',
textAlign: 'inherit'
textAlign: 'inherit',
textDecoration: 'none',
// list reset
listStyle: 'none',
// fix flexbox bugs
maxWidth: '100%',
minHeight: 0,
minWidth: 0
}
})