-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Refactor <TimePicker> to function component #24348
Refactor <TimePicker> to function component #24348
Conversation
f0071c5
to
ba0bdbf
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems to be working really nicely, appreciate all the effort into changing the tests over to react testing library, and adding the story.
I spotted one bug with the month select, though as far as I can tell it also seems to happen in master
, so it may be worth taking a look at in a separate PR.
A few separate code quality things, but nothing major 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for all the work on this!
Description
Refactor to function component following the latest best practices. Related to #22890. Notable changes are as follow.
<TimePicker>
story in storybook.useEffect
to reset the state when necessary.How has this been tested?
Several ways to test this:
components/TimePicker
.<PostSchedule>
component when editing a post and scheduling post time.Types of changes
New feature
Checklist: