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

[Feature Request] Calendar date picker #18704

Closed
MelvinFrohike opened this issue Nov 16, 2023 · 0 comments
Closed

[Feature Request] Calendar date picker #18704

MelvinFrohike opened this issue Nov 16, 2023 · 0 comments
Labels
S: stale This issue is untriaged and hasn't seen any activity in at least six months. S: triage

Comments

@MelvinFrohike
Copy link

Problem to solve

Our application needs a picker that can select a date without a year, e.g. for selecting annual holidays.
We've been able to co-opt the VDatePicker to do this using the following steps:

  1. set min and max dates of 2024-01-01 & 2024-12-31 (2024 as it is a leap year)
  2. strip the year from the returned date
  3. set the weekday-format prop to null to remove the weekday names from the picker.
  4. set the first-day-of-week prop dynamically so that the first day of each month is chosen (moving the first to the top left for each month)
  5. set the header-date-format prop to only show the month's name but strip the year

Unfortunately, this doesn't work with Vuetify 3 anymore as neither the first-day-of-week prop nor the header-date-format prop is available. With steps 1 - 3 still working, it is usable but makes for a confusing UI as the user clearly sees the year 2024 while expecting to select a date without a year.
Another drawback with Vuetify 3 is that the picker opens on the current month whereas before it opened on the month of the min-date, which means users will have to manually move into the correct year.

Proposed solution

I would love to have either a dedicated picker for calendar days without years, or a prop/mode in VDatePicker that configures it for that use-case. Alternatively, reintroducing the props first-day-of-week & header-date-format would allow me to co-opt the VDatePicker again, although this still feels like a dirty hack.

@github-actions github-actions bot added the S: stale This issue is untriaged and hasn't seen any activity in at least six months. label May 17, 2024
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Jun 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S: stale This issue is untriaged and hasn't seen any activity in at least six months. S: triage
Projects
None yet
Development

No branches or pull requests

1 participant