久久r热视频,国产午夜精品一区二区三区视频,亚洲精品自拍偷拍,欧美日韩精品二区

您的位置:首頁技術文章
文章詳情頁

html5 - svg如何做到一組動畫循環

瀏覽:120日期:2023-01-29 15:27:39

問題描述

問題解答

回答1:

如果只是單純的改變寬度,少年可以這樣實現

<svg> <rect x=’20’ y=’20’ width=’250’ height=’250’ fill=’blue’><animate animateType='css' attributeName='width' values='250;0;250' dur='3s' repeatCount='indefinite'/> </rect></svg>回答2:

給animate添加id后,使用begin來指定動畫開始的時間為另一個的結束。

不清楚有沒有更好的辦法。

<svg> <rect x='20' y='20' fill='blue'><animate attributeType='CSS' attributeName='width' begin='0s; second.end' from='250' to='0' dur='1s'></animate><animate attributeType='CSS' attributeName='width' begin='first.end' from='0' to='250' dur='1s'></animate> </rect></svg>

標簽: Html5
相關文章:
主站蜘蛛池模板: 平阳县| 丰城市| 隆德县| 舟山市| 高邑县| 杂多县| 闽清县| 五寨县| 社会| 营山县| 墨竹工卡县| 特克斯县| 子洲县| 平阳县| 鄂州市| 太康县| 加查县| 安多县| 章丘市| 会理县| 安福县| 邵东县| 股票| 龙门县| 木兰县| 海盐县| 衡南县| 库尔勒市| 姚安县| 双柏县| 红桥区| 盘锦市| 新安县| 登封市| 柘城县| 绥化市| 乃东县| 仙游县| 兰州市| 辰溪县| 吉木乃县|