Skip to content

Instantly share code, notes, and snippets.

@mcattx
Last active February 24, 2018 06:23
Show Gist options
  • Save mcattx/50c9a2589bff2d16aea7 to your computer and use it in GitHub Desktop.
Save mcattx/50c9a2589bff2d16aea7 to your computer and use it in GitHub Desktop.
a reset css for web page #css
/*参考了normalize.css和aliceui.org*/
/* ==========================================================================
Base
========================================================================== */
/**
* 1. 修正文本(text)当body标签的`font-size`使用`em`为单位时的缩放错误
* 2. 预防iOS在切换方向之后文本字号适应错误
*/
html {
font-size: 100%; /* 1 */
-ms-text-size-adjust: 100%; /* 2 */
-webkit-text-size-adjust: 100%; /* 2 */
}
/**
* 1. 采用了 12 像素,1.5 的行高,并且兼容 Mac 和 Window 的字体配置
* 2. \5b8b\4f53 是 unicode 编码的“宋体”
*/
body,button,input,select,textarea {
font:12px/1.5 tahoma,arial,"Hiragino Sans GB",\5b8b\4f53;
}
/**
* 调整 IE 6/7 中 margin 的错误显示
*/
body {
margin: 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment