idibidiart / react-native-responsive-grid

Bringing the Web's Responsive Design to React Native
Other
379 stars 42 forks source link

vAlign for Row contains wrong enums #11

Closed pratomchaip closed 7 years ago

pratomchaip commented 7 years ago

Using <Row vAlign="bottom">...</Row> displays a warning:

Warning: Failed prop type: Invalid prop vAlign of value bottom supplied to Row, expected one of ["stretch","middle","right","left"].

On closer inspection of the /src/component/Row.js code, it has: 62: vAlign: PropTypes.oneOf(['stretch', 'middle', 'right', 'left']),

which doesn't follow the Docs:

vAlign may also be supplied as prop to Row to align the columns within it in the vertical direction. Possible values are: top, middle, bottom, baseline and stretch. Default is top.

Fix, update enum list to: 62: vAlign: PropTypes.oneOf(['top', 'middle', 'bottom', 'baseline', 'stretch']),

idibidiart commented 7 years ago

Thank you @pratomchaip

This has been fixed in 0.34.05, and has been published to npm