UNPKG

@vime/angular

Version:

Angular bindings for the Vime media player.

25 lines (24 loc) 1.27 kB
import { ChangeDetectorRef, ElementRef, EventEmitter, NgZone } from '@angular/core'; import type { JSX, Components } from '@vime/core/dist/types'; export declare type Emitter<T extends ((...args: any[]) => any) | undefined> = EventEmitter<Parameters<Exclude<T, undefined>>[0]>; export declare interface Menu extends Components.VmMenu { } export declare class Menu { protected z: NgZone; protected el: HTMLElement; /** Emitted when the menu is open/active. */ vmOpen: Emitter<JSX.VmMenu["onVmOpen"]>; /** Emitted when the menu has closed/is not active. */ vmClose: Emitter<JSX.VmMenu["onVmClose"]>; /** Emitted when the menu is focused. */ vmFocus: Emitter<JSX.VmMenu["onVmFocus"]>; /** Emitted when the menu loses focus. */ vmBlur: Emitter<JSX.VmMenu["onVmBlur"]>; /** Emitted when the active submenu changes. */ vmActiveSubmenuChange: Emitter<JSX.VmMenu["onVmActiveSubmenuChange"]>; /** Emitted when the currently focused menu item changes. */ vmActiveMenuItemChange: Emitter<JSX.VmMenu["onVmActiveMenuItemChange"]>; /** Emitted when the height of the menu changes. */ vmMenuHeightChange: Emitter<JSX.VmMenu["onVmMenuHeightChange"]>; constructor(c: ChangeDetectorRef, r: ElementRef, z: NgZone); }