pglejzer / timepicker-ui

timepicker-ui is an easy library with timepicker. Fully wrote with TypeScript. This library is based on Material Design from Google.
MIT License
62 stars 18 forks source link

"0NaN" error when using touch input #27

Closed grizzlymannn closed 1 year ago

grizzlymannn commented 1 year ago

This only seems to happen on my laptop that has a touch screen. Doesn't happen on phone or tablet when using touch. Also doesn't happen on laptop when using mouse input.

When picking hour or minute using laptop touchscreen the corresponding hour or minute section becomes blank and this error occurs.

The specified value "0NaN" cannot be parsed, or is out of range. _handleEventToMoveHand @ timepicker-ui.umd.js:1 _mutliEventsMove @ timepicker-ui.umd.js:1

These are the options used when creating the TimepickerUI object. const option = { mobile: false, };

pglejzer commented 1 year ago

thanks for your PR, I already merged it. I will make new release with your code too. Thanks again!