Angular Skeleton Loader Component | ng-hub-ui-skeleton

Angular skeleton loading placeholders with reusable presets, inline DSL templates, responsive values and CSS variables for shimmer states.

API reference

Here's the full contract for skeleton: everything you can bind, listen to, project and theme, gathered in one place. Wire up what you need and style what you want — it's standalone and signal-friendly.

Inputs

Dial skeleton in with 7 inputs. Bind them like any Angular @Input.

NameTypeDefaultDescription
presetstring | nullnullName of a bundled or registered preset. When provided, the component resolves defaults, variants and alias composition from the preset registry.
templatestring | HubSkeletonTemplateDefinition | nullnullInline Emmet-like DSL string or template definition object with optional responsive breakpoint overrides.
paramsHubSkeletonParams{}Serializable parameters interpolated into `{{param}}` placeholders before parsing and preset expansion.
variantstring | nullnullOptional preset variant name, such as `compact`, used to switch template defaults or override the base preset template.
animatedbooleantrueEnables or disables the shimmer animation while keeping the same placeholder layout.
appearance'default' | 'subtle' | 'contrast''default'Changes the visual intensity of the skeleton surfaces without changing the resolved layout.
ariaLabelstring'Loading placeholder'Accessible label applied to the container element for assistive technologies.

Outputs

No outputs documented yet.

Templates

Make it yours — 3 template slots let you project custom markup.

NameDescriptionExample
Bundled PresetsAvailable preset names in the initial catalogue: card, list-item, table-row, detail-view, form-section, dashboard-widget, stat-card, chart-panel, profile-summary, master-detail, kanban-card, feed-item, search-result, table-toolbar, filter-bar and empty-state-skeleton.<hub-skeleton preset="table-row" [params]="{ columns: 4 }"></hub-skeleton>
Preset DSLCompact string syntax that supports node names, modifiers, sibling composition with `+`, child nesting with `>`, and repetition with `*N`.<hub-skeleton template="stack(gap:12)>circle(size:40)+stack(gap:8)>line(width:42%)+line(width:72%)"></hub-skeleton>
provideHubSkeletonPresetsRegisters custom presets in Angular dependency injection so any component can render them by name.providers: [provideHubSkeletonPresets([{ name: 'profile-card', template: 'stack(gap:16)>circle(size:72)+line(width:48%)' }])]