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

set validRange for DatePickerInput #130

Closed JamesOrtizBrazil closed 2 years ago

JamesOrtizBrazil commented 2 years ago

I'm setting the validRange in DatePickerInput, but the dialog allow type any date without validation. Ex:

 <DatePickerInput
                                            locale="pt"
                                            label="Data Inicial"
                                            value={dataInicial}
                                            onChange={(d) => setDataInicial(d!!)}
                                            inputMode="start"
                                            validRange={{
                                                startDate: new Date(),
                                                endDate: new Date()
                                            }}
                                        />
RichardLindhout commented 2 years ago

Thanks for bug report this will be fixed in next release this evening!