1、代码:
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>JS过度和变形效果演示</title>
<style type="text/css">
*{
margin: 0;
padding: 0;
}
.container{
158px;
height: 183px;
margin: 0 auto;
border:1px solid #fad282;
overflow: hidden;
}
.container img{
transition: all 1.2s ease;
}
.container img:hover{
transform: scale(1.2);
}
</style>
</head>
<body>
<div class="container">
<img src="html5.png" alt="html5.png">
</div>
</body>
</html>