Component v1.1.0 Foundations

Skeleton

Decorative loading placeholder for cards, text, avatars, and table rows.

API Stable 2.1 WCAG notes Ready Dark mode
Selector
ui-skeleton
Package
@ngnova/ui/skeleton

Import

Standalone Tailwind v4
import { UiSkeletonComponent } from '@ngnova/ui/skeleton';

Usage & variants

Live examples use the public ui-skeleton API, paired with the exact snippet a product team would paste into an Angular app.

API Reference

Loading card placeholder

Decorative loading placeholder for cards, text, avatars, and table rows.

Production guidance

Use these notes to decide when the component belongs in a product workflow and what to verify before shipping.

When to use

Use when real content shape is known and loading may take long enough to cause visual shift.

Watch for

Avoid replacing every tiny detail with a skeleton; preserve major layout blocks only.

Product recipes

Apply Skeleton in distinct, copyable product scenarios—not just an isolated component state.

Card placeholder

Combine circle and text placeholders for realistic loading states.

Angular template ui-skeleton-recipe.example.html
1
2
3
4
5
<div class="space-y-3">
  <ui-skeleton shape="circle" width="2.5rem" height="2.5rem" />
  <ui-skeleton shape="text" width="70%" height="0.875rem" />
  <ui-skeleton height="8rem" />
</div>

Results table loading

Repeat aligned placeholders to preserve table rhythm while report data is loading.

Angular template ui-skeleton-recipe.example.html
1
2
3
4
5
6
7
8
9
<div aria-busy="true" aria-label="Loading release results" class="grid gap-3">
  @for (row of [1, 2, 3]; track row) {
    <div class="grid grid-cols-[2fr_1fr_5rem] gap-4">
      <ui-skeleton />
      <ui-skeleton />
      <ui-skeleton />
    </div>
  }
</div>

API Reference

Inputs and outputs are semver-sensitive public API. Keep examples aligned with this table.

Inputs

shape 'rect'
'text' | 'rect' | 'circle'

Placeholder shape.

width '100%'
string

CSS width value.

height '1rem'
string

CSS height value.

animated true
boolean

Enables the pulse animation, with automatic reduced-motion suppression.

Accessibility

  • Skeleton is aria-hidden because another live region or loading label should announce loading.
  • Pulse animation automatically stops when the user prefers reduced motion.

Keyboard behavior

  • Skeleton has no keyboard interaction.

Testing guidance

  • Assert aria-hidden, all shapes, width/height bindings, and animation opt-out.
  • No component harness is included because Skeleton is decorative, non-interactive, and intentionally absent from the accessibility tree.