UNPKG

ng-devui

Version:

DevUI components based on Angular

63 lines (62 loc) 3.37 kB
import { AfterViewInit, ChangeDetectorRef, ElementRef, EventEmitter, OnChanges, QueryList, SimpleChanges, TemplateRef } from '@angular/core'; import { Observable } from 'rxjs'; import { TabComponent } from './tab.component'; import * as i0 from "@angular/core"; export interface ITabOperation { id: number | string; operation: string; } export declare class TabsComponent implements OnChanges, AfterViewInit { private el; private cdr; static ID_SEED: number; tabsEle: ElementRef; tabsViewport: ElementRef; type: 'tabs' | 'pills' | 'options' | 'wrapped' | 'slider'; size: 'lg' | 'md' | 'sm' | 'xs'; showContent: boolean; scrollMode: boolean | 'normal' | 'auto'; activeTab: number | string; customWidth: string; reactivable: boolean; closeable: boolean; closeableIds: any[]; addable: boolean; addTabTpl: TemplateRef<any>; scrollModeOperationTpl: TemplateRef<any>; /** * @todo * 待重新设计 */ vertical: boolean; /** * @deprecated * class设置无需内层,外层即可 */ cssClass: string; isHidden: boolean; beforeChange: (currentValue: any, previousValue: any) => boolean | Promise<boolean> | Observable<boolean>; tabs: QueryList<TabComponent>; activeTabChange: EventEmitter<string | number>; addOrDeleteTabChange: EventEmitter<ITabOperation>; id: string; offsetIndex: number; offsetLeft: number; offsetWidth: number; scrollModeToggle: boolean; tabsWidth: any[]; ARROW_DROPDOWN_WIDTH: number; get isShowShadow(): boolean; constructor(el: ElementRef, cdr: ChangeDetectorRef); ngOnChanges(changes: SimpleChanges): void; ngAfterViewInit(): void; changeActiveSlidingBlock(): void; canChange(currentTab: number | string): Promise<boolean>; select(id: number | string, callback?: Function): void; addOrDeleteTab(event: Event, id?: number | string): void; getTabsWidth(): void; scroll(direction?: string, index?: number, tab?: TabComponent, isInitScrollMode?: boolean): void; scrollIntoView(dom: HTMLElement): void; static ɵfac: i0.ɵɵFactoryDeclaration<TabsComponent, never>; static ɵcmp: i0.ɵɵComponentDeclaration<TabsComponent, "d-tabs", ["tabs"], { "type": { "alias": "type"; "required": false; }; "size": { "alias": "size"; "required": false; }; "showContent": { "alias": "showContent"; "required": false; }; "scrollMode": { "alias": "scrollMode"; "required": false; }; "activeTab": { "alias": "activeTab"; "required": false; }; "customWidth": { "alias": "customWidth"; "required": false; }; "reactivable": { "alias": "reactivable"; "required": false; }; "closeable": { "alias": "closeable"; "required": false; }; "closeableIds": { "alias": "closeableIds"; "required": false; }; "addable": { "alias": "addable"; "required": false; }; "addTabTpl": { "alias": "addTabTpl"; "required": false; }; "scrollModeOperationTpl": { "alias": "scrollModeOperationTpl"; "required": false; }; "vertical": { "alias": "vertical"; "required": false; }; "cssClass": { "alias": "cssClass"; "required": false; }; "isHidden": { "alias": "isHidden"; "required": false; }; "beforeChange": { "alias": "beforeChange"; "required": false; }; }, { "activeTabChange": "activeTabChange"; "addOrDeleteTabChange": "addOrDeleteTabChange"; }, ["tabs"], never, false, never>; }