import { NumberInput } from '@angular/cdk/coercion'; import { ChangeDetectorRef, ElementRef, TemplateRef } from '@angular/core'; import { Destroy } from '@deja-js/component/core'; import { IViewPortItem, ViewPortService } from '@deja-js/component/core/item-list'; import * as i0 from "@angular/core"; export declare type DejaViewPortScrollStyleType = 'scrollbar' | 'buttons'; export declare class DejaViewPortComponent extends Destroy { private changeDetectorRef; private viewPort; hasUpButton: boolean; hasDownButton: boolean; _isHorizontal: boolean; _hasButtons: boolean; /** Permet de définir un template d'élément par binding */ itemTemplateExternal: TemplateRef; private itemTemplateInternal; beforeSize: number; afterSize: number; vpItems: IDejaViewPortItem[]; vpStartIndex: number; vpEndIndex: number; startOffset: number; get hasButtons(): boolean; get isHorizontal(): boolean; private _items; private element; private downButton$; private upButton$; private scrollPosition; private _buttonsStep; set buttonsStep(value: number); get buttonsStep(): number; set downButton(element: ElementRef); set upButton(element: ElementRef); /** Set the list of models to render inside the viewport control */ set models(models: unknown[]); /** Set the list of items to render inside the viewport control */ set items(items: IDejaViewPortItem[]); /** Set the scrolling style * scrollbar: Classic scrollbars * buttons: A button before is placed at the top or at the left of the list, and a button after is placed at the right or the bottom of the list. */ set scrollingStyle(value: DejaViewPortScrollStyleType); /** Set the direction of the items rendering * vertical: The item are displayed vertically * horizontal: The item are displayed horizontally */ set direction(value: string); /** Set the item size in fixed mode or the default item size before rendering in auto mode */ set itemSize(value: NumberInput); get itemSize(): NumberInput; set wrapperElement(element: ElementRef); get itemTemplate(): TemplateRef; get clientSize(): number; set scrollPos(value: number); get scrollPos(): number; /** * Définit la méthode de calcul de la taille des éléments. Les valuers acceptées sont * disabled: Tous les éléments sont rendus. (< 100 éléments) * fixed: Seul les éléments visibles sont rendus. La taille des éléments est constante et définie par itemsSize. (performances ++) * variable: Seul les éléments visibles sont rendus. La taille des éléments est variable et définie par item.size. (performances +-) * auto: Seul les éléments visibles sont rendus. La taille des éléments est calculée automatiquement (performances --) */ set viewportMode(mode: string); get viewportMode(): string; constructor(changeDetectorRef: ChangeDetectorRef, viewPort: ViewPortService); refresh(): void; /** Recalcule le viewport. */ refreshViewPort(item?: IViewPortItem, clearMeasuredHeight?: boolean): void; ensureVisible(item: unknown): void; getCssSize(item: IViewPortItem): string; getItemSize(item: IViewPortItem): NumberInput; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } export interface IDejaViewPortItem extends IViewPortItem { model?: unknown; }