/** * @license * Copyright Akveo. All Rights Reserved. * Licensed under the MIT License. See License.txt in the project root for license information. */ import { Component } from '@angular/core'; import { NbMediaBreakpointsService, NbThemeService } from '../../framework/theme'; @Component({ selector: 'nb-breakpoint-test', template: ` Akveo Breakpoint

Resize the window to the next/prev breakpoint to see the change

Prev breakpoint : {{ change[0]?.name }} ({{ change[0]?.width }})
Current breakpoint : {{ change[1]?.name }} ({{ change[1]?.width }})
© Akveo 2017
`, }) export class NbThemeBreakpointTestComponent { change: any = []; constructor(private themeService: NbThemeService) { this.themeService.onMediaQueryChange() .subscribe((change: any) => { this.change = change; }); } }