Skip to content

The TimePicker component is not being controlled initially #7927

@Alphka

Description

@Alphka

Dependencies check up

  • I have verified that I use latest version of all @mantine/* packages

What version of @mantine/* packages do you have in package.json?

8.0.2

What package has an issue?

@mantine/dates

What framework do you use?

Next.js

In which browsers you can reproduce the issue?

Chrome

Describe the bug

When the TimePicker component first renders with an empty string (""), its value can't be controlled externally (e.g. using a state).
After changing its value using the input from the screen, it goes back to normal.

It works fine if null is used in the first render.

I noticed this didn't happen in v8.0.1.

If possible, include a link to a codesandbox with a minimal reproduction

https://codesandbox.io/p/devbox/beautiful-danny-vn4mkd

Possible fix

No response

Self-service

  • I would be willing to implement a fix for this issue

Metadata

Metadata

Assignees

No one assigned

    Labels

    FixedCompleted issues that will be published with next patch (1.0.X)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions