uvarov-frontend / vanilla-calendar-pro

The Vanilla Calendar Pro is a versatile JavaScript date and time picker component with TypeScript support, making it compatible with any JavaScript frameworks and libraries. It is designed to be lightweight, easy to use, and feature-rich, without relying on external dependencies.
https://vanilla-calendar.pro
Other
482 stars 60 forks source link

[HELP]How to determine in onChangeToInput that the time is changing? #335

Open anyude opened 4 hours ago

anyude commented 4 hours ago

I created a datetime picker. When I click on a date, the calendar is closed. But when I reopen the calendar, dragging the time slider triggers onChangeToInput instead of just onChangeTime. How can I prevent onChangeToInput or determine in onChangeToInput that only the time is changing?

Example link: https://codesandbox.io/p/sandbox/youthful-chaplygin-wxjfzc