Skip to content

Add DateInputCalendarDelegate to customize date input#181105

Open
Mairramer wants to merge 8 commits intoflutter:masterfrom
Mairramer:feature/create-date-input-delegate
Open

Add DateInputCalendarDelegate to customize date input#181105
Mairramer wants to merge 8 commits intoflutter:masterfrom
Mairramer:feature/create-date-input-delegate

Conversation

@Mairramer
Copy link
Contributor

@Mairramer Mairramer commented Jan 17, 2026

This PR introduces DateInputGregorianCalendarDelegate, a specialized calendar delegate that extends GregorianCalendarDelegate to support customizable text input behavior in showDatePicker and showDateRangePicker when using DatePickerEntryMode.input.

The default behavior of showDatePicker and showDateRangePicker remains unchanged. This change improves the extensibility of the date picker’s input mode without affecting the calendar UI or existing APIs.

Fixes #83302
Fixes #97134
Fixes #62401
Fixes #181043
Fixes #115151
Partially fixes #150611

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-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.

@github-actions github-actions bot added framework flutter/packages/flutter repository. See also f: labels. f: material design flutter/packages/flutter/material repository. d: api docs Issues with https://api.flutter.dev/ d: examples Sample code and demos labels Jan 17, 2026
@Mairramer Mairramer changed the title 【WIP】Add DateInputCalendarDelegate to customize date input Add DateInputCalendarDelegate to customize date input Jan 23, 2026
@Mairramer Mairramer marked this pull request as ready for review January 23, 2026 16:15
@Mairramer
Copy link
Contributor Author

/gemini review

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces DateInputCalendarDelegate, which allows for customizable date input formatting in showDatePicker and showDateRangePicker. The changes include a new example demonstrating its usage, updates to core date picker files to integrate the new delegate, and corresponding tests. The implementation appears solid, providing a flexible extension point for date input.

@Mairramer Mairramer force-pushed the feature/create-date-input-delegate branch from 787eb5a to 25522f5 Compare February 3, 2026 20:32
@Mairramer Mairramer force-pushed the feature/create-date-input-delegate branch from 4cba849 to 4583052 Compare February 16, 2026 17:06
@Mairramer Mairramer force-pushed the feature/create-date-input-delegate branch from 4583052 to c9c9dd2 Compare February 23, 2026 17:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

d: api docs Issues with https://api.flutter.dev/ d: examples Sample code and demos f: material design flutter/packages/flutter/material repository. framework flutter/packages/flutter repository. See also f: labels.

Projects

None yet

2 participants