fixed lint errors

This commit is contained in:
William Welling
2017-07-13 11:19:02 -05:00
parent 75cb60e70f
commit 066bba28af
123 changed files with 1295 additions and 1407 deletions

View File

@@ -1,10 +1,11 @@
import { HostWindowState } from "./host-window.reducer";
import { Injectable } from "@angular/core";
import { Store } from "@ngrx/store";
import { Observable } from "rxjs/Observable";
import { hasValue } from "./empty.util";
import { HostWindowState } from './host-window.reducer';
import { Injectable } from '@angular/core';
import { Store } from '@ngrx/store';
import { Observable } from 'rxjs/Observable';
//TODO ideally we should get these from sass somehow
import { hasValue } from './empty.util';
// TODO: ideally we should get these from sass somehow
export enum GridBreakpoint {
XS = 0,
SM = 576,
@@ -23,36 +24,36 @@ export class HostWindowService {
private getWidthObs(): Observable<number> {
return this.store.select<number>('hostWindow', 'width')
.filter(width => hasValue(width));
.filter((width) => hasValue(width));
}
isXs(): Observable<boolean> {
return this.getWidthObs()
.map(width => width < GridBreakpoint.SM)
.map((width) => width < GridBreakpoint.SM)
.distinctUntilChanged();
}
isSm(): Observable<boolean> {
return this.getWidthObs()
.map(width => width >= GridBreakpoint.SM && width < GridBreakpoint.MD)
.map((width) => width >= GridBreakpoint.SM && width < GridBreakpoint.MD)
.distinctUntilChanged();
}
isMd(): Observable<boolean> {
return this.getWidthObs()
.map(width => width >= GridBreakpoint.MD && width < GridBreakpoint.LG)
.map((width) => width >= GridBreakpoint.MD && width < GridBreakpoint.LG)
.distinctUntilChanged();
}
isLg(): Observable<boolean> {
return this.getWidthObs()
.map(width => width >= GridBreakpoint.LG && width < GridBreakpoint.XL)
.map((width) => width >= GridBreakpoint.LG && width < GridBreakpoint.XL)
.distinctUntilChanged();
}
isXl(): Observable<boolean> {
return this.getWidthObs()
.map(width => width >= GridBreakpoint.XL)
.map((width) => width >= GridBreakpoint.XL)
.distinctUntilChanged();
}
}