Есть рамка с линейным градиентом.
Хочется, чтобы градиент вращался, т.е чтобы менялось свойство gradientTransform="rotate(40)"
В документации сказано что свойство gradientTransform "Animatable"
https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/gradientTransform
Скажите пожалуйста - как его анимировать?
Я бы хотел чтобы градиент вращался от 0 до 360 градусов.
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
viewBox="0 0 240 120"
>
<defs>
<linearGradient id="linearGradient" gradientTransform="rotate(40)" >
<stop style="stop-color:violet; stop-opacity: .7;" offset="0%"/>
<stop style="stop-color:blue; stop-opacity: .4;" offset="40%"/>
<stop style="stop-color:orange" offset="90%"/>
</linearGradient>
</defs>
<g >
<rect x="5" y="5" width="230" height="110" ry="10"
style="fill:none;stroke-width:5;stroke:url(#linearGradient);" />
<animateTransform
attributeName="gradientTransform"
type="rotate"
from="0"
to="45"
repeatCount="indefinite"
dur="25s"
/>
</g>
</svg>