Skip to content

Spinner for Angular

AngularFeedback

Indeterminate loading indicator: a role=“status” region with a decorative rotating icon and a localized label that is announced politely when it appears. An optional delay avoids flicker for fast operations.

  • Accessible statusA status role with a label, visible or for screen readers only.
  • Show delayWaits before it appears, so quick loads never flash a spinner.
  • Three sizesSmall, medium, and large, with an icon you can replace.
  • Reduced motionRespects the reduced motion preference of the user.

Behavior, design tokens, and limitations are described on the Spinner page; this page covers the Angular API.

import { Component, signal } from '@angular/core';
import { AuiSpinner } from '@absoluteui/angular/spinner';
@Component({
selector: 'app-results',
imports: [AuiSpinner],
template: `@if (loading()) { <aui-spinner label="Loading results" [delay]="300" size="sm"></aui-spinner> }`,
})
export class ResultsComponent {
readonly loading = signal(true);
}
Terminal window
npm install @absoluteui/angular @absoluteui/components @absoluteui/core @absoluteui/theme

Setup with provideAbsoluteUI() is covered in Getting started. Styles are included with the component.

import { AuiSpinner } from '@absoluteui/angular/spinner';

Defaults for every instance: provideAbsoluteUIConfig({ components: { spinner: { ... } } }) (see Configuration).

Class AuiSpinner; template reference #ref="auiSpinner".

Server rendering: Renders on the server; the browser re-creates it after hydration.

Input Type Default Description
label string Announced (and optionally visible) label. Default: localized “Loading”.
showLabel boolean false Show the label visibly; otherwise it is visually hidden but announced.
icons Partial<SpinnerIcons> Icon slot overrides.
size SpinnerSize 'md' Icon size.
delay number '0' Milliseconds (integer 0..60000) before the content is shown.
locale string 'en-US' Message locale for the default label.

Pattern: ARIA status live region (role=“status”, implicit aria-live=“polite”).

The Angular component renders the framework-neutral component, so its keyboard support, roles, WCAG 2.2 criteria, budgets, and import cost apply unchanged: see Spinner: Accessibility and performance.