当前位置: 首页 > news >正文

方形变圆形html动画,CSS3 方形到圆角到圆形变换动画

CSS

语言:

CSSSCSS

确定

* {

padding: 0;

margin: 0;

box-sizing: border-box;

}

body {

background: #f5f5f5;

animation: bg 10s ease-in-out infinite;

}

@keyframes bg {

30% {

background: #2c3e50;

}

70% {

background: #415a8a;

}

}

.circle {

position: absolute;

top: 50%;

left: 50%;

transform: translate(-50%, -50%);

width: 100px;

height: 100px;

background: transparent;

border: 3px double tomato;

display: block;

animation: rt 2s ease-out infinite;

}

.circle:before {

content: '';

position: absolute;

top: 50%;

left: 50%;

transform: translate(-50%, -50%);

width: 100px;

height: 100px;

background: transparent;

border: 3px double tomato;

display: block;

animation: rt 3s ease-out infinite;

}

.circle:after {

content: '';

position: absolute;

top: 50%;

left: 50%;

transform: translate(-50%, -50%);

width: 120px;

height: 120px;

background: transparent;

border: 3px solid tomato;

display: block;

animation: rt 4s ease-out infinite;

}

.circle-two {

position: absolute;

top: 50%;

left: 50%;

transform: translate(-50%, -50%);

width: 200px;

height: 200px;

background: transparent;

border: 3px double tomato;

display: block;

animation: rtw 4s ease-out infinite;

}

.circle-two:before {

content: '';

position: absolute;

top: 50%;

left: 50%;

transform: translate(-50%, -50%);

width: 200px;

height: 200px;

background: transparent;

border: 3px solid tomato;

display: block;

animation: rtw 4s ease-out infinite;

}

.circle-two:after {

content: '';

position: absolute;

top: 50%;

left: 50%;

transform: translate(-50%, -50%);

width: 200px;

height: 200px;

background: transparent;

border: 3px solid tomato;

display: block;

animation: rtw 5s ease-out infinite;

}

@keyframes rt {

10% {

transform: translate(-50%, -50%) rotate(50deg);

}

50% {

transform: translate(-50%, -50%) rotate(180deg);

border-color: #295ba0;

height: 50px;

width: 50px;

}

70% {

border-radius: 50%;

}

100% {

transform: translate(-50%, -50%) rotate(360deg);

border-radius: 0%;

}

}

@keyframes rtw {

10% {

transform: translate(-50%, -50%) rotate(50deg);

}

50% {

transform: translate(-50%, -50%) rotate(180deg);

border-color: #2ecc71;

height: 50px;

width: 50px;

}

70% {

border-radius: 50%;

}

100% {

transform: translate(-50%, -50%) rotate(360deg);

border-radius: 0%;

}

}

相关文章:

  • 中移动员工工资待遇全揭秘
  • html代码格式化vscode,Vscode代码格式化
  • 视频:百度打击google的最新广告 google执行官估计得吐血
  • 从psd到css+div+html网页制作全流程过程讲解,从PSD到CSS+DIV+HTML网页制作全流程过程讲解_docx...
  • 1 制作一个表格html表格,学术论文表格制作速成!
  • WINDOWS专集大集合,绝对是精品中的精品
  • 鲁东大学2021高考成绩查询,2021年鲁东大学录取结果查询网址入口及录取结果公布时间...
  • 深山红叶袖珍PE系统工具箱说明 V22 正式版
  • 2021云南省卫生副高考试成绩查询,2021年卫生高级职称考试准考证打印入口:云南卫生健康人才网...
  • html文件无法通过复制粘贴传输,远程桌面无法复制粘贴传输文件解决办法
  • 计算机网络实验指导书谢希仁,计算机网络[谢希仁]实验指导书.doc
  • 燕山大学计算机网络课程设计,燕山大学计算机网络课程设计报告1.doc
  • 计算机大赛剪辑的视频,视频创作剪辑大赛活动策划
  • 大学生计算机课程内容1000字,大学生计算机实习报告1000字【一】.doc
  • Oracle10gR2 autotrace function was changed and enhanced
  • Android路由框架AnnoRouter:使用Java接口来定义路由跳转
  • JavaScript标准库系列——Math对象和Date对象(二)
  • Java精华积累:初学者都应该搞懂的问题
  • Kibana配置logstash,报表一体化
  • miniui datagrid 的客户端分页解决方案 - CS结合
  • mysql常用命令汇总
  • Node项目之评分系统(二)- 数据库设计
  • Redis提升并发能力 | 从0开始构建SpringCloud微服务(2)
  • SpringBoot 实战 (三) | 配置文件详解
  • ubuntu 下nginx安装 并支持https协议
  • vue+element后台管理系统,从后端获取路由表,并正常渲染
  • 干货 | 以太坊Mist负责人教你建立无服务器应用
  • 使用 Docker 部署 Spring Boot项目
  • 通信类
  • 微信小程序:实现悬浮返回和分享按钮
  • 我与Jetbrains的这些年
  • 消息队列系列二(IOT中消息队列的应用)
  • 新手搭建网站的主要流程
  • 一个普通的 5 年iOS开发者的自我总结,以及5年开发经历和感想!
  • 中国人寿如何基于容器搭建金融PaaS云平台
  • Spring第一个helloWorld
  • ​linux启动进程的方式
  • ###C语言程序设计-----C语言学习(3)#
  • (+3)1.3敏捷宣言与敏捷过程的特点
  • (13)Hive调优——动态分区导致的小文件问题
  • (27)4.8 习题课
  • (4)事件处理——(7)简单事件(Simple events)
  • (C语言)编写程序将一个4×4的数组进行顺时针旋转90度后输出。
  • (ZT) 理解系统底层的概念是多么重要(by趋势科技邹飞)
  • (附源码)ssm基于微信小程序的疫苗管理系统 毕业设计 092354
  • (九十四)函数和二维数组
  • (论文阅读30/100)Convolutional Pose Machines
  • (收藏)Git和Repo扫盲——如何取得Android源代码
  • (万字长文)Spring的核心知识尽揽其中
  • .gitattributes 文件
  • .net 8 发布了,试下微软最近强推的MAUI
  • .net core 连接数据库,通过数据库生成Modell
  • .net 设置默认首页
  • .net/c# memcached 获取所有缓存键(keys)
  • .NET/C# 使用 SpanT 为字符串处理提升性能