css实现文字顶部滚动模糊渐变效果代码
代码语言:html
所属分类:加载滚动
代码描述:css实现文字顶部滚动模糊渐变效果代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="en" >
<head>
<meta charset="UTF-8">
<style>
header {
height: 160px;
width: 100%;
position: fixed;
top: 0;
left: 0;
background: rgba(255, 255, 255, 0.8);
backdrop-filter: blur(4px);
mask: linear-gradient(to bottom, black 20%, rgba(0, 0, 0, 0));
}
header:after {
content: "";
position: absolute;
top: -20px;
width: 100%;
height: 50px;
background: rgba(255, 255, 255, 0.5);
filter: blur(4px);
}
.title {
position: sticky;
top: 16px;
font-size: 18px;
font-weight: bold;
}
div {
line-height: 1.3em;
}
</style>
</head>
<body translate="no">
<header></header>
<div class="title" style="max-width: 480px; margin: 120px auto 20px">Title</div>
<di.........完整代码请登录后点击上方下载按钮下载查看
















网友评论0