Created
November 24, 2017 10:51
-
-
Save yusureabc/7988a229e336372aeeb7bf839b9c2870 to your computer and use it in GitHub Desktop.
CSS3实现手机页面1px边框(发丝边框)
This file contains 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
.panel{ | |
height: 48vmin; | |
width: 50%; | |
margin-top: 0px; | |
margin-bottom: 0px; | |
border-radius:0px; | |
color: #ffffff; | |
position: relative; | |
border: none; | |
overflow:hidden; | |
} | |
.panel:after | |
{ | |
content: ''; | |
position: absolute; | |
top: 0; | |
left: 0; | |
border: 1px solid #efefef; | |
border-bottom: none; | |
border-left: none; | |
-webkit-box-sizing: border-box; | |
box-sizing: border-box; | |
width: 200%; | |
height: 200%; | |
-webkit-transform: scale(0.5); | |
transform: scale(0.5); | |
-webkit-transform-origin: left top; | |
transform-origin: left top; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment