Defining steps with the useTimeField #4400
jussivirtanen
started this conversation in
Ideas
Replies: 2 comments 3 replies
-
I think we could consider adding this to make it easier. I'm not sure we'd want to add it quite like the native control. It's a bit weird to use. The step value applies across every segment and controls if there is a seconds field or not. If you specify something like 150, it just pretends it was never specified. And it looks like even the spec has some outstanding issues https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/time#step |
Beta Was this translation helpful? Give feedback.
3 replies
-
Please, have a look at #4410 (comment) where I proposed a solution. Any improvements are welcome! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
In our project, we'd like to make the
useTimeField
minute selector accept only specific increments (0, 15, 30 and 45). With the native<input type="time">
element, it's possible to use the step attribute to determine the granularity in seconds.It would be great to have this functionality with the useTimeField! And, if there is a way to get this functionality working with the existing
useTimeField
version, I'm thrilled to hear about that. Thanks!Beta Was this translation helpful? Give feedback.
All reactions