A Pen by Alexander Johansson on CodePen.
Created
November 25, 2013 07:43
-
-
Save KATT/7637777 to your computer and use it in GitHub Desktop.
A Pen by Alexander Johansson.
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
.dot | |
.outer | |
.inner |
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
$orange = #d35400; | |
body { | |
height: 100%; | |
width: 100%; | |
background: #34495e; | |
} | |
* { | |
box-sizing: border-box; | |
} | |
centerize() { | |
left: 50%; | |
top: 50%; | |
margin-left: (-@width/2); | |
margin-top: (-@height/2); | |
} | |
.dot { | |
position: absolute; | |
left: 50%; | |
top: 50%; | |
width: 40px; | |
height: 40px; | |
margin-left: (-@width/2); | |
margin-top: (-@height/2); | |
.inner, .outer { | |
position: absolute; | |
display: block; | |
content: ""; | |
border-radius: 1000px; | |
transition: all 0.2s ease-out; | |
} | |
.outer { | |
background: $orange; | |
width: 16px; | |
height: 16px; | |
centerize(); | |
} | |
.inner { | |
border: 4px solid #ecf0f1; | |
width: 8px; | |
height: 8px; | |
centerize(); | |
} | |
&:hover { | |
.inner { | |
width: 24px; | |
height: 24px; | |
border-width: 6px; | |
centerize(); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment