-
-
Notifications
You must be signed in to change notification settings - Fork 78.5k
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
Popover with data-trigger="focus"
does not work on iOS Safari when used on <a> without class="btn"
#15935
Comments
Hi @MrOrz! You appear to have posted a live example (http://run.plnkr.co/plunks/M0NIAPtXOet8ppl2dShP/), which is always a good first step. However, according to Bootlint, your example has some Bootstrap usage errors, which might potentially be causing your issue:
You'll need to fix these errors and post a revised example before we can proceed further. (Please note that this is a fully automated comment.) |
The url is the same as before: http://run.plnkr.co/plunks/M0NIAPtXOet8ppl2dShP/ |
class="btn"
data-trigger="focus"
does not work on iOS Safari when used on <a> without class="btn"
|
Probable X-Ref: #15277 |
Confirmed on iOS 8.1.
Yes, iOS Safari is stingy/quirky about elements being clickable/focusable; see https://developer.mozilla.org/en-US/docs/Web/Events/click#Safari_Mobile |
If at all possible, the best solution is to use an actual @cvrebert perhaps adding a rule to the CSS along lines of |
@patrickhlauke |
ah, safari...gotta love it. regarding normalize, as that's been sitting there since october, worth doing our own patch? |
Sure, go for it. Let's see what mdo thinks. |
What would be best? making a change to our local normalize.less, or adding the above to, say, buttons.less ? |
Our normalize.less is basically vendored and thus shouldn't be modified. |
scaffolding.less might be more appropriate than buttons.less |
@patrickhlauke @cvrebert: Maybe we should add a comment that an upstream patch has been submitted so that we revise this and remove it if added in normalize.css? |
@XhmikosR Agreed. Might wanna move your comment to the PR. |
iOS fix for role="button" elements; [fixes #15935]
@patrickhlauke: you should not merge that yet. #15935 (comment) |
Well I realise that NOW (this is what happens when discussions get fragmented across issues/PRs, sorry)...so, how do I undo this? |
Just add a new commit with the comment. Well, I didn't have the time to move the comment to the PR. The problem is that there are so many PRs and issues that things like this happen. Just look at the notifications more closely. |
Done. Will be more careful in future (maybe bad idea to have my notifications set to "firehose"...) |
I want to add that this bug is also happening for me on Safari 8.0.4. Not just on iOS. I resolved this by adding the |
@DavidVII That's a very different problem. As already mentioned in the docs, |
@cvrebert My mistake. Figured since it worked on all other browsers except safari that this was related some how. |
Though to be fair, Safari is the main reason that the tabindex is necessary; see https://gist.github.com/cvrebert/68659d0333a578d75372 |
After #11788 and #14156 the popover with
data-trigger="focus"
is working very well. However, there is a super weird bug that only happens in iOS safari.Consider the following 2
<a>
, the only difference between them isclass="btn"
.The problem is, popover works fine for the first
<a>
, but not the second.Hope the recording below will help better illustrating the problem:
Demo Plunker: http://embed.plnkr.co/M0NIAPtXOet8ppl2dShP/preview
(Please open using iPhone or iOS simulator. OSX Chrome, Android Chrome, OSX Safari, OSX Firefox works perfectly on both
<a>
s.)It seems that the focus event is somehow not triggered in iOS Safari. When I put a breakpoint in the focus event callback, the first
<a>
invokes the callback as expected while the second<a>
does not.No idea why this happens ._.
The text was updated successfully, but these errors were encountered: