Next.js: The screen automatically zooms in when tapping on a material-ui TextField on ios devices

Created on 27 Apr 2019  路  9Comments  路  Source: vercel/next.js

Bug report

Describe the bug

Since i have upgraded my project to next.js 8, when i tap on some of the TextFields, the screen suddenly zooms in. it only happens on ios devices. i downgraded my app to next.js 7 again just to be sure and the problem was solved.

System information

  • OS: ios
  • Browser : all kinds
  • Version of Next.js: 8.0.4

Most helpful comment

@niloofarmzk put the meta tag inside _app here is why https://github.com/zeit/next.js/issues/6919

All 9 comments

@niloofarmzk this is expected behaviour on iOS. It's possible the previous version was disabling scaling via a meta tag but if your font is less than 16px it'll automatically zoom the field on focus.

Next 8.0.4 includes a viewport meta tag by default. cc @developit

@niloofarmzk this is expected behaviour on iOS. It's possible the previous version was disabling scaling via a meta tag but if your font is less than 16px it'll automatically zoom the field on focus.

Is there a way that we can disable scaling manually? @notrab

@niloofarmzk You can but it's not recommended. <meta name="viewport" content="width=device-width, user-scalable=no" />

@notrab actually i have this meta tag in my _document.js file: <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"/> but it doesn't seem to be working.
is there a possibility that it is being overwritten by some other meta tag in next.js 8?

@niloofarmzk put the meta tag inside _app here is why https://github.com/zeit/next.js/issues/6919

@niloofarmzk put the meta tag inside _app here is why #6919

thanks!that worked.

@niloofarmzk you should close this if there is no problem

Thanks @MarchWorks, closing because resolved.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

renatorib picture renatorib  路  3Comments

ghost picture ghost  路  3Comments

olifante picture olifante  路  3Comments

wagerfield picture wagerfield  路  3Comments

knipferrc picture knipferrc  路  3Comments