/*!
 * SPDX-License-Identifier: Apache-2.0
 *
 * The OpenSearch Contributors require contributions made to
 * this file be licensed under the Apache-2.0 license or a
 * compatible open source license.
 *
 * Modifications Copyright OpenSearch Contributors. See
 * GitHub history for details.
 */

.ouiBasicTable {

  &-loading {
    position: relative;

    tbody {
      overflow: hidden;
    }

    tbody:before {
      position: absolute;
      content: '';
      width: 100%;
      height: $ouiBorderWidthThick;
      background-color: $ouiColorPrimary;
      animation: ouiBasicTableLoading 1000ms linear;
      animation-iteration-count: infinite;
    }

  }
}


@keyframes ouiBasicTableLoading {
  from {
    left: 0;
    width: 0;
  }

  20% {
    left: 0;
    width: 40%;
  }

  80% {
    left: 60%;
    width: 40%;
  }

  100% {
    left: 100%;
    width: 0;
  }
}
