cube-grid.html 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. <style>
  2. body, html, #<%= globals.id %> {
  3. background: <%= options.background %>;
  4. width: 100%;
  5. height: 100%;
  6. display: flex;
  7. justify-content: center;
  8. align-items: center;
  9. margin: 0;
  10. padding: 0;
  11. }
  12. .sk-cube-grid {
  13. width: 40px;
  14. height: 40px;
  15. }
  16. .sk-cube-grid .sk-cube {
  17. width: 33%;
  18. height: 33%;
  19. background-color: <%= options.color %>;
  20. float: left;
  21. -webkit-animation: sk-cubeGridScaleDelay 1.3s infinite ease-in-out;
  22. animation: sk-cubeGridScaleDelay 1.3s infinite ease-in-out;
  23. }
  24. .sk-cube-grid .sk-cube1 {
  25. -webkit-animation-delay: 0.2s;
  26. animation-delay: 0.2s; }
  27. .sk-cube-grid .sk-cube2 {
  28. -webkit-animation-delay: 0.3s;
  29. animation-delay: 0.3s; }
  30. .sk-cube-grid .sk-cube3 {
  31. -webkit-animation-delay: 0.4s;
  32. animation-delay: 0.4s; }
  33. .sk-cube-grid .sk-cube4 {
  34. -webkit-animation-delay: 0.1s;
  35. animation-delay: 0.1s; }
  36. .sk-cube-grid .sk-cube5 {
  37. -webkit-animation-delay: 0.2s;
  38. animation-delay: 0.2s; }
  39. .sk-cube-grid .sk-cube6 {
  40. -webkit-animation-delay: 0.3s;
  41. animation-delay: 0.3s; }
  42. .sk-cube-grid .sk-cube7 {
  43. -webkit-animation-delay: 0s;
  44. animation-delay: 0s; }
  45. .sk-cube-grid .sk-cube8 {
  46. -webkit-animation-delay: 0.1s;
  47. animation-delay: 0.1s; }
  48. .sk-cube-grid .sk-cube9 {
  49. -webkit-animation-delay: 0.2s;
  50. animation-delay: 0.2s; }
  51. @-webkit-keyframes sk-cubeGridScaleDelay {
  52. 0%, 70%, 100% {
  53. -webkit-transform: scale3D(1, 1, 1);
  54. transform: scale3D(1, 1, 1);
  55. } 35% {
  56. -webkit-transform: scale3D(0, 0, 1);
  57. transform: scale3D(0, 0, 1);
  58. }
  59. }
  60. @keyframes sk-cubeGridScaleDelay {
  61. 0%, 70%, 100% {
  62. -webkit-transform: scale3D(1, 1, 1);
  63. transform: scale3D(1, 1, 1);
  64. } 35% {
  65. -webkit-transform: scale3D(0, 0, 1);
  66. transform: scale3D(0, 0, 1);
  67. }
  68. }
  69. </style>
  70. <div class="sk-cube-grid">
  71. <div class="sk-cube sk-cube1"></div>
  72. <div class="sk-cube sk-cube2"></div>
  73. <div class="sk-cube sk-cube3"></div>
  74. <div class="sk-cube sk-cube4"></div>
  75. <div class="sk-cube sk-cube5"></div>
  76. <div class="sk-cube sk-cube6"></div>
  77. <div class="sk-cube sk-cube7"></div>
  78. <div class="sk-cube sk-cube8"></div>
  79. <div class="sk-cube sk-cube9"></div>
  80. </div>
  81. <%= options.dev ? '<!-- http://tobiasahlin.com/spinkit -->' : '' %>