热门标签 | HotTags
当前位置:  开发笔记 > 编程语言 > 正文

小星星制作css3

```原理:一个正方形两个圆定位旋转圆角边属性body部分<body><div><!--:before

```

原理:一个正方形 两个圆 定位 旋转 圆角边属性 

body部分








css部分


.heart-body{
width: 200px;
height: 200px;
left: 50%;
top: 50%;
margin: 10px auto;
background: red;
position: absolute;
transform: rotate(45deg);
animation: love 1s ease infinite;
}
.heart-shape{
width: 200px;
height: 200px;
background: indianred;
box-shadow: 0 0 50px rgb(255,0,0);
}
.heart-body:before{
content:'';
width: 200px;
height: 200px;
background: indianred;
border-radius: 50%;
box-shadow: 0 0 50px rgb(255,0,0);
position: absolute;
top: 0;
left: -100px;
}
.heart-body:after{
content:'';
width: 200px;
height: 200px;
background: indianred;
border-radius: 50%;
box-shadow: 0 0 50px rgb(255,0,0);
position: absolute;
top: -100px;
left: 0px;
}
@keyframes love {
0%,100%{transform: scale(0.9,0.9)rotate(45deg)}
50%{transform: scale(1.2,1.2)rotate(45deg)}
}

```


推荐阅读
author-avatar
123123
这个家伙很懒,什么也没留下!
PHP1.CN | 中国最专业的PHP中文社区 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved | 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有