AurumSkeleton

Aurum's shimmer/skeleton loading placeholder — the SwiftUI port of aurum-android's AurumSkeleton.

familyFeedback
platformiOS 17+ · SwiftUI
sourceSources/Aurum/Component/Feedback/AurumSkeleton.swift
snapshots1 baselines · iPhone 17 Pro · iOS 26.5

Aurum's shimmer/skeleton loading placeholder — the SwiftUI port of aurum-android's AurumSkeleton.

Renders a solid mid-contrast background with a translucent shimmer gradient that animates horizontally left to right. Callers control the clipping shape via the initializer and dimensions via .frame(...):

// Text-line placeholder AurumSkeleton() .frame(height: Aurum.space.s5)

// Avatar placeholder AurumSkeleton(shape: Circle()) .frame(width: Aurum.space.s9, height: Aurum.space.s9)

Intended use

Use as a content-shaped placeholder during the initial fetch on list / detail surfaces, where the eventual layout is known and the wait is multi-second. Keeps the surface visually stable so users perceive less latency. For action-bound short waits use AurumLoader instead.

Do

  • Match the skeleton dimensions and shape to the eventual content (avatar circle, full-width text-line height) so the swap-in is invisible.
  • Render multiple skeletons with realistic variation in widths to mimic real text — uniform-width rows look fake.
  • Keep the shimmer running until real content is ready; never freeze on a static skeleton frame.

Don’t

  • Use for short single-action waits — that's AurumLoader.
  • Render skeletons indefinitely on error states — switch to a meaningful empty/error view after a reasonable timeout.
  • Replace text-line skeletons with bare horizontal lines — pad to the realistic line height so the layout doesn't jump on swap-in.

Snapshots

Recorded on the pinned simulator — iPhone 17 Pro · iOS 26.5 · Xcode 26.6.

AurumSkeleton — ComponentSnapshotTests · testSkeleton
ComponentSnapshotTests · testSkeleton