import { AfterViewInit, ElementRef, EventEmitter, OnDestroy, OnInit, Renderer2 } from '@angular/core'; import { Layout } from '../common/layout'; import { DropdownService } from './dropdown.service'; import { Dropdown } from './models'; import * as i0 from "@angular/core"; /** * * @smeDoc {@label Dropdown @id sme-dropdown-component @internal} * * @overview * @file {@filepath ./examples/dropdown-overview.md} * * @example {@label Basic Usage @id basic-usage} * @file {@filename component.html @filepath ./examples/basic-usage.component.html} * * @example {@label Dropdown with advanced content @id advanced-dropdown} * @file {@filename component.html @filepath ./examples/advanced-dropdown.component.html} * @file {@filename component.ts @filepath ./examples/advanced-dropdown.component.ts} * */ /** * Component to create an dropdown */ export declare class DropdownComponent implements OnDestroy, OnInit, Dropdown, AfterViewInit { private renderer; private element; private dropdownService; private layout; private layoutChangeSubscriber; /** * Event Emitter for when the dropdown opens or closes. Emits a boolean to indicate if the dropdown is open * @deprecated since 9/25/2019. Please use 'toggled' instead */ get onToggled(): EventEmitter; toggled: EventEmitter; /** * It indicates should automatically toggle to dropdown when the toggle element is clicked. Defaults to true */ autoToggle: boolean; /** * It indicates whether to set the dropdown content width to be based on the actual content */ autoWidth: boolean; /** * It determine whether to calculate height for the dropdown */ calculateHeight: boolean; /** * It determines whether to display dropdown menu to side of toggle. Defaults to below */ displayToSide: boolean; isContextMenu: boolean; /** * The content element. This must be provided by the DropdownContentDirective or possibly some custom implementation */ contentElement: ElementRef; /** * The toggle element. This must be provided by the DropdownToggleDirective or possibly some custom implementation */ toggleElement: ElementRef; /** * Determine if the dropdown will use the sme-form-field to limit its max-width */ dropdownApplyFormFieldOffsetWidth: boolean; /** * Indicates the open state of the dropdown */ isOpen: boolean; /** * Indicates how far the dropdown content has been translated to remain fully on screen */ left: number; /** * Indicates how far the dropdown content has been translated to remain fully on screen */ top: number; /** * Indicates if the dropdown is larger than the horizontal space available */ overflowX: boolean; /** * Indicates if the dropdown is larger than the vertical space available */ overflowY: boolean; /** * Indicates that dropdown should be disabled. */ disabled: boolean; private unsubscribeToggleClick; /** * Initializes a new instance of the DropdownDirective */ constructor(renderer: Renderer2, element: ElementRef, dropdownService: DropdownService, layout: Layout); /** * Angulars On Init Lifecycle Hook */ ngOnInit(): void; ngAfterViewInit(): void; /** * Angulars On Destroy Lifecycle Hook */ ngOnDestroy(): void; /** * Opens this dropdown */ open(): void; /** * Listen to keyboard event and close dropdown when users do not focus on dropdown list */ onKeyup(event: KeyboardEvent): void; /** * Closes this dropdown * @param event keyboard event including the current event target */ close(event?: KeyboardEvent): void; /** * Toggles the dropdown * @param open Optional. If provided, forces the dropdown open or closed. */ toggle(open?: boolean, calculateHeight?: boolean, displayToSide?: boolean, event?: KeyboardEvent): void; /** * Handler for the click event for the toggle element * @param event the mouse event of the click * @param manualToggle determine whether this is manually toggle */ onToggleClick(event: any, manualToggle?: boolean): boolean; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; }