From b7b6c00f3927b8d937c30c1f4c250e8fba67249d Mon Sep 17 00:00:00 2001 From: Camille Moinier Date: Fri, 26 Apr 2024 08:31:25 +0200 Subject: [PATCH] feat(dh): add ogc api links as options in preview section --- .../record/src/lib/map-view/map-view.component.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/libs/feature/record/src/lib/map-view/map-view.component.ts b/libs/feature/record/src/lib/map-view/map-view.component.ts index 5cc2a7f295..6dad2b6382 100644 --- a/libs/feature/record/src/lib/map-view/map-view.component.ts +++ b/libs/feature/record/src/lib/map-view/map-view.component.ts @@ -205,6 +205,16 @@ export class MapViewComponent implements OnInit, OnDestroy { data, })) ) + } else if ( + link.type === 'service' && + link.accessServiceProtocol === 'ogcFeatures' + ) { + return this.dataService.readAsGeoJson(link).pipe( + map((data) => ({ + type: MapContextLayerTypeEnum.GEOJSON, + data, + })) + ) } return throwError(() => 'protocol not supported') }