import * as i0 from '@angular/core'; import { AfterViewInit, OnDestroy, ElementRef, ChangeDetectorRef, QueryList, OnInit, Renderer2, EventEmitter, Optional } from '@angular/core'; import * as rxjs from 'rxjs'; import { BehaviorSubject, Subject } from 'rxjs'; import { BooleanInput } from '@angular/cdk/coercion'; import { FocusMonitor } from '@angular/cdk/a11y'; import * as i1 from '@angular/common'; import * as i2 from '@aposin/ng-aquila/icon'; import * as i3 from '@aposin/ng-aquila/copytext'; import * as i4 from '@aposin/ng-aquila/swipebar'; interface NxExpandable { /** Indicates if this expandable instance is open or not. */ expanded: BehaviorSubject; /** Toggles the open state. */ toggle(): void; /** Expands this component. */ expand(): void; /** Closes this component. */ close(): void; } /** * This toggle button can be clicked and toggles expandable elements. * * E.g. it can toggle a expandable table row or anything else that implements the `NxExpandable` interface. */ declare class NxToggleButtonComponent implements AfterViewInit, OnDestroy { private readonly _cdr; private readonly _focusMonitor; _expanded: boolean; _buttonElement: ElementRef; /** * This is the expandable target that will be toggled when the user clicks the button. */ set target(value: NxExpandable); _target: NxExpandable; set ariaLabel(value: string); _ariaLabel: string; private _subscription; constructor(_cdr: ChangeDetectorRef, _focusMonitor: FocusMonitor); ngAfterViewInit(): void; _onClick(): void; ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } /** * This is an expandable table row. * It can collapse its height to hide the content. * Requires the table cells to have the `[nxExpandableTableCell]` component. */ declare class NxExpandableTableRowComponent implements NxExpandable { private readonly _cdr; set isExpanded(value: BooleanInput); get isExpanded(): BooleanInput; private _isExpanded; readonly expanded: BehaviorSubject; constructor(_cdr: ChangeDetectorRef); /** * Toggles the expansion of this row. */ toggle(): void; /** * Expands this row. */ expand(): void; /** * Closes this row. */ close(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } /** * The nxExpandableTable adds row expansion functionality to the nxTable. * It provides the logic to expand/collapse all expandable rows simultanously. */ declare class NxExpandableTableDirective implements OnDestroy, AfterViewInit, NxExpandable { rows: QueryList; readonly expanded: BehaviorSubject; private readonly _destroyed; ngAfterViewInit(): void; ngOnDestroy(): void; /** * Toggles the expandable rows. If all rows are open it will close them, otherwise it will open them. */ toggle(): void; /** * Expands all expandable rows. */ expand(): void; /** * Closes all expandable rows. */ close(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵdir: i0.ɵɵDirectiveDeclaration; } /** * This is an expandable table cell. * Only works in conjunction with the `[nxExpandableTableRow]` component. */ declare class NxExpandableTableCellComponent implements OnDestroy { private readonly _cdr; _open: boolean; private readonly _destroyed; constructor(_row: NxExpandableTableRowComponent, _cdr: ChangeDetectorRef); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } /** * This is a table header cell. */ declare class NxHeaderCellDirective { readonly elementRef: ElementRef; constructor(elementRef: ElementRef); static ɵfac: i0.ɵɵFactoryDeclaration; static ɵdir: i0.ɵɵDirectiveDeclaration; } declare class NxHeaderResizeDirective implements OnInit, OnDestroy { private readonly documentRef; private readonly elementRef; private readonly header; private renderer; private mousedown; private touchstart; private mousemove; private touchmove; private mouseup; private touchend; readonly resizable: rxjs.Observable; private readonly _destroyed; constructor(documentRef: Document, elementRef: ElementRef, header: NxHeaderCellDirective, renderer: Renderer2); ngOnInit(): void; ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵdir: i0.ɵɵDirectiveDeclaration; } /** * @deprecated due to not fulfilling the WCAG accessibility requirements. */ declare class NxTableCellClipDirective { static ɵfac: i0.ɵɵFactoryDeclaration; static ɵdir: i0.ɵɵDirectiveDeclaration; } type SortDirection = 'asc' | 'desc'; declare class SortEvent { /** The name of the column that is being sorted by. */ readonly active: string; /** The sort direction. */ readonly direction: SortDirection; constructor( /** The name of the column that is being sorted by. */ active: string, /** The sort direction. */ direction: SortDirection); } declare class NxSortDirective implements OnDestroy { readonly _stateChanges: Subject; /** Sets the key of the most recently sorted column. */ set active(value: string); get active(): string; private _active; /** Sets the direction of the currently active sorted column. Default: 'asc'. */ set direction(value: SortDirection); get direction(): SortDirection; private _direction; /** * An event emitted when the active value has changed. * @docs-private */ readonly activeChange: EventEmitter; /** * An event emitted when the direction value has changed. * @docs-private */ readonly directionChange: EventEmitter; /** An event emitted when either the active sort or sort direction changes. */ readonly sortChange: EventEmitter; ngOnDestroy(): void; /** * Sets the active sort key and determines the new sort direction. * Afterwards the output event `sortChange` is called. * * If `sortable` is not the key of the active sort header, the initial direction to sort is 'asc'. * Otherwise the direction of the sorted column changes. */ sort(sortable: string): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵdir: i0.ɵɵDirectiveDeclaration; } declare class NxSortHeaderIntl { /** * Stream that emits whenever the labels here are changed. Use this to notify * components if the labels have changed after initialization. */ readonly changes: Subject; /** The aria label for a header that can be clicked to sort ascending. */ sortAscendingAriaLabel: string; /** The aria label for a header that can be clicked to sort descending. */ sortDescendingAriaLabel: string; /** The aria label for a column that is sorted ascending. */ sortedAscendingAriaLabel: string; /** The aria label for a column that is sorted descending. */ sortedDescendingAriaLabel: string; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } declare class NxSortHeaderComponent implements OnInit, AfterViewInit, OnDestroy { readonly _intl: NxSortHeaderIntl; private readonly _cdr; private readonly _focusMonitor; /** Sets the key of this sort header. */ set key(value: string); get key(): string; private _key; _focusContainer: ElementRef; readonly _sort: NxSortDirective; private readonly _destroyed; constructor(_sort: NxSortDirective | null, _intl: NxSortHeaderIntl, _cdr: ChangeDetectorRef, _focusMonitor: FocusMonitor); ngOnInit(): void; ngAfterViewInit(): void; ngOnDestroy(): void; _handleClick(): void; _onKeydown($event: KeyboardEvent): void; _isSortedAscending(): boolean; _isSortedDescending(): boolean; _isSorted(): boolean; _getAriaLabel(): string | null; _getTitle(): string; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } /** * This is a table. * The table supports a `zebra` and a `condensed` mode. */ declare class NxTableComponent { private readonly _cdr; private readonly _expandableTableDirective; /** Change the table mode to condensed */ set condensed(value: BooleanInput); get condensed(): boolean; private _condensed; /** Change the table mode to zebra */ set zebra(value: BooleanInput); get zebra(): boolean; private _zebra; /** * Makes first or last column "sticky". * * Values: `'first' | 'last' | 'both'`. */ set sticky(value: string); get sticky(): string; private _sticky; constructor(_cdr: ChangeDetectorRef, _expandableTableDirective: NxExpandableTableDirective | null); static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } /** * This is a table cell. */ declare class NxTableCellComponent { static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } /** * This is a table row. */ declare class NxTableRowComponent { protected readonly _cdr: ChangeDetectorRef; private readonly _elementRef; /** Whether this table row is selectable */ set selectable(value: BooleanInput); get selectable(): boolean; private _selectable; /** Whether this table row is selected */ set selected(value: BooleanInput); get selected(): boolean; private _selected; readonly select: EventEmitter; /** Whether this row is rendered "sticky". Only works for `nxHeaderCell` cells. */ set mayStick(value: BooleanInput); get mayStick(): boolean; private _mayStick; constructor(_cdr: ChangeDetectorRef, _elementRef: ElementRef); _onSelect($event: KeyboardEvent): void; /** * Checks if the event would trigger an action or if default action is prevented. * Returns `true` if a button, link, input or label are clicked. */ private isSelectionPrevented; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } /** * @docs-private * @deprecated No longer used. * @deletion-target 18.0.0 */ declare function NX_SORT_HEADER_INTL_PROVIDER_FACTORY(parentIntl: NxSortHeaderIntl): NxSortHeaderIntl; /** * @docs-private * @deprecated No longer used. * @deletion-target 18.0.0 */ declare const NX_SORT_HEADER_INTL_PROVIDER: { provide: typeof NxSortHeaderIntl; deps: Optional[][]; useFactory: typeof NX_SORT_HEADER_INTL_PROVIDER_FACTORY; }; declare class NxTableModule { static ɵfac: i0.ɵɵFactoryDeclaration; static ɵmod: i0.ɵɵNgModuleDeclaration; static ɵinj: i0.ɵɵInjectorDeclaration; } export { NX_SORT_HEADER_INTL_PROVIDER, NX_SORT_HEADER_INTL_PROVIDER_FACTORY, NxExpandableTableCellComponent, NxExpandableTableDirective, NxExpandableTableRowComponent, NxHeaderCellDirective, NxHeaderResizeDirective, NxSortDirective, NxSortHeaderComponent, NxSortHeaderIntl, NxTableCellClipDirective, NxTableCellComponent, NxTableComponent, NxTableModule, NxTableRowComponent, NxToggleButtonComponent, SortEvent }; export type { NxExpandable, SortDirection };