-
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
TimePicker components should have option to disable date field #52734
Comments
This suggestion makes sense to me. My feeling is that The current implementation of Actual
Expected
|
I think the complexity here is that |
I absolutely agree with the proposed expected table specification from the comment above.
Changing a format is not an option since it sounds like a breaking change. So, if we want to support hiding the date part, the only option is to keep the same component configuration with the full format and provide an additional boolean property. Here is the draft PR: #60034 @mirka, what do you think? |
I've investigated the other component libraries and watched how they return the time picker value. Most of them return it in the full-date format, with the current date if it's not set, which is also our case. From my perspective, it isn't a half-fake date string and a blocker for further component improvements. If this still doesn't sound like a possible solution, I would recommend creating a new separate Time picker without a date part. I can open a feature request, and then we can shape the details.
Once we build the component, we can incorporate it in the current time picker with the date component, so we maintain only one Time component. What do you think? |
@bogiii Apologies for the late reply! To add some context for this thread: I wasn't sure if I was being too idealistic about the
As for the props, let's keep it simple and stick to the API surface of TimePicker for now — so just |
At the moment there is no component to display a time picker that only show time.
The timepicker component has no optio to disable the date field. So it's mostly a light version of datetimepicker.
The text was updated successfully, but these errors were encountered: