<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>jquery的动画效果</title>
<script type="text/javascript" src="jquery-3.3.1.min.js"></script>
<style type="text/css">
.mian{
height:240px;
width: 200px;
margin-right: 20px;
float:left;
}
.box1,.box2 {
height: 200px;
width: 200px;
background: red;
}
button{
height: 40px;
width: 200px;
border:none;}
</style>
<script type="text/javascript">
$(document).ready(function(){
$('.box1').hide()
$('.btu1').click(function(){
$('.box1').fadeIn(1500)
})
$('.btu2').click(function(){
$('.box2').fadeOut(1500)
})
})
</script>
</head>
<body>
<div class="mian">
<button class="btu1">淡入</button>
<div class="box1"></div>
</div>
<br>
<div>
<button class="btu2">淡出</button>
<div class="box2"></div>
</div>
</body>
</html>
Are you asking if the animation effect of this is not smooth enough?