Skip to content

[material_ui] Support custom date input formatters via CalendarDelegate - #12507

Draft
Mairramer wants to merge 2 commits into
flutter:mainfrom
Mairramer:feature/create-date-input-delegate
Draft

[material_ui] Support custom date input formatters via CalendarDelegate#12507
Mairramer wants to merge 2 commits into
flutter:mainfrom
Mairramer:feature/create-date-input-delegate

Conversation

@Mairramer

@Mairramer Mairramer commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

This PR adds the keyboardInputFormatters method to CalendarDelegate.

Previously, date input was strictly coupled to MaterialLocalizations. This change allows developers to provide a list of TextInputFormatters via a custom CalendarDelegate to enforce specific input masks (e.g., dd/MM/yyyy) or restrict character entry in date pickers (showDatePicker, showDateRangePicker, and InputDatePickerFormField).

Fixes flutter/flutter#83302
Fixes flutter/flutter#97134
Fixes flutter/flutter#62401
Fixes flutter/flutter#181043
Fixes flutter/flutter#115151
Fixes partially flutter/flutter#150611

Port of flutter/flutter#181105

Pre-Review 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-assist bot 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.

Footnotes

  1. Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling. 2

@github-actions github-actions Bot added triage-framework Should be looked at in framework triage p: material_ui labels Aug 19, 2026
@Mairramer Mairramer changed the title Feature/create date input delegate [material_ui] Support custom date input formatters via CalendarDelegate Aug 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment