iOS 7 Safari: OS locks up for 4 seconds when clicking/focusing on a HTML input

前端 未结 13 622
不思量自难忘°
不思量自难忘° 2020-12-07 19:36

UPDATE: The issue seems to stem from having many select elements on a page. How random is that?

So here\'s the issue. On iOS 7 Safari, when tapping

13条回答
  •  臣服心动
    2020-12-07 20:05

    It happens not only in iOS but in safari 7 for MAC OS (Maverics) too, I have found that the problem happens when you use a lot of div tags to contain inputs (or selects) within a form:

    ...

    I changed the layout of my selects to use ul/li and fieldsets instead of divs and the freezze time was reduced drastically.

Here are two examples in jsfiddle:

freezze for 5 seconds

http://jsfiddle.net/k3j5v/5/

freeze for 1 second

http://jsfiddle.net/k3j5v/6/

I hope it might help someone

提交回复
热议问题