实例:
![](https://i-blog.csdnimg.cn/blog_migrate/9d0ec41e2d8866d1fcc491e34e243294.gif)
实例代码:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>视频标签栏切换</title>
<style>
* {
padding: 0;
margin: 0;
}
ul {
list-style-type: none;
}
a {
text-decoration: none;
color: #e1e1e1;
}
.contain {
position: relative;
top: 10px;
width: 100%;
height: 500px;
}
.box1 {
display: block;
overflow: hidden;
position: absolute;
width: 100%;
height: 100%;
}
.ul1 {
width: 100%;
height: 100%;
}
.box1-li {
background-size: 100% 100%;
width: 100%;
}
.box1-li a {
width: 100%;
height: 100%;
position: absolute;
}
.ul1 .current {
display: block;
height: 100%;
}
.box2 {
display: inline-block;
position: absolute;
top: 5px;
right: 10%;
width: 280px;
height: 490px;
background: rgba(0, 0, 0, 0.5);
}
.ul2 {
width: 100%;
margin-top: 30px;
}
.box2-li {
w