Refactoring types
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import { Directive, ViewContainerRef,TemplateRef,OnInit,Input, OnChanges } from '@angular/core';
|
||||
import { layer } from 'ol';
|
||||
import { Layer } from 'ol/layer';
|
||||
import { Source } from 'ol/source';
|
||||
import { MapComponent } from 'ngx-openlayers';
|
||||
|
||||
@Directive({
|
||||
@@ -7,7 +8,7 @@ import { MapComponent } from 'ngx-openlayers';
|
||||
})
|
||||
export class ifZoomToShowDirective implements OnInit {
|
||||
@Input()
|
||||
set fmMapIfZoomToShow(layer:layer) {
|
||||
set fmMapIfZoomToShow(layer:Layer<Source>) {
|
||||
this.layer$=layer;
|
||||
this.checkZoom();
|
||||
}
|
||||
@@ -24,7 +25,7 @@ export class ifZoomToShowDirective implements OnInit {
|
||||
this.checkZoom();
|
||||
}
|
||||
|
||||
private layer$:layer;
|
||||
private layer$:Layer<Source>;
|
||||
private thenTemplate$:TemplateRef<any>;
|
||||
private elseTemplate$:TemplateRef<any>;
|
||||
private showView = false;
|
||||
|
Reference in New Issue
Block a user