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

Selection doesn't work on safari #3

Closed
zkirby opened this issue Jul 15, 2019 · 6 comments
Closed

Selection doesn't work on safari #3

zkirby opened this issue Jul 15, 2019 · 6 comments

Comments

@zkirby
Copy link

zkirby commented Jul 15, 2019

Hi Dan!

It appears that prevent_user_select also prevents selection highlighting from working in Safari, I was wondering the reasoning behind this function?

Thanks!

@zkirby zkirby changed the title Selection doesn Selection doesn't work on safari Jul 15, 2019
@Dan503
Copy link
Owner

Dan503 commented Jul 15, 2019

In order to make the polyfill work I need to control what the user is able to select. Only day, month, or year is allowed to be selected at any one time.

Allowing the user to select any text in the input that they want causes bugs and breaks the functionality.

I'm unable to test in Safari since I only have access to a Windows PC. Does this functionality make the polyfill not work as intended?

@zkirby
Copy link
Author

zkirby commented Jul 15, 2019

I believe removing the prevent_user_select (or at least using = 'text' instead) doesn't prevent the functionality you mentioned. Or at least I can't seem to replicate said errors.

And correct, in safari this prevents highlighting

@Dan503
Copy link
Owner

Dan503 commented Jul 16, 2019

It's been quite a while since I looked at the code for this. I might have a look tonight and see if I can remove it safely.

@zkirby
Copy link
Author

zkirby commented Jul 16, 2019

Awesome, thank you so much Dan, I appreciate you taking the time to go back and look through this :)!

Dan503 added a commit that referenced this issue Jul 16, 2019
Preventing user select is actually cusing a worse UX in Safari and Firefox. Removing it improves the funcitonality.
@Dan503
Copy link
Owner

Dan503 commented Jul 16, 2019

I was fortunately able to replicate the sort of issues that you were describing in FireFox in the demo site. You were right, preventing user select was a pointless extra bit of functionality that was making the UX worse for no good reason. Thanks for pointing that out 😊👍

I've released a fix for this in version 1.0.6.

@Dan503 Dan503 closed this as completed Jul 16, 2019
@zkirby
Copy link
Author

zkirby commented Jul 16, 2019

Awesome, thanks for the quick response and fix!!

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

2 participants