UNPKG

primeng

Version:

PrimeNG is an open source UI library for Angular featuring a rich set of 80+ components, a theme designer, various theme alternatives such as Material, Bootstrap, Tailwind, premium templates and professional support. In addition, it integrates with PrimeB

255 lines (254 loc) 9.4 kB
import { AfterContentInit, ElementRef, EventEmitter, NgZone, QueryList, SimpleChanges, TemplateRef } from '@angular/core'; import { Footer, Header, PrimeTemplate } from 'primeng/api'; import { BaseComponent } from 'primeng/basecomponent'; import { ButtonProps } from 'primeng/button'; import { CarouselPageEvent, CarouselResponsiveOptions } from './carousel.interface'; import { CarouselStyle } from './style/carouselstyle'; import * as i0 from "@angular/core"; import * as i1 from "primeng/api"; /** * Carousel is a content slider featuring various customization options. * @group Components */ export declare class Carousel extends BaseComponent implements AfterContentInit { el: ElementRef; zone: NgZone; /** * Index of the first item. * @defaultValue 0 * @group Props */ get page(): number; set page(val: number); /** * Number of items per page. * @defaultValue 1 * @group Props */ get numVisible(): number; set numVisible(val: number); /** * Number of items to scroll. * @defaultValue 1 * @group Props */ get numScroll(): number; set numScroll(val: number); /** * An array of options for responsive design. * @see {CarouselResponsiveOptions} * @group Props */ responsiveOptions: CarouselResponsiveOptions[] | undefined; /** * Specifies the layout of the component. * @group Props */ orientation: 'horizontal' | 'vertical'; /** * Height of the viewport in vertical layout. * @group Props */ verticalViewPortHeight: string; /** * Style class of main content. * @group Props */ contentClass: string; /** * Style class of the indicator items. * @group Props */ indicatorsContentClass: string; /** * Inline style of the indicator items. * @group Props */ indicatorsContentStyle: { [klass: string]: any; } | null | undefined; /** * Style class of the indicators. * @group Props */ indicatorStyleClass: string; /** * Style of the indicators. * @group Props */ indicatorStyle: { [klass: string]: any; } | null | undefined; /** * An array of objects to display. * @defaultValue null * @group Props */ get value(): any[]; set value(val: any[]); /** * Defines if scrolling would be infinite. * @group Props */ circular: boolean; /** * Whether to display indicator container. * @group Props */ showIndicators: boolean; /** * Whether to display navigation buttons in container. * @group Props */ showNavigators: boolean; /** * Time in milliseconds to scroll items automatically. * @group Props */ autoplayInterval: number; /** * Inline style of the component. * @group Props */ style: { [klass: string]: any; } | null | undefined; /** * Style class of the viewport container. * @group Props */ styleClass: string | undefined; /** * Used to pass all properties of the ButtonProps to the Button component. * @group Props */ prevButtonProps: ButtonProps; /** * Used to pass all properties of the ButtonProps to the Button component. * @group Props */ nextButtonProps: ButtonProps; /** * Callback to invoke after scroll. * @param {CarouselPageEvent} event - Custom page event. * @group Emits */ onPage: EventEmitter<CarouselPageEvent>; itemsContainer: ElementRef | undefined; indicatorContent: ElementRef | undefined; headerFacet: QueryList<Header> | undefined; footerFacet: QueryList<Footer> | undefined; _numVisible: number; _numScroll: number; _oldNumScroll: number; prevState: any; defaultNumScroll: number; defaultNumVisible: number; _page: number; _value: any[] | null | undefined; carouselStyle: any; id: string | undefined; totalShiftedItems: any; isRemainingItemsAdded: boolean; animationTimeout: any; translateTimeout: any; remainingItems: number; _items: any[] | undefined; startPos: any; documentResizeListener: any; clonedItemsForStarting: any[] | undefined; clonedItemsForFinishing: any[] | undefined; allowAutoplay: boolean | undefined; interval: any; isCreated: boolean | undefined; swipeThreshold: number; /** * Template for carousel items. * @group Templates */ itemTemplate: TemplateRef<any> | undefined; /** * Template for the carousel header. * @group Templates */ headerTemplate: TemplateRef<any> | undefined; /** * Template for the carousel footer. * @group Templates */ footerTemplate: TemplateRef<any> | undefined; /** * Template for the previous button icon. * @group Templates */ previousIconTemplate: TemplateRef<any> | undefined; /** * Template for the next button icon. * @group Templates */ nextIconTemplate: TemplateRef<any> | undefined; _itemTemplate: TemplateRef<any> | undefined; _headerTemplate: TemplateRef<any> | undefined; _footerTemplate: TemplateRef<any> | undefined; _previousIconTemplate: TemplateRef<any> | undefined; _nextIconTemplate: TemplateRef<any> | undefined; window: Window; _componentStyle: CarouselStyle; constructor(el: ElementRef, zone: NgZone); ngOnChanges(simpleChange: SimpleChanges): void; templates: QueryList<PrimeTemplate> | undefined; ngAfterContentInit(): void; ngAfterContentChecked(): void; createStyle(): void; calculatePosition(): void; setCloneItems(): void; firstIndex(): number; lastIndex(): number; totalDots(): number; totalDotsArray(): any[]; isVertical(): boolean; isCircular(): boolean; isAutoplay(): boolean; isForwardNavDisabled(): boolean; isBackwardNavDisabled(): boolean; isEmpty(): boolean; navForward(e: MouseEvent | TouchEvent, index?: number): void; navBackward(e: MouseEvent | TouchEvent, index?: number): void; onDotClick(e: MouseEvent, index: number): void; onIndicatorKeydown(event: KeyboardEvent): void; onRightKey(): void; onLeftKey(): void; onHomeKey(): void; onEndKey(): void; onTabKey(): void; findFocusedIndicatorIndex(): number; changedFocusedIndicator(prevInd: any, nextInd: any): void; step(dir: number, page?: number): void; startAutoplay(): void; stopAutoplay(changeAllow?: boolean): void; isPlaying(): boolean; onTransitionEnd(): void; onTouchStart(e: TouchEvent): void; onTouchMove(e: TouchEvent | MouseEvent): void; onTouchEnd(e: TouchEvent): void; changePageOnTouch(e: TouchEvent | MouseEvent, diff: number): void; ariaPrevButtonLabel(): string; ariaSlideLabel(): string; ariaNextButtonLabel(): string; ariaSlideNumber(value: any): string; ariaPageLabel(value: any): string; bindDocumentListeners(): void; unbindDocumentListeners(): void; ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<Carousel, never>; static ɵcmp: i0.ɵɵComponentDeclaration<Carousel, "p-carousel", never, { "page": { "alias": "page"; "required": false; }; "numVisible": { "alias": "numVisible"; "required": false; }; "numScroll": { "alias": "numScroll"; "required": false; }; "responsiveOptions": { "alias": "responsiveOptions"; "required": false; }; "orientation": { "alias": "orientation"; "required": false; }; "verticalViewPortHeight": { "alias": "verticalViewPortHeight"; "required": false; }; "contentClass": { "alias": "contentClass"; "required": false; }; "indicatorsContentClass": { "alias": "indicatorsContentClass"; "required": false; }; "indicatorsContentStyle": { "alias": "indicatorsContentStyle"; "required": false; }; "indicatorStyleClass": { "alias": "indicatorStyleClass"; "required": false; }; "indicatorStyle": { "alias": "indicatorStyle"; "required": false; }; "value": { "alias": "value"; "required": false; }; "circular": { "alias": "circular"; "required": false; }; "showIndicators": { "alias": "showIndicators"; "required": false; }; "showNavigators": { "alias": "showNavigators"; "required": false; }; "autoplayInterval": { "alias": "autoplayInterval"; "required": false; }; "style": { "alias": "style"; "required": false; }; "styleClass": { "alias": "styleClass"; "required": false; }; "prevButtonProps": { "alias": "prevButtonProps"; "required": false; }; "nextButtonProps": { "alias": "nextButtonProps"; "required": false; }; }, { "onPage": "onPage"; }, ["headerFacet", "footerFacet", "itemTemplate", "headerTemplate", "footerTemplate", "previousIconTemplate", "nextIconTemplate", "templates"], ["p-header", "p-footer"], true, never>; static ngAcceptInputType_circular: unknown; static ngAcceptInputType_showIndicators: unknown; static ngAcceptInputType_showNavigators: unknown; static ngAcceptInputType_autoplayInterval: unknown; } export declare class CarouselModule { static ɵfac: i0.ɵɵFactoryDeclaration<CarouselModule, never>; static ɵmod: i0.ɵɵNgModuleDeclaration<CarouselModule, never, [typeof Carousel, typeof i1.SharedModule], [typeof Carousel, typeof i1.SharedModule]>; static ɵinj: i0.ɵɵInjectorDeclaration<CarouselModule>; }