<template>
  <div style="position: relative;">
    <div class="div">
      <span />
      <span />
      <span />
      <span />
    </div>
    <p class="text">
      输入中
    </p>
  </div>
</template>

<style scoped>
.text{
  display: block;
  width: 100%;
  font-size: 1.5em;
  text-align: center;
  position: absolute;
  left: 0;
  bottom: -6em;
}
.div {
  display: flex;
  flex-flow: row nowrap;
  align-items: center;
  justify-content: space-between;
  width: 20em;
}

span {
  width: 3em;
  height: 6em;
  background-color: #7fe7c4;
}

span:nth-of-type(1) {
  animation: grow 1s -0.45s ease-in-out infinite;
}

span:nth-of-type(2) {
  animation: grow 1s -0.3s ease-in-out infinite;
}

span:nth-of-type(3) {
  animation: grow 1s -0.15s ease-in-out infinite;
}

span:nth-of-type(4) {
  animation: grow 1s ease-in-out infinite;
}

@keyframes grow {
  0%,
  100% {
    transform: scaleY(1);
  }

  50% {
    transform: scaleY(2);
  }
}
</style>
