Skip to content
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

[date-picker] Add support for disabled dates #1820

Open
Wnt opened this issue Mar 15, 2019 · 5 comments
Open

[date-picker] Add support for disabled dates #1820

Wnt opened this issue Mar 15, 2019 · 5 comments
Labels
enhancement New feature or request vaadin-date-picker
Projects

Comments

@Wnt
Copy link
Contributor

Wnt commented Mar 15, 2019

I would like to prevent particular dates, e.g. Saturdays, Sundays and public holiday from being selected.

@ashishlahoti
Copy link

I would like to prevent particular dates, e.g. Saturdays, Sundays and public holiday from being selected.

We are also having the exact same requirement to disable saturdays, sundays and public holidays.

@vaadin-bot vaadin-bot transferred this issue from vaadin/vaadin-date-picker May 19, 2021
@vaadin-bot vaadin-bot added enhancement New feature or request vaadin-date-picker labels May 19, 2021
@web-padawan web-padawan changed the title Add support for disabled dates [date-picker] Add support for disabled dates May 19, 2021
@rolfsmeds
Copy link
Contributor

Acceptance Criteria: vaadin/platform#2867

@rolfsmeds rolfsmeds added the papercuts "Services Papercuts" project label Mar 28, 2022
@web-padawan web-padawan removed the papercuts "Services Papercuts" project label Apr 11, 2022
@ghost
Copy link

ghost commented Jan 4, 2023

Cross-posting this note I also added to the above acceptance criteria link:

This request is exactly what we need in our use of the vaadin date picker, except we have no need for the Java side of things. We use the date picker purely as a web component consumed within a LitElement. Would it be acceptable for us to develop a PR that implements a Javascript-only implementation where the is-date-available function is provided as a Javascript function that returns boolean? This is how our legacy datepicker is implemented and we're hoping to replace it with the Vaadin date picker yet keep this critical piece of functionality for disabling arbitrary dates.

@stefanuebe
Copy link

Two additional wishes:

It should also be possible to define tooltips for certain disabled dates, so that the user gets the info why the day is disabled, e. g. "Christmas", "New Year", "Day Of The Tentacle", etc.

And, if the dates will be defined in an eager way, it should be possible to define date ranges for better DX (e.g. to represent co-worker vacation).

@esommars
Copy link

esommars commented Oct 5, 2023

Looks like a great feature, in our case a valid delivery date can be any date determined by the user, so not the classical "Sat,Sun" or holiday schenario

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request vaadin-date-picker
Projects
No open projects
vaadin-core
  
📬  Inbox
7 participants