package
An Angular service to quickly use the HTML5 fullscreen API
npm install angular-bigscreenGitHub-flavored package documentation.
Across all versions.
Download trend unavailable.
Runtime metadata.
Tagged topics.
Estimated unpacked size across 2 packages.
189.0 kB
Includes dependencies.
AngularBigScreen is an Angular service to quickly use the HTML5 fullscreen API.
Install angular-bigscreen node module through npm:
$ npm install angular-bigscreen --saveImport BigScreenModule to your AppModule
import { BigScreenModule } from 'angular-bigscreen';
@NgModule({
imports: [
BigScreenModule
]
})
export class AppModule {
}Import BigScreenService and use it in a component
import { BigScreenService } from 'angular-bigscreen';
@Component({
selector:
For example:
// Request fullscreen
this.bigScreenService.request(this.elementRef.nativeElement);this.bigScreenService.isFullscreen()Returns a boolean. True if fullscreen is being used, else false.
this.bigScreenService.isEnabled()Returns a boolean. Checks if fullscreen is enabled.
this.bigScreenService.request(el: ElementRef)Requests fullscreen on an ElementRef.
this.bigScreenService.exit()Exits from fullscreen.
this.bigScreenService.onChange(callback: any)This is a wrapper for document.fullscreenchange.
this.bigScreenService.onError(callback: any)This is a wrapper for document.fullscreenerror.
this.bigScreenService.getElement()Returns an element. This is a wrapper for document.fullscreenElement.
MIT. Copyright (c) Alex.