Skip to main content
cngx-src documentation

provideCngxTabs

Functioncommon/tabsv0.1.0

projects/common/tabs/provide-cngx-tabs.ts

Description#

Unified aggregator for tabs configuration.
Routes features by _target to provideTabsConfig and provideTabsI18n.
Sibling to

  • provideCngxMenu and
  • provideCngxSelect; apply once in the app providers array.
    Returns EnvironmentProviders; for
  • viewProviders use provideCngxTabsAt — opaque
  • EnvironmentProviders cannot live there.
bootstrapApplication(AppComponent, {
  providers: [
    provideCngxTabs(
      withTabsDefaultOrientation('vertical'),
      withTabsAriaLabels({ tabsRegion: 'Bereiche' }),
      withTabsI18nLabels({ tabsLabel: 'Bereiche', moreTabsLabel: (n) => `${n} mehr` }),
      withTabOverflowStabilizeMs(150),
    ),
  ],
});

Signature#

provideCngxTabs(...features: undefined)

Parameters#

@paramfeatures

Returns#

EnvironmentProviders