纯 CSS 实现的的3种扫光效果 - 掘金
https://juejin.cn/post/7385935890931712019
- .shark-wrap::after{
- content: '';
- position: absolute;
- inset: -20%;
- background: linear-gradient(45deg, rgba(255,255,255,0) 40%, rgba(255, 255, 255, 0.7), rgba(255,255,255,0) 60%);
- animation: shark-wrap 2s infinite;
- transform: translateX(-100%);
- }
- @keyframes shark-wrap {
- to {
- transform: translateX(100%);
- }
- }
复制代码
|
|