You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jun 9, 2022. It is now read-only.
Select that fire correctly in Chrome on Android, don't fire when in the PWA of that same site.
FastClick is the only plugin, everything else is vanilla JS.
It only doesn't fire on select's that ALSO have an eventListener attached to them (usually change) OR that are checked inside the the eventListener of another element.
For example, I have a "Country" select with option val=0 being "Please Select". The submit button for that form checks to see if that select's val is still 0, and if so marks it with some CSS. Inside a PWA, this select box doesn't open.
If I duplicate the same form but remove the click eventListener on the submit button, the select DOES fire.
This is all bypassed by "needsclick" class, but I found it interesting there was this distinction.
Now, for every page before calling FastClick, I run:
let selects = document.querySelectorAll('select');
for(let i = 0; i < selects.length; i++){
selects[i].classList.add('needsclick');
}
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Select that fire correctly in Chrome on Android, don't fire when in the PWA of that same site.
FastClick is the only plugin, everything else is vanilla JS.
It only doesn't fire on select's that ALSO have an eventListener attached to them (usually change) OR that are checked inside the the eventListener of another element.
For example, I have a "Country" select with option val=0 being "Please Select". The submit button for that form checks to see if that select's val is still 0, and if so marks it with some CSS. Inside a PWA, this select box doesn't open.
If I duplicate the same form but remove the click eventListener on the submit button, the select DOES fire.
This is all bypassed by "needsclick" class, but I found it interesting there was this distinction.
Now, for every page before calling FastClick, I run:
The text was updated successfully, but these errors were encountered: