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

DatePicker: buttonBar for time-only variant shows meaningless "Today" button #7333

Open
jasonfellows opened this issue Feb 26, 2025 · 0 comments
Labels
Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible

Comments

@jasonfellows
Copy link

jasonfellows commented Feb 26, 2025

Describe the bug

When using DatePicker's timeOnly variant with showButtonBar enabled, both "Today" and "Clear" buttons are included, but "Today" has no meaning with a date.

"Clear" remains very useful. We would like to render the buttonBar for timeOnly Datepickers without the "Today" button by default to avoid needing passthrough to control its visibility.

Image

Pull Request Link

#7334

Reproducer

https://stackblitz.com/edit/primevue-4-vite-issue-template-h3e3k76w?file=src%2FApp.vue

Environment

The bug is reproducible with any client of PrimeVue v4 (Chome MacOS Nuxt 3 app in my case)

Vue version

3.x.x

PrimeVue version

4.x.x

Node version

x.x.x

Browser(s)

No response

Steps to reproduce the behavior

  1. Render DatePicker with timeOnly="true" and showButtonBar="true"
  2. Click on the input
  3. View the "Today" button rendered without a calendar present

Expected behavior

When timeOnly="true", the buttonBar contains only the "Clear" button.

@jasonfellows jasonfellows added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Feb 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible
Projects
None yet
Development

No branches or pull requests

1 participant