Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Demo vs Firefox. Clicks cause the date picker to be hidden. #324

Closed
ollicle opened this issue May 25, 2015 · 3 comments
Closed

Demo vs Firefox. Clicks cause the date picker to be hidden. #324

ollicle opened this issue May 25, 2015 · 3 comments

Comments

@ollicle
Copy link

ollicle commented May 25, 2015

Steps to reproduce:

  1. Load: http://dbushell.github.io/Pikaday/ in Firefox (37.0.1)

  2. Click or focus input – widget displays as expected

  3. Click:

    a day of month, back/next arrows: widget hides & input remains blank

    the current month/year: month select displays momentarily & widget hides

@benelliott
Copy link

Can confirm this happens on Chrome v42 as well!

@quintenvk
Copy link

+1 on Firefox 38.0.5, OS X build.

@ZeStrid3r
Copy link
Contributor

Firefox sets default "ontouchend" event in document object, so the "onmousedown" event isn't created cause to the line 546 :

pikaday.js

546    addEvent(self.el, 'ontouchend' in document ? 'touchend' : 'mousedown', self._onMouseDown, true);

Try to replace it by :

if('ontouchend' in document)
    addEvent(self.el, 'touchend', self._onMouseDown, true);
if('onmousedown' in document)
    addEvent(self.el, 'mousedown', self._onMouseDown, true);

Works on Firefox 39.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants