黑松山资源网 Design By www.paidiu.com
用CSS3实现了一个小风车的效果,转转转,挺简单。
效果
代码
XML/HTML Code复制内容到剪贴板- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta charset="UTF-8">
- <title>小风车-转啊转</title>
- <style type="text/css">
- html {
- font-size: 10px;
- }
- html * {
- -webkit-box-sizing: border-box;
- box-sizing: border-box;
- }
- .windmill {
- width: 25rem;
- min-height: 30rem;
- height: auto;
- margin: 3rem auto;
- display: -webkit-box;
- display: -webkit-flex;
- display: -ms-flexbox;
- display: flex;
- -webkit-box-orient: vertical;
- -webkit-box-direction: normal;
- -webkit-flex-direction: column;
- -ms-flex-direction: column;
- flex-direction: column;
- -webkit-box-pack: start;
- -webkit-justify-content: flex-start;
- -ms-flex-pack: start;
- justify-content: flex-start;
- -webkit-box-align: center;
- -webkit-align-items: center;
- -ms-flex-align: center;
- align-items: center;
- }
- /* 头部 */
- .windmill-head {
- height: 20rem;
- width: 20rem;
- display: -webkit-box;
- display: -webkit-flex;
- display: -ms-flexbox;
- display: flex;
- -webkit-box-orient: horizontal;
- -webkit-box-direction: normal;
- -webkit-flex-direction: row;
- -ms-flex-direction: row;
- flex-direction: row;
- -webkit-flex-wrap: wrap;
- -ms-flex-wrap: wrap;
- flex-wrap: wrap;
- -webkit-justify-content: space-around;
- -ms-flex-pack: distribute;
- justify-content: space-around;
- -webkit-align-content: space-around;
- -ms-flex-line-pack: distribute;
- align-content: space-around;
- -webkit-transform: translateZ(0);
- transform: translateZ(0);
- -webkit-animation: rotate-windmill 1s linear infinite;
- animation: rotate-windmill 1s linear infinite;
- border-radius: 50%;
- border: 0.1rem solid #DBE526;
- -webkit-transition: border-radius 2s linear;
- transition: border-radius 2s linear;
- }
- /* 两片叶子的包裹层 */
- .wrapper {
- display: -webkit-box;
- display: -webkit-flex;
- display: -ms-flexbox;
- display: flex;
- -webkit-box-orient: vertical;
- -webkit-box-direction: normal;
- -webkit-flex-direction: column;
- -ms-flex-direction: column;
- flex-direction: column;
- -webkit-flex-wrap: wrap;
- -ms-flex-wrap: wrap;
- flex-wrap: wrap;
- -webkit-box-pack: justify;
- -webkit-justify-content: space-between;
- -ms-flex-pack: justify;
- justify-content: space-between;
- height: 135%;
- width: 50%;
- -webkit-box-align: center;
- -webkit-align-items: center;
- -ms-flex-align: center;
- align-items: center;
- }
- /* 包裹层对称 */
- .wrapper1 {
- -webkit-transform: rotate(-45deg) translate(5rem);
- transform: rotate(-45deg) translate(5rem);
- -webkit-transform-origin: right center;
- transform-origin: right center;
- }
- .wrapper2 {
- -webkit-transform: rotate(45deg) translate(-5rem);
- transform: rotate(45deg) translate(-5rem);
- -webkit-transform-origin: left center;
- transform-origin: left center;
- }
- /* 扇叶的形状及底色 */
- .leaf {
- height: 13rem;
- width: 5rem;
- border-radius: 5rem/ 5rem 5rem 20rem 20rem;
- -webkit-box-shadow: 0.1rem 0.1rem 1rem rgba(64, 56, 56, .35) inset, 0.2rem 0.2rem 0.05rem rgba(0, 0, 0, .65);
- box-shadow: 0.1rem 0.1rem 1rem rgba(64, 56, 56, .35) inset, 0.2rem 0.2rem 0.05rem rgba(0, 0, 0, .65);
- }
- .leaf1 {
- border: 0.05rem solid #D1A23A;
- -webkit-transform: rotate(0deg) translate(0);
- transform: rotate(0deg) translate(0);
- background-color: rgba(230, 0, 100, 5);
- background: -webkit-gradient(linear, left top, left bottom, from(#D02CE4), to(#f5f5f5));
- background: -webkit-linear-gradient(top, #D02CE4, #f5f5f5);
- background: linear-gradient(180deg, #D02CE4, #f5f5f5);
- -webkit-transition: background 2s linear;
- transition: background 2s linear;
- }
- .leaf2 {
- border: 0.05rem solid #49D13A;
- background-color: rgba(230, 0, 150, 5);
- -webkit-transform: rotate(-180deg) translate(0);
- transform: rotate(-180deg) translate(0);
- background: -webkit-gradient(linear, left top, left bottom, from(#B91717), to(#f5f5f5));
- background: -webkit-linear-gradient(top, #B91717, #f5f5f5);
- background: linear-gradient(180deg, #B91717, #f5f5f5);
- -webkit-transition: background 2s linear 2s;
- transition: background 2s linear 2s;
- }
- .leaf3 {
- border: 0.05rem solid #C6079D;
- background-color: rgba(130, 0, 100, 5);
- -webkit-transform: rotate(0deg) translate(0);
- transform: rotate(0deg) translate(0);
- background: -webkit-gradient(linear, left top, left bottom, from(#1CBA9F), to(#f5f5f5));
- background: -webkit-linear-gradient(top, #1CBA9F, #f5f5f5);
- background: linear-gradient(180deg, #1CBA9F, #f5f5f5);
- -webkit-transition: background 2s linear;
- transition: background 2s linear;
- -webkit-transition: background 2s linear 4s;
- transition: background 2s linear 4s;
- }
- .leaf4 {
- border: 0.05rem solid #3A5FD1;
- background-color: rgba(230, 100, 100, 5);
- -webkit-transform: rotate(-180deg) translate(0);
- transform: rotate(-180deg) translate(0);
- background: -webkit-gradient(linear, left top, left bottom, from(#335642), to(#f5f5f5));
- background: -webkit-linear-gradient(top, #335642, #f5f5f5);
- background: linear-gradient(180deg, #335642, #f5f5f5);
- -webkit-transition: background 2s linear 6s;
- transition: background 2s linear 6s;
- }
- /* 尾部 */
- .windmill-pillar {
- -webkit-transform: translateZ(0);
- transform: translateZ(0);
- width: 3rem;
- height: 20rem;
- background: #FFF;
- -webkit-transform: translateY(-52%);
- transform: translateY(-52%);
- position: relative;
- z-index: -2;
- border-radius: 50% 50% 0 0;
- -webkit-animation: cd 2s linear infinite;
- animation: cd 2s linear infinite;
- }
- @-webkit-keyframes rotate-windmill {
- 0% {
- -webkit-transform: rotate(0);
- transform: rotate(0);
- }
- 100% {
- -webkit-transform: rotate(360deg);
- transform: rotate(360deg);
- }
- }
- @keyframes rotate-windmill {
- 0% {
- -webkit-transform: rotate(0);
- transform: rotate(0);
- }
- 100% {
- -webkit-transform: rotate(360deg);
- transform: rotate(360deg);
- }
- }
- @-webkit-keyframes cd {
- 0% {
- background: #F5F5F5;
- }
- 50% {
- background: #E1CB82;
- }
- 75% {
- background: #F1F358;
- }
- 100% {
- background: #FFFC00;
- }
- }
- @keyframes cd {
- 0% {
- background: #F5F5F5;
- }
- 50% {
- background: #E1CB82;
- }
- 75% {
- background: #F1F358;
- }
- 100% {
- background: #FFFC00;
- }
- }
- </style>
- </head>
- <body>
- <div class="windmill">
- <div class="windmill-head">
- <div class="wrapper wrapper1">
- <div class="leaf leaf1"></div>
- <div class="leaf leaf2"></div>
- </div>
- <div class="wrapper wrapper2">
- <div class="leaf leaf3"></div>
- <div class="leaf leaf4"></div>
- </div>
- </div>
- <div class="windmill-pillar"></div>
- </div>
- </body>
- </html>
黑松山资源网 Design By www.paidiu.com
广告合作:本站广告合作请联系QQ:858582 申请时备注:广告合作(否则不回)
免责声明:本站资源来自互联网收集,仅供用于学习和交流,请遵循相关法律法规,本站一切资源不代表本站立场,如有侵权、后门、不妥请联系本站删除!
免责声明:本站资源来自互联网收集,仅供用于学习和交流,请遵循相关法律法规,本站一切资源不代表本站立场,如有侵权、后门、不妥请联系本站删除!
黑松山资源网 Design By www.paidiu.com
暂无评论...
RTX 5090要首发 性能要翻倍!三星展示GDDR7显存
三星在GTC上展示了专为下一代游戏GPU设计的GDDR7内存。
首次推出的GDDR7内存模块密度为16GB,每个模块容量为2GB。其速度预设为32 Gbps(PAM3),但也可以降至28 Gbps,以提高产量和初始阶段的整体性能和成本效益。
据三星表示,GDDR7内存的能效将提高20%,同时工作电压仅为1.1V,低于标准的1.2V。通过采用更新的封装材料和优化的电路设计,使得在高速运行时的发热量降低,GDDR7的热阻比GDDR6降低了70%。
更新日志
2024年11月16日
2024年11月16日
- 三国志8重制版恶名怎么消除 恶名影响与消除方法介绍
- 模拟之声慢刻CD《柏林之声5》2019[原抓WAV+CUE]
- AlexandraSoumm-Parisestunefte(2024)[24Bit-96kHz]FLAC
- 李嘉《国语转调1》[天王唱片][WAV整轨]
- 不是哥们 这都能跑?网友展示用720显卡跑《黑神话》
- 玩家自制《黑神话:悟空》亢金星君3D动画 现代妆容绝美
- 大佬的审美冲击!《GTA6》环境设计师展示最新作品
- 纪晓君.2001-野火·春风【魔岩】【WAV+CUE】
- 汪峰.2005-怒放的生命【创盟音乐】【WAV+CUE】
- 群星.1995-坠入情网【宝丽金】【WAV+CUE】
- 群星《谁杀死了Hi-Fi音乐》涂鸦精品 [WAV+CUE][1G]
- 群星1998《宝丽金最精彩98》香港首版[WAV+CUE][1G]
- 汪峰《也许我可以无视死亡》星文[WAV+CUE][1G]
- 李嘉-1991《国语转调2》[天王唱片][WAV整轨]
- 蔡琴2008《金声回忆录101》6CD[环星唱片][WAV整轨]