{"version":3,"file":"tabs.mjs","sources":["../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab-content.ts","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab-label.ts","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab.ts","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab.html","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tabs-animations.ts","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab-body.ts","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab-body.html","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab-config.ts","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/paginated-tab-header.ts","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab-label-wrapper.ts","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab-header.ts","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab-header.html","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab-group.ts","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab-group.html","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab-nav-bar.ts","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tab-nav-bar.html","../../../../../k8-fastbuild-ST-fdfa778d11ba/bin/src/angular/tabs/tabs-module.ts"],"sourcesContent":["import { Directive, InjectionToken, TemplateRef } from '@angular/core';\n\n/**\n * Injection token that can be used to reference instances of `SbbTabContent`. It serves as\n * alternative token to the actual `SbbTabContent` class which could cause unnecessary\n * retention of the class and its directive metadata.\n */\nexport const SBB_TAB_CONTENT = new InjectionToken<SbbTabContent>('SbbTabContent');\n\n/** Decorates the `ng-template` tags and reads out the template from it. */\n@Directive({\n  selector: '[sbbTabContent]',\n  providers: [{ provide: SBB_TAB_CONTENT, useExisting: SbbTabContent }],\n})\nexport class SbbTabContent {\n  constructor(/** Content for the tab. */ public template: TemplateRef<any>) {}\n}\n","import { CdkPortal } from '@angular/cdk/portal';\nimport { Directive, inject, InjectionToken } from '@angular/core';\n\n/**\n * Injection token that can be used to reference instances of `SbbTabLabel`. It serves as\n * alternative token to the actual `SbbTabLabel` class which could cause unnecessary\n * retention of the class and its directive metadata.\n */\nexport const SBB_TAB_LABEL = new InjectionToken<SbbTabLabel>('SbbTabLabel');\n\n/**\n * Used to provide a tab label to a tab without causing a circular dependency.\n * @docs-private\n */\nexport const SBB_TAB = new InjectionToken<any>('SBB_TAB');\n\n/** Used to flag tab labels for use with the portal directive */\n@Directive({\n  selector: '[sbb-tab-label], [sbbTabLabel]',\n  providers: [{ provide: SBB_TAB_LABEL, useExisting: SbbTabLabel }],\n})\nexport class SbbTabLabel extends CdkPortal {\n  _closestTab: any = inject(SBB_TAB, { optional: true });\n}\n","import { TemplatePortal } from '@angular/cdk/portal';\nimport {\n  booleanAttribute,\n  ChangeDetectionStrategy,\n  Component,\n  ContentChild,\n  Inject,\n  InjectionToken,\n  Input,\n  OnChanges,\n  OnDestroy,\n  OnInit,\n  SimpleChanges,\n  TemplateRef,\n  ViewChild,\n  ViewContainerRef,\n  ViewEncapsulation,\n} from '@angular/core';\nimport { Subject } from 'rxjs';\n\nimport { SBB_TAB_CONTENT } from './tab-content';\nimport { SbbTabLabel, SBB_TAB, SBB_TAB_LABEL } from './tab-label';\n\n/**\n * Used to provide a tab group to a tab without causing a circular dependency.\n * @docs-private\n */\nexport const SBB_TAB_GROUP = new InjectionToken<any>('SBB_TAB_GROUP');\n\n@Component({\n  selector: 'sbb-tab',\n  templateUrl: 'tab.html',\n  inputs: ['disabled'],\n  // tslint:disable-next-line:validate-decorators\n  changeDetection: ChangeDetectionStrategy.Default,\n  encapsulation: ViewEncapsulation.None,\n  exportAs: 'sbbTab',\n  providers: [{ provide: SBB_TAB, useExisting: SbbTab }],\n})\nexport class SbbTab implements OnInit, OnChanges, OnDestroy {\n  /** Content for the tab label given by `<ng-template sbb-tab-label>`. */\n  @ContentChild(SBB_TAB_LABEL)\n  get templateLabel(): SbbTabLabel {\n    return this._templateLabel;\n  }\n  set templateLabel(value: SbbTabLabel) {\n    this._setTemplateLabelInput(value);\n  }\n  protected _templateLabel!: SbbTabLabel;\n\n  /**\n   * Template provided in the tab content that will be used if present, used to enable lazy-loading\n   */\n  @ContentChild(SBB_TAB_CONTENT, { read: TemplateRef, static: true })\n  _explicitContent!: TemplateRef<any>;\n\n  /** Template inside the SbbTab view that contains an `<ng-content>`. */\n  @ViewChild(TemplateRef, { static: true }) _implicitContent!: TemplateRef<any>;\n\n  /** Plain text label for the tab, used when there is no template label. */\n  @Input('label') textLabel: string = '';\n\n  /** Aria label for the tab. */\n  @Input('aria-label') ariaLabel!: string;\n\n  /**\n   * Reference to the element that the tab is labelled by.\n   * Will be cleared if `aria-label` is set at the same time.\n   */\n  @Input('aria-labelledby') ariaLabelledby!: string;\n\n  /**\n   * Classes to be passed to the tab label inside the sbb-tab-header container.\n   */\n  @Input() labelClass!: string | string[];\n\n  /**\n   * Classes to be passed to the tab sbb-tab-body container.\n   */\n  @Input() bodyClass!: string | string[];\n\n  /** Whether the tab is disabled */\n  @Input({ transform: booleanAttribute }) disabled: boolean = false;\n\n  /** Portal that will be the hosted content of the tab */\n  private _contentPortal: TemplatePortal | null = null;\n\n  /** @docs-private */\n  get content(): TemplatePortal | null {\n    return this._contentPortal;\n  }\n\n  /** Emits whenever the internal state of the tab changes. */\n  readonly _stateChanges = new Subject<void>();\n\n  /**\n   * The relatively indexed position where 0 represents the center, negative is left, and positive\n   * represents the right.\n   */\n  position: number | null = null;\n\n  /**\n   * The initial relatively index origin of the tab if it was created and selected after there\n   * was already a selected tab. Provides context of what position the tab should originate from.\n   */\n  origin: number | null = null;\n\n  /**\n   * Whether the tab is currently active.\n   */\n  isActive: boolean = false;\n\n  constructor(\n    private _viewContainerRef: ViewContainerRef,\n    @Inject(SBB_TAB_GROUP) public _closestTabGroup: any,\n  ) {}\n\n  ngOnChanges(changes: SimpleChanges): void {\n    if (changes.hasOwnProperty('textLabel') || changes.hasOwnProperty('disabled')) {\n      this._stateChanges.next();\n    }\n  }\n\n  ngOnDestroy(): void {\n    this._stateChanges.complete();\n  }\n\n  ngOnInit(): void {\n    this._contentPortal = new TemplatePortal(\n      this._explicitContent || this._implicitContent,\n      this._viewContainerRef,\n    );\n  }\n\n  /**\n   * This has been extracted to a util because of TS 4 and VE.\n   * View Engine doesn't support property rename inheritance.\n   * TS 4.0 doesn't allow properties to override accessors or vice-versa.\n   * @docs-private\n   */\n  protected _setTemplateLabelInput(value: SbbTabLabel | undefined) {\n    // Only update the label if the query managed to find one. This works around an issue where a\n    // user may have manually set `templateLabel` during creation mode, which would then get\n    // clobbered by `undefined` when the query resolves. Also note that we check that the closest\n    // tab matches the current one so that we don't pick up labels from nested tabs.\n    if (value && value._closestTab === this) {\n      this._templateLabel = value;\n    }\n  }\n}\n","<!-- Create a template for the content of the <sbb-tab> so that we can grab a reference to this\n    TemplateRef and use it in a Portal to render the tab content in the appropriate place in the\n    tab-group. -->\n<ng-template><ng-content></ng-content></ng-template>\n","import {\n  animate,\n  AnimationTriggerMetadata,\n  state,\n  style,\n  transition,\n  trigger,\n} from '@angular/animations';\n\n/**\n * Animations used by the SBB tabs.\n * @docs-private\n */\nexport const sbbTabsAnimations: {\n  readonly translateTab: AnimationTriggerMetadata;\n} = {\n  translateTab: trigger('translateTab', [\n    state(\n      'hidden',\n      style({\n        // Normally this is redundant since we detach the content from the DOM, but if the user\n        // opted into keeping the content in the DOM, we have to hide it so it isn't focusable.\n        visibility: 'hidden',\n      }),\n    ),\n    transition('* => void, * => hidden', [\n      style({ opacity: 1 }),\n      animate('{{animationDurationHide}} ease', style({ opacity: 0 })),\n    ]),\n    transition('hidden => show', [\n      style({ opacity: 0, visibility: 'visible' }),\n      animate('{{animationDuration}} ease', style({ opacity: 1 })),\n    ]),\n    transition('void => show', animate('0s')),\n  ]),\n};\n","import { AnimationEvent } from '@angular/animations';\nimport { CdkPortalOutlet, TemplatePortal } from '@angular/cdk/portal';\nimport { CdkScrollable } from '@angular/cdk/scrolling';\nimport {\n  ChangeDetectionStrategy,\n  Component,\n  Directive,\n  ElementRef,\n  EventEmitter,\n  inject,\n  Input,\n  OnDestroy,\n  OnInit,\n  Output,\n  ViewChild,\n  ViewEncapsulation,\n} from '@angular/core';\nimport { Subject, Subscription } from 'rxjs';\nimport { startWith } from 'rxjs/operators';\n\nimport { sbbTabsAnimations } from './tabs-animations';\n\n/**\n * These position states are used internally as animation states for the tab body.\n */\nexport type SbbTabBodyPositionState = 'hidden' | 'show';\n\n/**\n * The portal host directive for the contents of the tab.\n * @docs-private\n */\n@Directive({\n  selector: '[sbbTabBodyHost]',\n})\nexport class SbbTabBodyPortal extends CdkPortalOutlet implements OnInit, OnDestroy {\n  private _host = inject(SbbTabBody);\n\n  /** Subscription to events for when the tab body begins centering. */\n  private _centeringSub = Subscription.EMPTY;\n  /** Subscription to events for when the tab body finishes leaving from center position. */\n  private _leavingSub = Subscription.EMPTY;\n\n  constructor() {\n    super();\n  }\n\n  /** Set initial visibility or set up subscription for changing visibility. */\n  override ngOnInit(): void {\n    super.ngOnInit();\n\n    this._centeringSub = this._host._beforeCentering\n      .pipe(startWith(this._host._isCenterPosition(this._host._position)))\n      .subscribe((isCentering: boolean) => {\n        if (this._host._content && isCentering && !this.hasAttached()) {\n          this.attach(this._host._content);\n        }\n      });\n\n    this._leavingSub = this._host._afterLeavingCenter.subscribe(() => {\n      if (!this._host.preserveContent) {\n        this.detach();\n      }\n    });\n  }\n\n  /** Clean up centering subscription. */\n  override ngOnDestroy(): void {\n    super.ngOnDestroy();\n    this._centeringSub.unsubscribe();\n    this._leavingSub.unsubscribe();\n  }\n}\n\n/**\n * Wrapper for the contents of a tab.\n * @docs-private\n */\n@Component({\n  selector: 'sbb-tab-body',\n  templateUrl: 'tab-body.html',\n  styleUrls: ['tab-body.css'],\n  encapsulation: ViewEncapsulation.None,\n  // tslint:disable-next-line:validate-decorators\n  changeDetection: ChangeDetectionStrategy.Default,\n  animations: [sbbTabsAnimations.translateTab],\n  host: {\n    class: 'sbb-tab-body',\n  },\n  imports: [CdkScrollable, SbbTabBodyPortal],\n})\nexport class SbbTabBody implements OnDestroy {\n  /** Current position of the tab-body in the tab-group. Zero means that the tab is visible. */\n  private _positionIndex!: number;\n\n  /** Subscription to the directionality change observable. */\n  private _dirChangeSubscription = Subscription.EMPTY;\n\n  /** Tab body position state. Used by the animation trigger for the current state. */\n  _position!: SbbTabBodyPositionState;\n\n  /** Emits when an animation on the tab is complete. */\n  readonly _translateTabComplete = new Subject<AnimationEvent>();\n\n  /** Event emitted when the tab begins to animate towards the center as the active tab. */\n  @Output() readonly _onCentering: EventEmitter<number> = new EventEmitter<number>();\n\n  /** Event emitted before the centering of the tab begins. */\n  @Output() readonly _beforeCentering: EventEmitter<boolean> = new EventEmitter<boolean>();\n\n  /** Event emitted before the centering of the tab begins. */\n  @Output() readonly _afterLeavingCenter: EventEmitter<void> = new EventEmitter<void>();\n\n  /** Event emitted when the tab completes its animation towards the center. */\n  @Output() readonly _onCentered: EventEmitter<void> = new EventEmitter<void>(true);\n\n  /** The portal host inside of this container into which the tab body content will be loaded. */\n  @ViewChild(CdkPortalOutlet) _portalHost!: CdkPortalOutlet;\n\n  /** The tab body content to display. */\n  @Input('content') _content!: TemplatePortal;\n\n  /** Position that will be used when the tab is immediately becoming visible after creation. */\n  @Input() origin: number | null = null;\n\n  // Note that the default value will always be overwritten by `SbbTabBody`, but we need one\n  // anyway to prevent the animations module from throwing an error if the body is used on its own.\n  /** Duration for the tab's animation. */\n  @Input() animationDuration: string = '500ms';\n\n  /** Duration of hide animation. */\n  @Input() animationDurationHide: string = '150ms';\n\n  /** Whether the tab's content should be kept in the DOM while it's off-screen. */\n  @Input() preserveContent: boolean = false;\n\n  /** The shifted index position of the tab body, where zero represents the active center tab. */\n  @Input()\n  set position(position: number) {\n    this._positionIndex = position;\n    this._computePositionAnimationState();\n  }\n\n  constructor(private _elementRef: ElementRef<HTMLElement>) {\n    this._translateTabComplete.subscribe((event) => {\n      // If the transition to the center is complete, emit an event.\n      if (this._isCenterPosition(event.toState) && this._isCenterPosition(this._position)) {\n        this._onCentered.emit();\n      }\n\n      if (this._isCenterPosition(event.fromState) && !this._isCenterPosition(this._position)) {\n        this._afterLeavingCenter.emit();\n      }\n    });\n  }\n\n  ngOnDestroy() {\n    this._dirChangeSubscription.unsubscribe();\n    this._translateTabComplete.complete();\n  }\n\n  _onTranslateTabStarted(event: AnimationEvent): void {\n    const isCentering = this._isCenterPosition(event.toState);\n    this._beforeCentering.emit(isCentering);\n    if (isCentering) {\n      this._onCentering.emit(this._elementRef.nativeElement.clientHeight);\n    }\n  }\n\n  /** Whether the provided position state is considered center, regardless of origin. */\n  _isCenterPosition(position: SbbTabBodyPositionState | string): boolean {\n    return position === 'show';\n  }\n\n  /** Computes the position state that will be used for the tab-body animation trigger. */\n  private _computePositionAnimationState() {\n    this._position = this._positionIndex === 0 ? 'show' : 'hidden';\n  }\n}\n","<div\n  class=\"sbb-tab-body-content\"\n  #content\n  [@translateTab]=\"{\n    value: _position,\n    params: { animationDuration: animationDuration, animationDurationHide: animationDurationHide },\n  }\"\n  (@translateTab.start)=\"_onTranslateTabStarted($event)\"\n  (@translateTab.done)=\"_translateTabComplete.next($event)\"\n  cdkScrollable\n>\n  <ng-template sbbTabBodyHost></ng-template>\n</div>\n","import { InjectionToken } from '@angular/core';\n\n/** Object that can be used to configure the default options for the tabs module. */\nexport interface SbbTabsConfig {\n  /** Duration for the tab animation. Must be a valid CSS value (e.g. 600ms). */\n  animationDuration?: string;\n\n  /**\n   * Whether pagination should be disabled. This can be used to avoid unnecessary\n   * layout recalculations if it's known that pagination won't be required.\n   * This applies only for lean design.\n   */\n  disablePagination?: boolean;\n\n  /** Whether the tab group should grow to the size of the active tab. */\n  dynamicHeight?: boolean;\n\n  /**\n   * By default tabs remove their content from the DOM while it's off-screen.\n   * Setting this to `true` will keep it in the DOM which will prevent elements\n   * like iframes and videos from reloading next time it comes back into the view.\n   */\n  preserveContent?: boolean;\n}\n\n/** Injection token that can be used to provide the default options the tabs module. */\nexport const SBB_TABS_CONFIG = new InjectionToken<SbbTabsConfig>('SBB_TABS_CONFIG');\n","import { FocusableOption, FocusKeyManager } from '@angular/cdk/a11y';\nimport { BooleanInput, coerceBooleanProperty } from '@angular/cdk/coercion';\nimport { ENTER, hasModifierKey, SPACE } from '@angular/cdk/keycodes';\nimport { normalizePassiveListenerOptions, Platform } from '@angular/cdk/platform';\nimport { ViewportRuler } from '@angular/cdk/scrolling';\nimport {\n  AfterContentChecked,\n  AfterContentInit,\n  afterNextRender,\n  AfterViewInit,\n  ANIMATION_MODULE_TYPE,\n  ChangeDetectorRef,\n  Directive,\n  ElementRef,\n  EventEmitter,\n  inject,\n  Inject,\n  Injector,\n  Input,\n  NgZone,\n  numberAttribute,\n  OnDestroy,\n  Optional,\n  QueryList,\n} from '@angular/core';\nimport { mixinVariant } from '@sbb-esta/angular/core';\nimport { fromEvent, merge, Subject, timer } from 'rxjs';\nimport { distinctUntilChanged, filter, map, startWith, switchMap, takeUntil } from 'rxjs/operators';\n\n/** Config used to bind passive event listeners */\nconst passiveEventListenerOptions = normalizePassiveListenerOptions({\n  passive: true,\n}) as EventListenerOptions;\n\n/**\n * The directions that scrolling can go in when the header's tabs exceed the header width. 'After'\n * will scroll the header towards the end of the tabs list and 'before' will scroll towards the\n * beginning of the list.\n */\nexport type ScrollDirection = 'after' | 'before';\n\n/**\n * The distance in pixels that will be overshot when scrolling a tab label into view. This helps\n * provide a small affordance to the label next to it.\n */\nconst EXAGGERATED_OVERSCROLL = 60;\n\n/**\n * Amount of milliseconds to wait before starting to scroll the header automatically.\n * Set a little conservatively in order to handle fake events dispatched on touch devices.\n */\nconst HEADER_SCROLL_DELAY = 650;\n\n/**\n * Interval in milliseconds at which to scroll the header\n * while the user is holding their pointer.\n */\nconst HEADER_SCROLL_INTERVAL = 100;\n\n/** Item inside a paginated tab header. */\nexport type SbbPaginatedTabHeaderItem = FocusableOption & { elementRef: ElementRef };\n\n/**\n * The scroll state of the tabs header. 'hidden' implies no scrollbar, 'middle' indicates\n * the scrollbar is in the middle of the scroll width and 'left' and 'right' means\n * it is either on the left or right end of the scroll container.\n */\nexport type SbbTabHeaderScrollState = 'hidden' | 'middle' | 'left' | 'right';\n\n// Boilerplate for applying mixins to SbbPaginatedTabHeader.\nconst _SbbPaginatedTabHeaderMixinBase = mixinVariant(class {});\n\n/**\n * Base class for a tab header that supports pagination.\n * @docs-private\n */\n@Directive()\nexport abstract class SbbPaginatedTabHeader\n  extends _SbbPaginatedTabHeaderMixinBase\n  implements AfterContentChecked, AfterContentInit, AfterViewInit, OnDestroy\n{\n  abstract _items: QueryList<SbbPaginatedTabHeaderItem>;\n  abstract _tabListContainer: ElementRef<HTMLElement>;\n  abstract _tabList: ElementRef<HTMLElement>;\n  abstract _tabListInner: ElementRef<HTMLElement>;\n  abstract _nextPaginator: ElementRef<HTMLElement>;\n  abstract _previousPaginator: ElementRef<HTMLElement>;\n\n  /** Trigger a scroll shadow check. */\n  private _scrollShadowTrigger = new Subject<void>();\n\n  /** The distance in pixels that the tab labels should be translated to the left. */\n  private _scrollDistance = 0;\n\n  /** Whether the header should scroll to the selected index after the view has been checked. */\n  private _selectedIndexChanged = false;\n\n  /** Emits when the component is destroyed. */\n  protected readonly _destroyed: Subject<void> = new Subject<void>();\n\n  /** Whether the controls for pagination should be displayed */\n  _showPaginationControls: boolean = false;\n\n  /** Whether the tab list can be scrolled more towards the end of the tab label list. */\n  _disableScrollAfter: boolean = true;\n\n  /** Whether the tab list can be scrolled more towards the beginning of the tab label list. */\n  _disableScrollBefore: boolean = true;\n\n  /**\n   * The number of tab labels that are displayed on the header. When this changes, the header\n   * should re-evaluate the scroll position.\n   */\n  private _tabLabelCount!: number;\n\n  /** Whether the scroll distance has changed and should be applied after the view is checked. */\n  private _scrollDistanceChanged: boolean = false;\n\n  /** Used to manage focus between the tabs. */\n  private _keyManager!: FocusKeyManager<SbbPaginatedTabHeaderItem>;\n\n  /** Cached text content of the header. */\n  private _currentTextContent!: string;\n\n  /** Stream that will stop the automated scrolling. */\n  private _stopScrolling = new Subject<void>();\n\n  /**\n   * Whether pagination should be disabled. This can be used to avoid unnecessary\n   * layout recalculations if it's known that pagination won't be required.\n   * This applies only for lean design.\n   */\n  @Input()\n  get disablePagination(): boolean {\n    return this._disablePagination;\n  }\n  set disablePagination(value: BooleanInput) {\n    this._disablePagination = coerceBooleanProperty(value);\n  }\n  private _disablePagination: boolean = false;\n\n  /** The index of the active tab. */\n  @Input({ transform: numberAttribute })\n  get selectedIndex(): number {\n    return this._selectedIndex;\n  }\n  set selectedIndex(v: number) {\n    const value = isNaN(v) ? 0 : v;\n\n    if (this._selectedIndex !== value) {\n      this._selectedIndexChanged = true;\n      this._selectedIndex = value;\n\n      if (this._keyManager) {\n        this._keyManager.updateActiveItem(value);\n      }\n    }\n  }\n  private _selectedIndex: number = 0;\n\n  /** Event emitted when the option is selected. */\n  readonly selectFocusedIndex: EventEmitter<number> = new EventEmitter<number>();\n\n  /** Event emitted when a label is focused. */\n  readonly indexFocused: EventEmitter<number> = new EventEmitter<number>();\n\n  private _injector = inject(Injector);\n\n  constructor(\n    protected _elementRef: ElementRef<HTMLElement>,\n    protected _changeDetectorRef: ChangeDetectorRef,\n    private _viewportRuler: ViewportRuler,\n    private _ngZone: NgZone,\n    private _platform: Platform,\n    @Optional() @Inject(ANIMATION_MODULE_TYPE) public _animationMode?: string,\n  ) {\n    super();\n    // Bind the `mouseleave` event on the outside since it doesn't change anything in the view.\n    _ngZone.runOutsideAngular(() => {\n      fromEvent(_elementRef.nativeElement, 'mouseleave')\n        .pipe(takeUntil(this._destroyed))\n        .subscribe(() => {\n          this._stopInterval();\n        });\n    });\n  }\n\n  /** Called when the user has selected an item via the keyboard. */\n  protected abstract _itemSelected(event: KeyboardEvent): void;\n\n  ngAfterViewInit() {\n    // We need to handle these events manually, because we want to bind passive event listeners.\n    fromEvent(this._previousPaginator.nativeElement, 'touchstart', passiveEventListenerOptions)\n      .pipe(takeUntil(this._destroyed))\n      .subscribe(() => {\n        this._handlePaginatorPress('before');\n      });\n\n    fromEvent(this._nextPaginator.nativeElement, 'touchstart', passiveEventListenerOptions)\n      .pipe(takeUntil(this._destroyed))\n      .subscribe(() => {\n        this._handlePaginatorPress('after');\n      });\n  }\n\n  ngAfterContentInit() {\n    const resize = this._viewportRuler.change(150);\n    const realign = () => this.updatePagination();\n    this._keyManager = new FocusKeyManager<SbbPaginatedTabHeaderItem>(this._items)\n      .withHorizontalOrientation('ltr')\n      .withHomeAndEnd()\n      .withWrap();\n\n    this._keyManager.updateActiveItem(this._selectedIndex);\n\n    // Defer the first call in order to allow for slower browsers to lay out the elements.\n    // This helps in cases where the user lands directly on a page with paginated tabs.\n    // TODO(mmalerba): Consider breaking this into multiple `afterNextRender` calls with explicit\n    //  phase.\n    afterNextRender(realign, { injector: this._injector });\n\n    // On window resize, items change or variant change, realign\n    merge(resize, this._items.changes, this.variant)\n      .pipe(takeUntil(this._destroyed))\n      .subscribe(() => {\n        // We need to defer this to give the browser some time to recalculate\n        // the element dimensions. The call has to be wrapped in `NgZone.run`,\n        // because the viewport change handler runs outside of Angular.\n        this._ngZone.run(() => {\n          Promise.resolve().then(() => {\n            // Clamp the scroll distance, because it can change with the number of tabs.\n            this._scrollDistance = Math.max(\n              0,\n              Math.min(this._getMaxScrollDistance(), this._scrollDistance),\n            );\n            realign();\n          });\n        });\n      });\n\n    // If there is a change in the focus key manager we need to emit the `indexFocused`\n    // event in order to provide a public event that notifies about focus changes. Also we realign\n    // the tabs container by scrolling the new focused tab into the visible section.\n    this._keyManager.change.subscribe((newFocusIndex) => {\n      this.indexFocused.emit(newFocusIndex);\n      this._setTabFocus(newFocusIndex);\n    });\n\n    // Calculate scroll shadows only in standard design\n    this._ngZone.runOutsideAngular(() => {\n      this.variant\n        .pipe(\n          filter((variant) => variant === 'standard'),\n          switchMap(() =>\n            merge(\n              fromEvent(\n                this._tabListContainer.nativeElement,\n                'scroll',\n                passiveEventListenerOptions,\n              ),\n              this._scrollShadowTrigger,\n              resize,\n            ),\n          ),\n          startWith(null! as any),\n          map(() => this._calculateScrollState()),\n          distinctUntilChanged(),\n          takeUntil(this._destroyed),\n        )\n        .subscribe((state) => this._applyScrollShadows(state));\n    });\n\n    // Reset transform and scrolling when switching design variant in docs\n    this._ngZone.runOutsideAngular(() => {\n      this.variant.pipe(takeUntil(this._destroyed)).subscribe((variant) => {\n        if (variant === 'lean') {\n          this._tabListContainer.nativeElement.scrollLeft = 0;\n        } else {\n          this._tabList.nativeElement.style.removeProperty('transform');\n        }\n      });\n    });\n  }\n\n  ngAfterContentChecked(): void {\n    // If the number of tab labels have changed, check if scrolling should be enabled\n    if (this._tabLabelCount !== this._items.length) {\n      this.updatePagination();\n      this._tabLabelCount = this._items.length;\n      this._changeDetectorRef.markForCheck();\n    }\n\n    // If the selected index has changed, scroll to the label and check if the scrolling controls\n    // should be disabled.\n    if (this._selectedIndexChanged) {\n      this._scrollToLabel(this._selectedIndex);\n      this._checkScrollingControls();\n      this._selectedIndexChanged = false;\n      this._changeDetectorRef.markForCheck();\n    }\n\n    // If the scroll distance has been changed (tab selected, focused, scroll controls activated),\n    // then translate the header to reflect this.\n    if (this._scrollDistanceChanged) {\n      this._updateTabScrollPosition();\n      this._scrollDistanceChanged = false;\n      this._changeDetectorRef.markForCheck();\n    }\n  }\n\n  ngOnDestroy() {\n    this._keyManager?.destroy();\n    this._destroyed.next();\n    this._destroyed.complete();\n    this._stopScrolling.complete();\n  }\n\n  /** Handles keyboard events on the header. */\n  _handleKeydown(event: KeyboardEvent) {\n    // We don't handle any key bindings with a modifier key.\n    if (hasModifierKey(event)) {\n      return;\n    }\n\n    switch (event.keyCode) {\n      case ENTER:\n      case SPACE:\n        if (this.focusIndex !== this.selectedIndex) {\n          this.selectFocusedIndex.emit(this.focusIndex);\n          this._itemSelected(event);\n        }\n        break;\n      default:\n        this._keyManager.onKeydown(event);\n    }\n  }\n\n  /**\n   * Callback for when the MutationObserver detects that the content has changed.\n   */\n  _onContentChanges() {\n    const textContent = this._elementRef.nativeElement.textContent;\n\n    // We need to diff the text content of the header, because the MutationObserver callback\n    // will fire even if the text content didn't change which is inefficient and is prone\n    // to infinite loops if a poorly constructed expression is passed in (see #14249).\n    if (textContent !== this._currentTextContent) {\n      this._currentTextContent = textContent || '';\n\n      // The content observer runs outside the `NgZone` by default, which\n      // means that we need to bring the callback back in ourselves.\n      this._ngZone.run(() => {\n        this.updatePagination();\n        this._changeDetectorRef.markForCheck();\n      });\n    }\n  }\n\n  /**\n   * Updates the view whether pagination should be enabled or not.\n   *\n   * WARNING: Calling this method can be very costly in terms of performance. It should be called\n   * as infrequently as possible from outside of the Tabs component as it causes a reflow of the\n   * page.\n   */\n  updatePagination() {\n    this._checkPaginationEnabled();\n    this._checkScrollingControls();\n    this._updateTabScrollPosition();\n  }\n\n  /** Tracks which element has focus; used for keyboard navigation */\n  get focusIndex(): number {\n    return this._keyManager ? this._keyManager.activeItemIndex! : 0;\n  }\n\n  /** When the focus index is set, we must manually send focus to the correct label */\n  set focusIndex(value: number) {\n    if (!this._isValidIndex(value) || this.focusIndex === value || !this._keyManager) {\n      return;\n    }\n\n    this._keyManager.setActiveItem(value);\n  }\n\n  /**\n   * Determines if an index is valid.  If the tabs are not ready yet, we assume that the user is\n   * providing a valid index and return true.\n   */\n  _isValidIndex(index: number): boolean {\n    if (!this._items) {\n      return true;\n    }\n\n    const tab = this._items ? this._items.toArray()[index] : null;\n    return !!tab && !tab.disabled;\n  }\n\n  /**\n   * Sets focus on the HTML element for the label wrapper and scrolls it into the view if\n   * scrolling is enabled.\n   */\n  _setTabFocus(tabIndex: number) {\n    if (this._showPaginationControls) {\n      this._scrollToLabel(tabIndex);\n    }\n\n    if (this._items && this._items.length) {\n      this._items.toArray()[tabIndex].focus();\n\n      // Do not let the browser manage scrolling to focus the element, this will be handled\n      // by using translation.\n      this._tabListContainer.nativeElement.scrollLeft = 0;\n    }\n  }\n\n  /** Performs the CSS transformation on the tab list that will cause the list to scroll. */\n  _updateTabScrollPosition() {\n    if (this.disablePagination || this.variantSnapshot === 'standard') {\n      return;\n    }\n\n    const scrollDistance = this.scrollDistance;\n    const translateX = -scrollDistance;\n\n    // Don't use `translate3d` here because we don't want to create a new layer.\n    // We round the `transform` here, because transforms with sub-pixel precision cause some\n    // browsers to blur the content of the element.\n    this._tabList.nativeElement.style.transform = `translateX(${Math.round(translateX)}px)`;\n\n    // Setting the `transform` on IE will change the scroll offset of the parent, causing the\n    // position to be thrown off in some cases. We have to reset it ourselves to ensure that\n    // it doesn't get thrown off. Note that we scope it only to IE and Edge, because messing\n    // with the scroll position throws off Chrome 71+ in RTL mode (see #14689).\n    if (this._platform.TRIDENT || this._platform.EDGE) {\n      this._tabListContainer.nativeElement.scrollLeft = 0;\n    }\n  }\n\n  /** Sets the distance in pixels that the tab header should be transformed in the X-axis. */\n  get scrollDistance(): number {\n    return this._scrollDistance;\n  }\n  set scrollDistance(value: number) {\n    this._scrollTo(value);\n  }\n\n  /**\n   * Moves the tab list in the 'before' or 'after' direction (towards the beginning of the list or\n   * the end of the list, respectively). The distance to scroll is computed to be a third of the\n   * length of the tab list view window.\n   *\n   * This is an expensive call that forces a layout reflow to compute box and scroll metrics and\n   * should be called sparingly.\n   */\n  _scrollHeader(direction: ScrollDirection) {\n    const viewLength = this._tabListContainer.nativeElement.offsetWidth;\n\n    // Move the scroll distance one-third the length of the tab list's viewport.\n    const scrollAmount = ((direction === 'before' ? -1 : 1) * viewLength) / 3;\n\n    return this._scrollTo(this._scrollDistance + scrollAmount);\n  }\n\n  /** Handles click events on the pagination arrows. */\n  _handlePaginatorClick(direction: ScrollDirection) {\n    this._stopInterval();\n    this._scrollHeader(direction);\n  }\n\n  /**\n   * Moves the tab list such that the desired tab label (marked by index) is moved into view.\n   *\n   * This is an expensive call that forces a layout reflow to compute box and scroll metrics and\n   * should be called sparingly.\n   */\n  _scrollToLabel(labelIndex: number) {\n    if (this.disablePagination || this.variantSnapshot === 'standard') {\n      return;\n    }\n\n    const selectedLabel = this._items ? this._items.toArray()[labelIndex] : null;\n\n    if (!selectedLabel) {\n      return;\n    }\n\n    // The view length is the visible width of the tab labels.\n    const viewLength = this._tabListContainer.nativeElement.offsetWidth;\n    const { offsetLeft, offsetWidth } = selectedLabel.elementRef.nativeElement;\n\n    const labelBeforePos = offsetLeft;\n    const labelAfterPos = labelBeforePos + offsetWidth;\n\n    const beforeVisiblePos = this.scrollDistance;\n    const afterVisiblePos = this.scrollDistance + viewLength;\n\n    if (labelBeforePos < beforeVisiblePos) {\n      // Scroll header to move label to the before direction\n      this.scrollDistance -= beforeVisiblePos - labelBeforePos + EXAGGERATED_OVERSCROLL;\n    } else if (labelAfterPos > afterVisiblePos) {\n      // Scroll header to move label to the after direction\n      this.scrollDistance += labelAfterPos - afterVisiblePos + EXAGGERATED_OVERSCROLL;\n    }\n  }\n\n  /**\n   * Evaluate whether the pagination controls should be displayed. If the scroll width of the\n   * tab list is wider than the size of the header container, then the pagination controls should\n   * be shown.\n   *\n   * This is an expensive call that forces a layout reflow to compute box and scroll metrics and\n   * should be called sparingly.\n   */\n  _checkPaginationEnabled() {\n    if (this.disablePagination || this.variantSnapshot === 'standard') {\n      this._showPaginationControls = false;\n    } else {\n      // Allow difference delta of 1px to avoid falsy enabled pagination if browser has zoom levels other than 100%\n      const isEnabled =\n        this._tabListInner.nativeElement.scrollWidth - this._elementRef.nativeElement.offsetWidth >\n        1;\n\n      if (!isEnabled) {\n        this.scrollDistance = 0;\n      }\n\n      if (isEnabled !== this._showPaginationControls) {\n        this._changeDetectorRef.markForCheck();\n      }\n\n      this._showPaginationControls = isEnabled;\n    }\n  }\n\n  /**\n   * Evaluate whether the before and after controls should be enabled or disabled.\n   * If the header is at the beginning of the list (scroll distance is equal to 0) then disable the\n   * before button. If the header is at the end of the list (scroll distance is equal to the\n   * maximum distance we can scroll), then disable the after button.\n   *\n   * This is an expensive call that forces a layout reflow to compute box and scroll metrics and\n   * should be called sparingly.\n   */\n  _checkScrollingControls() {\n    if (this.disablePagination || this.variantSnapshot === 'standard') {\n      this._disableScrollAfter = this._disableScrollBefore = true;\n    } else {\n      // Check if the pagination arrows should be activated.\n      this._disableScrollBefore = this.scrollDistance === 0;\n      this._disableScrollAfter = this.scrollDistance === this._getMaxScrollDistance();\n      this._changeDetectorRef.markForCheck();\n    }\n  }\n\n  /**\n   * Determines what is the maximum length in pixels that can be set for the scroll distance. This\n   * is equal to the difference in width between the tab list container and tab header container.\n   *\n   * This is an expensive call that forces a layout reflow to compute box and scroll metrics and\n   * should be called sparingly.\n   */\n  _getMaxScrollDistance(): number {\n    const lengthOfTabList = this._tabListInner.nativeElement.scrollWidth;\n    const viewLength = this._tabListContainer.nativeElement.offsetWidth;\n    return lengthOfTabList - viewLength || 0;\n  }\n\n  /** Stops the currently-running paginator interval.  */\n  _stopInterval() {\n    this._stopScrolling.next();\n  }\n\n  /**\n   * Handles the user pressing down on one of the paginators.\n   * Starts scrolling the header after a certain amount of time.\n   * @param direction In which direction the paginator should be scrolled.\n   */\n  _handlePaginatorPress(direction: ScrollDirection, mouseEvent?: MouseEvent) {\n    // Don't start auto scrolling for right mouse button clicks. Note that we shouldn't have to\n    // null check the `button`, but we do it so we don't break tests that use fake events.\n    if (mouseEvent && mouseEvent.button != null && mouseEvent.button !== 0) {\n      return;\n    }\n\n    // Avoid overlapping timers.\n    this._stopInterval();\n\n    // Start a timer after the delay and keep firing based on the interval.\n    timer(HEADER_SCROLL_DELAY, HEADER_SCROLL_INTERVAL)\n      // Keep the timer going until something tells it to stop or the component is destroyed.\n      .pipe(takeUntil(merge(this._stopScrolling, this._destroyed)))\n      .subscribe(() => {\n        const { maxScrollDistance, distance } = this._scrollHeader(direction);\n\n        // Stop the timer if we've reached the start or the end.\n        if (distance === 0 || distance >= maxScrollDistance) {\n          this._stopInterval();\n        }\n      });\n  }\n\n  /**\n   * Scrolls the header to a given position.\n   * @param position Position to which to scroll.\n   * @returns Information on the current scroll distance and the maximum.\n   */\n  private _scrollTo(position: number) {\n    if (this.disablePagination || this.variantSnapshot === 'standard') {\n      return { maxScrollDistance: 0, distance: 0 };\n    }\n\n    const maxScrollDistance = this._getMaxScrollDistance();\n    this._scrollDistance = Math.max(0, Math.min(maxScrollDistance, position));\n\n    // Mark that the scroll distance has changed so that after the view is checked, the CSS\n    // transformation can move the header.\n    this._scrollDistanceChanged = true;\n    this._checkScrollingControls();\n\n    return { maxScrollDistance, distance: this._scrollDistance };\n  }\n\n  /**\n   * Calculate whether the scroll shadows should be hidden or shown left, right or on both sides.\n   */\n  private _calculateScrollState(): SbbTabHeaderScrollState {\n    const element = this._tabListContainer.nativeElement;\n    if (element.scrollWidth === element.offsetWidth) {\n      return 'hidden';\n    }\n    const isAtStart = element.scrollLeft === 0;\n    // In some cases the combined value of scrollLeft and offsetWidth is off by\n    // 1 pixel from the scrollWidth.\n    const isAtEnd = element.scrollWidth - element.scrollLeft - element.offsetWidth <= 1;\n    return !isAtStart && !isAtEnd ? 'middle' : isAtStart ? 'left' : 'right';\n  }\n\n  /**\n   * Apply the scroll shadow state. Adds or removes the appropriate css classes\n   * for the shadow.\n   * We do this manually due to being in a subclass and outside of Angular's\n   * change detection.\n   * @param state The state of the scroll shadows.\n   */\n  private _applyScrollShadows(state: SbbTabHeaderScrollState) {\n    const element = this._elementRef.nativeElement;\n    if (state === 'hidden' || state === 'left') {\n      element.classList.remove('sbb-tab-header-left-shadow');\n    } else {\n      element.classList.add('sbb-tab-header-left-shadow');\n    }\n    if (state === 'hidden' || state === 'right') {\n      element.classList.remove('sbb-tab-header-right-shadow');\n    } else {\n      element.classList.add('sbb-tab-header-right-shadow');\n    }\n  }\n}\n","import { booleanAttribute, Directive, ElementRef, Input } from '@angular/core';\n\n/**\n * Used in the `sbb-tab-group` view to display tab labels.\n * @docs-private\n */\n@Directive({\n  selector: '[sbbTabLabelWrapper]',\n  host: {\n    '[class.sbb-tab-disabled]': 'disabled',\n    '[attr.aria-disabled]': '!!disabled',\n  },\n})\nexport class SbbTabLabelWrapper {\n  /** Whether the tab is disabled. */\n  @Input({ transform: booleanAttribute }) disabled: boolean = false;\n\n  constructor(public elementRef: ElementRef) {}\n\n  /** Sets focus on the wrapper element */\n  focus(): void {\n    this.elementRef.nativeElement.focus();\n  }\n\n  getOffsetLeft(): number {\n    return this.elementRef.nativeElement.offsetLeft;\n  }\n\n  getOffsetWidth(): number {\n    return this.elementRef.nativeElement.offsetWidth;\n  }\n}\n","import { CdkObserveContent } from '@angular/cdk/observers';\nimport { Platform } from '@angular/cdk/platform';\nimport { ViewportRuler } from '@angular/cdk/scrolling';\nimport {\n  AfterContentChecked,\n  AfterContentInit,\n  AfterViewInit,\n  ANIMATION_MODULE_TYPE,\n  ChangeDetectionStrategy,\n  ChangeDetectorRef,\n  Component,\n  ContentChildren,\n  ElementRef,\n  EventEmitter,\n  Inject,\n  Input,\n  NgZone,\n  OnDestroy,\n  Optional,\n  Output,\n  QueryList,\n  ViewChild,\n  ViewEncapsulation,\n} from '@angular/core';\nimport { SbbIcon } from '@sbb-esta/angular/icon';\n\nimport { SbbPaginatedTabHeader } from './paginated-tab-header';\nimport { SbbTabLabelWrapper } from './tab-label-wrapper';\n\n/**\n * The header of the tab group which displays a list of all the tabs in the tab group. Includes\n * an ink bar that follows the currently selected tab. When the tabs list's width exceeds the\n * width of the header container, then arrows will be displayed to allow the user to scroll\n * left and right across the header.\n * @docs-private\n */\n@Component({\n  selector: 'sbb-tab-header',\n  templateUrl: 'tab-header.html',\n  styleUrls: ['tab-header.css'],\n  inputs: ['selectedIndex'],\n  encapsulation: ViewEncapsulation.None,\n  // tslint:disable-next-line:validate-decorators\n  changeDetection: ChangeDetectionStrategy.Default,\n  host: {\n    class: 'sbb-tab-header',\n    '[class.sbb-tab-header-pagination-controls-enabled]': `_showPaginationControls && this.variantSnapshot === 'lean'`,\n  },\n  imports: [SbbIcon, CdkObserveContent],\n})\nexport class SbbTabHeader\n  extends SbbPaginatedTabHeader\n  implements AfterContentChecked, AfterContentInit, AfterViewInit, OnDestroy\n{\n  @ContentChildren(SbbTabLabelWrapper, { descendants: false })\n  _items!: QueryList<SbbTabLabelWrapper>;\n  @ViewChild('tabListContainer', { static: true }) _tabListContainer!: ElementRef;\n  @ViewChild('tabList', { static: true }) _tabList!: ElementRef;\n  @ViewChild('tabListInner', { static: true }) _tabListInner!: ElementRef;\n  @ViewChild('nextPaginator') _nextPaginator!: ElementRef<HTMLElement>;\n  @ViewChild('previousPaginator') _previousPaginator!: ElementRef<HTMLElement>;\n\n  /** Aria label of the header. */\n  @Input('aria-label') ariaLabel!: string;\n\n  /** Sets the `aria-labelledby` of the header. */\n  @Input('aria-labelledby') ariaLabelledby!: string;\n\n  @Output() override selectFocusedIndex: EventEmitter<number> = new EventEmitter<number>();\n  @Output() override indexFocused: EventEmitter<number> = new EventEmitter<number>();\n\n  constructor(\n    elementRef: ElementRef,\n    changeDetectorRef: ChangeDetectorRef,\n    viewportRuler: ViewportRuler,\n    ngZone: NgZone,\n    platform: Platform,\n    @Optional() @Inject(ANIMATION_MODULE_TYPE) animationMode?: string,\n  ) {\n    super(elementRef, changeDetectorRef, viewportRuler, ngZone, platform, animationMode);\n  }\n\n  protected _itemSelected(event: KeyboardEvent) {\n    event.preventDefault();\n  }\n}\n","<button\n  class=\"sbb-tab-header-pagination sbb-tab-header-pagination-before sbb-button-reset-frameless\"\n  #previousPaginator\n  aria-hidden=\"true\"\n  type=\"button\"\n  tabindex=\"-1\"\n  [class.sbb-tab-header-pagination-disabled]=\"_disableScrollBefore\"\n  [disabled]=\"_disableScrollBefore || null\"\n  (click)=\"_handlePaginatorClick('before')\"\n  (mousedown)=\"_handlePaginatorPress('before', $event)\"\n  (touchend)=\"_stopInterval()\"\n>\n  <sbb-icon svgIcon=\"chevron-left-small\" class=\"sbb-tab-header-pagination-chevron\"></sbb-icon>\n</button>\n\n<div\n  class=\"sbb-tab-label-container sbb-scrollbar\"\n  #tabListContainer\n  (keydown)=\"_handleKeydown($event)\"\n>\n  <div\n    #tabList\n    class=\"sbb-tab-list\"\n    [class._sbb-animation-noopable]=\"_animationMode === 'NoopAnimations'\"\n    role=\"tablist\"\n    [attr.aria-label]=\"ariaLabel || null\"\n    [attr.aria-labelledby]=\"ariaLabelledby || null\"\n    (cdkObserveContent)=\"_onContentChanges()\"\n  >\n    <div class=\"sbb-tab-labels\" #tabListInner>\n      <ng-content></ng-content>\n    </div>\n  </div>\n</div>\n\n<button\n  class=\"sbb-tab-header-pagination sbb-tab-header-pagination-after sbb-button-reset-frameless\"\n  #nextPaginator\n  aria-hidden=\"true\"\n  type=\"button\"\n  [class.sbb-tab-header-pagination-disabled]=\"_disableScrollAfter\"\n  [disabled]=\"_disableScrollAfter || null\"\n  tabindex=\"-1\"\n  (mousedown)=\"_handlePaginatorPress('after', $event)\"\n  (click)=\"_handlePaginatorClick('after')\"\n  (touchend)=\"_stopInterval()\"\n>\n  <sbb-icon svgIcon=\"chevron-right-small\" class=\"sbb-tab-header-pagination-chevron\"></sbb-icon>\n</button>\n","import { CdkMonitorFocus, FocusOrigin } from '@angular/cdk/a11y';\nimport {\n  BooleanInput,\n  coerceBooleanProperty,\n  coerceNumberProperty,\n  NumberInput,\n} from '@angular/cdk/coercion';\nimport { CdkPortalOutlet } from '@angular/cdk/portal';\nimport {\n  AfterContentChecked,\n  AfterContentInit,\n  ANIMATION_MODULE_TYPE,\n  ChangeDetectionStrategy,\n  ChangeDetectorRef,\n  Component,\n  ContentChildren,\n  ElementRef,\n  EventEmitter,\n  Inject,\n  Input,\n  OnDestroy,\n  Optional,\n  Output,\n  QueryList,\n  ViewChild,\n  ViewEncapsulation,\n} from '@angular/core';\nimport { merge, Subscription } from 'rxjs';\nimport { startWith } from 'rxjs/operators';\n\nimport { SbbTab, SBB_TAB_GROUP } from './tab';\nimport { SbbTabBody } from './tab-body';\nimport { SbbTabsConfig, SBB_TABS_CONFIG } from './tab-config';\nimport { SbbTabHeader } from './tab-header';\nimport { SbbTabLabelWrapper } from './tab-label-wrapper';\n\n/** Used to generate unique ID's for each tab component */\nlet nextId = 0;\n\n/** A simple change event emitted on focus or selection changes. */\nexport class SbbTabChangeEvent {\n  /** Index of the currently-selected tab. */\n  index!: number;\n  /** Reference to the currently-selected tab. */\n  tab!: SbbTab;\n}\n\ninterface SbbTabGroupBaseHeader {\n  updatePagination(): void;\n  focusIndex: number;\n}\n\n@Component({\n  selector: 'sbb-tab-group',\n  exportAs: 'sbbTabGroup',\n  templateUrl: 'tab-group.html',\n  styleUrls: ['tab-group.css'],\n  encapsulation: ViewEncapsulation.None,\n  // tslint:disable-next-line:validate-decorators\n  changeDetection: ChangeDetectionStrategy.Default,\n  providers: [\n    {\n      provide: SBB_TAB_GROUP,\n      useExisting: SbbTabGroup,\n    },\n  ],\n  host: {\n    class: 'sbb-tab-group',\n    '[class.sbb-tab-group-dynamic-height]': 'dynamicHeight',\n  },\n  imports: [SbbTabHeader, SbbTabLabelWrapper, CdkMonitorFocus, CdkPortalOutlet, SbbTabBody],\n})\nexport class SbbTabGroup implements AfterContentInit, AfterContentChecked, OnDestroy {\n  /**\n   * All tabs inside the tab group. This includes tabs that belong to groups that are nested\n   * inside the current one. We filter out only the tabs that belong to this group in `_tabs`.\n   */\n  @ContentChildren(SbbTab, { descendants: true }) _allTabs!: QueryList<SbbTab>;\n  @ViewChild('tabBodyWrapper') _tabBodyWrapper!: ElementRef;\n  @ViewChild('tabHeader') _tabHeader!: SbbTabGroupBaseHeader;\n\n  /** All of the tabs that belong to the group. */\n  _tabs: QueryList<SbbTab> = new QueryList<SbbTab>();\n\n  /** The tab index that should be selected after the content has been checked. */\n  private _indexToSelect: number | null = 0;\n\n  /** Index of the tab that was focused last. */\n  private _lastFocusedTabIndex: number | null = null;\n\n  /** Snapshot of the height of the tab body wrapper before another tab is activated. */\n  private _tabBodyWrapperHeight: number = 0;\n\n  /** Subscription to tabs being added/removed. */\n  private _tabsSubscription = Subscription.EMPTY;\n\n  /** Subscription to changes in the tab labels. */\n  private _tabLabelSubscription = Subscription.EMPTY;\n\n  /** Whether the tab group should grow to the size of the active tab. */\n  @Input()\n  get dynamicHeight(): boolean {\n    return this._dynamicHeight;\n  }\n  set dynamicHeight(value: BooleanInput) {\n    this._dynamicHeight = coerceBooleanProperty(value);\n  }\n  private _dynamicHeight: boolean = false;\n\n  /** The index of the active tab. */\n  @Input()\n  get selectedIndex(): number | null {\n    return this._selectedIndex;\n  }\n  set selectedIndex(value: NumberInput) {\n    this._indexToSelect = coerceNumberProperty(value, null);\n  }\n  private _selectedIndex: number | null = null;\n\n  /** Duration for the tab animation. Will be normalized to milliseconds if no units are set. */\n  @Input()\n  get animationDuration(): string {\n    return this._animationDuration;\n  }\n  set animationDuration(value: NumberInput) {\n    this._animationDuration = /^\\d+$/.test(value + '') ? value + 'ms' : (value as string);\n\n    const match = this.animationDuration.match(/^(\\d+|\\.\\d+|\\d+\\.\\d+)(\\w*)$/);\n    if (match) {\n      const durationParsed = parseFloat(match[1]) / 3;\n      const durationRounded = Math.round(durationParsed * 100) / 100;\n      this._animationDurationHide = `${durationRounded}${match[2]}`;\n    } else {\n      this._animationDurationHide = '0ms';\n    }\n  }\n  private _animationDuration!: string;\n\n  /** Calculated hide duration which is one third of animationDuration. */\n  _animationDurationHide!: string;\n\n  /**\n   * Whether pagination should be disabled. This can be used to avoid unnecessary\n   * layout recalculations if it's known that pagination won't be required.\n   * This applies only for lean design.\n   */\n  @Input()\n  get disablePagination(): boolean {\n    return this._disablePagination;\n  }\n  set disablePagination(value: BooleanInput) {\n    this._disablePagination = coerceBooleanProperty(value);\n  }\n  private _disablePagination: boolean = false;\n\n  /**\n   * By default tabs remove their content from the DOM while it's off-screen.\n   * Setting this to `true` will keep it in the DOM which will prevent elements\n   * like iframes and videos from reloading next time it comes back into the view.\n   */\n  @Input()\n  get preserveContent(): boolean {\n    return this._preserveContent;\n  }\n  set preserveContent(value: BooleanInput) {\n    this._preserveContent = coerceBooleanProperty(value);\n  }\n  private _preserveContent: boolean = false;\n\n  /** Aria label of the inner `tablist` of the group. */\n  @Input('aria-label') ariaLabel!: string;\n\n  /** Sets the `aria-labelledby` of the inner `tablist` of the group. */\n  @Input('aria-labelledby') ariaLabelledby!: string;\n\n  /** Output to enable support for two-way binding on `[(selectedIndex)]` */\n  @Output() readonly selectedIndexChange: EventEmitter<number> = new EventEmitter<number>();\n\n  /** Event emitted when focus has changed within a tab group. */\n  @Output()\n  readonly focusChange: EventEmitter<SbbTabChangeEvent> = new EventEmitter<SbbTabChangeEvent>();\n\n  /** Event emitted when the body animation has completed */\n  @Output() readonly animationDone: EventEmitter<void> = new EventEmitter<void>();\n\n  /** Event emitted when the tab selection has changed. */\n  @Output()\n  readonly selectedTabChange: EventEmitter<SbbTabChangeEvent> = new EventEmitter<SbbTabChangeEvent>(\n    true,\n  );\n\n  private _groupId: number;\n\n  constructor(\n    protected _changeDetectorRef: ChangeDetectorRef,\n    @Inject(SBB_TABS_CONFIG) @Optional() defaultConfig?: SbbTabsConfig,\n    @Optional() @Inject(ANIMATION_MODULE_TYPE) public _animationMode?: string,\n  ) {\n    this._groupId = nextId++;\n    this.animationDuration =\n      defaultConfig && defaultConfig.animationDuration ? defaultConfig.animationDuration : '500ms';\n    this.disablePagination =\n      defaultConfig && defaultConfig.disablePagination != null\n        ? defaultConfig.disablePagination\n        : false;\n    this.dynamicHeight =\n      defaultConfig && defaultConfig.dynamicHeight != null ? defaultConfig.dynamicHeight : false;\n    this.preserveContent = !!defaultConfig?.preserveContent;\n  }\n\n  /**\n   * After the content is checked, this component knows what tabs have been defined\n   * and what the selected index should be. This is where we can know exactly what position\n   * each tab should be in according to the new selected index, and additionally we know how\n   * a new selected tab should transition in (from the left or right).\n   */\n  ngAfterContentChecked() {\n    // Don't clamp the `indexToSelect` immediately in the setter because it can happen that\n    // the amount of tabs changes before the actual change detection runs.\n    const indexToSelect = (this._indexToSelect = this._clampTabIndex(this._indexToSelect));\n\n    // If there is a change in selected index, emit a change event. Should not trigger if\n    // the selected index has not yet been initialized.\n    if (this._selectedIndex !== indexToSelect) {\n      const isFirstRun = this._selectedIndex == null;\n\n      if (!isFirstRun) {\n        this.selectedTabChange.emit(this._createChangeEvent(indexToSelect));\n        // Preserve the height so page doesn't scroll up during tab change.\n        const wrapper = this._tabBodyWrapper.nativeElement;\n        wrapper.style.minHeight = wrapper.clientHeight + 'px';\n      }\n\n      // Changing these values after change detection has run\n      // since the checked content may contain references to them.\n      Promise.resolve().then(() => {\n        this._tabs.forEach((tab, index) => (tab.isActive = index === indexToSelect));\n\n        if (!isFirstRun) {\n          this.selectedIndexChange.emit(indexToSelect);\n          // Clear the min-height, this was needed during tab change to avoid\n          // unnecessary scrolling.\n          this._tabBodyWrapper.nativeElement.style.minHeight = '';\n        }\n      });\n    }\n\n    // Setup the position for each tab and optionally setup an origin on the next selected tab.\n    this._tabs.forEach((tab: SbbTab, index: number) => {\n      tab.position = index - indexToSelect;\n\n      // If there is already a selected tab, then set up an origin for the next selected tab\n      // if it doesn't have one already.\n      if (this._selectedIndex != null && tab.position === 0 && !tab.origin) {\n        tab.origin = indexToSelect - this._selectedIndex;\n      }\n    });\n\n    if (this._selectedIndex !== indexToSelect) {\n      this._selectedIndex = indexToSelect;\n      this._lastFocusedTabIndex = null;\n      this._changeDetectorRef.markForCheck();\n    }\n  }\n\n  ngAfterContentInit() {\n    this._subscribeToAllTabChanges();\n    this._subscribeToTabLabels();\n\n    // Subscribe to changes in the amount of tabs, in order to be\n    // able to re-render the content as new tabs are added or removed.\n    this._tabsSubscription = this._tabs.changes.subscribe(() => {\n      const indexToSelect = this._clampTabIndex(this._indexToSelect);\n\n      // Maintain the previously-selected tab if a new tab is added or removed and there is no\n      // explicit change that selects a different tab.\n      if (indexToSelect === this._selectedIndex) {\n        const tabs = this._tabs.toArray();\n        let selectedTab: SbbTab | undefined;\n\n        for (let i = 0; i < tabs.length; i++) {\n          if (tabs[i].isActive) {\n            // Assign both to the `_indexToSelect` and `_selectedIndex` so we don't fire a changed\n            // event, otherwise the consumer may end up in an infinite loop in some edge cases like\n            // adding a tab within the `selectedIndexChange` event.\n            this._indexToSelect = this._selectedIndex = i;\n            this._lastFocusedTabIndex = null;\n            selectedTab = tabs[i];\n            break;\n          }\n        }\n\n        // If we haven't found an active tab and a tab exists at the selected index, it means\n        // that the active tab was swapped out. Since this won't be picked up by the rendering\n        // loop in `ngAfterContentChecked`, we need to sync it up manually.\n        if (!selectedTab && tabs[indexToSelect]) {\n          Promise.resolve().then(() => {\n            tabs[indexToSelect].isActive = true;\n            this.selectedTabChange.emit(this._createChangeEvent(indexToSelect));\n          });\n        }\n      }\n\n      this._changeDetectorRef.markForCheck();\n    });\n  }\n\n  /** Listens to changes in all of the tabs. */\n  private _subscribeToAllTabChanges() {\n    // Since we use a query with `descendants: true` to pick up the tabs, we may end up catching\n    // some that are inside of nested tab groups. We filter them out manually by checking that\n    // the closest group to the tab is the current one.\n    this._allTabs.changes.pipe(startWith(this._allTabs)).subscribe((tabs: QueryList<SbbTab>) => {\n      this._tabs.reset(\n        tabs.filter((tab) => tab._closestTabGroup === this || !tab._closestTabGroup),\n      );\n      this._tabs.notifyOnChanges();\n    });\n  }\n\n  ngOnDestroy() {\n    this._tabs.destroy();\n    this._tabsSubscription.unsubscribe();\n    this._tabLabelSubscription.unsubscribe();\n  }\n\n  /**\n   * Recalculates the tab group's pagination dimensions.\n   *\n   * WARNING: Calling this method can be very costly in terms of performance. It should be called\n   * as infrequently as possible from outside of the Tabs component as it causes a reflow of the\n   * page.\n   */\n  updatePagination() {\n    if (this._tabHeader) {\n      this._tabHeader.updatePagination();\n    }\n  }\n\n  /**\n   * Sets focus to a particular tab.\n   * @param index Index of the tab to be focused.\n   */\n  focusTab(index: number) {\n    const header = this._tabHeader;\n\n    if (header) {\n      header.focusIndex = index;\n    }\n  }\n\n  _focusChanged(index: number) {\n    this._lastFocusedTabIndex = index;\n    this.focusChange.emit(this._createChangeEvent(index));\n  }\n\n  private _createChangeEvent(index: number): SbbTabChangeEvent {\n    const event = new SbbTabChangeEvent();\n    event.index = index;\n    if (this._tabs && this._tabs.length) {\n      event.tab = this._tabs.toArray()[index];\n    }\n    return event;\n  }\n\n  /**\n   * Subscribes to changes in the tab labels. This is needed, because the @Input for the label is\n   * on the SbbTab component, whereas the data binding is inside the SbbTabGroup. In order for the\n   * binding to be updated, we need to subscribe to changes in it and trigger change detection\n   * manually.\n   */\n  private _subscribeToTabLabels() {\n    if (this._tabLabelSubscription) {\n      this._tabLabelSubscription.unsubscribe();\n    }\n\n    this._tabLabelSubscription = merge(...this._tabs.map((tab) => tab._stateChanges)).subscribe(\n      () => this._changeDetectorRef.markForCheck(),\n    );\n  }\n\n  /** Clamps the given index to the bounds of 0 and the tabs length. */\n  private _clampTabIndex(index: number | null): number {\n    // Note the `|| 0`, which ensures that values like NaN can't get through\n    // and which would otherwise throw the component into an infinite loop\n    // (since Math.max(NaN, 0) === NaN).\n    return Math.min(this._tabs.length - 1, Math.max(index || 0, 0));\n  }\n\n  /** Returns a unique id for each tab label element */\n  _getTabLabelId(i: number): string {\n    return `sbb-tab-label-${this._groupId}-${i}`;\n  }\n\n  /** Returns a unique id for each tab content element */\n  _getTabContentId(i: number): string {\n    return `sbb-tab-content-${this._groupId}-${i}`;\n  }\n\n  /**\n   * Sets the height of the body wrapper to the height of the activating tab if dynamic\n   * height property is true.\n   */\n  _setTabBodyWrapperHeight(tabHeight: number): void {\n    if (!this._dynamicHeight || !this._tabBodyWrapperHeight) {\n      return;\n    }\n\n    const wrapper: HTMLElement = this._tabBodyWrapper.nativeElement;\n\n    wrapper.style.height = this._tabBodyWrapperHeight + 'px';\n\n    // This conditional forces the browser to paint the height so that\n    // the animation to the new height can have an origin.\n    if (this._tabBodyWrapper.nativeElement.offsetHeight) {\n      wrapper.style.height = tabHeight + 'px';\n    }\n  }\n\n  /** Removes the height of the tab body wrapper. */\n  _removeTabBodyWrapperHeight(): void {\n    const wrapper = this._tabBodyWrapper.nativeElement;\n    this._tabBodyWrapperHeight = wrapper.clientHeight;\n    wrapper.style.height = '';\n    this.animationDone.emit();\n  }\n\n  /** Handle click events, setting new selected index if appropriate. */\n  _handleClick(tab: SbbTab, tabHeader: SbbTabGroupBaseHeader, index: number) {\n    if (!tab.disabled) {\n      this.selectedIndex = tabHeader.focusIndex = index;\n    }\n  }\n\n  /** Retrieves the tabindex for the tab. */\n  _getTabIndex(tab: SbbTab, index: number): number | null {\n    if (tab.disabled) {\n      return null;\n    }\n    const targetIndex = this._lastFocusedTabIndex ?? this.selectedIndex;\n    return index === targetIndex ? 0 : -1;\n  }\n\n  /** Callback for when the focused state of a tab has changed. */\n  _tabFocusChanged(focusOrigin: FocusOrigin, index: number) {\n    // Mouse/touch focus happens during the `mousedown`/`touchstart` phase which\n    // can cause the tab to be moved out from under the pointer, interrupting the\n    // click sequence (see #21898). We don't need to scroll the tab into view for\n    // such cases anyway, because it will be done when the tab becomes selected.\n    if (focusOrigin && focusOrigin !== 'mouse' && focusOrigin !== 'touch') {\n      this._tabHeader.focusIndex = index;\n    }\n  }\n}\n","<sbb-tab-header\n  #tabHeader\n  [selectedIndex]=\"selectedIndex || 0\"\n  [disablePagination]=\"disablePagination\"\n  [aria-label]=\"ariaLabel\"\n  [aria-labelledby]=\"ariaLabelledby\"\n  (indexFocused)=\"_focusChanged($event)\"\n  (selectFocusedIndex)=\"selectedIndex = $event\"\n>\n  @for (tab of _tabs; track tab; let i = $index) {\n    <div\n      class=\"sbb-tab-label\"\n      role=\"tab\"\n      sbbTabLabelWrapper\n      cdkMonitorElementFocus\n      [id]=\"_getTabLabelId(i)\"\n      [attr.tabIndex]=\"_getTabIndex(tab, i)\"\n      [attr.aria-posinset]=\"i + 1\"\n      [attr.aria-setsize]=\"_tabs.length\"\n      [attr.aria-controls]=\"_getTabContentId(i)\"\n      [attr.aria-selected]=\"selectedIndex == i\"\n      [attr.aria-label]=\"tab.ariaLabel || null\"\n      [attr.aria-labelledby]=\"!tab.ariaLabel && tab.ariaLabelledby ? tab.ariaLabelledby : null\"\n      [class.sbb-tab-label-active]=\"selectedIndex == i\"\n      [class]=\"tab.labelClass\"\n      [disabled]=\"tab.disabled\"\n      (click)=\"_handleClick(tab, tabHeader, i)\"\n      (cdkFocusChange)=\"_tabFocusChanged($event, i)\"\n    >\n      <div class=\"sbb-tab-label-content\">\n        <!-- If there is a label template, use it. -->\n        @if (tab.templateLabel) {\n          <ng-template [cdkPortalOutlet]=\"tab.templateLabel\"></ng-template>\n        } @else {\n          {{ tab.textLabel }}\n        }\n        <!-- If there is not a label template, fall back to the text label. -->\n      </div>\n    </div>\n  }\n</sbb-tab-header>\n\n<div\n  class=\"sbb-tab-body-wrapper\"\n  [class._sbb-animation-noopable]=\"_animationMode === 'NoopAnimations'\"\n  #tabBodyWrapper\n>\n  @for (tab of _tabs; track tab; let i = $index) {\n    <sbb-tab-body\n      role=\"tabpanel\"\n      [id]=\"_getTabContentId(i)\"\n      [attr.aria-labelledby]=\"_getTabLabelId(i)\"\n      [attr.aria-hidden]=\"selectedIndex !== i\"\n      [class.sbb-tab-body-active]=\"selectedIndex == i\"\n      [class]=\"tab.bodyClass\"\n      [content]=\"tab.content!\"\n      [position]=\"tab.position!\"\n      [origin]=\"tab.origin\"\n      [animationDuration]=\"animationDuration\"\n      [animationDurationHide]=\"_animationDurationHide\"\n      [preserveContent]=\"preserveContent\"\n      (_onCentered)=\"_removeTabBodyWrapperHeight()\"\n      (_onCentering)=\"_setTabBodyWrapperHeight($event)\"\n    >\n    </sbb-tab-body>\n  }\n</div>\n","import { FocusableOption, FocusMonitor, _IdGenerator } from '@angular/cdk/a11y';\nimport { ENTER, SPACE } from '@angular/cdk/keycodes';\nimport { CdkObserveContent } from '@angular/cdk/observers';\nimport { Platform } from '@angular/cdk/platform';\nimport { ViewportRuler } from '@angular/cdk/scrolling';\nimport {\n  AfterContentChecked,\n  AfterContentInit,\n  AfterViewInit,\n  ANIMATION_MODULE_TYPE,\n  Attribute,\n  booleanAttribute,\n  ChangeDetectionStrategy,\n  ChangeDetectorRef,\n  Component,\n  ContentChildren,\n  Directive,\n  ElementRef,\n  forwardRef,\n  inject,\n  Inject,\n  Input,\n  NgZone,\n  numberAttribute,\n  OnDestroy,\n  Optional,\n  QueryList,\n  ViewChild,\n  ViewEncapsulation,\n} from '@angular/core';\nimport { SbbIcon } from '@sbb-esta/angular/icon';\nimport { startWith, takeUntil } from 'rxjs/operators';\n\nimport { SbbPaginatedTabHeader } from './paginated-tab-header';\n\n/**\n * Navigation component matching the styles of the tab group header.\n * Provides anchored navigation with animated ink bar.\n */\n@Component({\n  selector: '[sbb-tab-nav-bar]',\n  exportAs: 'sbbTabNavBar, sbbTabNav',\n  templateUrl: 'tab-nav-bar.html',\n  styleUrls: ['tab-nav-bar.css'],\n  host: {\n    '[attr.role]': '_getRole()',\n    class: 'sbb-tab-nav-bar sbb-tab-header',\n    '[class.sbb-tab-header-pagination-controls-enabled]': `_showPaginationControls && this.variantSnapshot === 'lean'`,\n  },\n  encapsulation: ViewEncapsulation.None,\n  // tslint:disable-next-line:validate-decorators\n  changeDetection: ChangeDetectionStrategy.Default,\n  imports: [SbbIcon, CdkObserveContent],\n})\nexport class SbbTabNav\n  extends SbbPaginatedTabHeader\n  implements AfterContentChecked, AfterContentInit, OnDestroy\n{\n  /** Query list of all tab links of the tab navigation. */\n  @ContentChildren(forwardRef(() => SbbTabLink), { descendants: true })\n  _items!: QueryList<SbbTabLink>;\n\n  /**\n   * Associated tab panel controlled by the nav bar. If not provided, then the nav bar\n   * follows the ARIA link / navigation landmark pattern. If provided, it follows the\n   * ARIA tabs design pattern.\n   */\n  @Input() tabPanel?: SbbTabNavPanel;\n\n  @ViewChild('tabListContainer', { static: true }) _tabListContainer!: ElementRef;\n  @ViewChild('tabList', { static: true }) _tabList!: ElementRef;\n  @ViewChild('tabListInner', { static: true }) _tabListInner!: ElementRef;\n  @ViewChild('nextPaginator') _nextPaginator!: ElementRef<HTMLElement>;\n  @ViewChild('previousPaginator') _previousPaginator!: ElementRef<HTMLElement>;\n\n  constructor(\n    elementRef: ElementRef,\n    ngZone: NgZone,\n    changeDetectorRef: ChangeDetectorRef,\n    viewportRuler: ViewportRuler,\n    platform: Platform,\n    @Optional() @Inject(ANIMATION_MODULE_TYPE) animationMode?: string,\n  ) {\n    super(elementRef, changeDetectorRef, viewportRuler, ngZone, platform, animationMode);\n  }\n\n  protected _itemSelected() {\n    // noop\n  }\n\n  override ngAfterContentInit() {\n    // We need this to run before the `changes` subscription in parent to ensure that the\n    // selectedIndex is up-to-date by the time the super class starts looking for it.\n    this._items.changes.pipe(startWith(null), takeUntil(this._destroyed)).subscribe(() => {\n      this.updateActiveLink();\n    });\n\n    super.ngAfterContentInit();\n  }\n\n  /** Notifies the component that the active link has been changed. */\n  updateActiveLink() {\n    if (!this._items) {\n      return;\n    }\n\n    const items = this._items.toArray();\n\n    for (let i = 0; i < items.length; i++) {\n      if (items[i].active) {\n        this.selectedIndex = i;\n        this._changeDetectorRef.markForCheck();\n\n        if (this.tabPanel) {\n          this.tabPanel._activeTabId = items[i].id;\n        }\n\n        return;\n      }\n    }\n\n    this.selectedIndex = -1;\n  }\n\n  _getRole(): string | null {\n    return this.tabPanel ? 'tablist' : this._elementRef.nativeElement.getAttribute('role');\n  }\n}\n\n/**\n * Link inside of a `sbb-tab-nav-bar`.\n */\n@Directive({\n  selector: '[sbb-tab-link], [sbbTabLink]',\n  exportAs: 'sbbTabLink',\n  host: {\n    class: 'sbb-tab-link sbb-link-reset',\n    '[attr.aria-controls]': '_getAriaControls()',\n    '[attr.aria-current]': '_getAriaCurrent()',\n    '[attr.aria-disabled]': 'disabled',\n    '[attr.aria-selected]': '_getAriaSelected()',\n    '[attr.id]': 'id',\n    '[attr.tabIndex]': '_getTabIndex()',\n    '[attr.role]': '_getRole()',\n    '[class.sbb-tab-disabled]': 'disabled',\n    '[class.sbb-tab-label-active]': 'active',\n    '(focus)': '_handleFocus()',\n    '(keydown)': '_handleKeydown($event)',\n  },\n})\nexport class SbbTabLink implements AfterViewInit, OnDestroy, FocusableOption {\n  /** Whether the tab link is disabled. */\n  @Input({ transform: booleanAttribute }) disabled: boolean = false;\n\n  /** Tab index for the tab link. */\n  @Input({ transform: (value: unknown) => (value == null ? 0 : numberAttribute(value)) })\n  tabIndex: number = 0;\n\n  /** Whether the link is active. */\n  @Input({ transform: booleanAttribute })\n  get active(): boolean {\n    return this._isActive;\n  }\n  set active(value: boolean) {\n    if (value !== this._isActive) {\n      this._isActive = value;\n      this._tabNavBar.updateActiveLink();\n    }\n  }\n  protected _isActive: boolean = false;\n\n  /** Unique id for the tab. */\n  @Input() id: string = inject(_IdGenerator).getId('sbb-tab-link-');\n\n  constructor(\n    private _tabNavBar: SbbTabNav,\n    /** @docs-private */ public elementRef: ElementRef,\n    @Attribute('tabindex') tabIndex: string,\n    private _focusMonitor: FocusMonitor,\n  ) {\n    this.tabIndex = parseInt(tabIndex, 10) || 0;\n  }\n\n  /** Focuses the tab link. */\n  focus() {\n    this.elementRef.nativeElement.focus();\n  }\n\n  ngAfterViewInit() {\n    this._focusMonitor.monitor(this.elementRef);\n  }\n\n  ngOnDestroy() {\n    this._focusMonitor.stopMonitoring(this.elementRef);\n  }\n\n  _handleFocus() {\n    // Since we allow navigation through tabbing in the nav bar, we\n    // have to update the focused index whenever the link receives focus.\n    this._tabNavBar.focusIndex = this._tabNavBar._items.toArray().indexOf(this);\n  }\n\n  _handleKeydown(event: KeyboardEvent) {\n    if (event.keyCode === SPACE || event.keyCode === ENTER) {\n      if (this.disabled) {\n        event.preventDefault();\n      } else if (this._tabNavBar.tabPanel) {\n        // Only prevent the default action on space since it can scroll the page.\n        // Don't prevent enter since it can break link navigation.\n        if (event.keyCode === SPACE) {\n          event.preventDefault();\n        }\n        this.elementRef.nativeElement.click();\n      }\n    }\n  }\n\n  _getAriaControls(): string | null {\n    return this._tabNavBar.tabPanel\n      ? this._tabNavBar.tabPanel?.id\n      : this.elementRef.nativeElement.getAttribute('aria-controls');\n  }\n\n  _getAriaSelected(): string | null {\n    if (this._tabNavBar.tabPanel) {\n      return this.active ? 'true' : 'false';\n    } else {\n      return this.elementRef.nativeElement.getAttribute('aria-selected');\n    }\n  }\n\n  _getAriaCurrent(): string | null {\n    return this.active && !this._tabNavBar.tabPanel ? 'page' : null;\n  }\n\n  _getRole(): string | null {\n    return this._tabNavBar.tabPanel ? 'tab' : this.elementRef.nativeElement.getAttribute('role');\n  }\n\n  _getTabIndex(): number {\n    if (this._tabNavBar.tabPanel) {\n      return this._isActive ? 0 : -1;\n    } else {\n      return this.disabled ? -1 : this.tabIndex;\n    }\n  }\n}\n\n/**\n * Link inside of a `sbb-tab-nav-bar`.\n */\n/**\n * Tab panel component associated with SbbTabNav.\n */\n@Component({\n  selector: 'sbb-tab-nav-panel',\n  exportAs: 'sbbTabNavPanel',\n  template: '<ng-content></ng-content>',\n  host: {\n    '[attr.aria-labelledby]': '_activeTabId',\n    '[attr.id]': 'id',\n    class: 'sbb-tab-nav-panel',\n    role: 'tabpanel',\n  },\n  encapsulation: ViewEncapsulation.None,\n  changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SbbTabNavPanel {\n  /** Unique id for the tab panel. */\n  @Input() id: string = inject(_IdGenerator).getId('sbb-tab-nav-panel-');\n\n  /** Id of the active tab in the nav bar. */\n  _activeTabId?: string;\n}\n","<button\n  class=\"sbb-tab-header-pagination sbb-tab-header-pagination-before sbb-button-reset-frameless\"\n  #previousPaginator\n  aria-hidden=\"true\"\n  type=\"button\"\n  tabindex=\"-1\"\n  [class.sbb-tab-header-pagination-disabled]=\"_disableScrollBefore\"\n  [disabled]=\"_disableScrollBefore || null\"\n  (click)=\"_handlePaginatorClick('before')\"\n  (mousedown)=\"_handlePaginatorPress('before', $event)\"\n  (touchend)=\"_stopInterval()\"\n>\n  <sbb-icon svgIcon=\"chevron-left-small\" class=\"sbb-tab-header-pagination-chevron\"></sbb-icon>\n</button>\n\n<div\n  class=\"sbb-tab-link-container sbb-scrollbar\"\n  #tabListContainer\n  (keydown)=\"_handleKeydown($event)\"\n>\n  <div\n    class=\"sbb-tab-list\"\n    [class._sbb-animation-noopable]=\"_animationMode === 'NoopAnimations'\"\n    #tabList\n    (cdkObserveContent)=\"_onContentChanges()\"\n  >\n    <div class=\"sbb-tab-links\" #tabListInner>\n      <ng-content></ng-content>\n    </div>\n  </div>\n</div>\n\n<button\n  class=\"sbb-tab-header-pagination sbb-tab-header-pagination-after sbb-button-reset-frameless\"\n  #nextPaginator\n  aria-hidden=\"true\"\n  type=\"button\"\n  [class.sbb-tab-header-pagination-disabled]=\"_disableScrollAfter\"\n  [disabled]=\"_disableScrollAfter || null\"\n  tabindex=\"-1\"\n  (mousedown)=\"_handlePaginatorPress('after', $event)\"\n  (click)=\"_handlePaginatorClick('after')\"\n  (touchend)=\"_stopInterval()\"\n>\n  <sbb-icon svgIcon=\"chevron-right-small\" class=\"sbb-tab-header-pagination-chevron\"></sbb-icon>\n</button>\n","import { CdkScrollableModule } from '@angular/cdk/scrolling';\nimport { NgModule } from '@angular/core';\nimport { SbbCommonModule } from '@sbb-esta/angular/core';\nimport { SbbIconModule } from '@sbb-esta/angular/icon';\n\nimport { SbbTab } from './tab';\nimport { SbbTabContent } from './tab-content';\nimport { SbbTabGroup } from './tab-group';\nimport { SbbTabLabel } from './tab-label';\nimport { SbbTabLink, SbbTabNav, SbbTabNavPanel } from './tab-nav-bar';\n\n@NgModule({\n  imports: [\n    CdkScrollableModule,\n    SbbCommonModule,\n    SbbIconModule,\n    SbbTabGroup,\n    SbbTabLabel,\n    SbbTab,\n    SbbTabNav,\n    SbbTabNavPanel,\n    SbbTabLink,\n    SbbTabContent,\n  ],\n  // Don't export all components because some are only to be used internally.\n  exports: [\n    SbbCommonModule,\n    SbbTabGroup,\n    SbbTabLabel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