AW-6046 Angular improvement
All checks were successful
FarmMaps.Develop/FarmMapsLib/pipeline/head This commit looks good
All checks were successful
FarmMaps.Develop/FarmMapsLib/pipeline/head This commit looks good
This commit is contained in:
@@ -1,10 +1,10 @@
|
||||
import { Component, OnInit, OnChanges, SimpleChanges } from '@angular/core';
|
||||
import {IItemLayer} from '../../models/item.layer';
|
||||
import { Component, OnChanges, OnInit } from '@angular/core';
|
||||
import { Store } from '@ngrx/store';
|
||||
import * as mapReducers from '../../reducers/map.reducer';
|
||||
import * as mapActions from '../../actions/map.actions';
|
||||
import {createEmpty,extend } from 'ol/extent';
|
||||
import { createEmpty, extend } from 'ol/extent';
|
||||
import { Observable } from 'rxjs';
|
||||
import * as mapActions from '../../actions/map.actions';
|
||||
import { IItemLayer } from '../../models/item.layer';
|
||||
import * as mapReducers from '../../reducers/map.reducer';
|
||||
|
||||
@Component({
|
||||
selector: 'fm-map-layer-switcher',
|
||||
@@ -32,11 +32,9 @@ export class LayerSwitcher implements OnInit,OnChanges{
|
||||
this.showLayerSwitcher = this.store.select(mapReducers.selectGetShowLayerSwitcher);
|
||||
}
|
||||
|
||||
ngOnChanges(changes: SimpleChanges) {
|
||||
ngOnChanges() {
|
||||
}
|
||||
|
||||
|
||||
|
||||
handleClick(event:Event) {
|
||||
event.stopPropagation();
|
||||
this.store.dispatch(new mapActions.ShowLayerSwitcher(true));
|
||||
@@ -47,8 +45,6 @@ export class LayerSwitcher implements OnInit,OnChanges{
|
||||
this.store.dispatch(new mapActions.ShowLayerSwitcher(false));
|
||||
}
|
||||
|
||||
|
||||
|
||||
handleOnToggleVisibility(itemLayer: IItemLayer) {
|
||||
this.store.dispatch(new mapActions.SetVisibility(itemLayer,!itemLayer.visible));
|
||||
}
|
||||
|
Reference in New Issue
Block a user