web-ridge / react-native-paper-dates

Smooth and fast cross platform Material Design date and time picker for React Native Paper
https://www.reactnativepaperdates.com
MIT License
657 stars 170 forks source link

Conditionally render HelperText in DatePickerInput #124

Closed Grijnak closed 2 years ago

Grijnak commented 2 years ago

HelperText will take up space even when not visible. The recommended fix is to render it conditionally: react-native-paper/issues/2316.

This can lead to weird looking empty spaces and sometimes the HelperText will never be used anyway making it in the way.

Unused HelperText taking up space

RichardLindhout commented 2 years ago

You should add the datePicker input in a so it will render below the input (since default flexDirection is column in a View)

Grijnak commented 2 years ago

Wrapping the input in a view messes up the row because the helpertext now takes up space below the input. To be clear the issue is that it takes up space, no matter where. Even in it's own row, it will eat space even though nothing is displayed. This is what it looks like with datepickerinput in its own view on the same row:

Screenshot from 2021-12-26 18-52-29

RichardLindhout commented 2 years ago

Will be there in next release!