Not sure if I am doing this wrong? Is it possible to animate two properties on a path in an SVG at once? This works as I would expect in Firefox but not on Safari or Chrome.
Example SVG:
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg width="100%" height="100%" viewBox="0 0 400 200" xmlns="http://www.w3.org/2000/svg" version="1.1">
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
<g id="holder">
<path id="ShapeRight" d="M16,20 L21,16.5004951 C21,16.5004951 19.5760225,15.5035698 18.8640337,15.0051072 C17.9093558,14.336738 16,13 16,13 L16,20 L16,20 Z" opacity="0.55" fill="#999"></path>
</g>
</g>
</svg>
Relevant Sass/CSS (obviously prefixes needed in some instances)
#holder {
#ShapeRight {
opacity: 1;
transform: scale(1);
animation: pulseArrow 2s forwards ease-in-out infinite;
transform-origin: 50% 50%;
display: inline-block;
}
}
@keyframes pulseArrow {
0% {
transform: scale(1) translateX(0);
opacity: 0;
}
50% {
transform: scale(2) translateX(0);
opacity: 1;
}
100% {
transform: scale(1) translateX(0);
opacity: 0;
}
}
Here is a reduction on Codepen:
You can see that only the last part of the animation is applied (the opacity). Should both work or is this a limitation to animating SVG with CSS?