Skip to content
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

Iphone Safari Auto-zooms on Input selection #2159

Closed
csytan opened this issue Feb 22, 2012 · 5 comments
Closed

Iphone Safari Auto-zooms on Input selection #2159

csytan opened this issue Feb 22, 2012 · 5 comments

Comments

@csytan
Copy link

csytan commented Feb 22, 2012

When you select an input (such as a text input) in Safari on the Iphone, the viewport zooms in and does not return to normal size when editing has been completed. Two double taps are required to return to the initial viewport size.

Normal size, no zoom:
normal size

After input selected, zoomed:
zoomed

Here are some possible solutions to this (http://stackoverflow.com/questions/2989263/disable-auto-zoom-in-input-text-tag-safari-on-iphone):

  1. Disable zoom in meta tag
  2. Use js events to change meta tag dynamically
  3. Set font-size for inputs to 16px

Changing the font size (#3) seems like the easiest and most reliable way to do this.

@andriijas
Copy link
Contributor

How about not optimizing things for mobile webkit?

@mdo
Copy link
Member

mdo commented Feb 22, 2012

Since this is default behavior for Mobile Safari, I'm inclined not to mess with it.

@andriijas: no need to get to snarky about an honest question like this :).

@mdo mdo closed this as completed Feb 22, 2012
gnuhub pushed a commit to gnuhub/mediawiki_extensions that referenced this issue Apr 19, 2014
Project: mediawiki/extensions/MobileFrontend  e53eee64d290e35b26a85180ad2603ab086f7968

Bug 49771: Prevent zooming on iOS

Giving a font size of at least 16px seems to stop
zooming in iOS

twbs/bootstrap#2159

Change-Id: I37ea6aefe91e8086468af1f4a564b277663fef19
@victoriaSh
Copy link

The easiest way is to set "tabindex=0" for div at top of page. It works for me.

@Haroenv
Copy link

Haroenv commented Jan 1, 2017

I know this is long closed, but maybe can we have the default font size of inputs 16px or larger?

@hnrch02
Copy link
Collaborator

hnrch02 commented Jan 1, 2017

@Haroenv Please file a new ticket instead of necroposting. Thanks.

@twbs twbs locked and limited conversation to collaborators Jan 1, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants