JSDM

HTML

 
1
<body>
2
<div class="wrapper">
3
  <div class="planet"></div>
4
  <div class="moon"></div>
5
</div>
6
  
7
</body>
!

CSS

x
 
1
/*moon movement*/
2
3
@-webkit-keyframes moonMovement {
4
   0%  {bottom:24%;left:14%;z-index: 1;}
5
    3% {bottom:27%;left:17%;}
6
    25% {-webkit-transform: scale(0.2);}
7
    47% {bottom:59%;left:69%;}
8
    49% {z-index: 1;-webkit-transform: scale(1);}
9
    50% {bottom:62%;left:72%;z-index: 10;box-shadow: -25px 25px 0 2px rgba(0,0,0,0.5)}
10
    57% {bottom:59%;left:69%;}
11
    75% {-webkit-transform: scale(2.2);box-shadow: 0px 0px 0 4px rgba(0,0,0,0.8)}
12
    97% {bottom:27%;left:17%;box-shadow: 15px -15px 0 2px rgba(0,0,0,0)}
13
    99% {z-index: 10;}
14
    100% {bottom:24%;left:14%;z-index: 1;-webkit-transform: scale(1);box-shadow: 15px -15px 0 2px rgba(0,0,0,0)}
15
}
16
17
@keyframes moonMovement {
18
   0%  {bottom:24%;left:14%;z-index: 1;}
19
    3% {bottom:27%;left:17%;}
20
    25% {-webkit-transform: scale(0.2);}
21
    47% {bottom:59%;left:69%;}
22
    49% {z-index: 1;-webkit-transform: scale(1);}
23
    50% {bottom:62%;left:72%;z-index: 10;box-shadow: -25px 25px 0 2px rgba(0,0,0,0.5)}
24
    57% {bottom:59%;left:69%;}
25
    75% {-webkit-transform: scale(2.2);box-shadow: 0px 0px 0 4px rgba(0,0,0,0.8)}
26
    97% {bottom:27%;left:17%;box-shadow: 15px -15px 0 2px rgba(0,0,0,0)}
27
    99% {z-index: 10;}
28
    100% {bottom:24%;left:14%;z-index: 1;-webkit-transform: scale(1);box-shadow: 15px -15px 0 2px rgba(0,0,0,0)}
29
}
30
31
32
33
body {
34
    background-color: #000;
35
}
36
37
.wrapper {
38
  width:250px;
39
  height:250px;
40
  /*border: 1px solid red;*/
41
  margin: 0 auto;
42
  margin-top: 10%;
43
  position: relative;
44
}
45
46
.planet {
47
  width:100px;
48
  height:100px;
49
  border-radius: 50%;
50
  background-color: #2574A9;
51
  position: absolute;
52
  left:50%;
53
  top:50%;
54
  box-shadow: -20px 20px 0 0px rgba(0,0,0,0.7);
55
  transform:translate(-50%,-50%);
56
  z-index: 5;
57
  overflow: hidden;
58
}
59
60
.planet::before {
61
  content:"";
62
  height:100px;
63
  width:100px;
64
  border-radius: 50%;
65
  position: absolute;
66
  left:10%;
67
  bottom:10%;
68
  background-color: #1A8BC3;
69
}
70
71
.planet::after {
72
  content:"";
73
  height:100px;
74
  width:100px;
75
  border-radius: 50%;
76
  position: absolute;
77
  left:15%;
78
  bottom:15%;
79
  background-color: #3498DB;
80
81
}
82
83
.moon {
84
  width:30px;
85
  height:30px;
86
  border-radius: 50%;
87
  background-color: #95A5A6;
88
  position: absolute;
89
  left:40%;
90
  bottom:30%;
91
  overflow: hidden;
92
  -webkit-animation: moonMovement 1.9s linear infinite;
93
  animation: moonMovement 1.9s linear infinite;
94
}
95
96
.moon::before {
97
  content:"";
98
  height:30px;
99
  width:30px;
100
  border-radius: 50%;
101
  position: absolute;
102
  left:10%;
103
  bottom:10%;
104
  background-color: #D2D7D3;
105
}
!
? ?
? ?
必须是有效的URL
+ 添加另一个资源

JS

xxxxxxxxxx
1
 
1
!
必须是有效的URL
+ 添加另一个资源
Close

文件管理 点击文件查看URL

图片

  1. 暂无文件

CSS

  1. 暂无文件

JavaScript

  1. 暂无文件

其他

  1. 暂无文件
拖动文件到上面的区域或者:
加载中 ..................