2
0

_loading-mask.scss 846 B

12345678910111213141516171819202122232425262728293031323334353637
  1. @use 'sass:map';
  2. // Loading mask: overlays a certain area with a loading spinner and a faded out cover to prevent interaction
  3. .loading-mask {
  4. &.loading {
  5. position: relative;
  6. &:before,
  7. &:after {
  8. position: absolute;
  9. display: block;
  10. }
  11. &:before {
  12. content: '';
  13. top: -5px;
  14. inset-inline-start: -5px;
  15. bottom: -5px;
  16. inset-inline-end: -5px;
  17. z-index: 1;
  18. background-color: theme('colors.white-50');
  19. }
  20. &:after {
  21. content: '';
  22. display: block;
  23. width: 1.875rem;
  24. height: 1.875rem;
  25. inset-inline-start: 50%;
  26. top: 50%;
  27. animation: spin-wag 0.5s infinite linear;
  28. mask-image: url('#{$images-root}icons/spinner.svg');
  29. mask-repeat: no-repeat;
  30. z-index: 2;
  31. background: theme('colors.surface-button-default');
  32. }
  33. }
  34. }