Skip to content

Added initial DatePickerTheme, DatePickerThemeData to customize showDatePicker appearance - #93981

Closed
kirolous-nashaat wants to merge 2 commits into
flutter:masterfrom
kirolous-nashaat:fix93707
Closed

kirolous-nashaat wants to merge 2 commits into
flutter:masterfrom
kirolous-nashaat:fix93707

Conversation

@kirolous-nashaat

@kirolous-nashaat kirolous-nashaat commented Nov 20, 2021 •

Copy link
Copy Markdown
Contributor

Added initial DatePickerTheme to customize showDatePicker appearance for now it only has:

  • backgroundColor
  • entryModeIconColor
  • helpTextStyle
  • shape
  • selectedDayDecoration
  • disabledDayDecoration
  • todayDecoration

Partially fixes #93707

Pre-launch Checklist

  • I read the [Contributor Guide] and followed the process outlined there for submitting PRs.
  • I read the [Tree Hygiene] wiki page, which explains my responsibilities.
  • I read and followed the [Flutter Style Guide], including [Features we expect every widget to implement].
  • I signed the [CLA].
  • I listed at least one issue that this PR fixes in the description above.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making, or this PR is [test-exempt].
  • All existing and new tests are passing.

@flutter-dashboard flutter-dashboard Bot added p: material_ui material_ui package in flutter/packages framework flutter/packages/flutter repository. See also f: labels. labels Nov 20, 2021
@google-cla google-cla Bot added the cla: yes label Nov 20, 2021
@kirolous-nashaat
kirolous-nashaat marked this pull request as draft November 20, 2021 23:08
@kirolous-nashaat
kirolous-nashaat marked this pull request as ready for review November 20, 2021 23:12
@kirolous-nashaat
kirolous-nashaat marked this pull request as draft November 20, 2021 23:32
@kirolous-nashaat
kirolous-nashaat marked this pull request as ready for review November 20, 2021 23:36
@kirolous-nashaat
kirolous-nashaat marked this pull request as draft November 22, 2021 16:33
@kirolous-nashaat kirolous-nashaat changed the title Added initial DatePickerTheme, DatePickerThemeData to customize showDatePicker appearance [WIP] Added initial DatePickerTheme, DatePickerThemeData to customize showDatePicker appearance Nov 22, 2021
@kirolous-nashaat
kirolous-nashaat marked this pull request as ready for review November 22, 2021 21:48
@kirolous-nashaat kirolous-nashaat changed the title [WIP] Added initial DatePickerTheme, DatePickerThemeData to customize showDatePicker appearance Added initial DatePickerTheme, DatePickerThemeData to customize showDatePicker appearance Nov 23, 2021
@darrenaustin
darrenaustin self-requested a review February 23, 2022 00:19

@darrenaustin darrenaustin left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@kirolous-nashaat thanks so much for the contribution. So sorry it took me so long to review it. Nice work.

Comments and requests below, but this is a great start. We might want to flush this out with more text styles for the various header and other labels used by the picker, as well as some decoration for the header, but those can be added later.

Thx.

Comment thread packages/flutter/lib/src/material/calendar_date_picker.dart Outdated
Comment thread packages/flutter/lib/src/material/calendar_date_picker.dart Outdated
Comment thread packages/flutter/lib/src/material/date_picker_theme.dart Outdated
Comment thread packages/flutter/lib/src/material/theme_data.dart
@kirolous-nashaat

Copy link
Copy Markdown
Contributor Author

@darrenaustin all done, please check and let me know.
Btw the error in rainbowmonkey customer test doesnt seem relevant to the pr, right?

@kirolous-nashaat

kirolous-nashaat commented Mar 23, 2022 •

Copy link
Copy Markdown
Contributor Author

any updates?, are the customer tests related to the PR ? @darrenaustin

@guidezpl guidezpl removed the cla: yes label May 1, 2022
@guidezpl

guidezpl commented Jun 3, 2022

Copy link
Copy Markdown
Member

Can you please resolve conflicts and merge/rebase? Should clear the testing issue.

@kirolous-nashaat
kirolous-nashaat force-pushed the fix93707 branch 2 times, most recently from c98d4cf to 5f9090d Compare June 8, 2022 18:45
@kirolous-nashaat

Copy link
Copy Markdown
Contributor Author

@guidezpl , Done ✅
Some tests are failing but I don't know how it's related to the PR.

@kirolous-nashaat

Copy link
Copy Markdown
Contributor Author

Rebased again, and all checks passed @guidezpl

@TahaTesser

Copy link
Copy Markdown
Contributor

Need theme support for #101481

@guidezpl

Copy link
Copy Markdown
Member

Great, looking for approval from @darrenaustin since he requested changes.

@lexxxel

lexxxel commented Jul 15, 2022

Copy link
Copy Markdown

@darrenaustin could you review this MR again?

@darrenaustin

Copy link
Copy Markdown
Contributor

Really sorry about the lag on this. I have not had the cycles to devote to this. However, given that there is an update to the design of the Date Picker for Material 3 coming shortly, I think it would be best to wait until we add M3 support to the date picker to add a theme. That way we make sure the properties we support in the theme are the same as the spec and we won't need to break anything to support M3. The issue tracking this is:

#101481.

I will make a note there to reference this PR when the spec is available the M3 data picker. Hopefully we can still use this work in some form during the M3 migration. In the mean time I will go ahead and close this PR while awaiting the spec.

Thanks so much for your contribution and your patience.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

framework flutter/packages/flutter repository. See also f: labels. p: material_ui material_ui package in flutter/packages

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Proposal] Add DatePicker and DateRangePicker Theme

5 participants