Orbit Loader

A compact loader made of nested orbit rings; each spins at a different speed and starting phase so the dots never align.

ByMihirJaiswalUpdated

Loading...

Orbit Loader is a small React loader that stacks 1–4 concentric rings, each with a single dot travelling around it. Alternating rotation directions and staggered speeds mean the dots never synchronise, so the motion stays visually interesting even at long dwell times. Pure CSS — zero JS runtime — and it honours prefers-reduced-motion.

Installation

Usage

import { OrbitLoader } from "@/components/ui/orbit-loader";
 
export function Example() {
  return <OrbitLoader />;
}

Tinted and larger

<OrbitLoader size={72} rings={4} speed={1.6} className="text-brand" />

Props

PropTypeDefaultDescription
sizenumber48Overall diameter in pixels.
colorstringcurrentColorColour for the orbiting dots.
ringColorstringmuted border toneColour for the ring strokes.
showRingsbooleantrueShow the orbit ring strokes.
speednumber1.2Base rotation period in seconds (inner ring).
ringsnumber3Number of orbiting rings. 1–4.
tailnumber120Arc length of the comet tail behind each dot, in degrees. 0 hides it.
labelstring"Loading"Accessible label.
classNamestring—Extra classes applied to the root <span>.