import * as i0 from '@angular/core'; import { ElementRef, OnInit, OnDestroy, NgZone } from '@angular/core'; import { Observable } from 'rxjs'; interface ThyFullscreenConfig { /** * immersive 模式使用了浏览器提供的全屏,整个窗体都全屏,emulated 模式为仿真的,只会在 body 区域全屏,默认 immersive */ mode?: ThyFullscreenMode; /** * 需要全屏的目标元素,可以是选择器,可以是 HTML Element, 也可以是 Angular 的 ElementRef */ target: string | Element | ElementRef; /** * 目标元素已经打开全屏的样式 */ targetLaunchedClass?: string; /** * emulated 模式下的目标元素全屏的容器,默认是 body */ emulatedContainer?: string | Element | ElementRef; } declare enum ThyFullscreenMode { immersive = "immersive", emulated = "emulated" } /** * 全屏组件,将某一区域进行全屏展示,支持组件`thy-fullscreen`和`thyFullscreen`指令两种形式 * @name thy-fullscreen,[thyFullscreen] * @order 10 */ declare class ThyFullscreenComponent implements OnInit, OnDestroy { private elementRef; private service; /** * immersive 模式使用了浏览器提供的全屏,整个窗体都全屏,emulated 模式为仿真的,只会在 body 区域全屏 * @type immersive | emulated */ readonly thyMode: i0.InputSignal; /** * 打开全屏时需要添加的类名 */ readonly thyFullscreenClasses: i0.InputSignal; /** * 全屏之后的回调 */ readonly thyFullscreenChange: i0.OutputEmitterRef; readonly fullscreenLaunch: i0.Signal | undefined>; private ngUnsubscribe$; private fullscreenLaunch$; constructor(); ngOnInit(): void; private handleFullscreen; ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } /** * 全屏指令 * @name thyFullscreenLaunch,[fullscreen-launch] */ declare class ThyFullscreenLaunchDirective { static ɵfac: i0.ɵɵFactoryDeclaration; static ɵdir: i0.ɵɵDirectiveDeclaration; } declare class ThyFullscreenModule { static ɵfac: i0.ɵɵFactoryDeclaration; static ɵmod: i0.ɵɵNgModuleDeclaration; static ɵinj: i0.ɵɵInjectorDeclaration; } declare class ThyFullscreenRef { protected document: Document; private ngZone; fullscreenConfig: ThyFullscreenConfig; private isFullscreen; private ngUnsubscribe$; private readonly _afterLaunched; private readonly _afterExited; constructor(document: Document, ngZone: NgZone); private onFullscreenChange; private resetElement; private isImmersiveFullscreen; private handleKeyDown; private launchNormalFullscreen; private exitNormalFullscreen; protected launchImmersiveFullscreen(): void; protected exitImmersiveFullscreen(): void; launch(): void; exit(): void; afterLaunched(): Observable; afterExited(): Observable; } declare class ThyFullscreen { protected document: Document; private ngZone; private fullscreenRefs; /** * 开始全屏 * @param config */ launch(config: ThyFullscreenConfig): ThyFullscreenRef; /** * 退出最后一个 ThyFullscreenRef 的全屏 * @param config */ exit(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } export { ThyFullscreen, ThyFullscreenComponent, ThyFullscreenLaunchDirective, ThyFullscreenMode, ThyFullscreenModule, ThyFullscreenRef }; export type { ThyFullscreenConfig };