Vuepic / vue-datepicker

Datepicker component for Vue 3
https://vue3datepicker.com
MIT License
1.46k stars 146 forks source link

12 Hour Time Selection issue with min/max times (Unable to choose 12:00-12:59) #851

Closed chrisworrell closed 4 months ago

chrisworrell commented 5 months ago

Describe the bug When using time-picker and you set is-24=false it becomes impossible to select hour 12 on the AM side when you have a min-time and max-time set.

For example I am trying to do a 12 hour time picker where the selection is between 6am and 10pm. If i use the up/down arrows I am able to select 12:30 for example, but in the pop up to select the specific hour 12 is disabled.

To Reproduce Steps to reproduce the behavior: ` <VueDatePicker v-model="date" :is-24="false" time-picker :start-time="{ hours: 6, minutes: 0 }" :min-time="{ hours: 6, minutes: 0 }" :max-time="{ hours: 22, minutes: 0 }"

`

Expected behavior I should be able to select hour 12 in the AM grid

Screenshots First image is the AM time selection, notice that 12 is disabled image Second image is the PM time selection, which only allows me to choose 1pm and forward. image

Desktop & mobile (please complete the following information):