A Pen by Brandon Reid on CodePen.
Created
May 7, 2019 19:00
-
-
Save chibaye/e264906d9b50570256d2d9c2440d088d to your computer and use it in GitHub Desktop.
Simple pulsating svg circle
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
<div> | |
<svg width="60px" height="60px" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 14 14"> | |
<animate | |
xlink:href="#back" | |
attributeName="r" | |
from="5.3" | |
to="6.5" | |
dur="1s" | |
begin="0s" | |
repeatCount="indefinite" | |
fill="freeze" | |
id="circ-anim" | |
/> | |
<animate | |
xlink:href="#back" | |
attributeType="CSS" attributeName="opacity" | |
from="1" | |
to="0" | |
dur="1s" | |
begin="0s" | |
repeatCount="indefinite" | |
fill="freeze" | |
id="circ-anim" | |
/> | |
<circle id="back" cx="7.2" cy="7" r="6.5" stroke-width="0.333"/> | |
<circle class="front" cx="7.2" cy="7" r="5.5"/> | |
</svg> | |
</div> |
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
body { | |
text-align: center; | |
padding-top: 5em; | |
} | |
.front { | |
fill: fadeOut(#ff8800, 10); | |
} | |
#back { | |
fill: transparent; | |
stroke: fadeOut(#ff8800, 30); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment