Skip to content

Latest commit

 

History

History
544 lines (507 loc) · 21.3 KB

index.api.md

File metadata and controls

544 lines (507 loc) · 21.3 KB

API Report File for "@angular/material_tabs"

Do not edit this file. It is a report generated by API Extractor.

import { AfterContentChecked } from '@angular/core';
import { AfterContentInit } from '@angular/core';
import { AfterViewInit } from '@angular/core';
import { BehaviorSubject } from 'rxjs';
import { CdkPortal } from '@angular/cdk/portal';
import { CdkPortalOutlet } from '@angular/cdk/portal';
import { ChangeDetectorRef } from '@angular/core';
import { Direction } from '@angular/cdk/bidi';
import { ElementRef } from '@angular/core';
import { EventEmitter } from '@angular/core';
import { FocusableOption } from '@angular/cdk/a11y';
import { FocusOrigin } from '@angular/cdk/a11y';
import * as i0 from '@angular/core';
import * as i1 from '@angular/cdk/bidi';
import { InjectionToken } from '@angular/core';
import { OnChanges } from '@angular/core';
import { OnDestroy } from '@angular/core';
import { OnInit } from '@angular/core';
import { QueryList } from '@angular/core';
import { SimpleChanges } from '@angular/core';
import { Subject } from 'rxjs';
import { TemplatePortal } from '@angular/cdk/portal';
import { TemplateRef } from '@angular/core';

// @public
export const _MAT_INK_BAR_POSITIONER: InjectionToken<_MatInkBarPositioner>;

// @public @deprecated
export function _MAT_INK_BAR_POSITIONER_FACTORY(): _MatInkBarPositioner;

// @public
export const MAT_TAB: InjectionToken<MatTabBase>;

// @public
export const MAT_TAB_CONTENT: InjectionToken<MatTabContent>;

// @public
export const MAT_TAB_GROUP: InjectionToken<MatTabGroupBase>;

// @public
export const MAT_TAB_LABEL: InjectionToken<MatTabLabel>;

// @public
export const MAT_TABS_CONFIG: InjectionToken<MatTabsConfig>;

// @public
export class MatInkBar {
    constructor(_items: QueryList<MatInkBarItem>);
    alignToElement(element: HTMLElement): void;
    hide(): void;
}

// @public
export interface _MatInkBarPositioner {
    // (undocumented)
    (element: HTMLElement): {
        left: string;
        width: string;
    };
}

// @public
export abstract class MatPaginatedTabHeader implements AfterContentChecked, AfterContentInit, AfterViewInit, OnDestroy {
    constructor(...args: unknown[]);
    _alignInkBarToSelectedTab(): void;
    // (undocumented)
    _animationsDisabled: boolean;
    // (undocumented)
    protected _changeDetectorRef: ChangeDetectorRef;
    _checkPaginationEnabled(): void;
    _checkScrollingControls(): void;
    protected readonly _destroyed: Subject<void>;
    disablePagination: boolean;
    _disableScrollAfter: boolean;
    _disableScrollBefore: boolean;
    // (undocumented)
    protected _elementRef: ElementRef<HTMLElement>;
    get focusIndex(): number;
    set focusIndex(value: number);
    _getLayoutDirection(): Direction;
    _getMaxScrollDistance(): number;
    _handleKeydown(event: KeyboardEvent): void;
    _handlePaginatorClick(direction: ScrollDirection): void;
    _handlePaginatorPress(direction: ScrollDirection, mouseEvent?: MouseEvent): void;
    readonly indexFocused: EventEmitter<number>;
    // (undocumented)
    abstract _inkBar: {
        hide: () => void;
        alignToElement: (element: HTMLElement) => void;
    };
    _isValidIndex(index: number): boolean;
    // (undocumented)
    abstract _items: QueryList<MatPaginatedTabHeaderItem>;
    protected abstract _itemSelected(event: KeyboardEvent): void;
    // (undocumented)
    abstract _nextPaginator: ElementRef<HTMLElement>;
    // (undocumented)
    static ngAcceptInputType_disablePagination: unknown;
    // (undocumented)
    static ngAcceptInputType_selectedIndex: unknown;
    // (undocumented)
    ngAfterContentChecked(): void;
    // (undocumented)
    ngAfterContentInit(): void;
    // (undocumented)
    ngAfterViewInit(): void;
    // (undocumented)
    ngOnDestroy(): void;
    _onContentChanges(): void;
    // (undocumented)
    abstract _previousPaginator: ElementRef<HTMLElement>;
    get scrollDistance(): number;
    set scrollDistance(value: number);
    _scrollHeader(direction: ScrollDirection): {
        maxScrollDistance: number;
        distance: number;
    };
    _scrollToLabel(labelIndex: number): void;
    get selectedIndex(): number;
    set selectedIndex(v: number);
    readonly selectFocusedIndex: EventEmitter<number>;
    _setTabFocus(tabIndex: number): void;
    _showPaginationControls: boolean;
    _stopInterval(): void;
    // (undocumented)
    abstract _tabList: ElementRef<HTMLElement>;
    // (undocumented)
    abstract _tabListContainer: ElementRef<HTMLElement>;
    // (undocumented)
    abstract _tabListInner: ElementRef<HTMLElement>;
    updatePagination(): void;
    _updateTabScrollPosition(): void;
    // (undocumented)
    static ɵdir: i0.ɵɵDirectiveDeclaration<MatPaginatedTabHeader, never, never, { "disablePagination": { "alias": "disablePagination"; "required": false; }; "selectedIndex": { "alias": "selectedIndex"; "required": false; }; }, { "selectFocusedIndex": "selectFocusedIndex"; "indexFocused": "indexFocused"; }, never, never, true, never>;
    // (undocumented)
    static ɵfac: i0.ɵɵFactoryDeclaration<MatPaginatedTabHeader, never>;
}

// @public (undocumented)
export class MatTab implements MatTabBase, OnInit, OnChanges, OnDestroy {
    constructor(...args: unknown[]);
    ariaLabel: string;
    ariaLabelledby: string;
    bodyClass: string | string[];
    // (undocumented)
    _closestTabGroup: MatTabGroupBase | null;
    get content(): TemplatePortal | null;
    disabled: boolean;
    id: string | null;
    _implicitContent?: TemplateRef<unknown>;
    isActive: boolean;
    labelClass: string | string[];
    // (undocumented)
    static ngAcceptInputType_disabled: unknown;
    // (undocumented)
    ngOnChanges(changes: SimpleChanges): void;
    // (undocumented)
    ngOnDestroy(): void;
    // (undocumented)
    ngOnInit(): void;
    origin: number | null;
    position: number | null;
    readonly _stateChanges: Subject<void>;
    get templateLabel(): MatTabLabel;
    set templateLabel(value: MatTabLabel);
    textLabel: string;
    // (undocumented)
    static ɵcmp: i0.ɵɵComponentDeclaration<MatTab, "mat-tab", ["matTab"], { "disabled": { "alias": "disabled"; "required": false; }; "textLabel": { "alias": "label"; "required": false; }; "ariaLabel": { "alias": "aria-label"; "required": false; }; "ariaLabelledby": { "alias": "aria-labelledby"; "required": false; }; "labelClass": { "alias": "labelClass"; "required": false; }; "bodyClass": { "alias": "bodyClass"; "required": false; }; "id": { "alias": "id"; "required": false; }; }, {}, ["templateLabel", "_explicitContent"], ["*"], true, never>;
    // (undocumented)
    static ɵfac: i0.ɵɵFactoryDeclaration<MatTab, never>;
}

// @public
export interface MatTabBase {
}

// @public
export class MatTabBody implements OnInit, OnDestroy {
    constructor(...args: unknown[]);
    readonly _afterLeavingCenter: EventEmitter<void>;
    animationDuration: string;
    readonly _beforeCentering: EventEmitter<boolean>;
    _content: TemplatePortal;
    _contentElement: ElementRef<HTMLElement> | undefined;
    _getLayoutDirection(): Direction;
    _isCenterPosition(): boolean;
    // (undocumented)
    ngOnDestroy(): void;
    // (undocumented)
    ngOnInit(): void;
    readonly _onCentered: EventEmitter<void>;
    readonly _onCentering: EventEmitter<number>;
    _portalHost: MatTabBodyPortal;
    set position(position: number);
    _position: MatTabBodyPositionState;
    preserveContent: boolean;
    protected _previousPosition: MatTabBodyPositionState | undefined;
    _setActiveClass(isActive: boolean): void;
    // (undocumented)
    static ɵcmp: i0.ɵɵComponentDeclaration<MatTabBody, "mat-tab-body", never, { "_content": { "alias": "content"; "required": false; }; "animationDuration": { "alias": "animationDuration"; "required": false; }; "preserveContent": { "alias": "preserveContent"; "required": false; }; "position": { "alias": "position"; "required": false; }; }, { "_onCentering": "_onCentering"; "_beforeCentering": "_beforeCentering"; "_onCentered": "_onCentered"; }, never, never, true, never>;
    // (undocumented)
    static ɵfac: i0.ɵɵFactoryDeclaration<MatTabBody, never>;
}

// @public @deprecated
export type MatTabBodyOriginState = 'left' | 'right';

// @public
export class MatTabBodyPortal extends CdkPortalOutlet implements OnInit, OnDestroy {
    constructor(...args: unknown[]);
    ngOnDestroy(): void;
    ngOnInit(): void;
    // (undocumented)
    static ɵdir: i0.ɵɵDirectiveDeclaration<MatTabBodyPortal, "[matTabBodyHost]", never, {}, {}, never, never, true, never>;
    // (undocumented)
    static ɵfac: i0.ɵɵFactoryDeclaration<MatTabBodyPortal, never>;
}

// @public @deprecated
export type MatTabBodyPositionState = 'left' | 'center' | 'right';

// @public
export class MatTabChangeEvent {
    index: number;
    tab: MatTab;
}

// @public
export class MatTabContent {
    constructor(...args: unknown[]);
    // (undocumented)
    template: TemplateRef<unknown>;
    // (undocumented)
    static ɵdir: i0.ɵɵDirectiveDeclaration<MatTabContent, "[matTabContent]", never, {}, {}, never, never, true, never>;
    // (undocumented)
    static ɵfac: i0.ɵɵFactoryDeclaration<MatTabContent, never>;
}

// @public
export class MatTabGroup implements AfterViewInit, AfterContentInit, AfterContentChecked, OnDestroy {
    constructor(...args: unknown[]);
    alignTabs: string | null;
    _allTabs: QueryList<MatTab>;
    readonly animationDone: EventEmitter<void>;
    get animationDuration(): string;
    set animationDuration(value: string | number);
    // (undocumented)
    _animationsDisabled: boolean;
    ariaLabel: string;
    ariaLabelledby: string;
    // @deprecated
    get backgroundColor(): ThemePalette;
    set backgroundColor(value: ThemePalette);
    protected _bodyCentered(isCenter: boolean): void;
    color: ThemePalette;
    get contentTabIndex(): number | null;
    set contentTabIndex(value: number);
    disablePagination: boolean;
    disableRipple: boolean;
    dynamicHeight: boolean;
    // (undocumented)
    readonly _elementRef: ElementRef<any>;
    get fitInkBarToContent(): boolean;
    set fitInkBarToContent(value: boolean);
    readonly focusChange: EventEmitter<MatTabChangeEvent>;
    // (undocumented)
    _focusChanged(index: number): void;
    focusTab(index: number): void;
    _getTabContentId(index: number): string;
    _getTabIndex(index: number): number;
    _getTabLabelId(tab: MatTab, index: number): string;
    _handleClick(tab: MatTab, tabHeader: MatTabGroupBaseHeader, index: number): void;
    headerPosition: MatTabHeaderPosition;
    protected _isServer: boolean;
    // (undocumented)
    static ngAcceptInputType_contentTabIndex: unknown;
    // (undocumented)
    static ngAcceptInputType_disablePagination: unknown;
    // (undocumented)
    static ngAcceptInputType_disableRipple: unknown;
    // (undocumented)
    static ngAcceptInputType_dynamicHeight: unknown;
    // (undocumented)
    static ngAcceptInputType_fitInkBarToContent: unknown;
    // (undocumented)
    static ngAcceptInputType_preserveContent: unknown;
    // (undocumented)
    static ngAcceptInputType_selectedIndex: unknown;
    // (undocumented)
    static ngAcceptInputType_stretchTabs: unknown;
    ngAfterContentChecked(): void;
    // (undocumented)
    ngAfterContentInit(): void;
    // (undocumented)
    ngAfterViewInit(): void;
    // (undocumented)
    ngOnDestroy(): void;
    preserveContent: boolean;
    realignInkBar(): void;
    _removeTabBodyWrapperHeight(): void;
    get selectedIndex(): number | null;
    set selectedIndex(value: number);
    readonly selectedIndexChange: EventEmitter<number>;
    readonly selectedTabChange: EventEmitter<MatTabChangeEvent>;
    _setTabBodyWrapperHeight(tabHeight: number): void;
    stretchTabs: boolean;
    // (undocumented)
    _tabBodies: QueryList<MatTabBody> | undefined;
    // (undocumented)
    _tabBodyWrapper: ElementRef;
    _tabFocusChanged(focusOrigin: FocusOrigin, index: number): void;
    // (undocumented)
    _tabHeader: MatTabHeader;
    _tabs: QueryList<MatTab>;
    updatePagination(): void;
    // (undocumented)
    static ɵcmp: i0.ɵɵComponentDeclaration<MatTabGroup, "mat-tab-group", ["matTabGroup"], { "color": { "alias": "color"; "required": false; }; "fitInkBarToContent": { "alias": "fitInkBarToContent"; "required": false; }; "stretchTabs": { "alias": "mat-stretch-tabs"; "required": false; }; "alignTabs": { "alias": "mat-align-tabs"; "required": false; }; "dynamicHeight": { "alias": "dynamicHeight"; "required": false; }; "selectedIndex": { "alias": "selectedIndex"; "required": false; }; "headerPosition": { "alias": "headerPosition"; "required": false; }; "animationDuration": { "alias": "animationDuration"; "required": false; }; "contentTabIndex": { "alias": "contentTabIndex"; "required": false; }; "disablePagination": { "alias": "disablePagination"; "required": false; }; "disableRipple": { "alias": "disableRipple"; "required": false; }; "preserveContent": { "alias": "preserveContent"; "required": false; }; "backgroundColor": { "alias": "backgroundColor"; "required": false; }; "ariaLabel": { "alias": "aria-label"; "required": false; }; "ariaLabelledby": { "alias": "aria-labelledby"; "required": false; }; }, { "selectedIndexChange": "selectedIndexChange"; "focusChange": "focusChange"; "animationDone": "animationDone"; "selectedTabChange": "selectedTabChange"; }, ["_allTabs"], ["*"], true, never>;
    // (undocumented)
    static ɵfac: i0.ɵɵFactoryDeclaration<MatTabGroup, never>;
}

// @public
export interface MatTabGroupBase {
}

// @public
export interface MatTabGroupBaseHeader {
    // (undocumented)
    _alignInkBarToSelectedTab(): void;
    // (undocumented)
    focusIndex: number;
    // (undocumented)
    updatePagination(): void;
}

// @public
export class MatTabHeader extends MatPaginatedTabHeader implements AfterContentChecked, AfterContentInit, AfterViewInit, OnDestroy {
    ariaLabel: string;
    ariaLabelledby: string;
    disableRipple: boolean;
    // (undocumented)
    _inkBar: MatInkBar;
    // (undocumented)
    _items: QueryList<MatTabLabelWrapper>;
    // (undocumented)
    protected _itemSelected(event: KeyboardEvent): void;
    // (undocumented)
    _nextPaginator: ElementRef<HTMLElement>;
    // (undocumented)
    static ngAcceptInputType_disableRipple: unknown;
    // (undocumented)
    ngAfterContentInit(): void;
    // (undocumented)
    _previousPaginator: ElementRef<HTMLElement>;
    // (undocumented)
    _tabList: ElementRef;
    // (undocumented)
    _tabListContainer: ElementRef;
    // (undocumented)
    _tabListInner: ElementRef;
    // (undocumented)
    static ɵcmp: i0.ɵɵComponentDeclaration<MatTabHeader, "mat-tab-header", never, { "ariaLabel": { "alias": "aria-label"; "required": false; }; "ariaLabelledby": { "alias": "aria-labelledby"; "required": false; }; "disableRipple": { "alias": "disableRipple"; "required": false; }; }, {}, ["_items"], ["*"], true, never>;
    // (undocumented)
    static ɵfac: i0.ɵɵFactoryDeclaration<MatTabHeader, never>;
}

// @public
export type MatTabHeaderPosition = 'above' | 'below';

// @public
export class MatTabLabel extends CdkPortal {
    // (undocumented)
    _closestTab: MatTabBase | null;
    // (undocumented)
    static ɵdir: i0.ɵɵDirectiveDeclaration<MatTabLabel, "[mat-tab-label], [matTabLabel]", never, {}, {}, never, never, true, never>;
    // (undocumented)
    static ɵfac: i0.ɵɵFactoryDeclaration<MatTabLabel, never>;
}

// @public
export class MatTabLabelWrapper extends InkBarItem {
    disabled: boolean;
    // (undocumented)
    elementRef: ElementRef<any>;
    focus(): void;
    // (undocumented)
    getOffsetLeft(): number;
    // (undocumented)
    getOffsetWidth(): number;
    // (undocumented)
    static ngAcceptInputType_disabled: unknown;
    // (undocumented)
    static ɵdir: i0.ɵɵDirectiveDeclaration<MatTabLabelWrapper, "[matTabLabelWrapper]", never, { "disabled": { "alias": "disabled"; "required": false; }; }, {}, never, never, true, never>;
    // (undocumented)
    static ɵfac: i0.ɵɵFactoryDeclaration<MatTabLabelWrapper, never>;
}

// @public
export class MatTabLink extends InkBarItem implements AfterViewInit, OnDestroy, RippleTarget, FocusableOption {
    constructor(...args: unknown[]);
    get active(): boolean;
    set active(value: boolean);
    disabled: boolean;
    disableRipple: boolean;
    // (undocumented)
    elementRef: ElementRef<any>;
    focus(): void;
    // (undocumented)
    _getAriaControls(): string | null;
    // (undocumented)
    _getAriaCurrent(): string | null;
    // (undocumented)
    _getAriaSelected(): string | null;
    // (undocumented)
    _getRole(): string | null;
    // (undocumented)
    _getTabIndex(): number;
    // (undocumented)
    _handleFocus(): void;
    // (undocumented)
    _handleKeydown(event: KeyboardEvent): void;
    id: string;
    protected _isActive: boolean;
    // (undocumented)
    static ngAcceptInputType_active: unknown;
    // (undocumented)
    static ngAcceptInputType_disabled: unknown;
    // (undocumented)
    static ngAcceptInputType_disableRipple: unknown;
    // (undocumented)
    static ngAcceptInputType_tabIndex: unknown;
    // (undocumented)
    ngAfterViewInit(): void;
    // (undocumented)
    ngOnDestroy(): void;
    rippleConfig: RippleConfig & RippleGlobalOptions;
    get rippleDisabled(): boolean;
    // (undocumented)
    tabIndex: number;
    // (undocumented)
    static ɵcmp: i0.ɵɵComponentDeclaration<MatTabLink, "[mat-tab-link], [matTabLink]", ["matTabLink"], { "active": { "alias": "active"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "disableRipple": { "alias": "disableRipple"; "required": false; }; "tabIndex": { "alias": "tabIndex"; "required": false; }; "id": { "alias": "id"; "required": false; }; }, {}, never, ["*"], true, never>;
    // (undocumented)
    static ɵfac: i0.ɵɵFactoryDeclaration<MatTabLink, never>;
}

// @public
export class MatTabNav extends MatPaginatedTabHeader implements AfterContentInit, AfterViewInit {
    constructor(...args: unknown[]);
    // (undocumented)
    get animationDuration(): string;
    set animationDuration(value: string | number);
    get backgroundColor(): ThemePalette;
    set backgroundColor(value: ThemePalette);
    color: ThemePalette;
    disableRipple: boolean;
    get fitInkBarToContent(): boolean;
    set fitInkBarToContent(value: boolean);
    // (undocumented)
    _fitInkBarToContent: BehaviorSubject<boolean>;
    // (undocumented)
    _getRole(): string | null;
    // (undocumented)
    _inkBar: MatInkBar;
    _items: QueryList<MatTabLink>;
    // (undocumented)
    protected _itemSelected(): void;
    // (undocumented)
    _nextPaginator: ElementRef<HTMLElement>;
    // (undocumented)
    static ngAcceptInputType_disableRipple: unknown;
    // (undocumented)
    static ngAcceptInputType_fitInkBarToContent: unknown;
    // (undocumented)
    static ngAcceptInputType_stretchTabs: unknown;
    // (undocumented)
    ngAfterContentInit(): void;
    // (undocumented)
    ngAfterViewInit(): void;
    // (undocumented)
    _previousPaginator: ElementRef<HTMLElement>;
    stretchTabs: boolean;
    // (undocumented)
    _tabList: ElementRef;
    // (undocumented)
    _tabListContainer: ElementRef;
    // (undocumented)
    _tabListInner: ElementRef;
    tabPanel?: MatTabNavPanel;
    updateActiveLink(): void;
    // (undocumented)
    static ɵcmp: i0.ɵɵComponentDeclaration<MatTabNav, "[mat-tab-nav-bar]", ["matTabNavBar", "matTabNav"], { "fitInkBarToContent": { "alias": "fitInkBarToContent"; "required": false; }; "stretchTabs": { "alias": "mat-stretch-tabs"; "required": false; }; "animationDuration": { "alias": "animationDuration"; "required": false; }; "backgroundColor": { "alias": "backgroundColor"; "required": false; }; "disableRipple": { "alias": "disableRipple"; "required": false; }; "color": { "alias": "color"; "required": false; }; "tabPanel": { "alias": "tabPanel"; "required": false; }; }, {}, ["_items"], ["*"], true, never>;
    // (undocumented)
    static ɵfac: i0.ɵɵFactoryDeclaration<MatTabNav, never>;
}

// @public
export class MatTabNavPanel {
    _activeTabId?: string;
    id: string;
    // (undocumented)
    static ɵcmp: i0.ɵɵComponentDeclaration<MatTabNavPanel, "mat-tab-nav-panel", ["matTabNavPanel"], { "id": { "alias": "id"; "required": false; }; }, {}, never, ["*"], true, never>;
    // (undocumented)
    static ɵfac: i0.ɵɵFactoryDeclaration<MatTabNavPanel, never>;
}

// @public @deprecated
export const matTabsAnimations: {
    readonly translateTab: any;
};

// @public
export interface MatTabsConfig {
    alignTabs?: 'start' | 'center' | 'end';
    animationDuration?: string;
    contentTabIndex?: number;
    disablePagination?: boolean;
    dynamicHeight?: boolean;
    fitInkBarToContent?: boolean;
    preserveContent?: boolean;
    stretchTabs?: boolean;
}

// @public (undocumented)
export class MatTabsModule {
    // (undocumented)
    static ɵfac: i0.ɵɵFactoryDeclaration<MatTabsModule, never>;
    // (undocumented)
    static ɵinj: i0.ɵɵInjectorDeclaration<MatTabsModule>;
    // (undocumented)
    static ɵmod: i0.ɵɵNgModuleDeclaration<MatTabsModule, never, [typeof MatCommonModule, typeof MatTabContent, typeof MatTabLabel, typeof MatTab, typeof MatTabGroup, typeof MatTabNav, typeof MatTabNavPanel, typeof MatTabLink], [typeof MatCommonModule, typeof MatTabContent, typeof MatTabLabel, typeof MatTab, typeof MatTabGroup, typeof MatTabNav, typeof MatTabNavPanel, typeof MatTabLink]>;
}

// @public
export type ScrollDirection = 'after' | 'before';

// (No @packageDocumentation comment for this package)