how to override font boosting in mobile chrome

后端 未结 8 1135
面向向阳花
面向向阳花 2020-12-01 09:32

Is it possible to override font boosting in mobile chrome? I searched the internet before ~including stackoverflow~.

I found that some people say it\'s impossible, a

8条回答
  •  臣服心动
    2020-12-01 09:59

    For desktops, and likely mobile (haven't tested mobile), you can disable font size boosting in Chrome and FF by setting a base font size on the HTML element. For example:

    html {
      font-size: 16px;
    }
    

    This is less hacky than max-height. But, still dirty from an accessibility standpoint.

    You can also use jQuery to set this if you have to.

提交回复
热议问题