Skip to main content
cngx-src documentation

CngxTabBusySpinnerContext

Interface

projects/common/tabs/slots/tab-busy-spinner.directive.ts

Referenced by#

Import#

import { CngxTabBusySpinnerContext } from '@cngx/common/tabs'

Description#

Context for the *cngxTabBusySpinner template. Renders only on the in-flight commit target (matches presenter.intendedIndex() with commitState.status() === 'pending'); the visibility gate stays library-owned. intendedIndex is exposed so positional variants (progress bars, step counters) read the same source.

Index#

Instance Properties#

intendedIndex#number
Readonly

The flat-index of the in-flight commit target.

Readonly

The tab handle carrying id / label / disabled / aggregator signals.

CngxTabBusySpinner

The slot replaces only the visible spinner on the in-flight tab. The busy state is communicated to assistive tech by the library, so the template stays decorative.

  • Visibility is library-gated. The slot renders only while the tab is the in-flight commit target (status pending); the consumer never gates it.
  • The SR channel is library-owned. The tab button carries aria-busy="true" and an aria-describedby SR-only descriptor announces the pending state. The built-in glyph is aria-hidden.
  • Keep the template decorative. Do not add SR-only text inside it - the descriptor already announces, so a second label double-speaks. No interactive elements.
  • Do not signal busy by motion or colour alone. The aria-busy plus descriptor channel is the source of truth and is library-owned; the spinner is visual reinforcement.