Date input improvements (#7639)

* add max date, use modern field for birthday input

* rm legacy date input

* handle simplifying to simpleDateString internally

* update jsdoc
This commit is contained in:
Samuel Newman
2025-02-03 12:27:58 -08:00
committed by GitHub
parent 25991af722
commit 23e62b18de
9 changed files with 37 additions and 203 deletions
+2 -1
View File
@@ -206,7 +206,7 @@ export function StepInfo({
</DateField.LabelText>
<DateField.DateField
testID="date"
value={DateField.utils.toSimpleDateString(state.dateOfBirth)}
value={state.dateOfBirth}
onChangeDate={date => {
dispatch({
type: 'setDateOfBirth',
@@ -215,6 +215,7 @@ export function StepInfo({
}}
label={_(msg`Date of birth`)}
accessibilityHint={_(msg`Select your date of birth`)}
maximumDate={new Date()}
/>
</View>
<Policies