8000 Datepicker - Option to clear the value when an unavailable date is entered · Issue #2379 · chakra-ui/zag · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Datepicker - Option to clear the value when an unavailable date is entered #2379
Closed as not planned
@sascha-eisenmann

Description

@sascha-eisenmann

🚀 Feature request

Provide an option to clear the value when a date before min or after max date is entered in the input of the datepicker.

🧱 Problem Statement / Justification

We are using the datepicker to select a shipping date. We want to prevent a user from entering a date that is not available for shipping. Currently the datepicker will use the nearest available date which could lead to confusion.

✅ Proposed solution or API

Maybe add a flag to control this behavior, like clearOnUnavailableDate that will switch from the current behavior to clear the value when an unavailable date is entered.

↩️ Alternatives

It could also be a good idea to set the value back to the configured default value, when the user enters an unavailable date.

📝 Additional Information

If you think this feature should be something that should be added to the datepicker, I would like to create a pull request to add this feature.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0