<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>过渡动画</title>
<style type="text/css">
#div1 {
width: 100px;
height: 100px;
background: red;
/* 写在元素上会生效鼠标释放效果 */
/* transition: width 1s 1s; */
}
#div1:hover {
width: 200px;
/* 宽度过渡动画效果 */
/* transition-property: width; */
/* 过渡动画时间1秒 */
/* transition-duration: 1s; */
/* 动画效果-匀速 */
/* transition-timing-function: linear; */
/* 合并写法1.transition-property 2.transition-duration 3.transition-delay(延迟时间) */
transition: width 1s 1s;
}
</style>
</head>
<body>
<div id="div1"></div>
</body>
</html>