SOURCE

console 命令行工具 X clear

                    
>
console
function demo() {
  /***
    Add your demo script here...
    In this demo, click my button after 1000 milliseconds 
    You have approx three seconds to show off your stuff.
  ***/

  demointerval = setInterval(function() {
    var chkbox = document.querySelector('input[type="checkbox"]:not([checked])');
    if (chkbox) {
      chkbox.click();
      chkbox.setAttribute('checked', 'checked');
    } else {
      clearInterval(demointerval);
    }
  }, 600);
}
// Run demo if in searchresult preview frame
// http://codepen.io/jesperkc/post/trigger-animation-in-preview-frame
if (document.location.pathname.indexOf('fullcpgrid') > -1) {
  demo();
}
<div class="container">
  <div class="anim-icon heart">
    <input type="checkbox" id="heart" />
    <label for="heart"></label>
  </div>
  <div class="anim-icon star">
    <input type="checkbox" id="star" />
    <label for="star"></label>
  </div>
  <div class="anim-icon bookmark">
    <input type="checkbox" id="bookmark" />
    <label for="bookmark"></label>
  </div>

  <div></div>

  <div class="anim-icon anim-icon-lg heart">
    <input type="checkbox" id="heart2" />
    <label for="heart2"></label>
  </div>
  <div class="anim-icon anim-icon-lg star">
    <input type="checkbox" id="star2" />
    <label for="star2"></label>
  </div>
  <div class="anim-icon anim-icon-lg bookmark">
    <input type="checkbox" id="bookmark2" />
    <label for="bookmark2"></label>
  </div>

  <div></div>

  <div class="anim-icon anim-icon-md heart">
    <input type="checkbox" id="heart1" />
    <label for="heart1"></label>
  </div>
  <div class="anim-icon anim-icon-md star">
    <input type="checkbox" id="star1" />
    <label for="star1"></label>
  </div>
  <div class="anim-icon anim-icon-md bookmark">
    <input type="checkbox" id="bookmark1" />
    <label for="bookmark1"></label>
  </div>

</div>
html,
body {
  height: 100%;
}
.container {
  text-align: center;
  top: 50%;
  position: relative;
  margin-top: -141px;
}
.heart label {
  box-shadow: 0px 0px 0px 0px rgba(226, 32, 44, 0.5);
}
.heart label:after {
  content: "\f004";
}
.heart input:checked + label {
  background-color: #e2202c;
  border-color: #e2202c;
  box-shadow: 0px 0px 0px 0.5em rgba(226, 32, 44, 0);
}
.heart input:checked + label:after {
  color: #e2202c;
}
.star label {
  box-shadow: 0px 0px 0px 0px rgba(253, 192, 47, 0.5);
}
.star label:after {
  content: "\f005";
}
.star input:checked + label {
  background-color: #fdc02f;
  border-color: #fdc02f;
  box-shadow: 0px 0px 0px 0.5em rgba(253, 192, 47, 0);
}
.star input:checked + label:after {
  color: #fdc02f;
}
.bookmark label {
  box-shadow: 0px 0px 0px 0px rgba(13, 165, 142, 0.5);
}
.bookmark label:after {
  content: "\f02e";
}
.bookmark input:checked + label {
  background-color: #0da58e;
  border-color: #0da58e;
  box-shadow: 0px 0px 0px 0.5em rgba(13, 165, 142, 0);
}
.bookmark input:checked + label:after {
  color: #0da58e;
}
.anim-icon {
  width: 1.9em;
  height: 1.9em;
  margin: 20px;
  font-size: 13px;
  display: inline-block;
  position: relative;
  vertical-align: middle;
}
.anim-icon input {
  display: none;
}
.anim-icon label {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  border: 0.1em solid #ccc;
  border-radius: 100%;
  display: block;
  font: normal normal normal 13px/1 FontAwesome;
  color: #ccc;
  font-size: inherit;
  text-rendering: auto;
  -webkit-font-smoothing: antialiased;
}
.anim-icon label:after {
  left: 0;
  top: 50%;
  margin-top: -0.5em;
  display: block;
  position: relative;
  text-align: center;
}
.anim-icon input:checked + label {
  -webkit-animation: check-in 0.3s forwards;
          animation: check-in 0.3s forwards;
  -webkit-transition: background-color 0.1s 0.2s, box-shadow 1s;
  transition: background-color 0.1s 0.2s, box-shadow 1s;
  border-width: 0.1em;
  border-style: solid;
}
.anim-icon input:checked + label:after {
  -webkit-animation: icon .3s forwards;
          animation: icon .3s forwards;
}
.anim-icon-md {
  font-size: 20px;
}
.anim-icon-lg {
  font-size: 30px;
}
@-webkit-keyframes icon {
  0% {
    margin-top: -0.5em;
    font-size: 1.5em;
  }
  100% {
    font-size: 1em;
    opacity: 1;
    color: white;
  }
}
@keyframes icon {
  0% {
    margin-top: -0.5em;
    font-size: 1.5em;
  }
  100% {
    font-size: 1em;
    opacity: 1;
    color: white;
  }
}
@-webkit-keyframes check-in {
  0% {
    left: 20%;
    top: 20%;
    width: 60%;
    height: 60%;
  }
  80% {
    left: -5%;
    top: -5%;
    width: 110%;
    height: 110%;
  }
  100% {
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
  }
}
@keyframes check-in {
  0% {
    left: 20%;
    top: 20%;
    width: 60%;
    height: 60%;
  }
  80% {
    left: -5%;
    top: -5%;
    width: 110%;
    height: 110%;
  }
  100% {
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
  }
}
@-webkit-keyframes check {
  0% {
    left: 5%;
    top: 5%;
    width: 90%;
    height: 90%;
  }
  10% {
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
  }
  80% {
    left: -5%;
    top: -5%;
    width: 110%;
    height: 110%;
  }
  90% {
    left: 5%;
    top: 5%;
    width: 90%;
    height: 90%;
  }
  100% {
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
  }
}
@keyframes check {
  0% {
    left: 5%;
    top: 5%;
    width: 90%;
    height: 90%;
  }
  10% {
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
  }
  80% {
    left: -5%;
    top: -5%;
    width: 110%;
    height: 110%;
  }
  90% {
    left: 5%;
    top: 5%;
    width: 90%;
    height: 90%;
  }
  100% {
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
  }
}

本项目引用的自定义外部资源