import type { IPictureInPictureApi, PictureInPictureSettings } from '../../../types';
import { PictureInPictureType } from '../../../types';
import { ValueSubject } from '@vkontakte/videoplayer-shared';
declare const PICTURE_IN_PICTURE_EVENTS: readonly ["enterpictureinpicture", "leavepictureinpicture", "resize"];
type PictureInPictureEvents = typeof PICTURE_IN_PICTURE_EVENTS[number];
type PictureInPictureEventHandlers = {
    [key in PictureInPictureEvents]: (event: Event) => void;
};
export declare class PictureInPictureApi implements IPictureInPictureApi {
    private isRequested;
    private videoElement;
    private playerContainer;
    private playerDummyElement;
    private svelteContext;
    private externalEventHandlers;
    private readonly eventHandlers;
    info: {
        isActive$: ValueSubject<boolean>;
        isEnabled$: ValueSubject<boolean>;
        type: PictureInPictureType;
    };
    constructor({ enabled }?: PictureInPictureSettings);
    /**
     * Флаг показывает, есть ли в целом возможность использовать pip в данном браузере, поддерживается ли это.
     */
    isSupported(): boolean;
    /**
     * Флаг показывает, находится ли пользователь в режиме pip.
     */
    isActive(): boolean;
    setContext(svelteContext: Map<unknown, unknown>): void;
    revealPictureInPicture(): Promise<void>;
    request(): Promise<void>;
    remove(): Promise<void>;
    assignPlayerContainer(playerContainer: HTMLElement): void;
    updateVideoElement(): void;
    registryEventHandlers(): void;
    registryExternalEventHandlers(externalEventHandlers: Partial<PictureInPictureEventHandlers>): void;
    unregistryEventHandlers(): void;
    dispose(): Promise<void>;
    private onEnterPictureInPicture;
    private onLeavePictureInPicture;
    private onResize;
    /**
     * Флаг определяет может ли пользователь переходить в pip на уровне бизнес логике.
     */
    setEnabled(enabled: boolean): void;
}
export declare function isInstanceOfPictureInPictureApi(pictureInPictureApi?: IPictureInPictureApi): pictureInPictureApi is PictureInPictureApi;
export {};
