mobile-angular-ui
mobile-angular-ui copied to clipboard
Online demo works badly with Chrome on iPhone
Multiple problems on iOS 9.0.2 and Chrome v 45.0.2452.89:
- Menu is reopened after a menu item is clicked
- Navigation doesn't work
- Scrolling doesn't work
I'm sure there's a lot more. However, it works fine on safari.
Same problem occurs in Safari but this needs an additional easy step to reproduce. You need to add the website to your home screen (like bookmark but on home screen). After that, the menu is not usable anymore with exactly the same problem as depicted in this ticket.
Same here. Website opened from home screen in safari shows exactly same behaviour like in chrome on iPhone. Too bad.
@HerrHansen @xperseguers The issue is with Safari and not with MobileAngularUI. See section 10.3 of this spec https://w3c-webmob.github.io/installable-webapps/ You need to override the default a href behavior with document.addEventListener("click", function (e) { var elem = e.target; if (elem.tagName && elem.tagName === "A") { e.preventDefault(); location.href = elem.href; } });
Ah I see. Sorry, my fault. I forgot to add this proper code to YOUR online demo. ;-P Thank you.
@HerrHansen I am in no way affiliated with Mobile Angular UI, but I'll make a PR for this. If you actually make web apps and want to add this to your app then you should only register this event handler when the app starts if it meets the following conditions: if (((navigator.userAgent.match(/iPhone/i)) || (navigator.userAgent.match(/iPod/i))) && window.navigator.standalone)
This will make sure the user is actually on an apple device and they have launched from the home screen.
You are welcome,my friend.
At 2015-10-27 00:38:22, "HerrHansen" [email protected] wrote:
Ah I see. Sorry, my fault. I forgot to add this proper code to YOUR online demo. ;-P Thank you.
— Reply to this email directly or view it on GitHub.