我想要一个 svg 对象从颜色“A”淡入颜色“B”,然后无限期地返回到颜色“A”。
到目前为止,我使用的成功有限
<animate attributeName="fill" from="colorA" to="colorB" dur="10s" repeatCount="indefinite" />
但这不允许我淡出颜色“A”。
任何帮助,将不胜感激。
Use the values
属性而不是from
and to
.
<svg>
<rect width="100%" height="100%">
<animate attributeName="fill" values="red;blue;red" dur="10s" repeatCount="indefinite" />
</rect>
</svg>
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)