验证中...
Languages: CSS
Categories: CSS 技巧
Latest update 2019-04-26 10:50
这是按照1rem = 10px 来设置的,根字体大小就是html{font-size:62.5%},如果你有自动编译的工具设置为10即可
Raw Copy
html {
font-size: 62.5%;
}
body {
font-size: 12px;
font-size: 1.2rem;
}
p {
font-size: 14px;
font-size: 1.4rem;
}
@media only screen and (min-width: 320px) {
html {
font-size: 62.5% !important;
}
}
@media only screen and (min-width: 640px) {
html {
font-size: 125% !important;
}
}
@media only screen and (min-width: 750px) {
html {
font-size: 150% !important;
}
}
@media only screen and (min-width: 1242px) {
html {
font-size: 187.5% !important;
}
}

Comment list( 0 )

You need to Sign in for post a comment

Help Search

183227_9af5e6a8_1826025 111910_4d91f001_1826025