import { AfterContentChecked, EventEmitter, QueryList, TemplateRef } from '@angular/core'; import { FishAccordionConfig } from './accordion-config'; /** * This directive should be used to wrap accordion panel titles that need to contain HTML markup or other directives. */ export declare class FishPanelTitle { templateRef: TemplateRef; constructor(templateRef: TemplateRef); } /** * This directive must be used to wrap accordion panel content. */ export declare class FishPanelContent { templateRef: TemplateRef; constructor(templateRef: TemplateRef); } /** * The FishPanel directive represents an individual panel with the title and collapsible * content */ export declare class FishPanel { /** * A flag determining whether the panel is disabled or not. * When disabled, the panel cannot be toggled. */ disabled: boolean; /** * An optional id for the panel. The id should be unique. * If not provided, it will be auto-generated. */ id: string; /** * The title for the panel. */ title: string; /** * Accordion's types of panels to be applied per panel basis. * Bootstrap 4 recognizes the following types: "success", "info", "warning" and "danger". */ type: string; contentTpl: FishPanelContent; titleTpl: FishPanelTitle; } /** * The payload of the change event fired right before toggling an accordion panel */ export interface FishPanelChangeEvent { /** * Id of the accordion panel that is toggled */ panelId: string; /** * Whether the panel will be opened (true) or closed (false) */ nextState: boolean; /** * Function that will prevent panel toggling if called */ preventDefault: () => void; } /** * The FishAccordion directive is a collection of panels. * It can assure that only one panel can be opened at a time. */ export declare class FishAccordion implements AfterContentChecked { /** * A map that stores each panel state */ private _states; /** * A map that stores references to all panels */ private _panelRefs; panels: QueryList; /** * An array or comma separated strings of panel identifiers that should be opened */ activeIds: string | string[]; /** * Whether the other panels should be closed when a panel is opened */ closeOtherPanels: boolean; /** * Accordion's types of panels to be applied globally. * Bootstrap 4 recognizes the following types: "success", "info", "warning" and "danger". */ type: string; /** * A panel change event fired right before the panel toggle happens. See FishPanelChangeEvent for payload details */ panelChange: EventEmitter; constructor(config: FishAccordionConfig); /** * Programmatically toggle a panel with a given id. */ toggle(panelId: string): void; ngAfterContentChecked(): void; private _closeOthers(panelId); private _updateActiveIds(); private _updateStates(); }