Last active
September 21, 2017 20:19
-
-
Save lazyTai/698b794e77edb757984295cb30a589eb to your computer and use it in GitHub Desktop.
手机pc 居中
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* { | |
box-sizing: border-box; | |
} | |
html { | |
padding: 0; | |
} | |
body { | |
max-width: 700px; | |
margin: 0 auto !important; | |
} | |
@media screen and (min-width: 700px) { | |
body { | |
width: 700px; /*这是重点,pc居中*/ | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment