Aw5739 Add ngx openlayers
Some checks failed
FarmMaps.Develop/FarmMapsLib/pipeline/head There was a failure building this commit

This commit is contained in:
2023-12-29 11:01:36 +01:00
parent 5cbb6f32f9
commit 8e8f18ad7c
92 changed files with 6555 additions and 2465 deletions

View File

@@ -0,0 +1,42 @@
import { Component, Host, Input, OnInit, forwardRef } from '@angular/core';
import { LoadFunction } from 'ol/Tile';
import { BingMaps } from 'ol/source';
import { LayerTileComponent } from '../layers/layertile.component';
import { SourceComponent } from './source.component';
@Component({
selector: 'aol-source-bingmaps',
template: ` <div class="aol-source-bingmaps"></div> `,
providers: [{ provide: SourceComponent, useExisting: forwardRef(() => SourceBingmapsComponent) }],
})
export class SourceBingmapsComponent extends SourceComponent implements OnInit {
@Input()
cacheSize: number;
@Input()
hidpi: boolean;
@Input()
culture: string;
@Input()
key: string;
@Input()
imagerySet: 'Road' | 'Aerial' | 'AerialWithLabels' | 'collinsBart' | 'ordnanceSurvey' = 'Aerial';
@Input()
maxZoom: number;
@Input()
reprojectionErrorThreshold: number;
@Input()
tileLoadFunction: LoadFunction;
@Input()
wrapX: boolean;
instance: BingMaps;
constructor(@Host() layer: LayerTileComponent) {
super(layer);
}
ngOnInit() {
this.instance = new BingMaps(this);
this.host.instance.setSource(this.instance);
}
}