Refactoring for landingpage support
All checks were successful
FarmMaps.Develop/FarmMapsLib/pipeline/head This commit looks good

This commit is contained in:
Willem Dantuma
2020-10-29 19:14:06 +01:00
parent a5ece9b453
commit 46c5f74b49
8 changed files with 145 additions and 86 deletions

View File

@@ -34,7 +34,7 @@ export class ItemVectorSourceComponent extends SourceVectorComponent implements
@Input() selectedFeature: Feature;
@Input() selectedItem: IItem;
@Input() styles:IStyles;
@Output() onFeaturesSelected: EventEmitter<Feature> = new EventEmitter<Feature>();
@Output() onFeatureSelected: EventEmitter<Feature> = new EventEmitter<Feature>();
@Output() onFeatureHover: EventEmitter<Feature> = new EventEmitter<Feature>();
private stylesCache:IStyles = {};
@@ -96,9 +96,9 @@ export class ItemVectorSourceComponent extends SourceVectorComponent implements
this.map.instance.addInteraction(this._hoverSelect);
this._select.on('select', (e) => {
if (e.selected.length > 0 && e.selected[0]) {
this.onFeaturesSelected.emit(e.selected[0]);
this.onFeatureSelected.emit(e.selected[0]);
} else {
this.onFeaturesSelected.emit(null);
this.onFeatureSelected.emit(null);
}
});
this._hoverSelect.on('select', (e) => {