Google Chrome does not support small fonts below 12px, maybe because of user experience.
There are also some articles on the Internet saying that it can be used:
-webkit-text-size-adjust:none;
However, since chrome 27, support for this attribute has been removed.
Do we have any other ways to solve this problem?
Google Chrome supports CSS scaling, so we can make a fuss about this:
-webkit-transform: scale(0.5);
Since the minimum support is 12px, then scale based on 12px,
At the same time, you can use -webkit-transform-origin-x: 0; to solve the displacement problem of margin-left after scaling:
.test_tag{
font-size:12px;
-webkit-transform-origin-x: 0;
- webkit-transform: scale(0.5833333333333334);
}
The scale value is calculated as: 7 / 12 = 0.5833333333333334
Statement:The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn