Skip to content

Instantly share code, notes, and snippets.

@karschsp
Created September 10, 2015 01:39
Show Gist options
  • Save karschsp/84bd1b7e019515acf27a to your computer and use it in GitHub Desktop.
Save karschsp/84bd1b7e019515acf27a to your computer and use it in GitHub Desktop.
css play button
.channel__image:hover:before, .bxslider li a:hover:before {
content: " ";
border-radius: 50%;
width: 50px;
height: 50px;
margin-left: -25px;
margin-top: -25px;
color: #000000;
text-align: center;
position: absolute;
top: 60px;
right: 50%;
bottom: 50%;
left: 50%;
background: black;
background: rgba(0, 0, 0, 0.75);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr=#99000000, endColorstr=#99000000);
-ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#99000000, endColorstr=#99000000)";
z-index: 2;
}
Pseudo ::after element
.bxslider li a:hover:after {
border-top: 26px solid transparent;
border-bottom: 26px solid transparent;
border-left: 36px solid #9aca3b;
top: 42%;
margin-top: 0px;
margin-left: 13px;
}
.channel__image:hover:after, .bxslider li a:hover:after {
content: "";
position: absolute;
top: 60px;
right: 50%;
bottom: 50%;
left: 50%;
width: 0;
height: 0;
margin-top: -13px;
margin-left: -6px;
border-top: 13px solid transparent;
border-bottom: 13px solid transparent;
border-left: 18px solid #9aca3b;
z-index: 3;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment