Skip to main content
cngx-src documentation

CNGX_FILTER_BUILDER_ANNOUNCER_FACTORY

Tokenv0.1.0WCAG AA

InjectionToken<CngxFilterBuilderAnnouncerFactory>

Description#

Factory that builds the live-region announcer for <cngx-filter-builder> - a Signal<string> the component binds into its aria-live region, re-derived from each lastMutation event through the CngxFilterBuilderI18n.announcement formatters.

Default: createFilterBuilderAnnouncer. Swap it to localise messages, route them to telemetry, or stub them in tests, at root or component scope:

providers: [
  { provide: CNGX_FILTER_BUILDER_ANNOUNCER_FACTORY, useValue: myAnnouncer },
]

For message text only, override withFilterBuilderI18n({ announcement }) - that keeps the default derivation and swaps just the strings.

Type#

InjectionToken<CngxFilterBuilderAnnouncerFactory>

Provided in#

'root'