div+css模仿苹果手表图标滚动效果代码
代码语言:html
所属分类:加载滚动
代码描述:div+css模仿苹果手表图标滚动效果代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="en" >
<head>
<meta charset="UTF-8">
<style>
* {
box-sizing: border-box;
}
html {
color-scheme: light dark;
}
body {
display: flex;
align-items: center;
justify-content: center;
}
.box {
box-sizing: border-box;
border: 1px solid light-dark(black, white);
width: 400px;
height: 400px;
border-radius: 100px;
display: flex;
align-items: center;
justify-content: center;
flex-wrap: wrap;
row-gap: 16px;
overflow: auto;
}
.box::before, .box::after {
content: '';
display: block;
width: 100%;
height: 1px;
}
.profile {
position: relative;
background: grey;
width: 70px;
height: 70px;
border-radius: 50%;
animation-name: shrink-in-and-out;
animation-timeline: view();
animation-fill-mode: both;
transform-origin: 50% 50%;
/* animation-range: 10% entry 100%, exit -10%; */
}
.profile:nth-child(5n + 1),
.profile:nth-child(5n + 3),
.profile:nth-c.........完整代码请登录后点击上方下载按钮下载查看
















网友评论0