amsul / pickadate.js

The mobile-friendly, responsive, and lightweight jQuery date & time input picker.
http://amsul.ca/pickadate.js
MIT License
7.7k stars 1.02k forks source link

Time picker activates on repeated onRender #1249

Closed tsegreto closed 10 months ago

tsegreto commented 10 months ago

If you have a button that calls picker.render() and you double or triple click it the time picker will activate, even if you use event.stopPropagation. This behavior only occurs with timepicker.js, not datepicker.js.

tsegreto commented 10 months ago

I fixed it by removing $el.css( prop, state ) in picker.time.js

animations = function( $el, state ) {
  vendors( 'transform' ).map(function( prop ) {
      $el.css( prop, state )
  })
  vendors( 'transition' ).map(function( prop ) {
      $el.css( prop, state )
  })
}