loading3.vue 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182
  1. <template>
  2. <view class="container loading3">
  3. <view class="shape shape1"></view>
  4. <view class="shape shape2"></view>
  5. <view class="shape shape3"></view>
  6. <view class="shape shape4"></view>
  7. </view>
  8. </template>
  9. <script>
  10. export default {
  11. name: 'loading3',
  12. data() {
  13. return {};
  14. }
  15. }
  16. </script>
  17. <style scoped="true">
  18. .container {
  19. width: 30px;
  20. height: 30px;
  21. position: relative;
  22. }
  23. .container.loading3 {
  24. -webkit-animation: rotation 1s infinite;
  25. animation: rotation 1s infinite;
  26. }
  27. .container.loading3 .shape1 {
  28. border-top-left-radius: 10px;
  29. }
  30. .container.loading3 .shape2 {
  31. border-top-right-radius: 10px;
  32. }
  33. .container.loading3 .shape3 {
  34. border-bottom-left-radius: 10px;
  35. }
  36. .container.loading3 .shape4 {
  37. border-bottom-right-radius: 10px;
  38. }
  39. .container .shape {
  40. position: absolute;
  41. width: 10px;
  42. height: 10px;
  43. border-radius: 1px;
  44. }
  45. .container .shape.shape1 {
  46. left: 0;
  47. background-color: #1890FF;
  48. }
  49. .container .shape.shape2 {
  50. right: 0;
  51. background-color: #91CB74;
  52. }
  53. .container .shape.shape3 {
  54. bottom: 0;
  55. background-color: #FAC858;
  56. }
  57. .container .shape.shape4 {
  58. bottom: 0;
  59. right: 0;
  60. background-color: #EE6666;
  61. }
  62. .loading3 .shape1 {
  63. -webkit-animation: animation3shape1 0.5s ease 0s infinite alternate;
  64. animation: animation3shape1 0.5s ease 0s infinite alternate;
  65. }
  66. @-webkit-keyframes animation3shape1 {
  67. from {
  68. -webkit-transform: translate(0, 0);
  69. transform: translate(0, 0);
  70. }
  71. to {
  72. -webkit-transform: translate(5px, 5px);
  73. transform: translate(5px, 5px);
  74. }
  75. }
  76. @keyframes animation3shape1 {
  77. from {
  78. -webkit-transform: translate(0, 0);
  79. transform: translate(0, 0);
  80. }
  81. to {
  82. -webkit-transform: translate(5px, 5px);
  83. transform: translate(5px, 5px);
  84. }
  85. }
  86. .loading3 .shape2 {
  87. -webkit-animation: animation3shape2 0.5s ease 0s infinite alternate;
  88. animation: animation3shape2 0.5s ease 0s infinite alternate;
  89. }
  90. @-webkit-keyframes animation3shape2 {
  91. from {
  92. -webkit-transform: translate(0, 0);
  93. transform: translate(0, 0);
  94. }
  95. to {
  96. -webkit-transform: translate(-5px, 5px);
  97. transform: translate(-5px, 5px);
  98. }
  99. }
  100. @keyframes animation3shape2 {
  101. from {
  102. -webkit-transform: translate(0, 0);
  103. transform: translate(0, 0);
  104. }
  105. to {
  106. -webkit-transform: translate(-5px, 5px);
  107. transform: translate(-5px, 5px);
  108. }
  109. }
  110. .loading3 .shape3 {
  111. -webkit-animation: animation3shape3 0.5s ease 0s infinite alternate;
  112. animation: animation3shape3 0.5s ease 0s infinite alternate;
  113. }
  114. @-webkit-keyframes animation3shape3 {
  115. from {
  116. -webkit-transform: translate(0, 0);
  117. transform: translate(0, 0);
  118. }
  119. to {
  120. -webkit-transform: translate(5px, -5px);
  121. transform: translate(5px, -5px);
  122. }
  123. }
  124. @keyframes animation3shape3 {
  125. from {
  126. -webkit-transform: translate(0, 0);
  127. transform: translate(0, 0);
  128. }
  129. to {
  130. -webkit-transform: translate(5px, -5px);
  131. transform: translate(5px, -5px);
  132. }
  133. }
  134. .loading3 .shape4 {
  135. -webkit-animation: animation3shape4 0.5s ease 0s infinite alternate;
  136. animation: animation3shape4 0.5s ease 0s infinite alternate;
  137. }
  138. @-webkit-keyframes animation3shape4 {
  139. from {
  140. -webkit-transform: translate(0, 0);
  141. transform: translate(0, 0);
  142. }
  143. to {
  144. -webkit-transform: translate(-5px, -5px);
  145. transform: translate(-5px, -5px);
  146. }
  147. }
  148. @keyframes animation3shape4 {
  149. from {
  150. -webkit-transform: translate(0, 0);
  151. transform: translate(0, 0);
  152. }
  153. to {
  154. -webkit-transform: translate(-5px, -5px);
  155. transform: translate(-5px, -5px);
  156. }
  157. }
  158. </style>