Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat: allow the date picker dialog to be opened programmatically (closes #1477) #1478

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
geronimol wants to merge 4 commits into flutter-form-builder-ecosystem:main
base: main
Choose a base branch
Loading
from geronimol:show-date-picker-dynamically

Conversation

@geronimol
Copy link
Contributor

@geronimol geronimol commented Mar 13, 2025
edited
Loading

Connection with issue(s)

Close #1477

Solution description

Making FormBuilderDateTimePickerState public allows calling the showPicker method programatically.
We can access it like so:

final dateTimePickerKey = GlobalKey<FormBuilderDateTimePickerState>();
...
FormBuilderDateTimePicker(key: dateTimePickerKey),
...
dateTimePickerKey.currentState?.showPicker();

Screenshots or Videos

To Do

  • Read contributing guide
  • Check the original issue to confirm it is fully satisfied
  • Add solution description to help guide reviewers
  • Add unit test to verify new or fixed behaviour
  • If apply, add documentation to code properties and package readme

Copy link

codecov bot commented Mar 13, 2025
edited
Loading

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.88%. Comparing base (483f02f) to head (76f0a02).
Report is 2 commits behind head on main.

Additional details and impacted files
@@ Coverage Diff @@
## main #1478 +/- ##
=======================================
 Coverage 89.88% 89.88% 
=======================================
 Files 21 21 
 Lines 840 840 
=======================================
 Hits 755 755 
 Misses 85 85 

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@geronimol geronimol changed the title (削除) feat: allow the date picker dialog to be opened programmatically (削除ここまで) (追記) feat: allow the date picker dialog to be opened programmatically (closes #1477) (追記ここまで) Mar 13, 2025
Copy link
Collaborator

Thanks for PR!

This is a sustancial change. I think that need to think more about the consequences of this, as the ones I explain here #1132 (comment)

geronimol reacted with thumbs up emoji

Copy link
Contributor Author

@deandreamatias I wasn't sure about this either, but I saw the Flutter team is using this behavior in other widgets, such as PaginatedDataTable. You can see they left the PaginatedDataTableState as public, so you can access the pageTo method to dynamically change the page.

deandreamatias reacted with thumbs up emoji

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

Reviewers

No reviews

Assignees

No one assigned

Labels

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

[FormBuilderDateTimePicker]: Can't open the picker dialog dynamically anymore

AltStyle によって変換されたページ (->オリジナル) /