Vuepic / vue-datepicker

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

Time picker flow doesn't work after complete #864

Closed faizaaulia closed 2 months ago

faizaaulia commented 2 months ago

Describe the bug I use the time picker mode & set the flow to [hours, minutes], then I conditionally set the flow value based on the time picker value & what overlay is being opened. When the first flow is being proceed for the first time, the flow is working properly. On my case, it will directly open the hours overlay, then the minutes overlay. But after it, if I open the hours overlay again, it doesn't move to the minutes overlay

To Reproduce Steps to reproduce the behavior:

  1. Go to Reproduction
  2. Click the input, it will open the hours overlay directly
  3. Pick an hour, then it will open the minutes overlay
  4. Pick a minute, then it will close the minutes overlay and back to the time overlay (display with hours, minutes, and up & down button)
  5. Click the hours button, then pick an hours

Expected behavior After the step 5, the expected behavior is to open the minutes overlay, because the flow is still [hours, minutes]

Screenshots https://github.com/Vuepic/vue-datepicker/assets/21327758/66a798d8-6a45-4b47-a3cf-4065ff3999cd

Desktop & mobile (please complete the following information):

Jasenkoo commented 2 months ago

This is expected behavior, because flow is only triggered on the mount. I'll expose a method to re-trigger it.