1、兼容性根据canius(http://caniuse.com/#search=transition),transition 兼容性如下图所示: 1 <!DOCTYPE html> 2 <html> 3 <head> 4 &l ...
1、兼容性
根据canius(http://caniuse.com/#search=transition),transition 兼容性如下图所示:
1 <!DOCTYPE html> 2 <html> 3 <head> 4 <style> 5 div 6 { 7 width:100px; 8 height:100px; 9 background:blue;10 transition:width 2s;11 -moz-transition:width 2s; /* Firefox 4 */12 -webkit-transition:width 2s; /* Safari and Chrome */13 -o-transition:width 2s; /* Opera */14 }15 16 div:hover17 {18 width:300px;19 }20 </style>21 </head>22 <body>23 24 <div></div>25 26 <p>请把鼠标指针移动到蓝色的 div 元素上,就可以看到过渡效果。</p>27 28 <p><b>注释:</b>本例在 Internet Explorer 中无效。</p>29 30 </body>31 </html>
原标题:CSS3 transition 浏览器兼容性
关键词:CSS
*特别声明:以上内容来自于网络收集,著作权属原作者所有,如有侵权,请联系我们:
admin#shaoqun.com
(#换成@)。