Orbit loader
A loading indicator of three planets on tilted orbits around a glowing core. Pure CSS, no images.
import "./orbit-loader.css";
type OrbitLoaderProps = {
/** Size in pixels. */
size?: number;
/** Text read by screen readers. */
label?: string;
};
/**
* OrbitLoader: a pure CSS loader. Three rings are tilted in 3D and each
* carries one "planet" around a glowing core.
*/
export function OrbitLoader({
size = 120,
label = "Loading",
}: OrbitLoaderProps) {
return (
<div
className="gu-orbit"
role="status"
aria-label={label}
style={{ ["--size" as string]: `${size}px` }}
>
<span className="gu-orbit__core" />
<span className="gu-orbit__ring gu-orbit__ring--1">
<i />
</span>
<span className="gu-orbit__ring gu-orbit__ring--2">
<i />
</span>
<span className="gu-orbit__ring gu-orbit__ring--3">
<i />
</span>
</div>
);
}
Paste this into ChatGPT, Claude, Cursor, v0, Lovable or Bolt. It describes the layout, motion, colors and accessibility and includes the code, so the AI can rebuild it in any framework.
# Build this UI piece: Orbit loader
You are a senior front-end engineer. Recreate the piece below in my project. If I don't say which framework I use, ask once, then build it in that framework (React, Vue, Svelte, Angular, Astro, plain HTML/CSS/JS or anything else). Keep the behavior, motion, colors, spacing and accessibility exactly as described. Keep the code clean and commented for beginners.
## What it is
A pure-CSS loading indicator: a glowing orange core with three tilted rings orbiting it in 3D, each carrying a small lime "planet".
## Layout and look
- Square of --size (default 120px), perspective 600px, transform-style preserve-3d.
- Core: centered circle inset 38%, radial-gradient(circle at 35% 30%, #ffb08f, #ff5a1f 55%, #b33a0d), glow box-shadow 0 0 (size × 0.25) rgba(255,90,31,0.6).
- Rings: full-size circles with a 1.5px border rgba(255,90,31,0.35). Tilts: rotateX(70deg) with rotateY 0deg, 60deg and -60deg.
- Planet: 10px circle #d7ff3a with a 12px glow of the same color, placed at the top center of each ring.
## Behavior and motion
- Each ring spins rotateZ 0→360deg linearly, forever, applied after its tilt (transform: tilt rotateZ(angle)). Durations 1.8s, 2.6s and 3.4s (the last one reversed) so they never line up.
- The core gently scales to 1.12 and back every 2.4s.
## Accessibility
- Root has role="status" and an aria-label ("Loading").
- prefers-reduced-motion: rings freeze in their tilted positions; the core slowly fades between 100% and 55% opacity instead of scaling, so loading is still communicated.
## Props
size (px), label (string).
## Reference implementation
The original is written in React with one plain CSS file. Dependencies: none (plain React and CSS). Translate it faithfully; do not add new libraries unless my framework needs them.
### OrbitLoader.tsx
```tsx
import "./orbit-loader.css";
type OrbitLoaderProps = {
/** Size in pixels. */
size?: number;
/** Text read by screen readers. */
label?: string;
};
/**
* OrbitLoader: a pure CSS loader. Three rings are tilted in 3D and each
* carries one "planet" around a glowing core.
*/
export function OrbitLoader({
size = 120,
label = "Loading",
}: OrbitLoaderProps) {
return (
<div
className="gu-orbit"
role="status"
aria-label={label}
style={{ ["--size" as string]: `${size}px` }}
>
<span className="gu-orbit__core" />
<span className="gu-orbit__ring gu-orbit__ring--1">
<i />
</span>
<span className="gu-orbit__ring gu-orbit__ring--2">
<i />
</span>
<span className="gu-orbit__ring gu-orbit__ring--3">
<i />
</span>
</div>
);
}
```
### orbit-loader.css
```css
.gu-orbit {
--size: 120px;
--core: #ff5a1f;
--planet: #d7ff3a;
--ring: rgb(255 90 31 / 0.35);
position: relative;
width: var(--size);
height: var(--size);
perspective: 600px;
transform-style: preserve-3d;
}
.gu-orbit__core {
position: absolute;
inset: 38%;
border-radius: 50%;
background: radial-gradient(
circle at 35% 30%,
#ffb08f,
var(--core) 55%,
#b33a0d
);
box-shadow: 0 0 calc(var(--size) * 0.25) rgb(255 90 31 / 0.6);
animation: gu-orbit-pulse 2.4s ease-in-out infinite;
}
.gu-orbit__ring {
position: absolute;
inset: 0;
border: 1.5px solid var(--ring);
border-radius: 50%;
transform-style: preserve-3d;
animation: gu-orbit-spin 2.2s linear infinite;
}
/* Each ring gets its own tilt and speed. */
.gu-orbit__ring--1 {
--tilt: rotateX(70deg) rotateY(0deg);
animation-duration: 1.8s;
}
.gu-orbit__ring--2 {
--tilt: rotateX(70deg) rotateY(60deg);
animation-duration: 2.6s;
}
.gu-orbit__ring--3 {
--tilt: rotateX(70deg) rotateY(-60deg);
animation-duration: 3.4s;
animation-direction: reverse;
}
.gu-orbit__ring i {
position: absolute;
top: -5px;
left: calc(50% - 5px);
width: 10px;
height: 10px;
border-radius: 50%;
background: var(--planet);
box-shadow: 0 0 12px var(--planet);
}
@keyframes gu-orbit-spin {
from {
transform: var(--tilt) rotateZ(0deg);
}
to {
transform: var(--tilt) rotateZ(360deg);
}
}
@keyframes gu-orbit-pulse {
50% {
transform: scale(1.12);
}
}
@media (prefers-reduced-motion: reduce) {
.gu-orbit__ring {
animation: none;
transform: var(--tilt);
}
.gu-orbit__core {
animation: gu-orbit-fade 2.4s ease-in-out infinite !important;
animation-duration: 2.4s !important;
}
@keyframes gu-orbit-fade {
50% {
opacity: 0.55;
}
}
}
```
You might also want
Next piece: Bento features gridCurtain page loader
Animations, intermediate
Loader set
Animations, beginner
Split-flap countdown
Animations, intermediate