Skip to content

Bouncing Trio

Dots · Bounce · playful, ui

Customize

HTML

<div class="utw-loader-bouncing-trio" role="status">
  <span class="utw-loader-bouncing-trio__dot"></span>
  <span class="utw-loader-bouncing-trio__dot"></span>
  <span class="utw-loader-bouncing-trio__dot"></span>
  <span class="utw-loader-bouncing-trio__sr">Loading…</span>
</div>

CSS

/* Dots loader (Bounce) */
.utw-loader-bouncing-trio {
  box-sizing: border-box;
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 32px;
}

.utw-loader-bouncing-trio *,
.utw-loader-bouncing-trio *::before,
.utw-loader-bouncing-trio *::after {
  box-sizing: border-box;
}

.utw-loader-bouncing-trio__dot {
  display: block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #6366f1;
  animation: utw-loader-bouncing-trio-bounce 1.2s ease-in-out infinite;
}

.utw-loader-bouncing-trio__dot:nth-child(even) {
  background: #6366f1;
}

.utw-loader-bouncing-trio__dot:nth-child(1) {
  animation-delay: -1.2s;
}

.utw-loader-bouncing-trio__dot:nth-child(2) {
  animation-delay: -1s;
}

.utw-loader-bouncing-trio__dot:nth-child(3) {
  animation-delay: -0.8s;
}

.utw-loader-bouncing-trio__sr {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@keyframes utw-loader-bouncing-trio-bounce {
  0%,
  80%,
  100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(-12px);
  }
}

@keyframes utw-loader-bouncing-trio-calm {
  from {
    opacity: 1;
  }
  to {
    opacity: 0.5;
  }
}

@media (prefers-reduced-motion: reduce) {
  .utw-loader-bouncing-trio *,
  .utw-loader-bouncing-trio *::before,
  .utw-loader-bouncing-trio *::after {
    animation: none !important;
  }
  .utw-loader-bouncing-trio {
    animation: utw-loader-bouncing-trio-calm 2s ease-in-out infinite alternate !important;
  }
}

Related loaders