@layer fc.components {
.fc-spinner {
--fc-spinner-size: 1.25rem;
--fc-spinner-stroke: max(var(--fc-border-width-thick), calc(var(--fc-spinner-size) / 10));
--fc-spinner-slow: 1;
position: relative;
display: inline-block;
flex-shrink: 0;
inline-size: var(--fc-spinner-size);
block-size: var(--fc-spinner-size);
vertical-align: middle;
color: var(--fc-color-accent-text);
border: var(--fc-spinner-stroke) solid color-mix(in oklch, currentColor 20%, transparent);
border-block-start-color: currentColor;
border-radius: var(--fc-radius-full);
animation: fc-spinner-rotate calc(0.7s * var(--fc-spinner-slow)) linear infinite;
}
.fc-spinner--xs {
--fc-spinner-size: 0.75rem;
}
.fc-spinner--sm {
--fc-spinner-size: 1rem;
}
.fc-spinner--lg {
--fc-spinner-size: 2rem;
}
.fc-spinner--xl {
--fc-spinner-size: 3rem;
}
.fc-spinner--muted {
color: var(--fc-color-text-muted);
}
.fc-spinner--current {
color: inherit;
}
.fc-spinner--arc {
border: 0;
background-image: conic-gradient(transparent 10%, currentColor);
mask-image: radial-gradient(
farthest-side,
transparent calc(100% - var(--fc-spinner-stroke) - 0.03rem),
currentColor calc(100% - var(--fc-spinner-stroke))
);
animation-duration: calc(0.9s * var(--fc-spinner-slow));
}
.fc-spinner--dots {
display: inline-flex;
align-items: center;
justify-content: space-between;
inline-size: calc(var(--fc-spinner-size) * 1.6);
border: 0;
border-radius: 0;
animation: none;
}
.fc-spinner--dots > * {
inline-size: calc(var(--fc-spinner-size) * 0.32);
block-size: calc(var(--fc-spinner-size) * 0.32);
background-color: currentColor;
border-radius: var(--fc-radius-full);
animation: fc-spinner-bounce calc(1.2s * var(--fc-spinner-slow)) var(--fc-easing-standard) infinite;
}
.fc-spinner--dots > :nth-child(2) {
animation-delay: calc(0.15s * var(--fc-spinner-slow));
}
.fc-spinner--dots > :nth-child(3) {
animation-delay: calc(0.3s * var(--fc-spinner-slow));
}
.fc-spinner--pulse {
border: 0;
background-color: currentColor;
scale: 0.5;
animation: fc-spinner-pulse calc(1.6s * var(--fc-spinner-slow)) var(--fc-easing-decelerate) infinite;
}
.fc-spinner--bars {
display: inline-flex;
align-items: center;
justify-content: space-between;
border: 0;
border-radius: 0;
animation: none;
}
.fc-spinner--bars > * {
inline-size: 18%;
block-size: 100%;
background-color: currentColor;
border-radius: var(--fc-radius-full);
scale: 1 0.35;
animation: fc-spinner-bars calc(1s * var(--fc-spinner-slow)) ease-in-out infinite;
}
.fc-spinner--bars > :nth-child(2) {
animation-delay: calc(-0.8s * var(--fc-spinner-slow));
}
.fc-spinner--bars > :nth-child(3) {
animation-delay: calc(-0.6s * var(--fc-spinner-slow));
}
.fc-spinner--bars > :nth-child(4) {
animation-delay: calc(-0.4s * var(--fc-spinner-slow));
}
.fc-spinner--orbit {
border: 0;
background-image:
radial-gradient(circle at 50% 14%, currentColor 0 13%, transparent 14%),
radial-gradient(
circle at 50% 86%,
color-mix(in oklch, currentColor 40%, transparent) 0 11%,
transparent 12%
),
radial-gradient(
circle,
transparent 0 46%,
color-mix(in oklch, currentColor 15%, transparent) 47% 50%,
transparent 51%
);
animation-duration: calc(1.4s * var(--fc-spinner-slow));
animation-timing-function: var(--fc-easing-standard);
}
.fc-spinner--sparkle {
border: 0;
border-radius: 0;
background-image: var(
--fc-spinner-fill,
linear-gradient(135deg, var(--fc-color-accent-bg), var(--fc-color-info-bg))
);
clip-path: polygon(
50% 0%, 61% 39%, 100% 50%, 61% 61%,
50% 100%, 39% 61%, 0% 50%, 39% 39%
);
animation: fc-spinner-sparkle calc(1.6s * var(--fc-spinner-slow)) var(--fc-easing-standard) infinite;
}
@keyframes fc-spinner-rotate {
to {
rotate: 1turn;
}
}
@keyframes fc-spinner-bounce {
0%, 70%, 100% {
translate: 0 0;
opacity: 0.35;
}
35% {
translate: 0 -45%;
opacity: 1;
}
}
@keyframes fc-spinner-pulse {
0% {
scale: 0.45;
box-shadow: 0 0 0 0 color-mix(in oklch, currentColor 50%, transparent);
}
60% {
scale: 0.55;
box-shadow: 0 0 0 calc(var(--fc-spinner-size) * 0.45) transparent;
}
100% {
scale: 0.45;
box-shadow: 0 0 0 0 transparent;
}
}
@keyframes fc-spinner-bars {
0%, 100% {
scale: 1 0.35;
}
50% {
scale: 1 1;
}
}
@keyframes fc-spinner-sparkle {
0% {
rotate: 0deg;
scale: 0.7;
}
50% {
rotate: 45deg;
scale: 1;
}
100% {
rotate: 90deg;
scale: 0.7;
}
}
@keyframes fc-spinner-fade {
0%, 100% {
opacity: 0.35;
}
50% {
opacity: 1;
}
}
.fc-shimmer-text {
background-image: linear-gradient(
90deg,
var(--fc-color-text-muted) 0%,
var(--fc-color-text-muted) 35%,
var(--fc-color-text-default) 50%,
var(--fc-color-text-muted) 65%,
var(--fc-color-text-muted) 100%
);
background-size: 250% 100%;
background-clip: text;
color: transparent;
animation: fc-spinner-shimmer 2s linear infinite;
}
.fc-shimmer-text:dir(rtl) {
animation-direction: reverse;
}
@keyframes fc-spinner-shimmer {
from {
background-position: 100% 0;
}
to {
background-position: 0% 0;
}
}
@media (prefers-reduced-motion: reduce) {
.fc-spinner {
--fc-spinner-slow: 3;
}
.fc-spinner--dots > *,
.fc-spinner--bars > * {
translate: none;
scale: none;
animation-name: fc-spinner-fade;
}
.fc-spinner--pulse {
scale: 0.5;
animation-name: fc-spinner-fade;
}
.fc-spinner--sparkle {
scale: 0.85;
animation-name: fc-spinner-fade;
}
.fc-shimmer-text {
animation: none;
background-image: none;
color: var(--fc-color-text-muted);
}
}
@media (forced-colors: active) {
.fc-spinner {
forced-color-adjust: none;
color: CanvasText;
}
.fc-spinner--sparkle {
background-image: none;
background-color: CanvasText;
}
.fc-shimmer-text {
background-image: none;
color: CanvasText;
animation: none;
}
}
}