import { CdkScrollable, Overlay, OverlayConfig, ScrollStrategy } from '@angular/cdk/overlay'; import { AfterContentInit, AfterViewInit, EventEmitter, InjectionToken, OnInit, TemplateRef, Type } from '@angular/core'; import { FormControl } from '@angular/forms'; import { KbqPopUp, KbqPopUpPlacementValues, KbqPopUpSizeValues, KbqPopUpTrigger } from '@koobiq/components/core'; import { KbqDropdownTrigger } from '@koobiq/components/dropdown'; import { KbqInput } from '@koobiq/components/input'; import { Subscription } from 'rxjs'; import * as i0 from "@angular/core"; export interface KbqAppSwitcherApp { name: string; id: string | number; type?: string | number; /** Inline SVG markup for the application icon. Use this for SVG icons that should be rendered directly in the DOM. */ icon?: string; /** Path to the icon file (URL or relative path). */ iconSrc?: string; caption?: string; aliases?: KbqAppSwitcherApp[]; link?: string; } export interface KbqAppSwitcherSite { name: string; id: string | number; status?: string; /** Inline SVG markup for the site icon. Use this for SVG icons that should be rendered directly in the DOM. */ icon?: string; /** Path to the icon file (URL or relative path). */ iconSrc?: string; apps: KbqAppSwitcherApp[]; } /** @docs-private */ export declare function defaultGroupBy(app: KbqAppSwitcherApp, groups: Record, untyped: KbqAppSwitcherApp[]): void; export declare const KBQ_MIN_NUMBER_OF_APPS_TO_ENABLE_SEARCH: number; export declare const KBQ_MIN_NUMBER_OF_APPS_TO_ENABLE_GROUPING: number; /** @docs-private */ export declare const KBQ_APP_SWITCHER_SCROLL_STRATEGY: InjectionToken<() => ScrollStrategy>; /** @docs-private */ export declare function kbqAppSwitcherScrollStrategyFactory(overlay: Overlay): () => ScrollStrategy; /** @docs-private */ export declare const KBQ_APP_SWITCHER_SCROLL_STRATEGY_FACTORY_PROVIDER: { provide: InjectionToken<() => ScrollStrategy>; deps: (typeof Overlay)[]; useFactory: typeof kbqAppSwitcherScrollStrategyFactory; }; /** default configuration of app-switcher */ /** @docs-private */ export declare const KBQ_APP_SWITCHER_DEFAULT_CONFIGURATION: { searchPlaceholder: string; searchEmptyResult: string; sitesHeader: string; }; /** Injection Token for providing configuration of app-switcher */ /** @docs-private */ export declare const KBQ_APP_SWITCHER_CONFIGURATION: InjectionToken; /** @docs-private */ export declare class KbqAppSwitcherComponent extends KbqPopUp implements AfterViewInit { /** @docs-private */ protected readonly localeService: import("@koobiq/components/core").KbqLocaleService | null; readonly externalConfiguration: unknown; configuration: any; /** localized data * @docs-private */ get localeData(): any; /** @docs-private */ readonly searchControl: FormControl; /** @docs-private */ filteredSites: KbqAppSwitcherSite[]; /** @docs-private */ prefix: string; /** @docs-private */ trigger: KbqAppSwitcherTrigger; /** @docs-private */ isTrapFocus: boolean; /** @docs-private */ protected activeSite: KbqAppSwitcherSite; /** @docs-private */ protected activeApp: KbqAppSwitcherApp; /** @docs-private */ input: KbqInput; /** @docs-private */ otherSites: KbqDropdownTrigger; constructor(); ngAfterViewInit(): void; /** @docs-private */ updateClassMap(placement: string, customClass: string, size: KbqPopUpSizeValues): void; /** @docs-private */ updateTrapFocus(isTrapFocus: boolean): void; /** @docs-private */ escapeHandler(): void; /** @docs-private */ selectAppInSite(site: KbqAppSwitcherSite, app: KbqAppSwitcherApp): void; private filterSites; private updateLocaleParams; private initDefaultParams; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } export declare class KbqAppSwitcherTrigger extends KbqPopUpTrigger implements AfterContentInit, OnInit { /** @docs-private */ protected scrollStrategy: () => ScrollStrategy; /** @docs-private */ arrow: boolean; /** @docs-private */ customClass: string; /** @docs-private */ private hasBackdrop; /** @docs-private */ private size; /** @docs-private */ content: string | TemplateRef; /** @docs-private */ header: string | TemplateRef; /** @docs-private */ footer: string | TemplateRef; /** @docs-private */ private closeOnScroll; /** Whether search is used or not */ get withSearch(): boolean; /** Number of applications to choose from * @docs-private */ get appsCount(): number; /** Whether the sites are used or not * @docs-private */ get sitesMode(): boolean; /** @docs-private */ get currentApps(): KbqAppSwitcherApp[]; /** Selected application */ selectedApp: KbqAppSwitcherApp; /** Placement of popUp */ placement: KbqPopUpPlacementValues; /** Class that will be used in the background */ backdropClass: string; /** Offset of popUp */ offset: number | null; /** Array of sites */ get sites(): KbqAppSwitcherSite[]; set sites(value: KbqAppSwitcherSite[]); private _parsedSites; /** * @deprecated Will be removed in next major release, use `sites` with one element instead. */ get apps(): KbqAppSwitcherApp[]; set apps(apps: KbqAppSwitcherApp[]); private makeGroupsForApps; private _parsedApps; /** Function to group the apps by type. The first argument is an app object with type. * The second is a groups object and third is an array for untyped apps */ get groupBy(): (app: KbqAppSwitcherApp, groups: Record, untyped: KbqAppSwitcherApp[]) => void; set groupBy(fn: (app: KbqAppSwitcherApp, groups: Record, untyped: KbqAppSwitcherApp[]) => void); private _groupBy; /** Selected site */ get selectedSite(): KbqAppSwitcherSite; set selectedSite(value: KbqAppSwitcherSite); private _parsedSelectedSite; /** Whether the trigger is disabled. */ get disabled(): boolean; set disabled(value: boolean); /** @docs-private */ get hasClickTrigger(): boolean; /** Emits a change event whenever the placement state changes. */ readonly placementChange: EventEmitter; /** Emits a change event whenever the visible state changes. */ readonly visibleChange: EventEmitter; /** @docs-private */ readonly selectedSiteChange: EventEmitter; /** @docs-private */ readonly selectedAppChange: EventEmitter; /** @docs-private */ trigger: string; /** @docs-private */ originalSites: KbqAppSwitcherSite[]; /** @docs-private */ originalApps: KbqAppSwitcherApp[]; /** @docs-private */ protected originSelector: string; /** @docs-private */ protected get overlayConfig(): OverlayConfig; /** @docs-private */ protected preventClosingByInnerScrollSubscription: Subscription; ngOnInit(): void; ngAfterContentInit(): void; /** @docs-private */ updateData(): void; /** Updates the current position. * @docs-private */ updatePosition(reapplyPosition?: boolean): void; /** @docs-private */ getOverlayHandleComponentType(): Type; /** @docs-private */ updateClassMap(newPlacement?: string): void; /** @docs-private */ closingActions(): import("rxjs").Observable; private hideIfNotInViewPort; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵdir: i0.ɵɵDirectiveDeclaration; static ngAcceptInputType_offset: unknown; static ngAcceptInputType_disabled: unknown; }