google / google/material-design-lite

iOS Mobile Devices: Inputs within iFrames have the “in-focus” class even when the input is not dirty and out of focus

Open
#5,168 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
HTML
Stars
32.2k
Forks
4.9k
PR merge metrics
No merged PRs in 30d

Description

## Bugs

Please include the following information with your bug report:

> What MDL Version are you using? (please be specific, e.g. _major.minor.patch_)
**material-design-lite version v1.3.0**

> What browser(s) is this bug affecting (including version)?
All iOS mobile devices (on Chrome and Safari - and most likely all other browsers)

> What OS (and version) are you using?
iPhone 5s - iOS 11
iPad Air2 - iOS 10.3

> What are the steps to reproduce the bug? Can you create a plunker/codepen/jsfiddle which reproduces it?
1. Set up a dummy account at https://pantaya.com/billing/create-account?TID=
2. You are now at the payment page https://pantaya.com/billing/payment.
3. Click into the different fields and do not type anything.
3. Notice that all the inputs within iFrames keep the class "is-focused" when the input is **_not dirty_** meaning no text is inside the input. This makes the inputs behave as if it was in focus. Sometimes the cursor disappears when you try to refocus into that input.

> What is the expected behavior?
The expected behavior is that when you loose focus on an input that doesn't contain text will revert to the out of focus state. This works correctly on desktop Chrome and Safari.

> What is the actual behavior?
The actual behavior is that the inputs with iFrames on all iOS mobile devices remain in a focused state even when it is not in focused and the input is empty.

> Any other information you believe would be useful?
This issue seems to only happen when the input is within an iFrame on iOS mobile devices. If you try version 9 and back an additional error (that may be related) occurs. This error is that the cursor disappears when you click back into an empty input field that acts like it's "in-focus".

See attached photo
![screen shot 2017-10-31 at 11 39 59 am](https://user-images.githubusercontent.com/11908147/32242784-4802294c-be39-11e7-8539-447a314bb756.png)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.