Reputation: 11832
I have a button which is created using pure CSS.
On mouseover the button an arrow animates from top to bottom.I would like to create a circle just outside the arrow. So the circle should contain the arrow.
I am not sure if it is possible or not. I did some Google research but didn't find a suitable thing.
<a href="#" class="button">
<span>Hover Me</span>
</a>
The fiddle is here
Upvotes: 1
Views: 4772
Reputation: 3775
.button:hover span:after, .button:active span:after {
transition: opacity 0.2s, top 0.2s, right 0.2s;
opacity: 1;
border-color: #e24500;
right: 0;
top: 62%;
width: 20px;
height: 20px;
border-radius: 50%;
background-color: blue
}
Upvotes: 0
Reputation: 27628
If I understand you, something like this:
.button span:before {
content:' ';
position: absolute;
top: 0px;
right: -18px;
opacity: 0;
width: 30px;
height: 30px;
margin-top: -19px;
border-radius: 50%;
background: #000;
transition: opacity 0.2s, top 0.2s, right 0.2s;
}
Demo: http://jsfiddle.net/DFNn9/4/
Upvotes: 8