<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
/* #region */
html {
/* 滚动条添加滑动效果 */
scroll-behavior: smooth;
}
* {
margin: 0;
padding: 0;
}
.box {
position: relative;
}
.box6{
width: 500px;
height: 500px;
}
.box1 {
background-color: yellowgreen;
}
.box2 {
width: 500px;
height: 100px;
background-color: yellow;
position: absolute;
top: 0;
opacity: 0;
transition: .5s linear all;
}
/* 功能1 页面滑动和隐藏 */
.out {
position: fixed;
opacity: 1;
top: 0;
}
.box3 {
background-color: turquoise;
}
.box4 {
background-color: wheat;
JavaScript电梯导航1【基础】
最新推荐文章于 2024-04-10 15:12:17 发布
![](https://img-home.csdnimg.cn/images/20240711042549.png)