Repository navigation
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces the inputFormatters parameter to showDatePicker, showDateRangePicker, and their associated dialogs and form fields. This allows developers to provide a list of TextInputFormatter objects to control and format user input during manual date entry. The changes include updates to DatePickerDialog, DateRangePickerDialog, and InputDatePickerFormField to propagate these formatters to the underlying text fields. Additionally, a new code sample and unit tests have been added to demonstrate and verify the functionality. I have no feedback to provide.
nate-thegrate
left a comment
There was a problem hiding this comment.
Thanks so much for putting this together! I just have a few suggestions regarding documentation.
I don't really have an opinion about whether to move forward with this PR or with #181105, so I'll defer to other reviewers for an approval.
Co-authored-by: Nate Wilson <[email protected]>
Co-authored-by: Nate Wilson <[email protected]>
|
@nate-thegrate |
|
@dkwingsmt Can this help determine which of the PRs they should follow? |
|
Let's focus our effort on #181105 , which is both opened earlier and closer to completion. However, feel free to comment on that PR as well, since I believe you have accumulated many very valuable thoughts while drafting this PR! Thank you very much for your contribution all the same. :) |
This PR includes inputFormatters in the date picker, allowing you to create textFormatters for the TextField used in InputDatePickerFormField, showDatePicker, and showDateRangePicker.
The purpose of this change is to enable input formatting within the DatePicker when it is in DatePickerEntryMode.input.
Fixes #83302
Fixes #97134
Fixes #62401
Fixes #181043
Fixes #115151
Pre-launch Checklist
///).If you need help, consider asking for advice on the #hackers-new channel on Discord.
Note: The Flutter team is currently trialing the use of Gemini Code Assist for GitHub. Comments from the
gemini-code-assistbot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.