@igo2/integration 1.10.0 → 1.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/igo2-integration.umd.js +1297 -608
- package/bundles/igo2-integration.umd.js.map +1 -1
- package/esm2015/lib/about/about-tool/about-tool.component.js +3 -3
- package/esm2015/lib/about/about-tool/index.js +1 -1
- package/esm2015/lib/about/about.module.js +1 -1
- package/esm2015/lib/about/index.js +1 -1
- package/esm2015/lib/analytics/analytics-listener.service.js +1 -1
- package/esm2015/lib/analytics/analytics.module.js +1 -1
- package/esm2015/lib/analytics/index.js +1 -1
- package/esm2015/lib/catalog/catalog-browser-tool/catalog-browser-tool.component.js +1 -1
- package/esm2015/lib/catalog/catalog-browser-tool/catalog-browser-tool.module.js +1 -1
- package/esm2015/lib/catalog/catalog-library-tool/catalog-library-tool.component.js +1 -1
- package/esm2015/lib/catalog/catalog-library-tool/catalog-library-tool.module.js +1 -1
- package/esm2015/lib/catalog/catalog.module.js +1 -1
- package/esm2015/lib/catalog/catalog.state.js +1 -1
- package/esm2015/lib/catalog/index.js +1 -1
- package/esm2015/lib/context/context-editor-tool/context-editor-tool.component.js +1 -1
- package/esm2015/lib/context/context-manager-tool/context-manager-tool.component.js +1 -1
- package/esm2015/lib/context/context-permission-manager-tool/context-permission-manager-tool.component.js +1 -1
- package/esm2015/lib/context/context-share-tool/context-share-tool.component.js +1 -1
- package/esm2015/lib/context/context.module.js +1 -1
- package/esm2015/lib/context/context.state.js +1 -1
- package/esm2015/lib/context/index.js +1 -1
- package/esm2015/lib/directions/directions-tool/directions-tool.component.js +17 -8
- package/esm2015/lib/directions/directions-tool/index.js +1 -1
- package/esm2015/lib/directions/directions.module.js +1 -1
- package/esm2015/lib/directions/directions.state.js +1 -1
- package/esm2015/lib/directions/index.js +1 -1
- package/esm2015/lib/draw/draw.module.js +1 -1
- package/esm2015/lib/draw/draw.state.js +1 -1
- package/esm2015/lib/draw/drawing-tool/drawing-tool.component.js +1 -1
- package/esm2015/lib/draw/index.js +1 -1
- package/esm2015/lib/filter/active-ogc-filter-tool/active-ogc-filter-tool.animation.js +1 -1
- package/esm2015/lib/filter/active-ogc-filter-tool/active-ogc-filter-tool.component.js +1 -1
- package/esm2015/lib/filter/active-ogc-filter-tool/index.js +1 -1
- package/esm2015/lib/filter/active-time-filter-tool/active-time-filter-tool.animation.js +1 -1
- package/esm2015/lib/filter/active-time-filter-tool/active-time-filter-tool.component.js +1 -1
- package/esm2015/lib/filter/active-time-filter-tool/index.js +1 -1
- package/esm2015/lib/filter/filter.module.js +1 -1
- package/esm2015/lib/filter/index.js +1 -1
- package/esm2015/lib/filter/ogc-filter-tool/index.js +1 -1
- package/esm2015/lib/filter/ogc-filter-tool/ogc-filter-tool.component.js +1 -1
- package/esm2015/lib/filter/spatial-filter-tool/index.js +1 -1
- package/esm2015/lib/filter/spatial-filter-tool/spatial-filter-tool.component.js +4 -1
- package/esm2015/lib/filter/time-filter-tool/index.js +1 -1
- package/esm2015/lib/filter/time-filter-tool/time-filter-tool.component.js +1 -1
- package/esm2015/lib/import-export/import-export-tool/import-export-tool.component.js +1 -1
- package/esm2015/lib/import-export/import-export-tool/index.js +1 -1
- package/esm2015/lib/import-export/import-export.module.js +1 -1
- package/esm2015/lib/import-export/import-export.state.js +1 -1
- package/esm2015/lib/import-export/index.js +1 -1
- package/esm2015/lib/integration.module.js +1 -1
- package/esm2015/lib/map/advanced-map-tool/advanced-coordinates/advanced-coordinates.component.js +1 -1
- package/esm2015/lib/map/advanced-map-tool/advanced-map-tool.component.js +60 -11
- package/esm2015/lib/map/advanced-map-tool/advanced-swipe/advanced-swipe.component.js +1 -1
- package/esm2015/lib/map/advanced-map-tool/index.js +1 -1
- package/esm2015/lib/map/index.js +3 -1
- package/esm2015/lib/map/layer-list-tool.state.js +1 -1
- package/esm2015/lib/map/map-details-tool/index.js +1 -1
- package/esm2015/lib/map/map-details-tool/map-details-tool.component.js +1 -1
- package/esm2015/lib/map/map-legend/index.js +1 -1
- package/esm2015/lib/map/map-legend/map-legend-tool.component.js +1 -1
- package/esm2015/lib/map/map-proximity-tool/index.js +2 -0
- package/esm2015/lib/map/map-proximity-tool/map-proximity-tool.component.js +221 -0
- package/esm2015/lib/map/map-proximity.state.js +164 -0
- package/esm2015/lib/map/map-tool/index.js +1 -1
- package/esm2015/lib/map/map-tool/map-tool.component.js +1 -1
- package/esm2015/lib/map/map-tools/index.js +1 -1
- package/esm2015/lib/map/map-tools/map-tools.component.js +2 -2
- package/esm2015/lib/map/map.module.js +18 -8
- package/esm2015/lib/map/map.state.js +8 -6
- package/esm2015/lib/measure/index.js +1 -1
- package/esm2015/lib/measure/measure.module.js +1 -1
- package/esm2015/lib/measure/measure.state.js +1 -1
- package/esm2015/lib/measure/measurer-tool/measurer-tool.component.js +1 -1
- package/esm2015/lib/measure/measurer-tool/measurer-tool.module.js +1 -1
- package/esm2015/lib/print/index.js +1 -1
- package/esm2015/lib/print/print-tool/index.js +1 -1
- package/esm2015/lib/print/print-tool/print-tool.component.js +1 -1
- package/esm2015/lib/print/print.module.js +1 -1
- package/esm2015/lib/search/index.js +1 -1
- package/esm2015/lib/search/query.state.js +1 -1
- package/esm2015/lib/search/search-bar/search-bar-binding.directive.js +1 -1
- package/esm2015/lib/search/search-bar/search-bar.module.js +1 -1
- package/esm2015/lib/search/search-results-tool/search-results-tool.component.js +52 -28
- package/esm2015/lib/search/search-results-tool/search-results-tool.module.js +1 -1
- package/esm2015/lib/search/search.module.js +1 -1
- package/esm2015/lib/search/search.state.js +1 -1
- package/esm2015/lib/storage/index.js +1 -1
- package/esm2015/lib/storage/storage.module.js +1 -1
- package/esm2015/lib/storage/storage.state.js +1 -1
- package/esm2015/lib/tool/index.js +1 -1
- package/esm2015/lib/tool/tool.module.js +1 -1
- package/esm2015/lib/tool/tool.state.js +1 -1
- package/esm2015/lib/workspace/index.js +1 -1
- package/esm2015/lib/workspace/shared/edition-actions.service.js +157 -0
- package/esm2015/lib/workspace/shared/feature-actions.service.js +1 -1
- package/esm2015/lib/workspace/shared/index.js +1 -1
- package/esm2015/lib/workspace/shared/wfs-actions.service.js +2 -2
- package/esm2015/lib/workspace/shared/workspace.utils.js +1 -1
- package/esm2015/lib/workspace/workspace-button/index.js +1 -1
- package/esm2015/lib/workspace/workspace-button/workspace-button.component.js +1 -1
- package/esm2015/lib/workspace/workspace.module.js +1 -1
- package/esm2015/lib/workspace/workspace.state.js +41 -7
- package/esm2015/public_api.js +1 -1
- package/fesm2015/igo2-integration.js +843 -217
- package/fesm2015/igo2-integration.js.map +1 -1
- package/lib/directions/directions-tool/directions-tool.component.d.ts +6 -1
- package/lib/map/advanced-map-tool/advanced-map-tool.component.d.ts +7 -0
- package/lib/map/index.d.ts +2 -0
- package/lib/map/map-proximity-tool/index.d.ts +1 -0
- package/lib/map/map-proximity-tool/map-proximity-tool.component.d.ts +36 -0
- package/lib/map/map-proximity.state.d.ts +28 -0
- package/lib/map/map.module.d.ts +30 -28
- package/lib/map/map.state.d.ts +4 -1
- package/lib/search/search-results-tool/search-results-tool.component.d.ts +7 -1
- package/lib/workspace/shared/edition-actions.service.d.ts +26 -0
- package/lib/workspace/shared/workspace.utils.d.ts +2 -2
- package/lib/workspace/workspace.state.d.ts +8 -3
- package/ngcc.config.js +3 -3
- package/package.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"igo2-integration.js","sources":["../../../packages/integration/src/lib/analytics/analytics.module.ts","../../../packages/integration/src/lib/import-export/import-export.state.ts","../../../packages/integration/src/lib/tool/tool.state.ts","../../../packages/integration/src/lib/context/context-editor-tool/context-editor-tool.component.ts","../../../packages/integration/src/lib/context/context-editor-tool/context-editor-tool.component.html","../../../packages/integration/src/lib/map/map.state.ts","../../../packages/integration/src/lib/context/context-manager-tool/context-manager-tool.component.ts","../../../packages/integration/src/lib/context/context-manager-tool/context-manager-tool.component.html","../../../packages/integration/src/lib/context/context-permission-manager-tool/context-permission-manager-tool.component.ts","../../../packages/integration/src/lib/context/context-permission-manager-tool/context-permission-manager-tool.component.html","../../../packages/integration/src/lib/map/layer-list-tool.state.ts","../../../packages/integration/src/lib/context/context-share-tool/context-share-tool.component.ts","../../../packages/integration/src/lib/context/context-share-tool/context-share-tool.component.html","../../../packages/integration/src/lib/context/context.module.ts","../../../packages/integration/src/lib/catalog/catalog.state.ts","../../../packages/integration/src/lib/catalog/catalog-library-tool/catalog-library-tool.component.ts","../../../packages/integration/src/lib/catalog/catalog-library-tool/catalog-library-tool.component.html","../../../packages/integration/src/lib/catalog/catalog-library-tool/catalog-library-tool.module.ts","../../../packages/integration/src/lib/catalog/catalog-browser-tool/catalog-browser-tool.component.html","../../../packages/integration/src/lib/catalog/catalog-browser-tool/catalog-browser-tool.component.ts","../../../packages/integration/src/lib/catalog/catalog-browser-tool/catalog-browser-tool.module.ts","../../../packages/integration/src/lib/catalog/catalog.module.ts","../../../packages/integration/src/lib/directions/directions.state.ts","../../../packages/integration/src/lib/directions/directions-tool/directions-tool.component.ts","../../../packages/integration/src/lib/directions/directions-tool/directions-tool.component.html","../../../packages/integration/src/lib/directions/directions.module.ts","../../../packages/integration/src/lib/draw/draw.state.ts","../../../packages/integration/src/lib/draw/drawing-tool/drawing-tool.component.ts","../../../packages/integration/src/lib/draw/drawing-tool/drawing-tool.component.html","../../../packages/integration/src/lib/draw/draw.module.ts","../../../packages/integration/src/lib/workspace/shared/workspace.utils.ts","../../../packages/integration/src/lib/storage/storage.state.ts","../../../packages/integration/src/lib/workspace/shared/feature-actions.service.ts","../../../packages/integration/src/lib/workspace/shared/wfs-actions.service.ts","../../../packages/integration/src/lib/workspace/workspace.state.ts","../../../packages/integration/src/lib/workspace/workspace-button/workspace-button.component.html","../../../packages/integration/src/lib/workspace/workspace-button/workspace-button.component.ts","../../../packages/integration/src/lib/workspace/workspace.module.ts","../../../packages/integration/src/lib/import-export/import-export-tool/import-export-tool.component.html","../../../packages/integration/src/lib/import-export/import-export-tool/import-export-tool.component.ts","../../../packages/integration/src/lib/import-export/import-export.module.ts","../../../packages/integration/src/lib/map/map-details-tool/map-details-tool.component.html","../../../packages/integration/src/lib/map/map-details-tool/map-details-tool.component.ts","../../../packages/integration/src/lib/map/map-tool/map-tool.component.html","../../../packages/integration/src/lib/map/map-tool/map-tool.component.ts","../../../packages/integration/src/lib/map/map-tools/map-tools.component.html","../../../packages/integration/src/lib/map/map-tools/map-tools.component.ts","../../../packages/integration/src/lib/map/map-legend/map-legend-tool.component.html","../../../packages/integration/src/lib/map/map-legend/map-legend-tool.component.ts","../../../packages/integration/src/lib/map/advanced-map-tool/advanced-swipe/advanced-swipe.component.html","../../../packages/integration/src/lib/map/advanced-map-tool/advanced-swipe/advanced-swipe.component.ts","../../../packages/integration/src/lib/map/advanced-map-tool/advanced-coordinates/advanced-coordinates.component.html","../../../packages/integration/src/lib/map/advanced-map-tool/advanced-coordinates/advanced-coordinates.component.ts","../../../packages/integration/src/lib/map/advanced-map-tool/advanced-map-tool.component.ts","../../../packages/integration/src/lib/map/advanced-map-tool/advanced-map-tool.component.html","../../../packages/integration/src/lib/map/map.module.ts","../../../packages/integration/src/lib/measure/measure.state.ts","../../../packages/integration/src/lib/measure/measurer-tool/measurer-tool.component.ts","../../../packages/integration/src/lib/measure/measurer-tool/measurer-tool.component.html","../../../packages/integration/src/lib/measure/measurer-tool/measurer-tool.module.ts","../../../packages/integration/src/lib/measure/measure.module.ts","../../../packages/integration/src/lib/print/print-tool/print-tool.component.ts","../../../packages/integration/src/lib/print/print-tool/print-tool.component.html","../../../packages/integration/src/lib/print/print.module.ts","../../../packages/integration/src/lib/search/search.state.ts","../../../packages/integration/src/lib/search/search-bar/search-bar-binding.directive.ts","../../../packages/integration/src/lib/search/search-bar/search-bar.module.ts","../../../packages/integration/src/lib/search/search-results-tool/search-results-tool.component.html","../../../packages/integration/src/lib/search/search-results-tool/search-results-tool.component.ts","../../../packages/integration/src/lib/search/search-results-tool/search-results-tool.module.ts","../../../packages/integration/src/lib/search/search.module.ts","../../../packages/integration/src/lib/filter/ogc-filter-tool/ogc-filter-tool.component.ts","../../../packages/integration/src/lib/filter/ogc-filter-tool/ogc-filter-tool.component.html","../../../packages/integration/src/lib/filter/time-filter-tool/time-filter-tool.component.ts","../../../packages/integration/src/lib/filter/time-filter-tool/time-filter-tool.component.html","../../../packages/integration/src/lib/filter/spatial-filter-tool/spatial-filter-tool.component.html","../../../packages/integration/src/lib/filter/spatial-filter-tool/spatial-filter-tool.component.ts","../../../packages/integration/src/lib/filter/active-time-filter-tool/active-time-filter-tool.animation.ts","../../../packages/integration/src/lib/filter/active-time-filter-tool/active-time-filter-tool.component.ts","../../../packages/integration/src/lib/filter/active-time-filter-tool/active-time-filter-tool.component.html","../../../packages/integration/src/lib/filter/active-ogc-filter-tool/active-ogc-filter-tool.animation.ts","../../../packages/integration/src/lib/filter/active-ogc-filter-tool/active-ogc-filter-tool.component.ts","../../../packages/integration/src/lib/filter/active-ogc-filter-tool/active-ogc-filter-tool.component.html","../../../packages/integration/src/lib/filter/filter.module.ts","../../../packages/integration/src/lib/about/about-tool/about-tool.component.html","../../../packages/integration/src/lib/about/about-tool/about-tool.component.ts","../../../packages/integration/src/lib/about/about.module.ts","../../../packages/integration/src/lib/storage/storage.module.ts","../../../packages/integration/src/lib/integration.module.ts","../../../packages/integration/src/lib/tool/tool.module.ts","../../../packages/integration/src/lib/context/context.state.ts","../../../packages/integration/src/lib/analytics/analytics-listener.service.ts","../../../packages/integration/src/lib/search/query.state.ts","../../../packages/integration/src/public_api.ts","../../../packages/integration/src/igo2-integration.ts"],"sourcesContent":["import { NgModule } from '@angular/core';\n\n@NgModule({\n imports: [],\n declarations: [],\n exports: []\n})\nexport class IgoAppAnalyticsModule {}\n","import { Injectable } from '@angular/core';\n\nimport { BehaviorSubject } from 'rxjs';\nimport { ExportOptions } from '@igo2/geo';\n\nexport enum ImportExportType {\n layer = 'layer',\n context = 'context'\n}\n\nexport enum ImportExportMode {\n import = 'import',\n export = 'export'\n}\n\n/**\n * Service that holds the state of the importExport module\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ImportExportState {\n\n readonly importExportType$: BehaviorSubject<ImportExportType> = new BehaviorSubject(ImportExportType.layer);\n readonly selectedMode$: BehaviorSubject<ImportExportMode> = new BehaviorSubject(ImportExportMode.import);\n readonly exportOptions$: BehaviorSubject<ExportOptions> = new BehaviorSubject(undefined);\n\n setImportExportType(type: ImportExportType) {\n this.importExportType$.next(type);\n }\n\n setMode(mode: ImportExportMode) {\n this.selectedMode$.next(mode);\n }\n\n setsExportOptions(exportOptions: ExportOptions) {\n this.exportOptions$.next(exportOptions);\n }\n\n}\n","import { Injectable } from '@angular/core';\n\nimport { Toolbox, ToolService } from '@igo2/common';\n\nimport { ExportOptions } from '@igo2/geo';\nimport { BehaviorSubject } from 'rxjs';\nimport { ImportExportMode, ImportExportState } from '../import-export/import-export.state';\n\n/**\n * Service that holds the state of the search module\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ToolState {\n get toolbox(): Toolbox {\n return this.toolService.toolbox;\n }\n\n public openSidenav$: BehaviorSubject<boolean> = new BehaviorSubject(undefined);\n\n constructor(\n private toolService: ToolService,\n private importExportState: ImportExportState\n ) {}\n\n toolToActivateFromOptions(toolToActivate: { tool: string; options: {[key: string]: any} }) {\n if (!toolToActivate) { return; }\n if (toolToActivate.tool === 'importExport') {\n let exportOptions: ExportOptions = this.importExportState.exportOptions$.value;\n if (!exportOptions) {\n exportOptions = {\n layers: toolToActivate.options.layers,\n featureInMapExtent: toolToActivate.options.featureInMapExtent\n };\n } else {\n exportOptions.layers = toolToActivate.options.layers;\n exportOptions.featureInMapExtent = toolToActivate.options.featureInMapExtent;\n }\n this.importExportState.setsExportOptions(exportOptions);\n this.importExportState.setMode(ImportExportMode.export);\n }\n\n if (this.toolbox.getTool(toolToActivate.tool)) {\n this.toolbox.activateTool(toolToActivate.tool);\n this.openSidenav$.next(true);\n }\n }\n}\n","import { Component } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\nimport { ToolState } from '../../tool/tool.state';\n\n@ToolComponent({\n name: 'contextEditor',\n title: 'igo.integration.tools.contexts',\n icon: 'star',\n parent: 'contextManager'\n})\n@Component({\n selector: 'igo-context-editor-tool',\n templateUrl: './context-editor-tool.component.html'\n})\nexport class ContextEditorToolComponent {\n\n constructor(private toolState: ToolState) {}\n\n submitSuccessed() {\n this.toolState.toolbox.activatePreviousTool();\n }\n}\n","<igo-context-edit\n igoContextEditBinding\n (submitSuccessed)=\"submitSuccessed()\"\n></igo-context-edit>\n","import { Injectable } from '@angular/core';\n\nimport { IgoMap, MapService, ProjectionService } from '@igo2/geo';\n// import { BehaviorSubject } from 'rxjs';\n\n/**\n * Service that holds the state of the map module\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class MapState {\n\n // public mapCenter$ = new BehaviorSubject<boolean>(false);\n get showAllLegendsValue(): boolean {\n return this._legendToolShowAll;\n }\n\n set showAllLegendsValue(value) {\n this._legendToolShowAll = value;\n }\n private _legendToolShowAll: boolean;\n\n /**\n * Active map\n */\n get map(): IgoMap { return this._map; }\n private _map: IgoMap;\n\n constructor(\n private mapService: MapService,\n private projectionService: ProjectionService // Don't remove this or it'll never be injected\n ) {\n this._map = new IgoMap({\n controls: {\n scaleLine: true,\n attribution: {\n collapsed: true\n }\n }\n });\n\n this.mapService.setMap(this.map);\n }\n}\n","import { Component, Input } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\n\nimport { ToolState } from '../../tool/tool.state';\nimport { MapState } from '../../map/map.state';\nimport { IgoMap } from '@igo2/geo';\n\n@ToolComponent({\n name: 'contextManager',\n title: 'igo.integration.tools.contexts',\n icon: 'star'\n})\n@Component({\n selector: 'igo-context-manager-tool',\n templateUrl: './context-manager-tool.component.html'\n})\nexport class ContextManagerToolComponent {\n\n @Input() toolToOpenOnContextChange: string = 'mapTools';\n\n get map(): IgoMap { return this.mapState.map; }\n\n constructor(private toolState: ToolState, private mapState: MapState) {}\n\n editContext() {\n this.toolState.toolbox.activateTool('contextEditor');\n }\n\n managePermissions() {\n this.toolState.toolbox.activateTool('contextPermissionManager');\n }\n}\n","<igo-context-list\n igoContextListBinding\n [map]=\"map\"\n (edit)=\"editContext()\"\n (managePermissions)=\"managePermissions()\">\n</igo-context-list>\n","import { Component } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\n\n@ToolComponent({\n name: 'contextPermissionManager',\n title: 'igo.integration.tools.contexts',\n icon: 'star',\n parent: 'contextManager'\n})\n@Component({\n selector: 'igo-context-permission-manager-tool',\n templateUrl: './context-permission-manager-tool.component.html'\n})\nexport class ContextPermissionManagerToolComponent {}\n","<igo-context-permissions igoContextPermissionsBinding></igo-context-permissions>\n","import { Injectable } from '@angular/core';\nimport { BehaviorSubject } from 'rxjs';\nimport { LayerListControlsOptions } from '@igo2/geo';\n\n/**\n * Service that holds the state of layer list tool values\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class LayerListToolState {\n\n readonly keyword$: BehaviorSubject<string> = new BehaviorSubject('');\n readonly sortAlpha$: BehaviorSubject<boolean> = new BehaviorSubject(undefined);\n readonly onlyVisible$: BehaviorSubject<boolean> = new BehaviorSubject(undefined);\n readonly selectedTab$: BehaviorSubject<number> = new BehaviorSubject(undefined);\n\n setKeyword(keyword: string) {\n this.keyword$.next(keyword);\n }\n\n setSortAlpha(sort: boolean) {\n this.sortAlpha$.next(sort);\n }\n\n setOnlyVisible(onlyVisible: boolean) {\n this.onlyVisible$.next(onlyVisible);\n }\n\n setSelectedTab(tab: number) {\n this.selectedTab$.next(tab);\n }\n\n getLayerListControls(): LayerListControlsOptions {\n return {\n keyword: this.keyword$.value,\n onlyVisible: this.onlyVisible$.value,\n sortAlpha: this.sortAlpha$.value\n };\n }\n}\n","import { Component } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\nimport { IgoMap, LayerListControlsOptions } from '@igo2/geo';\n\nimport { MapState } from '../../map/map.state';\nimport { LayerListToolState } from '../../map/layer-list-tool.state';\n\n@ToolComponent({\n name: 'shareMap',\n title: 'igo.integration.tools.shareMap',\n icon: 'share-variant'\n})\n@Component({\n selector: 'igo-context-share-tool',\n templateUrl: './context-share-tool.component.html'\n})\nexport class ContextShareToolComponent {\n\n get map(): IgoMap { return this.mapState.map; }\n\n get layerListControls(): LayerListControlsOptions { return this.layerListToolState.getLayerListControls(); }\n\n constructor(\n private mapState: MapState,\n private layerListToolState: LayerListToolState\n ) {}\n}\n","<igo-share-map\n [map]=\"map\"></igo-share-map>\n","import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';\n\nimport { IgoContextModule } from '@igo2/context';\n\nimport { ContextEditorToolComponent } from './context-editor-tool/context-editor-tool.component';\nimport { ContextManagerToolComponent } from './context-manager-tool/context-manager-tool.component';\nimport { ContextPermissionManagerToolComponent } from './context-permission-manager-tool/context-permission-manager-tool.component';\nimport { ContextShareToolComponent } from './context-share-tool/context-share-tool.component';\n\n@NgModule({\n imports: [IgoContextModule],\n declarations: [\n ContextEditorToolComponent,\n ContextManagerToolComponent,\n ContextPermissionManagerToolComponent,\n ContextShareToolComponent\n ],\n exports: [\n ContextEditorToolComponent,\n ContextManagerToolComponent,\n ContextPermissionManagerToolComponent,\n ContextShareToolComponent\n ],\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\n})\nexport class IgoAppContextModule {}\n","import { Injectable } from '@angular/core';\n\nimport { AuthService } from '@igo2/auth';\nimport { EntityStore } from '@igo2/common';\nimport { Catalog, CatalogItem } from '@igo2/geo';\n\n/**\n * Service that holds the state of the catalog module\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class CatalogState {\n\n /**\n * Store that contains all the catalogs\n */\n get catalogStore(): EntityStore<Catalog> { return this._catalogStore; }\n private _catalogStore: EntityStore<Catalog>;\n\n /**\n * Catalog -> Catalog items store mapping\n */\n private catalogItemsStores = new Map<string, EntityStore<CatalogItem>>();\n\n constructor(authService: AuthService) {\n this._catalogStore = new EntityStore([]);\n\n authService.authenticate$.subscribe(() => {\n this.clearCatalogItemsStores();\n });\n }\n\n /**\n * Get a catalog's items store\n * @param catalog Catalog\n * @returns Store that contains the catalog items\n */\n getCatalogItemsStore(catalog: Catalog): EntityStore<CatalogItem> {\n return this.catalogItemsStores.get(catalog.id as string);\n }\n\n /**\n * Bind a catalog items store to a catalog\n * @param catalog Catalog\n * @param store Catalog items store\n */\n setCatalogItemsStore(catalog: Catalog, store: EntityStore<CatalogItem>) {\n this.catalogItemsStores.set(catalog.id as string, store);\n }\n\n /**\n * Clear all catalog items stores\n */\n clearCatalogItemsStores() {\n this.catalogItemsStores.clear();\n }\n}\n","import { Component, OnInit, ChangeDetectionStrategy, Input } from '@angular/core';\nimport { take } from 'rxjs/operators';\n\nimport { ToolComponent } from '@igo2/common';\n\nimport { EntityStore } from '@igo2/common';\nimport { Catalog, CatalogService } from '@igo2/geo';\nimport { StorageService } from '@igo2/core';\n\nimport { ToolState } from '../../tool/tool.state';\nimport { CatalogState } from '../catalog.state';\n\n/**\n * Tool to browse the list of available catalogs.\n */\n@ToolComponent({\n name: 'catalog',\n title: 'igo.integration.tools.catalog',\n icon: 'layers-plus'\n})\n@Component({\n selector: 'igo-catalog-library-tool',\n templateUrl: './catalog-library-tool.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class CatalogLibraryToolComponent implements OnInit {\n /**\n * Store that contains the catalogs\n * @internal\n */\n get store(): EntityStore<Catalog> {\n return this.catalogState.catalogStore;\n }\n\n /**\n * Determine if the form to add a catalog is allowed\n */\n @Input() addCatalogAllowed: boolean = false;\n\n /**\n * List of predefined catalogs\n */\n @Input() predefinedCatalogs: Catalog[] = [];\n\n constructor(\n private catalogService: CatalogService,\n private catalogState: CatalogState,\n private toolState: ToolState,\n private storageService: StorageService\n ) {}\n\n /**\n * @internal\n */\n ngOnInit() {\n if (this.store.count === 0) {\n this.loadCatalogs();\n }\n }\n\n /**\n * When the selected catalog changes, toggle the the CatalogBrowser tool.\n * @internal\n * @param event Select event\n */\n onCatalogSelectChange(event: { selected: boolean; catalog: Catalog }) {\n if (event.selected === false) {\n return;\n }\n this.toolState.toolbox.activateTool('catalogBrowser');\n }\n\n /**\n * Get all the available catalogs from the CatalogService and\n * load them into the store.\n */\n private loadCatalogs() {\n this.catalogService.loadCatalogs().pipe(take(1)).subscribe((catalogs: Catalog[]) => {\n this.store.clear();\n this.store.load(catalogs.concat((this.storageService.get('addedCatalogs') || []) as Catalog[]));\n });\n }\n}\n","<igo-catalog-library\n [predefinedCatalogs]=\"predefinedCatalogs\"\n [addCatalogAllowed]=\"addCatalogAllowed\"\n [store]=\"store\"\n (catalogSelectChange)=\"onCatalogSelectChange($event)\">\n</igo-catalog-library>\n","import { CommonModule } from '@angular/common';\nimport { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';\n\nimport { IgoCatalogLibraryModule } from '@igo2/geo';\nimport { CatalogLibraryToolComponent } from './catalog-library-tool.component';\n\n/**\n * @ignore\n */\n@NgModule({\n imports: [\n CommonModule,\n IgoCatalogLibraryModule\n ],\n declarations: [CatalogLibraryToolComponent],\n exports: [CatalogLibraryToolComponent],\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\n})\nexport class IgoAppCatalogLibraryToolModule {}\n","<igo-catalog-browser\n *ngIf=\"store$ | async as store\"\n [catalog]=\"catalog\"\n [store]=\"store\"\n [map]=\"map\"\n [toggleCollapsedGroup]=\"toggleCollapsedGroup\">\n</igo-catalog-browser>\n","import {\n Component,\n Input,\n OnInit,\n OnDestroy,\n ChangeDetectionStrategy\n} from '@angular/core';\n\nimport { BehaviorSubject, Subscription } from 'rxjs';\nimport { take } from 'rxjs/operators';\n\nimport { EntityRecord, EntityStore, ToolComponent } from '@igo2/common';\nimport { AuthService } from '@igo2/auth';\n\nimport {\n IgoMap,\n Catalog,\n CatalogItem,\n CatalogItemState,\n CatalogService\n} from '@igo2/geo';\n\nimport { MapState } from '../../map/map.state';\nimport { CatalogState } from '../catalog.state';\n\n/**\n * Tool to browse a catalog's groups and layers and display them to a map.\n */\n@ToolComponent({\n name: 'catalogBrowser',\n title: 'igo.integration.tools.catalog',\n icon: 'photo-browser',\n parent: 'catalog'\n})\n@Component({\n selector: 'igo-catalog-browser-tool',\n templateUrl: './catalog-browser-tool.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class CatalogBrowserToolComponent implements OnInit, OnDestroy {\n catalog: Catalog;\n\n /**\n * Store that contains the catalog items\n * @internal\n */\n store$ = new BehaviorSubject<EntityStore<CatalogItem, CatalogItemState>>(\n undefined\n );\n\n /**\n * Subscription to the selected catalog\n */\n private catalog$$: Subscription;\n\n /**\n * Subscription for authentication\n */\n private authenticate$$: Subscription;\n\n /**\n * Whether a group can be toggled when it's collapsed\n */\n @Input() toggleCollapsedGroup: boolean = true;\n\n /**\n * Map to add layers to\n * @internal\n */\n get map(): IgoMap {\n return this.mapState.map;\n }\n\n constructor(\n private catalogService: CatalogService,\n private catalogState: CatalogState,\n private mapState: MapState,\n private authService: AuthService\n ) {}\n\n /**\n * @internal\n */\n ngOnInit() {\n const catalogStore = this.catalogState.catalogStore;\n this.catalog$$ = catalogStore.stateView\n .firstBy$(\n (record: EntityRecord<Catalog>) => record.state.selected === true\n )\n .subscribe((record: EntityRecord<Catalog>) => {\n if (record && record.entity) {\n const catalog = record.entity;\n this.catalog = catalog;\n }\n });\n\n this.authenticate$$ = this.authService.authenticate$.subscribe(() => {\n this.loadCatalogItems(this.catalog);\n });\n }\n\n /**\n * @internal\n */\n ngOnDestroy() {\n this.catalog$$.unsubscribe();\n this.authenticate$$.unsubscribe();\n }\n\n /**\n * Get the selected catalog's items from the CatalogService and\n * load them into the store.\n * @param catalog Selected catalog\n */\n private loadCatalogItems(catalog: Catalog) {\n let store = this.catalogState.getCatalogItemsStore(catalog);\n if (store !== undefined) {\n this.store$.next(store);\n return;\n }\n\n store = new EntityStore<CatalogItem>([]);\n this.catalogState.setCatalogItemsStore(catalog, store);\n this.catalogService\n .loadCatalogItems(catalog)\n .pipe(take(1))\n .subscribe((items: CatalogItem[]) => {\n store.load(items);\n this.store$.next(store);\n });\n }\n}\n","import { CommonModule } from '@angular/common';\nimport { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';\n\nimport { IgoCatalogBrowserModule } from '@igo2/geo';\nimport { CatalogBrowserToolComponent } from './catalog-browser-tool.component';\n\n/**\n * @ignore\n */\n@NgModule({\n imports: [\n CommonModule,\n IgoCatalogBrowserModule\n ],\n declarations: [CatalogBrowserToolComponent],\n exports: [CatalogBrowserToolComponent],\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\n})\nexport class IgoAppCatalogBrowserToolModule {}\n","import { NgModule } from '@angular/core';\n\nimport { IgoAppCatalogLibraryToolModule } from './catalog-library-tool/catalog-library-tool.module';\nimport { IgoAppCatalogBrowserToolModule } from './catalog-browser-tool/catalog-browser-tool.module';\n\n@NgModule({\n imports: [],\n exports: [\n IgoAppCatalogLibraryToolModule,\n IgoAppCatalogBrowserToolModule\n ],\n declarations: []\n})\nexport class IgoAppCatalogModule {}\n","import { Injectable } from '@angular/core';\n\nimport { AnyLayerOptions, StopsStore, StopsFeatureStore, RoutesFeatureStore, StepFeatureStore } from '@igo2/geo';\nimport { Subject } from 'rxjs';\nimport { MapState } from '../map/map.state';\n\n/**\n * Service that holds the state of the direction module\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class DirectionState {\n\n public zoomToActiveRoute$: Subject<void> = new Subject();\n\n /**\n * Store that holds the stop\n */\n public stopsStore: StopsStore = new StopsStore([]);\n\n /**\n * Store that holds the driving stops as feature\n */\n public stopsFeatureStore: StopsFeatureStore = new StopsFeatureStore([], {\n map: this.mapState.map\n });\n\n /**\n * Store that holds the driving route as feature\n */\n public routesFeatureStore: RoutesFeatureStore = new RoutesFeatureStore([], {\n map: this.mapState.map\n });\n\n public stepFeatureStore: StepFeatureStore = new StepFeatureStore([], {\n map: this.mapState.map\n });\n\n public debounceTime: number = 200;\n\n constructor(private mapState: MapState) {\n\n this.mapState.map.ol.once('rendercomplete', () => {\n this.stopsFeatureStore.empty$.subscribe((empty) => {\n if (this.stopsFeatureStore.layer?.options) {\n (this.stopsFeatureStore.layer.options as AnyLayerOptions).showInLayerList = !empty;\n }\n });\n this.routesFeatureStore.empty$.subscribe((empty) => {\n if (this.routesFeatureStore.layer?.options) {\n (this.routesFeatureStore.layer.options as AnyLayerOptions).showInLayerList = !empty;\n }\n });\n });\n\n this.mapState.map.layers$.subscribe(() => {\n if (!this.mapState.map.getLayerById('igo-direction-stops-layer')) {\n this.stopsStore.deleteMany(this.stopsStore.all());\n this.stopsFeatureStore.deleteMany(this.stopsFeatureStore.all()); // not necessary\n }\n if (!this.mapState.map.getLayerById('igo-direction-route-layer')) {\n this.routesFeatureStore.deleteMany(this.routesFeatureStore.all());\n }\n });\n }\n\n}\n","import { Component, OnInit } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\nimport { LanguageService, MessageService, StorageScope, StorageService } from '@igo2/core';\nimport { IgoMap, RoutesFeatureStore, StopsFeatureStore, StopsStore, StepFeatureStore } from '@igo2/geo';\nimport { Subject } from 'rxjs';\n\nimport { MapState } from '../../map/map.state';\nimport { DirectionState } from '../directions.state';\n\n@ToolComponent({\n name: 'directions',\n title: 'igo.integration.tools.directions',\n icon: 'directions'\n})\n@Component({\n selector: 'igo-directions-tool',\n templateUrl: './directions-tool.component.html'\n})\nexport class DirectionsToolComponent implements OnInit {\n /**\n * stops\n * @internal\n */\n get stopsStore(): StopsStore { return this.directionState.stopsStore; }\n\n get debounceTime(): number { return this.directionState.debounceTime; }\n\n /**\n * stops\n * @internal\n */\n get stopsFeatureStore(): StopsFeatureStore { return this.directionState.stopsFeatureStore; }\n\n /**\n * routes\n * @internal\n */\n get routesFeatureStore(): RoutesFeatureStore { return this.directionState.routesFeatureStore; }\n\n /**\n * step store\n * @internal\n */\n get stepFeatureStore(): StepFeatureStore { return this.directionState.stepFeatureStore; }\n\n /**\n * step store\n * @internal\n */\n get zoomToActiveRoute$(): Subject<void> { return this.directionState.zoomToActiveRoute$; }\n\n\n /**\n * Map to measure on\n * @internal\n */\n get map(): IgoMap { return this.mapState.map; }\n\n constructor(\n private directionState: DirectionState,\n private mapState: MapState,\n private languageService: LanguageService,\n private messageService: MessageService,\n private storageService: StorageService\n ) {}\n\n ngOnInit(): void {\n const warningShown = this.storageService.get('direction.warning.shown') as boolean;\n if (!warningShown) {\n const translate = this.languageService.translate;\n const title = translate.instant(\n 'igo.integration.directions.warning.title'\n );\n const msg = translate.instant('igo.integration.directions.warning.message');\n this.messageService.info(msg, title, { timeOut: 20000 });\n this.storageService.set('direction.warning.shown', true, StorageScope.SESSION);\n }\n }\n\n}\n","<igo-directions\n [debounceTime]=\"debounceTime\"\n [stopsStore]=\"stopsStore\"\n [stopsFeatureStore]=\"stopsFeatureStore\"\n [stepFeatureStore]=\"stepFeatureStore\"\n [routesFeatureStore]=\"routesFeatureStore\"\n [zoomToActiveRoute$]=\"zoomToActiveRoute$\"> \n</igo-directions>","import {\n NgModule,\n ModuleWithProviders,\n CUSTOM_ELEMENTS_SCHEMA\n} from '@angular/core';\n\nimport { IgoDirectionsModule } from '@igo2/geo';\nimport { DirectionsToolComponent } from './directions-tool/directions-tool.component';\n\n@NgModule({\n imports: [IgoDirectionsModule],\n declarations: [DirectionsToolComponent],\n exports: [DirectionsToolComponent],\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\n})\nexport class IgoAppDirectionsModule {\n static forRoot(): ModuleWithProviders<IgoAppDirectionsModule> {\n return {\n ngModule: IgoAppDirectionsModule,\n providers: []\n };\n }\n}\n","import { Injectable } from '@angular/core';\n\nimport { FeatureStore, Feature } from '@igo2/geo';\nimport { MapState } from '../map/map.state';\n\n/**\n * Service that holds the state of the measure module\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class DrawState {\n\n /**\n * Store that holds the measures\n */\n public store: FeatureStore<Feature> = new FeatureStore<Feature>([], {\n map: this.mapState.map\n });\n\n constructor(private mapState: MapState) {\n\n this.mapState.map.layers$.subscribe(() => {\n if (!this.mapState.map.getLayerById('igo-draw-layer')) {\n this.store.deleteMany(this.store.all());\n }\n });\n }\n\n}\n","import {\n Component,\n ChangeDetectionStrategy\n } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\nimport { FeatureStore, Feature, IgoMap } from '@igo2/geo';\nimport { MapState } from '../../map/map.state';\nimport { DrawState } from '../draw.state';\n\n/**\n * Tool to measure lengths and areas\n */\n@ToolComponent({\n name: 'draw',\n title: 'igo.integration.tools.draw',\n icon: 'draw'\n})\n@Component({\n selector: 'igo-drawing-tool',\n templateUrl: './drawing-tool.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class DrawingToolComponent {\n\n/**\n * Map to measure on\n * @internal\n */\nget store(): FeatureStore<Feature> { return this.drawState.store; }\n\n/**\n * Map to measure on\n * @internal\n */\nget map(): IgoMap { return this.mapState.map; }\n\nconstructor(\n private drawState: DrawState,\n private mapState: MapState\n) {}\n\n}\n","<igo-draw [store]=\"store\" [map]=\"map\"></igo-draw>\n","import { NgModule } from '@angular/core';\n\nimport { IgoDrawingToolModule } from '@igo2/geo';\nimport { DrawingToolComponent } from './drawing-tool/drawing-tool.component';\n\n@NgModule({\n imports: [IgoDrawingToolModule],\n declarations: [DrawingToolComponent],\n exports: [\n DrawingToolComponent\n ]\n})\nexport class IgoAppDrawModule {}\n","import {\n FeatureMotion,\n FeatureStoreSelectionStrategy,\n FeatureWorkspace,\n WfsWorkspace\n} from '@igo2/geo';\n\n\nexport function handleZoomAuto(workspace: FeatureWorkspace | WfsWorkspace, storageService) {\n const zoomStrategy = workspace.entityStore\n .getStrategyOfType(FeatureStoreSelectionStrategy) as FeatureStoreSelectionStrategy;\n zoomStrategy.setMotion(storageService.get('zoomAuto') as boolean ? FeatureMotion.Default : FeatureMotion.None);\n}\n\n\n","import { Injectable } from '@angular/core';\n\nimport { StorageService } from '@igo2/core';\n\n/**\n * Service that holds the state of storage service\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class StorageState {\n get storageService(): StorageService {\n return this.igoStorageService;\n }\n\n constructor(private igoStorageService: StorageService) {}\n}\n","import { Injectable, OnDestroy } from '@angular/core';\n\nimport {\n Action,\n EntityStoreFilterCustomFuncStrategy,\n EntityStoreFilterSelectionStrategy\n} from '@igo2/common';\n\nimport { BehaviorSubject, Subscription } from 'rxjs';\nimport {\n FeatureWorkspace,\n mapExtentStrategyActiveToolTip,\n noElementSelected,\n ExportOptions\n} from '@igo2/geo';\nimport { StorageService, StorageServiceEvent, StorageServiceEventEnum, LanguageService, MediaService} from '@igo2/core';\nimport { StorageState } from '../../storage/storage.state';\nimport { map, skipWhile } from 'rxjs/operators';\nimport { ToolState } from '../../tool/tool.state';\nimport { handleZoomAuto } from './workspace.utils';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class FeatureActionsService implements OnDestroy {\n\n public maximize$: BehaviorSubject<boolean> = new BehaviorSubject(\n this.storageService.get('workspaceMaximize') as boolean\n );\n\n zoomAuto$: BehaviorSubject<boolean> = new BehaviorSubject(false);\n private storageChange$$: Subscription;\n\n get storageService(): StorageService {\n return this.storageState.storageService;\n }\n\n get zoomAuto(): boolean {\n return this.storageService.get('zoomAuto') as boolean;\n }\n\n constructor(\n private storageState: StorageState,\n public languageService: LanguageService,\n private toolState: ToolState,\n private mediaService: MediaService\n ) {}\n\n ngOnDestroy(): void {\n if (this.storageChange$$) {\n this.storageChange$$.unsubscribe();\n }\n }\n\n loadActions(\n workspace: FeatureWorkspace,\n rowsInMapExtentCheckCondition$: BehaviorSubject<boolean>,\n selectOnlyCheckCondition$: BehaviorSubject<boolean>\n ) {\n const actions = this.buildActions(\n workspace,\n rowsInMapExtentCheckCondition$,\n selectOnlyCheckCondition$\n );\n workspace.actionStore.load(actions);\n }\n\n buildActions(\n workspace: FeatureWorkspace,\n rowsInMapExtentCheckCondition$: BehaviorSubject<boolean>,\n selectOnlyCheckCondition$: BehaviorSubject<boolean>\n ): Action[] {\n this.zoomAuto$.next(this.zoomAuto);\n this.storageChange$$ = this.storageService.storageChange$\n .pipe(\n skipWhile(\n (storageChange: StorageServiceEvent) =>\n storageChange.key !== 'zoomAuto' || storageChange.event === StorageServiceEventEnum.CLEARED\n )\n )\n .subscribe(() => {\n this.zoomAuto$.next(this.zoomAuto);\n handleZoomAuto(workspace, this.storageService);\n });\n return [\n {\n id: 'zoomAuto',\n checkbox: true,\n title: 'igo.integration.workspace.zoomAuto.title',\n tooltip: 'igo.integration.workspace.zoomAuto.tooltip',\n checkCondition: this.zoomAuto$,\n handler: () => {\n handleZoomAuto(workspace, this.storageService);\n this.storageService.set(\n 'zoomAuto',\n !this.storageService.get('zoomAuto') as boolean\n );\n }\n },\n {\n id: 'filterInMapExtent',\n checkbox: true,\n title: 'igo.integration.workspace.inMapExtent.title',\n tooltip: mapExtentStrategyActiveToolTip(workspace),\n checkCondition: rowsInMapExtentCheckCondition$,\n handler: () => rowsInMapExtentCheckCondition$.next(!rowsInMapExtentCheckCondition$.value)\n },\n {\n id: 'selectedOnly',\n checkbox: true,\n title: 'igo.integration.workspace.selected.title',\n tooltip: 'igo.integration.workspace.selected.tooltip',\n checkCondition: selectOnlyCheckCondition$,\n handler: () => selectOnlyCheckCondition$.next(!selectOnlyCheckCondition$.value)\n },\n {\n id: 'clearselection',\n icon: 'select-off',\n title: 'igo.integration.workspace.clearSelection.title',\n tooltip: 'igo.integration.workspace.clearSelection.tooltip',\n handler: (ws: FeatureWorkspace) => {\n ws.entityStore.state.updateMany(ws.entityStore.view.all(), {\n selected: false\n });\n },\n args: [workspace],\n availability: (ws: FeatureWorkspace) => noElementSelected(ws)\n },\n {\n id: 'featureDownload',\n icon: 'file-export',\n title: 'igo.integration.workspace.download.title',\n tooltip: 'igo.integration.workspace.download.tooltip',\n handler: (ws: FeatureWorkspace) => {\n const filterStrategy = ws.entityStore.getStrategyOfType(\n EntityStoreFilterCustomFuncStrategy\n );\n const filterSelectionStrategy = ws.entityStore.getStrategyOfType(\n EntityStoreFilterSelectionStrategy\n );\n const layersWithSelection = filterSelectionStrategy.active\n ? [ws.layer.id]\n : [];\n this.toolState.toolToActivateFromOptions({\n tool: 'importExport',\n options: {\n layers: [ws.layer.id],\n featureInMapExtent: filterStrategy.active,\n layersWithSelection\n } as ExportOptions\n });\n },\n args: [workspace]\n },\n {\n id: 'maximize',\n title: this.languageService.translate.instant('igo.integration.workspace.maximize'),\n tooltip: this.languageService.translate.instant(\n 'igo.integration.workspace.maximizeTooltip'\n ),\n icon: 'resize',\n display: () => {\n return this.maximize$.pipe(map((v) => !v && !this.mediaService.isMobile()));\n },\n handler: () => {\n if (!this.mediaService.isMobile()) {\n this.maximize$.next(true);\n }\n },\n },\n {\n id: 'standardExtent',\n title: this.languageService.translate.instant(\n 'igo.integration.workspace.standardExtent'\n ),\n tooltip: this.languageService.translate.instant(\n 'igo.integration.workspace.standardExtentTooltip'\n ),\n icon: 'resize',\n display: () => {\n return this.maximize$.pipe(map((v) => v && !this.mediaService.isMobile()));\n },\n handler: () => {\n this.maximize$.next(false);\n }\n }\n ];\n }\n}\n","import { Inject, Injectable, OnDestroy } from '@angular/core';\n\nimport {\n Action,\n EntityStoreFilterCustomFuncStrategy,\n EntityStoreFilterSelectionStrategy,\n Widget\n} from '@igo2/common';\n\nimport { BehaviorSubject, Subscription } from 'rxjs';\nimport {\n WfsWorkspace,\n mapExtentStrategyActiveToolTip,\n noElementSelected,\n ExportOptions,\n OgcFilterWidget,\n OgcFilterableDataSource,\n} from '@igo2/geo';\nimport { StorageService, StorageServiceEvent, StorageServiceEventEnum, LanguageService, MediaService} from '@igo2/core';\nimport { StorageState } from '../../storage/storage.state';\nimport { map, skipWhile } from 'rxjs/operators';\nimport { ToolState } from '../../tool/tool.state';\nimport { handleZoomAuto } from './workspace.utils';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class WfsActionsService implements OnDestroy {\n\n public maximize$: BehaviorSubject<boolean> = new BehaviorSubject(\n this.storageService.get('workspaceMaximize') as boolean\n );\n\n selectOnlyCheckCondition$: BehaviorSubject<boolean> = new BehaviorSubject(false);\n // rowsInMapExtentCheckCondition$: BehaviorSubject<boolean> = new BehaviorSubject(true);\n zoomAuto$: BehaviorSubject<boolean> = new BehaviorSubject(false);\n private storageChange$$: Subscription;\n\n get storageService(): StorageService {\n return this.storageState.storageService;\n }\n\n get zoomAuto(): boolean {\n return this.storageService.get('zoomAuto') as boolean;\n }\n\n constructor(\n @Inject(OgcFilterWidget) private ogcFilterWidget: Widget,\n private storageState: StorageState,\n public languageService: LanguageService,\n private mediaService: MediaService,\n private toolState: ToolState) {}\n\n ngOnDestroy(): void {\n if (this.storageChange$$) {\n this.storageChange$$.unsubscribe();\n }\n }\n\n loadActions(\n workspace: WfsWorkspace,\n rowsInMapExtentCheckCondition$: BehaviorSubject<boolean>,\n selectOnlyCheckCondition$: BehaviorSubject<boolean>\n ) {\n const actions = this.buildActions(\n workspace,\n rowsInMapExtentCheckCondition$,\n selectOnlyCheckCondition$\n );\n workspace.actionStore.load(actions);\n }\n\n buildActions(\n workspace: WfsWorkspace,\n rowsInMapExtentCheckCondition$: BehaviorSubject<boolean>,\n selectOnlyCheckCondition$: BehaviorSubject<boolean>\n ): Action[] {\n this.zoomAuto$.next(this.zoomAuto);\n this.storageChange$$ = this.storageService.storageChange$\n .pipe(skipWhile((storageChange: StorageServiceEvent) =>\n storageChange.key !== 'zoomAuto' || storageChange.event === StorageServiceEventEnum.CLEARED))\n .subscribe(() => {\n this.zoomAuto$.next(this.zoomAuto);\n handleZoomAuto(workspace, this.storageService);\n });\n const actions = [\n {\n id: 'zoomAuto',\n checkbox: true,\n title: 'igo.integration.workspace.zoomAuto.title',\n tooltip: 'igo.integration.workspace.zoomAuto.tooltip',\n checkCondition: this.zoomAuto$,\n handler: () => {\n handleZoomAuto(workspace, this.storageService);\n this.storageService.set('zoomAuto', !this.storageService.get('zoomAuto') as boolean);\n }\n },\n {\n id: 'filterInMapExtent',\n checkbox: true,\n title: 'igo.integration.workspace.inMapExtent.title',\n tooltip: mapExtentStrategyActiveToolTip(workspace),\n checkCondition: rowsInMapExtentCheckCondition$,\n handler: () => rowsInMapExtentCheckCondition$.next(!rowsInMapExtentCheckCondition$.value)\n },\n {\n id: 'selectedOnly',\n checkbox: true,\n title: 'igo.integration.workspace.selected.title',\n tooltip: 'igo.integration.workspace.selected.title',\n checkCondition: selectOnlyCheckCondition$,\n handler: () => selectOnlyCheckCondition$.next(!selectOnlyCheckCondition$.value)\n },\n {\n id: 'clearselection',\n icon: 'select-off',\n title: 'igo.integration.workspace.clearSelection.title',\n tooltip: 'igo.integration.workspace.clearSelection.tooltip',\n handler: (ws: WfsWorkspace) => {\n ws.entityStore.state.updateMany(ws.entityStore.view.all(), { selected: false });\n },\n args: [workspace],\n availability: (ws: WfsWorkspace) => noElementSelected(ws)\n },\n {\n id: 'wfsDownload',\n icon: 'file-export',\n title: 'igo.integration.workspace.download.title',\n tooltip: 'igo.integration.workspace.download.tooltip',\n handler: (ws: WfsWorkspace) => {\n const filterStrategy = ws.entityStore.getStrategyOfType(EntityStoreFilterCustomFuncStrategy);\n const filterSelectionStrategy = ws.entityStore.getStrategyOfType(EntityStoreFilterSelectionStrategy);\n const layersWithSelection = filterSelectionStrategy.active ? [ws.layer.id] : [];\n this.toolState.toolToActivateFromOptions({\n tool: 'importExport',\n options: { layers: [ws.layer.id], featureInMapExtent: filterStrategy.active, layersWithSelection } as ExportOptions\n });\n },\n args: [workspace]\n },\n {\n id: 'ogcFilter',\n icon: 'filter',\n title: 'igo.integration.workspace.ogcFilter.title',\n tooltip: 'igo.integration.workspace.ogcFilter.tooltip',\n handler: (widget: Widget, ws: WfsWorkspace) => {\n ws.activateWidget(widget, {\n map: ws.map,\n layer: ws.layer\n });\n },\n args: [this.ogcFilterWidget, workspace]\n },\n {\n id: 'maximize',\n title: this.languageService.translate.instant('igo.integration.workspace.maximize'),\n tooltip: this.languageService.translate.instant(\n 'igo.integration.workspace.maximizeTooltip'\n ),\n icon: 'resize',\n display: () => {\n return this.maximize$.pipe(map((v) => !v && !this.mediaService.isMobile()));\n },\n handler: () => {\n if (!this.mediaService.isMobile()) {\n this.maximize$.next(true);\n }\n },\n },\n {\n id: 'standardExtent',\n title: this.languageService.translate.instant(\n 'igo.integration.workspace.standardExtent'\n ),\n tooltip: this.languageService.translate.instant(\n 'igo.integration.workspace.standardExtentTooltip'\n ),\n icon: 'resize',\n display: () => {\n return this.maximize$.pipe(map((v) => v && !this.mediaService.isMobile()));\n },\n handler: () => {\n this.maximize$.next(false);\n }\n }\n ];\n return (workspace.layer.dataSource as OgcFilterableDataSource).ogcFilters$?.value?.enabled ?\n actions : actions.filter(action => action.id !== 'ogcFilter');\n }\n}\n","import { Injectable, OnDestroy } from '@angular/core';\n\nimport { BehaviorSubject, Subscription } from 'rxjs';\n\nimport {\n EntityRecord,Workspace, WorkspaceStore, Widget,\n EntityStoreFilterCustomFuncStrategy, EntityStoreFilterSelectionStrategy } from '@igo2/common';\nimport { WfsWorkspace, FeatureWorkspace } from '@igo2/geo';\nimport { FeatureActionsService } from './shared/feature-actions.service';\nimport { WfsActionsService } from './shared/wfs-actions.service';\nimport { StorageService } from '@igo2/core';\n\n/**\n * Service that holds the state of the workspace module\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class WorkspaceState implements OnDestroy {\n\n public workspacePanelExpanded: boolean = false;\n\n readonly workspaceEnabled$: BehaviorSubject<boolean> = new BehaviorSubject<boolean>(false);\n readonly rowsInMapExtentCheckCondition$: BehaviorSubject<boolean> = new BehaviorSubject<boolean>(true);\n readonly selectOnlyCheckCondition$: BehaviorSubject<boolean> = new BehaviorSubject<boolean>(false);\n\n readonly workspaceMaximize$: BehaviorSubject<boolean> = new BehaviorSubject(\n this.storageService.get('workspaceMaximize') as boolean\n );\n private actionMaximize$$: Subscription[] = [];\n\n private rowsInMapExtentCheckCondition$$: Subscription;\n private selectOnlyCheckCondition$$: Subscription;\n\n /** Subscription to the active workspace */\n private activeWorkspace$$: Subscription;\n\n /** Subscription to the active workspace widget */\n private activeWorkspaceWidget$$: Subscription;\n\n /** Active widget observable. Only one may be active for all available workspaces */\n readonly activeWorkspaceWidget$: BehaviorSubject<Widget> = new BehaviorSubject<Widget>(undefined);\n\n /**\n * Observable of the active workspace\n */\n public workspace$ = new BehaviorSubject<Workspace>(undefined);\n\n /**\n * Store that holds all the available workspaces\n */\n get store(): WorkspaceStore { return this._store; }\n private _store: WorkspaceStore;\n\n constructor(\n private featureActionsService: FeatureActionsService,\n private wfsActionsService: WfsActionsService,\n private storageService: StorageService\n ) {\n this.initWorkspaces();\n }\n\n /**\n * Initialize the workspace store. Each time a workspace is activated,\n * subscribe to it's active widget. Tracking the active widget is useful\n * to make sure only one widget is active at a time.\n */\n private initWorkspaces() {\n this._store = new WorkspaceStore([]);\n this._store.stateView\n .firstBy$((record: EntityRecord<Workspace>) => record.state.active === true)\n .subscribe((record: EntityRecord<Workspace>) => {\n const workspace = record ? record.entity : undefined;\n this.workspace$.next(workspace);\n });\n\n this._store.stateView.all$()\n .subscribe((workspaces: EntityRecord<Workspace>[]) => {\n workspaces.map((wks: EntityRecord<Workspace>) => {\n if (wks.entity.actionStore.empty) {\n if (wks.entity instanceof WfsWorkspace) {\n this.wfsActionsService.loadActions(\n wks.entity,\n this.rowsInMapExtentCheckCondition$,\n this.selectOnlyCheckCondition$);\n } else if (wks.entity instanceof FeatureWorkspace) {\n this.featureActionsService.loadActions(\n wks.entity,\n this.rowsInMapExtentCheckCondition$,\n this.selectOnlyCheckCondition$);\n }\n }\n\n });\n });\n\n this.actionMaximize$$.push(this.featureActionsService.maximize$.subscribe(maximized => {\n this.setWorkspaceIsMaximized(maximized);\n }));\n\n this.actionMaximize$$.push(this.wfsActionsService.maximize$.subscribe(maximized => {\n this.setWorkspaceIsMaximized(maximized);\n }));\n\n this.activeWorkspace$$ = this.workspace$\n .subscribe((workspace: Workspace) => {\n if (this.activeWorkspaceWidget$$ !== undefined) {\n this.activeWorkspaceWidget$$.unsubscribe();\n this.activeWorkspaceWidget$$ = undefined;\n }\n\n if (workspace !== undefined) {\n this.activeWorkspaceWidget$$ = workspace.widget$\n .subscribe((widget: Widget) => this.activeWorkspaceWidget$.next(widget));\n }\n });\n\n this.rowsInMapExtentCheckCondition$$ = this.rowsInMapExtentCheckCondition$.subscribe((rowsInMapExtent) => {\n this._store.stateView.all().map((wks: EntityRecord<Workspace>) => {\n if (!wks.entity.actionStore.empty) {\n const filterStrategy = wks.entity.entityStore.getStrategyOfType(EntityStoreFilterCustomFuncStrategy);\n if (filterStrategy) {\n if (rowsInMapExtent) {\n filterStrategy.activate();\n } else {\n filterStrategy.deactivate();\n }\n }\n }\n });\n });\n\n this.selectOnlyCheckCondition$$ = this.selectOnlyCheckCondition$.subscribe((selectOnly) => {\n this._store.stateView.all().map((wks: EntityRecord<Workspace>) => {\n if (!wks.entity.actionStore.empty) {\n const filterStrategy = wks.entity.entityStore.getStrategyOfType(EntityStoreFilterSelectionStrategy);\n if (filterStrategy) {\n if (selectOnly) {\n filterStrategy.activate();\n } else {\n filterStrategy.deactivate();\n }\n }\n }\n });\n });\n }\n\n private setWorkspaceIsMaximized(maximized: boolean) {\n this.storageService.set('workspaceMaximize', maximized);\n this.workspaceMaximize$.next(maximized);\n }\n\n public setActiveWorkspaceById(id: string) {\n const wksFromId = this.store\n .all()\n .find(workspace => workspace.id === id);\n if (wksFromId) {\n this.store.activateWorkspace(wksFromId);\n }\n }\n\n /**\n * Teardown all the workspaces\n * @internal\n */\n ngOnDestroy() {\n this.teardownWorkspaces();\n this.actionMaximize$$.map(a => a.unsubscribe());\n if (this.rowsInMapExtentCheckCondition$$) {\n this.selectOnlyCheckCondition$$.unsubscribe();\n }\n if (this.selectOnlyCheckCondition$$) {\n this.selectOnlyCheckCondition$$.unsubscribe();\n }\n }\n\n /**\n * Teardown the workspace store and any subscribers\n */\n private teardownWorkspaces() {\n this.store.clear();\n if (this.activeWorkspaceWidget$$ !== undefined) {\n this.activeWorkspaceWidget$$.unsubscribe();\n }\n if (this.activeWorkspace$$ !== undefined) {\n this.activeWorkspace$$.unsubscribe();\n }\n }\n\n}\n","<button\n *ngIf=\"hasWorkspace$ | async\"\n mat-icon-button\n tooltip-position=\"below\"\n matTooltipShowDelay=\"500\"\n [matTooltip]=\"'igo.integration.workspace.toggleWorkspace' | translate\"\n [color]=\"color\"\n (click)=\"activateWorkspace()\"\n >\n <mat-icon svgIcon=\"table\"></mat-icon>\n</button>\n","import { Component, Input, ChangeDetectionStrategy, OnInit, OnDestroy } from '@angular/core';\nimport type { Layer } from '@igo2/geo';\nimport { WorkspaceState } from '../workspace.state';\nimport { BehaviorSubject, combineLatest, Subscription } from 'rxjs';\n\n@Component({\n selector: 'igo-workspace-button',\n templateUrl: './workspace-button.component.html',\n styleUrls: ['./workspace-button.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class WorkspaceButtonComponent implements OnInit, OnDestroy {\n\n public hasWorkspace$: BehaviorSubject<boolean> = new BehaviorSubject(false);\n private hasWorkspace$$: Subscription;\n\n private _layer: Layer;\n private layer$: BehaviorSubject<Layer> = new BehaviorSubject(undefined);\n @Input()\n set layer(value: Layer) {\n this._layer = value;\n this.layer$.next(this._layer);\n }\n\n get layer(): Layer {\n return this._layer;\n }\n\n @Input() color: string = 'primary';\n\n constructor(private workspaceState: WorkspaceState) { }\n\n ngOnInit(): void {\n this.hasWorkspace$$ = combineLatest([this.workspaceState.workspaceEnabled$, this.layer$])\n .subscribe(bunch => this.hasWorkspace$.next(bunch[0] && bunch[1]?.options.workspace?.enabled)\n );\n }\n\n ngOnDestroy(): void {\n this.hasWorkspace$$.unsubscribe();\n }\n\n activateWorkspace() {\n if (\n this.workspaceState.workspace$.value &&\n (this.workspaceState.workspace$.value as any).layer.id === this.layer.id &&\n this.workspaceState.workspacePanelExpanded) {\n this.workspaceState.workspacePanelExpanded = false;\n } else {\n this.workspaceState.workspacePanelExpanded = true;\n this.workspaceState.setActiveWorkspaceById(this.layer.id);\n }\n }\n}\n","import { NgModule } from '@angular/core';\nimport { WorkspaceButtonComponent } from './workspace-button/workspace-button.component';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatTooltipModule } from '@angular/material/tooltip';\nimport { MatIconModule } from '@angular/material/icon';\nimport { IgoLanguageModule } from '@igo2/core';\nimport { CommonModule } from '@angular/common';\n\n@NgModule({\n imports: [\n CommonModule,\n MatIconModule,\n MatButtonModule,\n MatTooltipModule,\n IgoLanguageModule\n ],\n declarations: [WorkspaceButtonComponent],\n exports: [WorkspaceButtonComponent]\n})\nexport class IgoAppWorkspaceModule {}\n","<mat-tab-group *ngIf=\"importExportShowBothType\" >\n <mat-tab [label]=\"'igo.integration.importExportTool.importExportData' | translate\">\n <igo-import-export \n [map]=\"map\"\n [selectFirstProj]=\"selectFirstProj\"\n [projectionsLimitations]=\"projectionsLimitations\"\n [store]=\"workspaceStore\"\n [selectedMode]=\"importExportState.selectedMode$ | async\"\n (selectMode)=\"modeChanged($event)\"\n [exportOptions$]=\"importExportState.exportOptions$\"\n (exportOptionsChange)=\"exportOptionsChange($event)\">\n </igo-import-export>\n </mat-tab>\n <mat-tab [label]=\"'igo.integration.importExportTool.importExportContext' | translate\">\n <igo-context-import-export [map]=\"map\"></igo-context-import-export>\n </mat-tab>\n</mat-tab-group>\n\n<igo-import-export \n *ngIf=\"!importExportShowBothType && importExportType === 'layer'\"\n [map]=\"map\"\n [store]=\"workspaceStore\"\n [selectedMode]=\"importExportState.selectedMode$ | async\"\n (selectMode)=\"modeChanged($event)\"\n [exportOptions$]=\"importExportState.exportOptions$\"\n (exportOptionsChange)=\"exportOptionsChange($event)\">\n</igo-import-export>\n\n<igo-context-import-export \n *ngIf=\"!importExportShowBothType && importExportType === 'context'\"\n [map]=\"map\">\n</igo-context-import-export>","import { Component, ChangeDetectionStrategy, OnInit, Input } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\nimport type { WorkspaceStore } from '@igo2/common';\nimport { IgoMap, ExportOptions, ProjectionsLimitationsOptions } from '@igo2/geo';\n\nimport { MapState } from '../../map/map.state';\nimport { ImportExportMode, ImportExportState, ImportExportType } from '../import-export.state';\nimport { WorkspaceState } from '../../workspace/workspace.state';\n\n@ToolComponent({\n name: 'importExport',\n title: 'igo.integration.tools.importExport',\n icon: 'file-move'\n})\n@Component({\n selector: 'igo-import-export-tool',\n templateUrl: './import-export-tool.component.html',\n styleUrls: ['./import-export-tool.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class ImportExportToolComponent implements OnInit {\n\n @Input() projectionsLimitations: ProjectionsLimitationsOptions;\n\n @Input() selectFirstProj: boolean = false;\n\n /**\n * Map to measure on\n * @internal\n */\n get map(): IgoMap { return this.mapState.map; }\n\n get workspaceStore(): WorkspaceStore {\n return this.workspaceState.store;\n }\n\n @Input() importExportType: ImportExportType = ImportExportType.layer;\n @Input() importExportShowBothType: boolean = true;\n\n constructor(\n private mapState: MapState,\n public importExportState: ImportExportState,\n private workspaceState: WorkspaceState,\n ) {}\n\n ngOnInit(): void {\n this.selectType();\n this.selectMode();\n }\n\n private selectType() {\n if (this.importExportType) {\n this.importExportState.importExportType$.next(this.importExportType);\n }\n const userSelectedType = this.importExportState.importExportType$.value;\n if (userSelectedType !== undefined) {\n this.importExportState.setImportExportType(userSelectedType);\n } else {\n this.importExportState.setImportExportType(ImportExportType.layer);\n }\n }\n\n private selectMode() {\n const userSelectedMode = this.importExportState.selectedMode$.value;\n if (userSelectedMode !== undefined) {\n this.importExportState.setMode(userSelectedMode);\n } else {\n this.importExportState.setMode(ImportExportMode.import);\n\n }\n }\n\n public modeChanged(mode: ImportExportMode) {\n this.importExportState.setMode(mode);\n }\n\n public exportOptionsChange(exportOptions: ExportOptions) {\n this.importExportState.setsExportOptions(exportOptions);\n }\n\n importExportTypeChange(event) {\n this.importExportType = event.value;\n }\n}\n","import {\n NgModule,\n ModuleWithProviders,\n CUSTOM_ELEMENTS_SCHEMA\n} from '@angular/core';\n\nimport { IgoImportExportModule } from '@igo2/geo';\nimport { ImportExportToolComponent } from './import-export-tool/import-export-tool.component';\nimport { CommonModule } from '@angular/common';\nimport { MatButtonToggleModule } from '@angular/material/button-toggle';\nimport { MatTabsModule } from '@angular/material/tabs';\n\nimport { IgoLanguageModule } from '@igo2/core';\nimport { IgoContextImportExportModule } from '@igo2/context';\n\n@NgModule({\n imports: [\n IgoImportExportModule,\n IgoContextImportExportModule,\n CommonModule,\n IgoLanguageModule,\n MatButtonToggleModule,\n MatTabsModule\n ],\n declarations: [ImportExportToolComponent],\n exports: [ImportExportToolComponent],\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\n})\nexport class IgoAppImportExportModule {\n static forRoot(): ModuleWithProviders<IgoAppImportExportModule> {\n return {\n ngModule: IgoAppImportExportModule,\n providers: []\n };\n }\n}\n","<igo-layer-list class=\"mapDetailsList\" *ngIf=\"(layers$ | async).length; else empty\"\n [map]=\"map\"\n igoLayerListBinding\n [excludeBaseLayers]=\"excludeBaseLayers\"\n [layerFilterAndSortOptions]=\"layerFilterAndSortOptions\"\n [expandLegendOfVisibleLayers]=\"expandLegendOfVisibleLayers\"\n [toggleLegendOnVisibilityChange]=\"toggleLegendOnVisibilityChange\"\n [updateLegendOnResolutionChange]=\"updateLegendOnResolutionChange\"\n floatLabel=\"never\"\n [queryBadge]=\"queryBadge\">\n\n <ng-template #igoLayerItemToolbar let-layer=\"layer\">\n <!-- <igo-download-button [layer]=\"layer\"></igo-download-button> -->\n <igo-workspace-button [layer]=\"layer\"></igo-workspace-button>\n <igo-export-button [layer]=\"layer\" (click)=\"activateExport(layer)\"></igo-export-button>\n <igo-ogc-filter-button [header]=\"ogcButton\" [layer]=\"layer\"></igo-ogc-filter-button>\n <igo-time-filter-button [header]=\"timeButton\" [layer]=\"layer\"></igo-time-filter-button>\n <igo-track-feature-button [trackFeature]=\"true\" [layer]=\"layer\"></igo-track-feature-button>\n <igo-metadata-button [layer]=\"layer\"></igo-metadata-button>\n </ng-template>\n\n</igo-layer-list>\n\n<ng-template #empty>\n <mat-list *ngIf=\"delayedShowEmptyMapContent\">\n <p class=\"map-empty mat-typography\">\n {{'igo.integration.mapTool.empty' | translate}}</p>\n <p *ngIf=\"layerAdditionAllowed && (searchToolInToolbar || catalogToolInToolbar || contextToolInToolbar)\" class=\"map-empty mat-typography\">\n {{'igo.integration.mapTool.customize' | translate}}</p>\n <mat-list-item *ngIf=\"layerAdditionAllowed && searchToolInToolbar\">\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%' preserveAspectRatio='xMidYMid meet' focusable='false'> <path d='M9.5,3A6.5,6.5 0 0,1 16,9.5C16,11.11 15.41,12.59 14.44,13.73L14.71,14H15.5L20.5,19L19,20.5L14,15.5V14.71L13.73,14.44C12.59,15.41 11.11,16 9.5,16A6.5,6.5 0 0,1 3,9.5A6.5,6.5 0 0,1 9.5,3M9.5,5C7,5 5,7 5,9.5C5,12 7,14 9.5,14C12,14 14,12 14,9.5C14,7 12,5 9.5,5Z'> </path> </svg></mat-icon>\n <h4 matLine class=\"search-tool mat-typography\" (click)=\"searchEmit()\">\n {{'igo.integration.mapTool.search-tool' | translate}}\n </h4>\n </mat-list-item>\n <mat-list-item *ngIf=\"layerAdditionAllowed && catalogToolInToolbar\">\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%' preserveAspectRatio='xMidYMid meet' focusable='false'> <path d='M17,14H19V17H22V19H19V22H17V19H14V17H17V14M11,16L2,9L11,2L20,9L11,16M11,18.54L12,17.75V18C12,18.71 12.12,19.39 12.35,20L11,21.07L2,14.07L3.62,12.81L11,18.54Z'></path> </svg></mat-icon>\n <h4 matLine class=\"catalog-tool mat-typography\" (click)=\"catalogEmit()\">\n {{'igo.integration.mapTool.catalog-tool' | translate}}\n </h4>\n </mat-list-item>\n <mat-list-item *ngIf=\"layerAdditionAllowed && contextToolInToolbar\">\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%' preserveAspectRatio='xMidYMid meet' focusable='false'> <path d='M12,17.27L18.18,21L16.54,13.97L22,9.24L14.81,8.62L12,2L9.19,8.62L2,9.24L7.45,13.97L5.82,21L12,17.27Z'></path> </svg></mat-icon>\n <h4 matLine class=\"context-tool mat-typography\" (click)=\"contextEmit()\">\n {{'igo.integration.mapTool.context-tool' | translate}}\n </h4>\n </mat-list-item>\n </mat-list>\n</ng-template>\n","import { Component, Input, OnInit, ChangeDetectorRef } from '@angular/core';\nimport { Observable } from 'rxjs';\nimport { map } from 'rxjs/operators';\n\nimport { ToolComponent } from '@igo2/common';\nimport {\n LayerListControlsEnum,\n Layer,\n IgoMap,\n LayerListControlsOptions,\n SearchSourceService,\n sourceCanSearch,\n ExportOptions\n} from '@igo2/geo';\n\nimport { ToolState } from './../../tool/tool.state';\nimport { MapState } from './../map.state';\nimport { ImportExportMode, ImportExportState } from '../../import-export/import-export.state';\n\n@ToolComponent({\n name: 'mapDetails',\n title: 'igo.integration.tools.map',\n icon: 'map'\n})\n@Component({\n selector: 'igo-map-details-tool',\n templateUrl: './map-details-tool.component.html',\n styleUrls: ['./map-details-tool.component.scss']\n})\nexport class MapDetailsToolComponent implements OnInit {\n public delayedShowEmptyMapContent: boolean = false;\n\n @Input() toggleLegendOnVisibilityChange: boolean = false;\n\n @Input() expandLegendOfVisibleLayers: boolean = false;\n\n @Input() updateLegendOnResolutionChange: boolean = false;\n\n @Input() ogcButton: boolean = true;\n\n @Input() timeButton: boolean = true;\n\n @Input() layerListControls: LayerListControlsOptions = {};\n\n @Input() queryBadge: boolean = false;\n\n @Input() layerAdditionAllowed: boolean = true;\n\n get map(): IgoMap {\n return this.mapState.map;\n }\n\n get layers$(): Observable<Layer[]> {\n return this.map.layers$.pipe(\n map((layers) =>\n layers.filter(\n (layer) =>\n layer.showInLayerList !== false &&\n (!this.excludeBaseLayers || !layer.baseLayer)\n )\n )\n );\n }\n\n get excludeBaseLayers(): boolean {\n return this.layerListControls.excludeBaseLayers || false;\n }\n\n get layerFilterAndSortOptions(): any {\n const filterSortOptions = Object.assign(\n {\n showToolbar: LayerListControlsEnum.default\n },\n this.layerListControls\n );\n\n switch (this.layerListControls.showToolbar) {\n case LayerListControlsEnum.always:\n filterSortOptions.showToolbar = LayerListControlsEnum.always;\n break;\n case LayerListControlsEnum.never:\n filterSortOptions.showToolbar = LayerListControlsEnum.never;\n break;\n default:\n break;\n }\n return filterSortOptions;\n }\n\n get searchToolInToolbar(): boolean {\n return (\n this.toolState.toolbox.getToolbar().indexOf('searchResults') !== -1 &&\n this.searchSourceService\n .getSources()\n .filter(sourceCanSearch)\n .filter((s) => s.available && s.getType() === 'Layer').length > 0\n );\n }\n\n get catalogToolInToolbar(): boolean {\n return this.toolState.toolbox.getToolbar().indexOf('catalog') !== -1;\n }\n\n get contextToolInToolbar(): boolean {\n return this.toolState.toolbox.getToolbar().indexOf('contextManager') !== -1;\n }\n\n constructor(\n private mapState: MapState,\n private toolState: ToolState,\n private searchSourceService: SearchSourceService,\n private cdRef: ChangeDetectorRef,\n private importExportState: ImportExportState\n ) {}\n\n ngOnInit(): void {\n // prevent message to be shown too quickly. Waiting for layers\n setTimeout(() => {\n this.delayedShowEmptyMapContent = true;\n this.cdRef.detectChanges();\n }, 250);\n }\n\n searchEmit() {\n this.toolState.toolbox.activateTool('searchResults');\n }\n\n catalogEmit() {\n this.toolState.toolbox.activateTool('catalog');\n }\n\n contextEmit() {\n this.toolState.toolbox.activateTool('contextManager');\n }\n\n activateExport(layer: Layer) {\n let id = layer.id;\n if (layer.options.workspace?.workspaceId) {\n id = layer.options.workspace.workspaceId !== layer.id ? layer.options.workspace.workspaceId : layer.id;\n }\n this.importExportState.setsExportOptions({ layers: [id] } as ExportOptions);\n this.importExportState.setMode(ImportExportMode.export);\n this.toolState.toolbox.activateTool('importExport');\n }\n}\n","<mat-tab-group>\n\n <mat-tab [label]=\"'igo.integration.tools.map' | translate\">\n <igo-layer-list\n [map]=\"map\"\n igoLayerListBinding\n [excludeBaseLayers]=\"excludeBaseLayers\"\n [layerFilterAndSortOptions]=\"layerFilterAndSortOptions\"\n [expandLegendOfVisibleLayers]=\"expandLegendOfVisibleLayers\"\n [toggleLegendOnVisibilityChange]=\"toggleLegendOnVisibilityChange\"\n [updateLegendOnResolutionChange]=\"updateLegendOnResolutionChange\"\n [floatLabel]=\"false\"\n [queryBadge]=\"queryBadge\">\n\n <ng-template #igoLayerItemToolbar let-layer=\"layer\">\n <!-- <igo-download-button [layer]=\"layer\"></igo-download-button> -->\n <igo-workspace-button [layer]=\"layer\"></igo-workspace-button>\n <igo-export-button [layer]=\"layer\" (click)=\"activateExport(layer)\"></igo-export-button>\n <igo-ogc-filter-button [header]=\"ogcButton\" [layer]=\"layer\"></igo-ogc-filter-button>\n <igo-time-filter-button [header]=\"timeButton\" [layer]=\"layer\"></igo-time-filter-button>\n <igo-track-feature-button [trackFeature]=\"true\" [layer]=\"layer\"></igo-track-feature-button>\n <igo-metadata-button [layer]=\"layer\"></igo-metadata-button>\n </ng-template>\n\n </igo-layer-list>\n </mat-tab>\n\n <mat-tab [label]=\"'igo.integration.tools.contexts' | translate\">\n <igo-context-list igoContextListBinding></igo-context-list>\n </mat-tab>\n\n</mat-tab-group>\n","import { Component, ChangeDetectionStrategy, Input } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\nimport {\n LayerListControlsEnum,\n LayerListControlsOptions,\n IgoMap,\n ExportOptions,\n Layer\n} from '@igo2/geo';\nimport { MapState } from './../map.state';\nimport { ImportExportMode, ImportExportState } from '../../import-export/import-export.state';\nimport { ToolState } from '../../tool/tool.state';\n\n/**\n * Tool to browse a map's layers or to choose a different map\n */\n@ToolComponent({\n name: 'map',\n title: 'igo.integration.tools.map',\n icon: 'map'\n})\n@Component({\n selector: 'igo-map-tool',\n templateUrl: './map-tool.component.html',\n styleUrls: ['./map-tool.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class MapToolComponent {\n @Input() toggleLegendOnVisibilityChange: boolean = false;\n\n @Input() expandLegendOfVisibleLayers: boolean = false;\n\n @Input() updateLegendOnResolutionChange: boolean = false;\n\n @Input() ogcButton: boolean = true;\n\n @Input() timeButton: boolean = true;\n\n @Input() layerListControls: LayerListControlsOptions = {};\n\n @Input() queryBadge: boolean = false;\n\n get map(): IgoMap {\n return this.mapState.map;\n }\n\n get excludeBaseLayers(): boolean {\n return this.layerListControls.excludeBaseLayers || false;\n }\n\n get layerFilterAndSortOptions(): any {\n const filterSortOptions = Object.assign(\n {\n showToolbar: LayerListControlsEnum.default\n },\n this.layerListControls\n );\n\n switch (this.layerListControls.showToolbar) {\n case LayerListControlsEnum.always:\n filterSortOptions.showToolbar = LayerListControlsEnum.always;\n break;\n case LayerListControlsEnum.never:\n filterSortOptions.showToolbar = LayerListControlsEnum.never;\n break;\n default:\n break;\n }\n return filterSortOptions;\n }\n\n constructor(\n private mapState: MapState,\n private toolState: ToolState,\n private importExportState: ImportExportState\n ) {}\n\n activateExport(layer: Layer) {\n let id = layer.id;\n if (layer.options.workspace?.workspaceId) {\n id = layer.options.workspace.workspaceId !== layer.id ? layer.options.workspace.workspaceId : layer.id;\n }\n this.importExportState.setsExportOptions({ layers: [id] } as ExportOptions);\n this.importExportState.setMode(ImportExportMode.export);\n this.toolState.toolbox.activateTool('importExport');\n }\n}\n","<mat-tab-group\n #tabGroup\n [selectedIndex]=\"layerListToolState.selectedTab$ | async\"\n (selectedTabChange)=\"tabChanged($event)\">\n\n <mat-tab [label]=\"'igo.integration.tools.layers' | translate\">\n <igo-layer-list *ngIf=\"(layers$ | async).length !== 0; else emptyLayers\"\n igoLayerListBinding\n [excludeBaseLayers]=\"excludeBaseLayers\"\n [layerFilterAndSortOptions]=\"layerFilterAndSortOptions\"\n [expandLegendOfVisibleLayers]=\"expandLegendOfVisibleLayers\"\n [toggleLegendOnVisibilityChange]=\"toggleLegendOnVisibilityChange\"\n [updateLegendOnResolutionChange]=\"updateLegendOnResolutionChange\"\n [floatLabel]=\"false\"\n [queryBadge]=\"queryBadge\"\n [map]=\"map\"\n (appliedFilterAndSort)= onLayerListChange($event)>\n\n <ng-template #igoLayerItemToolbar let-layer=\"layer\">\n <igo-metadata-button [layer]=\"layer\"></igo-metadata-button>\n <igo-track-feature-button [trackFeature]=\"true\" [layer]=\"layer\"></igo-track-feature-button>\n <igo-time-filter-button *ngIf=\"isTimeFilterButton(layer)\" [header]=\"timeButton\" [layer]=\"layer\"\n (click)=\"activateTimeFilter()\"></igo-time-filter-button>\n <igo-ogc-filter-button *ngIf=\"isOGCFilterButton(layer)\" [header]=\"ogcButton\" [layer]=\"layer\"\n (click)=\"activateOgcFilter()\"></igo-ogc-filter-button>\n <igo-export-button *ngIf=\"isExportButton(layer)\" [layer]=\"layer\" (click)=\"activateExport(layer)\"></igo-export-button>\n <igo-workspace-button [layer]=\"layer\"></igo-workspace-button>\n </ng-template>\n </igo-layer-list>\n </mat-tab>\n\n <mat-tab [label]=\"'igo.integration.tools.legend' | translate\">\n <igo-layer-legend-list *ngIf=\"showAllLegend()\"\n igoLayerLegendListBinding\n [allowShowAllLegends]=\"allowShowAllLegends\"\n [showAllLegendsValue]=\"(showAllLegendsValue$ | async)\"\n (allLegendsShown)=\"onShowAllLegends($event)\"\n [excludeBaseLayers]=\"excludeBaseLayers\"\n [updateLegendOnResolutionChange]=\"updateLegendOnResolutionChange\">\n </igo-layer-legend-list>\n <ng-template *ngIf=\"(layers$ | async).length !== 0; else emptyLayers\"></ng-template>\n\n <p class=\"map-empty mat-typography\"\n *ngIf=\"!allowShowAllLegends && (layers$ | async).length !== 0 && (visibleOrInRangeLayers$ | async).length === 0\">\n {{ ((visibleLayers$ | async).length) ? ('igo.integration.mapTool.noLayersInRange' | translate) : ('igo.integration.mapTool.noLayersVisible' | translate) }}\n </p>\n </mat-tab>\n\n <ng-template #emptyLayers>\n <mat-list *ngIf=\"delayedShowEmptyMapContent\">\n <p class=\"map-empty mat-typography\">\n {{'igo.integration.mapTool.empty' | translate}}</p>\n <p *ngIf=\"layerAdditionAllowed && (searchToolInToolbar || catalogToolInToolbar || contextToolInToolbar)\"\n class=\"map-empty mat-typography\">\n {{'igo.integration.mapTool.customize' | translate}}</p>\n\n <mat-list-item *ngIf=\"layerAdditionAllowed && searchToolInToolbar\">\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%'\n preserveAspectRatio='xMidYMid meet' focusable='false'>\n <path\n d='M9.5,3A6.5,6.5 0 0,1 16,9.5C16,11.11 15.41,12.59 14.44,13.73L14.71,14H15.5L20.5,19L19,20.5L14,15.5V14.71L13.73,14.44C12.59,15.41 11.11,16 9.5,16A6.5,6.5 0 0,1 3,9.5A6.5,6.5 0 0,1 9.5,3M9.5,5C7,5 5,7 5,9.5C5,12 7,14 9.5,14C12,14 14,12 14,9.5C14,7 12,5 9.5,5Z'>\n </path>\n </svg></mat-icon>\n <h4 matLine class=\"search-tool mat-typography\" (click)=\"searchEmit()\">\n {{'igo.integration.mapTool.search-tool' | translate}}\n </h4>\n </mat-list-item>\n <mat-list-item *ngIf=\"layerAdditionAllowed && catalogToolInToolbar\">\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%'\n preserveAspectRatio='xMidYMid meet' focusable='false'>\n <path\n d='M17,14H19V17H22V19H19V22H17V19H14V17H17V14M11,16L2,9L11,2L20,9L11,16M11,18.54L12,17.75V18C12,18.71 12.12,19.39 12.35,20L11,21.07L2,14.07L3.62,12.81L11,18.54Z'>\n </path>\n </svg></mat-icon>\n <h4 matLine class=\"catalog-tool mat-typography\" (click)=\"catalogEmit()\">\n {{'igo.integration.mapTool.catalog-tool' | translate}}\n </h4>\n </mat-list-item>\n <mat-list-item *ngIf=\"layerAdditionAllowed && contextToolInToolbar\">\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%'\n preserveAspectRatio='xMidYMid meet' focusable='false'>\n <path\n d='M12,17.27L18.18,21L16.54,13.97L22,9.24L14.81,8.62L12,2L9.19,8.62L2,9.24L7.45,13.97L5.82,21L12,17.27Z'>\n </path>\n </svg></mat-icon>\n <h4 matLine class=\"context-tool mat-typography\" (click)=\"contextEmit()\">\n {{'igo.integration.mapTool.context-tool' | translate}}\n </h4>\n </mat-list-item>\n </mat-list>\n </ng-template>\n</mat-tab-group>\n","import {\n Component,\n ChangeDetectionStrategy,\n Input,\n OnInit,\n ViewChild,\n OnDestroy\n} from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\nimport {\n LayerListControlsEnum,\n LayerListControlsOptions,\n IgoMap,\n SearchSourceService,\n sourceCanSearch,\n Layer,\n ExportOptions,\n VectorLayer\n} from '@igo2/geo';\n\nimport { LayerListToolState } from '../layer-list-tool.state';\nimport { MatTabChangeEvent } from '@angular/material/tabs';\nimport { ToolState } from '../../tool/tool.state';\nimport { MapState } from '../map.state';\nimport { BehaviorSubject, Observable, Subscription, combineLatest } from 'rxjs';\nimport { map, debounceTime } from 'rxjs/operators';\nimport { ImportExportMode, ImportExportState } from '../../import-export/import-export.state';\n/**\n * Tool to browse a map's layers or to choose a different map\n */\n@ToolComponent({\n name: 'mapTools',\n title: 'igo.integration.tools.map',\n icon: 'map'\n})\n@Component({\n selector: 'igo-map-tools',\n templateUrl: './map-tools.component.html',\n styleUrls: ['./map-tools.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class MapToolsComponent implements OnInit, OnDestroy {\n layers$: BehaviorSubject<Layer[]> = new BehaviorSubject([]);\n showAllLegendsValue$: BehaviorSubject<boolean> = new BehaviorSubject(false);\n\n private resolution$$: Subscription;\n private visibleOrInRangeLayers$$: Subscription;\n public delayedShowEmptyMapContent: boolean = false;\n\n @Input() allowShowAllLegends: boolean = false;\n\n @Input() showAllLegendsValue: boolean = false;\n\n @Input() toggleLegendOnVisibilityChange: boolean = false;\n\n @Input() expandLegendOfVisibleLayers: boolean = false;\n\n @Input() updateLegendOnResolutionChange: boolean = false;\n\n @Input() selectedTabAtOpening: string;\n\n @Input() ogcButton: boolean = true;\n\n @Input() timeButton: boolean = true;\n\n @Input() layerAdditionAllowed: boolean = true;\n\n @Input()\n get layerListControls(): LayerListControlsOptions {\n return this._layerListControls;\n }\n set layerListControls(value: LayerListControlsOptions) {\n const stateOptions = this.layerListToolState.getLayerListControls();\n const stateKeyword = stateOptions.keyword;\n const stateOnlyVisible = stateOptions.onlyVisible;\n const stateSortAlpha = stateOptions.sortAlpha;\n\n value.keyword = stateKeyword !== '' ? stateKeyword : value.keyword;\n value.onlyVisible =\n stateOnlyVisible !== undefined ? stateOnlyVisible : value.onlyVisible;\n value.sortAlpha =\n stateSortAlpha !== undefined ? stateSortAlpha : value.sortAlpha;\n\n value.onlyVisible =\n value.onlyVisible === undefined ? false : value.onlyVisible;\n value.sortAlpha = value.sortAlpha === undefined ? false : value.sortAlpha;\n\n this._layerListControls = value;\n }\n private _layerListControls = {};\n\n get map(): IgoMap {\n return this.mapState.map;\n }\n\n @Input() queryBadge: boolean = false;\n\n get visibleOrInRangeLayers$(): Observable<Layer[]> {\n return this.layers$.pipe(\n map((layers) =>\n layers.filter(\n (layer) => layer.visible$.value && layer.isInResolutionsRange$.value\n )\n )\n );\n }\n\n get visibleLayers$(): Observable<Layer[]> {\n return this.layers$.pipe(\n map((layers) => layers.filter((layer) => layer.visible$.value))\n );\n }\n\n get excludeBaseLayers(): boolean {\n return this.layerListControls.excludeBaseLayers || false;\n }\n\n get layerFilterAndSortOptions(): LayerListControlsOptions {\n const filterSortOptions = Object.assign(\n {\n showToolbar: LayerListControlsEnum.default\n },\n this.layerListControls\n );\n\n switch (this.layerListControls.showToolbar) {\n case LayerListControlsEnum.always:\n filterSortOptions.showToolbar = LayerListControlsEnum.always;\n break;\n case LayerListControlsEnum.never:\n filterSortOptions.showToolbar = LayerListControlsEnum.never;\n break;\n default:\n break;\n }\n return filterSortOptions;\n }\n\n @ViewChild('tabGroup', { static: true }) tabGroup;\n\n get searchToolInToolbar(): boolean {\n return (\n this.toolState.toolbox.getToolbar().indexOf('searchResults') !== -1 &&\n this.searchSourceService\n .getSources()\n .filter(sourceCanSearch)\n .filter((s) => s.available && s.getType() === 'Layer').length > 0\n );\n }\n\n get catalogToolInToolbar(): boolean {\n return this.toolState.toolbox.getToolbar().indexOf('catalog') !== -1;\n }\n\n get contextToolInToolbar(): boolean {\n return this.toolState.toolbox.getToolbar().indexOf('contextManager') !== -1;\n }\n\n constructor(\n public layerListToolState: LayerListToolState,\n private toolState: ToolState,\n public mapState: MapState,\n private searchSourceService: SearchSourceService,\n private importExportState: ImportExportState\n ) {}\n\n ngOnInit(): void {\n this.selectedTab();\n this.resolution$$ = combineLatest([\n this.map.layers$,\n this.map.viewController.resolution$\n ])\n .pipe(debounceTime(10))\n .subscribe((bunch: [Layer[], number]) => {\n this.layers$.next(\n bunch[0].filter(\n (layer) =>\n layer.showInLayerList !== false &&\n (!this.excludeBaseLayers || !layer.baseLayer)\n )\n );\n });\n\n if (this.allowShowAllLegends) {\n this.mapState.showAllLegendsValue =\n this.mapState.showAllLegendsValue !== undefined\n ? this.mapState.showAllLegendsValue\n : this.showAllLegendsValue || false;\n this.showAllLegendsValue$.next(this.mapState.showAllLegendsValue);\n } else {\n this.showAllLegendsValue$.next(false);\n }\n\n // prevent message to be shown too quickly. Waiting for layers\n setTimeout(() => (this.delayedShowEmptyMapContent = true), 250);\n }\n\n ngOnDestroy(): void {\n this.resolution$$.unsubscribe();\n if (this.visibleOrInRangeLayers$$) {\n this.visibleOrInRangeLayers$$.unsubscribe();\n }\n }\n\n onShowAllLegends(event) {\n this.mapState.showAllLegendsValue = event;\n this.showAllLegendsValue$.next(event);\n }\n\n private selectedTab() {\n const userSelectedTab = this.layerListToolState.selectedTab$.value;\n if (userSelectedTab !== undefined) {\n this.layerListToolState.setSelectedTab(userSelectedTab);\n } else {\n if (this.selectedTabAtOpening === 'legend') {\n this.layerListToolState.setSelectedTab(1);\n } else {\n this.layerListToolState.setSelectedTab(0);\n }\n }\n }\n\n public tabChanged(tab: MatTabChangeEvent) {\n this.layerListToolState.setSelectedTab(tab.index);\n this.layers$.next(\n this.map.layers.filter(\n (layer) =>\n layer.showInLayerList !== false &&\n (!this.excludeBaseLayers || !layer.baseLayer)\n )\n );\n }\n\n onLayerListChange(appliedFilters: LayerListControlsOptions) {\n this.layerListToolState.setKeyword(appliedFilters.keyword);\n this.layerListToolState.setSortAlpha(appliedFilters.sortAlpha);\n this.layerListToolState.setOnlyVisible(appliedFilters.onlyVisible);\n }\n\n showAllLegend() {\n if (this.layers$.getValue().length === 0) {\n return false;\n } else if (\n this.layers$.getValue().length !== 0 &&\n this.allowShowAllLegends === false\n ) {\n let visibleOrInRangeLayers;\n this.visibleOrInRangeLayers$$ = this.visibleOrInRangeLayers$.subscribe((value) => {\n value.length === 0\n ? (visibleOrInRangeLayers = false)\n : (visibleOrInRangeLayers = true);\n });\n\n if (visibleOrInRangeLayers === false) {\n return false;\n }\n }\n return true;\n }\n\n activateExport(layer: Layer) {\n let id = layer.id;\n if (layer.options.workspace?.workspaceId) {\n id = layer.options.workspace.workspaceId !== layer.id ? layer.options.workspace.workspaceId : layer.id;\n }\n this.importExportState.setsExportOptions({ layers: [id] } as ExportOptions);\n this.importExportState.setMode(ImportExportMode.export);\n this.toolState.toolbox.activateTool('importExport');\n }\n\n activateTimeFilter() {\n this.toolState.toolbox.activateTool('activeTimeFilter');\n }\n\n activateOgcFilter() {\n this.toolState.toolbox.activateTool('activeOgcFilter');\n }\n\n searchEmit() {\n this.toolState.toolbox.activateTool('searchResults');\n }\n\n catalogEmit() {\n this.toolState.toolbox.activateTool('catalog');\n }\n\n contextEmit() {\n this.toolState.toolbox.activateTool('contextManager');\n }\n\n isTimeFilterButton(layer): boolean {\n const options = layer.dataSource.options;\n return this.timeButton && options.timeFilterable && options.timeFilter;\n }\n\n isOGCFilterButton(layer): boolean {\n const options = layer.dataSource.options;\n return this.ogcButton && options.ogcFilters && options.ogcFilters.enabled &&\n (options.ogcFilters.pushButtons || options.ogcFilters.checkboxes || options.ogcFilters.radioButtons\n || options.ogcFilters.select || options.ogcFilters.editable);\n }\n\n isExportButton(layer: Layer): boolean {\n if (\n (layer instanceof VectorLayer && layer.exportable === true) ||\n (layer.dataSource.options.download && layer.dataSource.options.download.url) ||\n (layer.options.workspace?.enabled && layer.options.workspace?.workspaceId !== layer.id))\n {\n return true;\n }\n return false;\n }\n}\n","<igo-layer-legend-list *ngIf=\"showAllLegend()\"\n igoLayerLegendListBinding\n [excludeBaseLayers]=\"excludeBaseLayers\"\n [allowShowAllLegends]=\"allowShowAllLegends\"\n [updateLegendOnResolutionChange]=\"updateLegendOnResolutionChange\"\n [showAllLegendsValue]=\"(showAllLegendsValue$ | async)\"\n (allLegendsShown)=\"onShowAllLegends($event)\">\n</igo-layer-legend-list>\n<ng-template *ngIf=\"(layers$ | async).length !== 0; else emptyLayers\"></ng-template>\n\n<p class=\"map-empty mat-typography\"\n *ngIf=\"!allowShowAllLegends && (layers$ | async).length !== 0 && (visibleOrInRangeLayers$ | async).length === 0\">\n {{ ((visibleLayers$ | async).length) ? ('igo.integration.mapTool.noLayersInRange' | translate) : ('igo.integration.mapTool.noLayersVisible' | translate) }}\n</p>\n\n\n<ng-template #emptyLayers>\n <mat-list *ngIf=\"delayedShowEmptyMapContent\">\n <p class=\"map-empty mat-typography\">\n {{'igo.integration.mapTool.empty' | translate}}</p>\n <p *ngIf=\"layerAdditionAllowed && (searchToolInToolbar || catalogToolInToolbar || contextToolInToolbar)\" class=\"map-empty mat-typography\">\n {{'igo.integration.mapTool.customize' | translate}}</p>\n\n <mat-list-item *ngIf=\"layerAdditionAllowed && searchToolInToolbar\">\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%' preserveAspectRatio='xMidYMid meet' focusable='false'> <path d='M9.5,3A6.5,6.5 0 0,1 16,9.5C16,11.11 15.41,12.59 14.44,13.73L14.71,14H15.5L20.5,19L19,20.5L14,15.5V14.71L13.73,14.44C12.59,15.41 11.11,16 9.5,16A6.5,6.5 0 0,1 3,9.5A6.5,6.5 0 0,1 9.5,3M9.5,5C7,5 5,7 5,9.5C5,12 7,14 9.5,14C12,14 14,12 14,9.5C14,7 12,5 9.5,5Z'> </path> </svg></mat-icon>\n <h4 matLine class=\"search-tool mat-typography\" (click)=\"searchEmit()\">\n {{'igo.integration.mapTool.search-tool' | translate}}\n </h4>\n </mat-list-item>\n <mat-list-item *ngIf=\"layerAdditionAllowed && catalogToolInToolbar\">\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%' preserveAspectRatio='xMidYMid meet' focusable='false'> <path d='M17,14H19V17H22V19H19V22H17V19H14V17H17V14M11,16L2,9L11,2L20,9L11,16M11,18.54L12,17.75V18C12,18.71 12.12,19.39 12.35,20L11,21.07L2,14.07L3.62,12.81L11,18.54Z'></path> </svg></mat-icon>\n <h4 matLine class=\"catalog-tool mat-typography\" (click)=\"catalogEmit()\">\n {{'igo.integration.mapTool.catalog-tool' | translate}}\n </h4>\n </mat-list-item>\n <mat-list-item *ngIf=\"layerAdditionAllowed && contextToolInToolbar\">\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%' preserveAspectRatio='xMidYMid meet' focusable='false'> <path d='M12,17.27L18.18,21L16.54,13.97L22,9.24L14.81,8.62L12,2L9.19,8.62L2,9.24L7.45,13.97L5.82,21L12,17.27Z'></path> </svg></mat-icon>\n <h4 matLine class=\"context-tool mat-typography\" (click)=\"contextEmit()\">\n {{'igo.integration.mapTool.context-tool' | translate}}\n </h4>\n </mat-list-item>\n </mat-list>\n</ng-template>\n","import {\n Component,\n Input,\n OnInit,\n OnDestroy,\n ChangeDetectorRef\n} from '@angular/core';\nimport { Observable, Subscription, BehaviorSubject, ReplaySubject, combineLatest } from 'rxjs';\nimport { map, debounceTime } from 'rxjs/operators';\n\nimport { ToolComponent } from '@igo2/common';\nimport {\n Layer,\n IgoMap,\n LayerListControlsOptions,\n SearchSourceService,\n sourceCanSearch\n} from '@igo2/geo';\n\nimport { ToolState } from './../../tool/tool.state';\nimport { MapState } from './../map.state';\n\n@ToolComponent({\n name: 'mapLegend',\n title: 'igo.integration.tools.legend',\n icon: 'format-list-bulleted-type'\n})\n@Component({\n selector: 'igo-map-legend-tool',\n templateUrl: './map-legend-tool.component.html',\n styleUrls: ['./map-legend-tool.component.scss']\n})\nexport class MapLegendToolComponent implements OnInit, OnDestroy {\n public delayedShowEmptyMapContent: boolean = false;\n\n layers$: BehaviorSubject<Layer[]> = new BehaviorSubject([]);\n showAllLegendsValue$: BehaviorSubject<boolean> = new BehaviorSubject(false);\n change$ = new ReplaySubject<void>(1);\n\n private resolution$$: Subscription;\n private visibleOrInRangeLayers$$: Subscription;\n\n @Input() updateLegendOnResolutionChange: boolean = false;\n\n @Input() layerAdditionAllowed: boolean = true;\n\n @Input() allowShowAllLegends: boolean = false;\n\n @Input() showAllLegendsValue: boolean = false;\n\n @Input() layerListControls: LayerListControlsOptions = {};\n\n get map(): IgoMap {\n return this.mapState.map;\n }\n\n get visibleOrInRangeLayers$(): Observable<Layer[]> {\n return this.layers$.pipe(\n map(layers =>\n layers.filter(\n layer => layer.visible$.value && layer.isInResolutionsRange$.value\n )\n )\n );\n }\n\n get visibleLayers$(): Observable<Layer[]> {\n return this.layers$.pipe(\n map(layers => layers.filter(layer => layer.visible$.value))\n );\n }\n\n get excludeBaseLayers(): boolean {\n return this.layerListControls.excludeBaseLayers || false;\n }\n\n get searchToolInToolbar(): boolean {\n return (\n this.toolState.toolbox.getToolbar().indexOf('searchResults') !== -1 &&\n this.searchSourceService\n .getSources()\n .filter(sourceCanSearch)\n .filter(s => s.available && s.getType() === 'Layer').length > 0\n );\n }\n\n get catalogToolInToolbar(): boolean {\n return this.toolState.toolbox.getToolbar().indexOf('catalog') !== -1;\n }\n\n get contextToolInToolbar(): boolean {\n return this.toolState.toolbox.getToolbar().indexOf('contextManager') !== -1;\n }\n constructor(\n private mapState: MapState,\n private toolState: ToolState,\n private searchSourceService: SearchSourceService,\n private cdRef: ChangeDetectorRef\n ) {}\n\n ngOnInit(): void {\n this.resolution$$ = combineLatest([\n this.map.layers$,\n this.map.viewController.resolution$\n ])\n .pipe(debounceTime(10))\n .subscribe((bunch: [Layer[], number]) => {\n this.layers$.next(\n bunch[0].filter(\n layer =>\n layer.showInLayerList !== false &&\n (!this.excludeBaseLayers || !layer.baseLayer)\n )\n );\n });\n\n if (this.allowShowAllLegends) {\n this.mapState.showAllLegendsValue =\n this.mapState.showAllLegendsValue !== undefined\n ? this.mapState.showAllLegendsValue\n : this.showAllLegendsValue || false;\n this.showAllLegendsValue$.next(this.mapState.showAllLegendsValue);\n } else {\n this.showAllLegendsValue$.next(false);\n }\n\n // prevent message to be shown too quickly. Waiting for layers\n setTimeout(() => {\n this.delayedShowEmptyMapContent = true;\n this.cdRef.detectChanges();\n }, 250);\n }\n\n onShowAllLegends(event) {\n this.mapState.showAllLegendsValue = event;\n this.showAllLegendsValue$.next(event);\n }\n\n showAllLegend() {\n if (this.layers$.getValue().length === 0) {\n return false;\n } else if (\n this.layers$.getValue().length !== 0 &&\n this.allowShowAllLegends === false\n ) {\n let visibleOrInRangeLayers;\n this.visibleOrInRangeLayers$$ = this.visibleOrInRangeLayers$.subscribe(value => {\n value.length === 0\n ? (visibleOrInRangeLayers = false)\n : (visibleOrInRangeLayers = true);\n });\n\n if (visibleOrInRangeLayers === false) {\n return false;\n }\n }\n return true;\n }\n\n ngOnDestroy(): void {\n this.resolution$$.unsubscribe();\n if (this.visibleOrInRangeLayers$$) {\n this.visibleOrInRangeLayers$$.unsubscribe();\n }\n }\n\n searchEmit() {\n this.toolState.toolbox.activateTool('searchResults');\n }\n\n catalogEmit() {\n this.toolState.toolbox.activateTool('catalog');\n }\n\n contextEmit() {\n this.toolState.toolbox.activateTool('contextManager');\n }\n}\n","<div *ngIf=\"userControlledLayerList.length; else noLayersBlock\" class=\"igo-swipe-select-container\">\n <form class=\"igo-form\" [formGroup]=\"form\">\n <mat-form-field>\n <mat-label>{{'igo.integration.advanced-map-tool.advanced-swipe.swipe-select' | translate}}</mat-label>\n <mat-select formControlName=\"layers\" multiple>\n <mat-option [value]=\"1\" (click)=\"selectAll(e)\" #e>\n {{'igo.integration.advanced-map-tool.advanced-swipe.selectAll' | translate}}\n </mat-option>\n <mat-divider></mat-divider>\n <mat-option *ngFor=\"let layer of userControlledLayerList\" [value]=\"layer\" (click)=\"applyNewLayers(e)\">{{layer.title}}</mat-option>\n </mat-select>\n </mat-form-field>\n </form>\n\n <mat-slide-toggle class=\"swipe-toggle mat-typography\"\n [checked]=\"swipe\"\n [labelPosition]=\"'before'\"\n (change)=\"startSwipe($event.checked)\">\n {{'igo.integration.advanced-map-tool.advanced-swipe.swipe' | translate}}\n </mat-slide-toggle> \n</div>\n\n<ng-template #noLayersBlock>\n <mat-list>\n <p class=\"map-empty mat-typography\">\n {{'igo.integration.advanced-map-tool.advanced-swipe.empty' | translate}}</p>\n <p class=\"map-empty mat-typography\">\n {{'igo.integration.advanced-map-tool.advanced-swipe.customize' | translate}}</p>\n <mat-list-item>\n <mat-icon mat-list-icon svgIcon=\"magnify\"></mat-icon>\n <h4 matLine class=\"search-tool mat-typography\" (click)=\"searchEmit()\">\n {{'igo.integration.advanced-map-tool.advanced-swipe.search-tool' | translate}}\n </h4>\n </mat-list-item>\n <mat-list-item>\n <mat-icon mat-list-icon svgIcon=\"layers-plus\"></mat-icon>\n <h4 matLine class=\"catalog-tool mat-typography\" (click)=\"catalogEmit()\">\n {{'igo.integration.advanced-map-tool.advanced-swipe.catalog-tool' | translate}}\n </h4>\n </mat-list-item>\n <mat-list-item>\n <mat-icon mat-list-icon svgIcon=\"star\"></mat-icon>\n <h4 matLine class=\"context-tool mat-typography\" (click)=\"contextEmit()\">\n {{'igo.integration.advanced-map-tool.advanced-swipe.context-tool' | translate}}\n </h4>\n </mat-list-item>\n </mat-list>\n</ng-template>\n","import { Component, OnDestroy, OnInit } from '@angular/core';\nimport { FormGroup, FormBuilder, Validators } from '@angular/forms';\nimport { ContextService, DetailedContext } from '@igo2/context';\nimport { IgoMap, Layer, VectorLayer } from '@igo2/geo';\nimport { MapState } from '../../map.state';\nimport { ToolState } from '../../../tool/tool.state';\n\n@Component({\n selector: 'igo-advanced-swipe',\n templateUrl: './advanced-swipe.component.html',\n styleUrls: ['./advanced-swipe.component.scss']\n})\n\nexport class AdvancedSwipeComponent implements OnInit, OnDestroy {\n public swipe: boolean = false;\n public layerList: Layer[];\n public userControlledLayerList: Layer[];\n public form: FormGroup;\n public layers: VectorLayer[];\n public res: DetailedContext;\n public listForSwipe: Layer[];\n\n /**\n * Get an active map state\n */\n get map(): IgoMap {\n return this.mapState.map;\n }\n\n constructor(\n public mapState: MapState,\n private contextService: ContextService,\n private formBuilder: FormBuilder,\n private toolState: ToolState) {\n this.buildForm();\n }\n\n /**\n * Get the list of layers for swipe\n * @internal\n */\n ngOnInit() {\n this.map.layers$.subscribe(ll => this.userControlledLayerList = ll.filter(layer =>\n (!layer.baseLayer && layer.showInLayerList && layer.displayed)));\n }\n\n /**\n * Desactivate the swipe\n * @internal\n */\n ngOnDestroy(){\n this.swipe = false;\n this.map.swipeEnabled$.next(this.swipe);\n }\n\n /**\n * Build a form for choise of the layers\n */\n private buildForm() {\n this.form = this.formBuilder.group({\n layers: ['', [Validators.required]]\n });\n }\n\n /**\n * Activate the swipe, send a list of layers for a swipe-tool\n */\n startSwipe(toggle: boolean){\n this.swipe = toggle;\n this.map.swipeEnabled$.next(toggle);\n this.listForSwipe = [];\n for (const layer of this.form.value.layers) {\n this.listForSwipe.push(layer);\n }\n this.map.selectedFeatures$.next(this.listForSwipe);\n }\n\n /**\n * Restart a swipe for a new layers-list\n */\n applyNewLayers(e) {\n this.startSwipe(false); // l'approche KISS\n this.startSwipe(true);\n if (e._selected) {e._selected = false; }\n const allLayers = this.userControlledLayerList.length;\n const selectedLayers = this.form.controls.layers.value.length;\n if (selectedLayers === allLayers){\n e._selected = true;\n }\n }\n\n /**\n * Select all list of layers and restart a tool\n */\n selectAll(e) {\n if (e._selected) {\n this.form.controls.layers.setValue(this.userControlledLayerList);\n e._selected = true;\n }\n else {\n this.form.controls.layers.setValue([]);\n }\n this.startSwipe(false);\n this.startSwipe(true);\n }\n\n /**\n * Open search tool\n */\n searchEmit() {\n this.toolState.toolbox.activateTool('searchResults');\n }\n\n /**\n * Open catalog\n */\n catalogEmit() {\n this.toolState.toolbox.activateTool('catalog');\n }\n\n /**\n * Open context manager\n */\n contextEmit() {\n this.toolState.toolbox.activateTool('contextManager');\n }\n}\n","<mat-form-field *ngIf=\"units; else elseBlock\" class=\"coordinates\">\n <textarea #textArea matInput readonly rows=\"1\"\n [placeholder]=\"'igo.integration.advanced-map-tool.advanced-coordinates.lon' | translate\"\n [value]=\"coordinates[0]\"></textarea>\n</mat-form-field>\n<ng-template #elseBlock >\n <mat-form-field class=\"coordinates\">\n <textarea #textArea matInput readonly rows=\"1\"\n [placeholder]=\"'igo.integration.advanced-map-tool.advanced-coordinates.est' | translate\"\n [value]=\"coordinates[0]\"></textarea></mat-form-field>\n</ng-template>\n\n<mat-form-field *ngIf=\"units; else elseBlock2\" class=\"coordinates2\">\n <textarea #textArea matInput readonly rows=\"1\"\n [placeholder]=\"'igo.integration.advanced-map-tool.advanced-coordinates.lat' | translate\"\n [value]=\"coordinates[1]\"></textarea>\n</mat-form-field>\n<ng-template #elseBlock2 >\n <mat-form-field class=\"coordinates2\"> <textarea #textArea matInput readonly rows=\"1\"\n [placeholder]=\"'igo.integration.advanced-map-tool.advanced-coordinates.nord' | translate\"\n [value]=\"coordinates[1]\"></textarea></mat-form-field>\n</ng-template>\n\n<button class=\"igo-form-button-group\"\n mat-raised-button\n (click)=\"copyTextToClipboard()\">\n <mat-icon svgIcon=\"content-copy\"></mat-icon>\n {{ 'igo.integration.advanced-map-tool.advanced-coordinates.copy' | translate }}\n</button>\n\n<form class=\"igo-form\" [formGroup]=\"form\">\n <mat-form-field class=\"igo-input-container\">\n <mat-label>{{'igo.integration.advanced-map-tool.advanced-coordinates.coordSystem' | translate}}</mat-label>\n <mat-select [(value)]=\"inputProj\">\n <mat-option matTooltipShowDelay=\"500\"\n *ngFor=\"let projection of (projections$ | async)\"\n [value]=\"projection\"\n (click)=\"$event.stopPropagation()\">\n {{projection.translatedValue || projection.alias }}\n </mat-option>\n </mat-select>\n </mat-form-field>\n <mat-slide-toggle class=\"center-toggle mat-typography\"\n [checked]=\"center\"\n [labelPosition]=\"'before'\"\n (change)=\"displayCenter($event.checked)\">\n {{'igo.integration.advanced-map-tool.advanced-coordinates.center' | translate}}\n </mat-slide-toggle> \n</form>\n\n<p class=\"igo-zoom mat-typography\">{{'igo.integration.advanced-map-tool.advanced-coordinates.zoom' | translate}} {{map.viewController.getZoom() }}</p>\n<p class=\"igo-zoom mat-typography\">{{'igo.integration.advanced-map-tool.advanced-coordinates.scale' | translate}} {{ formattedScale$ | async }}</p>\n<p class=\"igo-zoom mat-typography\">{{'igo.integration.advanced-map-tool.advanced-coordinates.resolution' | translate}} {{map.viewController.getResolution() | number: '1.0-0' }}</p>","import { ChangeDetectorRef, Component, OnDestroy, OnInit, Input } from '@angular/core';\nimport { formatScale, IgoMap, InputProjections, ProjectionsLimitationsOptions } from '@igo2/geo';\nimport { MapState } from '../../map.state';\nimport { Clipboard } from '@igo2/utils';\nimport { MessageService, LanguageService, StorageService, StorageScope, ConfigService } from '@igo2/core';\nimport { BehaviorSubject, combineLatest, Subscription } from 'rxjs';\nimport { FormBuilder, FormGroup, Validators } from '@angular/forms';\nimport { debounceTime } from 'rxjs/operators';\nimport { zoneMtm, zoneUtm, computeProjectionsConstraints } from '@igo2/geo';\nimport * as olproj from 'ol/proj';\n/**\n * Tool to display the coordinates and a cursor of the center of the map\n */\n@Component({\n selector: 'igo-advanced-coordinates',\n templateUrl: './advanced-coordinates.component.html',\n styleUrls: ['./advanced-coordinates.component.scss']\n})\nexport class AdvancedCoordinatesComponent implements OnInit, OnDestroy {\n public formattedScale$: BehaviorSubject<string> = new BehaviorSubject('');\n public projections$: BehaviorSubject<InputProjections[]> = new BehaviorSubject([]);\n public form: FormGroup;\n public coordinates: string[];\n private currentCenterDefaultProj: [number, number];\n public center: boolean = this.storageService.get('centerToggle') as boolean;\n private inMtmZone: boolean = true;\n private inLambert2 = {32198: true, 3798: true};\n private mapState$$: Subscription;\n private _projectionsLimitations: ProjectionsLimitationsOptions = {};\n private projectionsConstraints: ProjectionsLimitationsOptions;\n private defaultProj: InputProjections = {\n translatedValue: this.languageService.translate.instant('igo.geo.importExportForm.projections.wgs84', { code: 'EPSG:4326' }),\n translateKey: 'wgs84', alias: 'WGS84', code: 'EPSG:4326', zone: ''\n };\n private currentZones = { utm: undefined, mtm: undefined };\n public units: boolean = true;\n get map(): IgoMap {\n return this.mapState.map;\n }\n\n get inputProj(): InputProjections {\n return this.form.get('inputProj').value;\n }\n set inputProj(value: InputProjections) {\n this.form.patchValue({ inputProj: value });\n }\n get projectionsLimitations(): ProjectionsLimitationsOptions {\n return this._projectionsLimitations || {};\n }\n\n @Input()\n set projectionsLimitations(value: ProjectionsLimitationsOptions) {\n this._projectionsLimitations = value;\n }\n\n constructor(\n public mapState: MapState,\n private languageService: LanguageService,\n private messageService: MessageService,\n private cdRef: ChangeDetectorRef,\n private storageService: StorageService,\n private config: ConfigService,\n private formBuilder: FormBuilder) {\n this.computeProjections();\n this.buildForm();\n }\n\n /**\n * Listen a state of the map, a state of a form, update the coordinates\n */\n ngOnInit(): void {\n this.mapState$$ = combineLatest([this.map.viewController.state$.pipe(debounceTime(50)), this.form.valueChanges])\n .subscribe(() => {\n this.setScaleValue(this.map);\n this.currentCenterDefaultProj = this.map.viewController.getCenter(this.defaultProj.code);\n const currentMtmZone = zoneMtm(this.currentCenterDefaultProj[0]);\n const currentUtmZone = zoneUtm(this.currentCenterDefaultProj[0]);\n if (!this.inMtmZone && currentMtmZone !== this.currentZones.mtm) {\n this.back2quebec();\n }\n let zoneChange = false;\n if (currentMtmZone !== this.currentZones.mtm) {\n this.currentZones.mtm = currentMtmZone;\n zoneChange = true;\n }\n if (currentUtmZone !== this.currentZones.utm) {\n this.currentZones.utm = currentUtmZone;\n zoneChange = true;\n }\n if (zoneChange) {\n this.updateProjectionsZoneChange();\n }\n this.checkLambert(this.currentCenterDefaultProj);\n this.coordinates = this.getCoordinates();\n this.cdRef.detectChanges();\n this.storageService.set('currentProjection', this.inputProj, StorageScope.SESSION);\n });\n\n const tempInputProj = this.storageService.get('currentProjection') as InputProjections;\n this.inputProj = this.projections$.value[0];\n if (tempInputProj !== null)\n {\n const pos = this.positionInList(tempInputProj);\n this.inputProj = this.projections$.value[pos];\n this.updateZoneMtmUtm();\n }\n this.map.mapCenter$.next(this.center);\n this.coordinates = this.getCoordinates();\n this.currentCenterDefaultProj = this.map.viewController.getCenter(this.defaultProj.code);\n }\n\n ngOnDestroy(): void {\n this.map.mapCenter$.next(false);\n this.mapState$$.unsubscribe();\n }\n\n setScaleValue(map: IgoMap) {\n this.formattedScale$.next(': ~ 1 / ' + formatScale(map.viewController.getScale()));\n }\n /**\n * Coordinates of the center of the map on the appropriate systeme of coordinates\n * @returns Array of two numbers\n */\n getCoordinates(): string[] {\n this.currentZones.mtm = zoneMtm(this.currentCenterDefaultProj[0]);\n this.currentZones.utm = zoneUtm(this.currentCenterDefaultProj[0]);\n let coord;\n const code = this.inputProj.code;\n let decimal = 2;\n if (code.includes('EPSG:4326') || code.includes('EPSG:4269')) {\n decimal = 5;\n }\n this.units = (code === 'EPSG:4326' || code === 'EPSG:4269');\n coord = this.map.viewController.getCenter(code).map(c => c.toFixed(decimal));\n return coord;\n }\n\n /**\n * Copy the coordinates to a clipboard\n */\n copyTextToClipboard(): void {\n const successful = Clipboard.copy(this.coordinates.toString());\n if (successful) {\n const translate = this.languageService.translate;\n const title = translate.instant(\n 'igo.integration.advanced-map-tool.advanced-coordinates.copyTitle'\n );\n const msg = translate.instant('igo.integration.advanced-map-tool.advanced-coordinates.copyMsg');\n this.messageService.success(msg, title);\n }\n }\n\n /**\n * Display a cursor on the center of the map\n */\n displayCenter(toggle: boolean): void {\n this.center = toggle;\n this.map.mapCenter$.next(toggle);\n this.storageService.set('centerToggle', toggle, StorageScope.SESSION);\n }\n\n /**\n * Builder of the form\n */\n private buildForm(): void {\n this.form = this.formBuilder.group({\n inputProj: ['', [Validators.required]]\n });\n }\n\n /**\n * Update list of projections after changing of the state of the map\n */\n private updateProjectionsZoneChange(): void {\n let modifiedProj = this.projections$.value;\n const translate = this.languageService.translate;\n modifiedProj.map(p => {\n if (p.translateKey === 'mtm') {\n const zone = zoneMtm(this.currentCenterDefaultProj[0]);\n if (zone) {\n const code = zone < 10 ? `EPSG:3218${zone}` : `EPSG:321${80 + zone}`;\n p.alias = `MTM ${zone}`;\n p.code = code;\n p.zone = `${zone}`;\n p.translatedValue = translate.instant('igo.geo.importExportForm.projections.mtm', p);\n }\n else {\n p.alias = '';\n this.inMtmZone = false;\n if (this.inputProj.translateKey === 'mtm') {\n this.inputProj = this.projections$.value[0];\n }\n }\n }\n if (p.translateKey === 'utm') {\n const zone = zoneUtm(this.currentCenterDefaultProj[0]);\n const code = `EPSG:326${zone}`;\n p.alias = `UTM ${zone}`;\n p.code = code;\n p.zone = `${zone}`;\n p.translatedValue = translate.instant('igo.geo.importExportForm.projections.utm', p);\n }\n });\n modifiedProj = modifiedProj.filter(p => p.alias !== '');\n this.projections$.next(modifiedProj);\n }\n\n /**\n * Create a list of currents projections\n */\n private computeProjections(): void {\n this.projectionsConstraints = computeProjectionsConstraints(this.projectionsLimitations);\n const projections: InputProjections[] = [];\n\n if (!this.currentCenterDefaultProj) {\n this.currentCenterDefaultProj = this.map.viewController.getCenter(this.defaultProj.code);\n }\n\n const translate = this.languageService.translate;\n if (this.projectionsConstraints.wgs84) {\n projections.push({\n translatedValue: translate.instant('igo.geo.importExportForm.projections.wgs84', { code: 'EPSG:4326' }),\n translateKey: 'wgs84', alias: 'WGS84', code: 'EPSG:4326', zone: ''\n });\n }\n\n if (this.projectionsConstraints.nad83) {\n projections.push({\n translatedValue: translate.instant('igo.geo.importExportForm.projections.nad83', { code: 'EPSG:4269' }),\n translateKey: 'nad83', alias: 'NAD83', code: 'EPSG:4269', zone: ''\n });\n }\n\n if (this.projectionsConstraints.webMercator) {\n projections.push({\n translatedValue: translate.instant('igo.geo.importExportForm.projections.webMercator', { code: 'EPSG:3857' }),\n translateKey: 'webMercator', alias: 'Web Mercator', code: 'EPSG:3857', zone: ''\n });\n }\n if (this.projectionsConstraints.mtm) {\n // Quebec\n const zone = zoneMtm(this.currentCenterDefaultProj[0]);\n if (zone) {\n this.inMtmZone = true;\n const code = zone < 10 ? `EPSG:3218${zone}` : `EPSG:321${80 + zone}`;\n projections.splice(3, 0, {\n translatedValue: this.languageService.translate.instant('igo.geo.importExportForm.projections.mtm', { code, zone }),\n translateKey: 'mtm', alias: `MTM ${zone}`, code, zone: `${zone}`\n });\n }\n else {\n this.inMtmZone = false;\n }\n }\n if (this.projectionsConstraints.utm) {\n const order = this.inMtmZone ? 4 : 3;\n const zone = zoneUtm(this.currentCenterDefaultProj[0]);\n const code = zone < 10 ? `EPSG:3260${zone}` : `EPSG:326${zone}`;\n projections.splice(order, 0, {\n translatedValue: this.languageService.translate.instant('igo.geo.importExportForm.projections.utm', { code, zone }),\n translateKey: 'utm', alias: `UTM ${zone}`, code, zone: `${zone}`\n });\n }\n let configProjection = [];\n if (this.projectionsConstraints.projFromConfig) {\n configProjection = this.config.getConfig('projections') || [];\n }\n this.projections$.next(projections.concat(configProjection));\n }\n\n /**\n * Push the MTM in the array of systeme of coordinates\n * @param projections Array of the InputProjections\n */\n private pushMtm(projections: Array<InputProjections>): void {\n if (this.projectionsConstraints.mtm) {\n const zone = zoneMtm(this.currentCenterDefaultProj[0]);\n const code = zone < 10 ? `EPSG:3218${zone}` : `EPSG:321${80 + zone}`;\n projections.splice(3, 0, {\n translatedValue: this.languageService.translate.instant('igo.geo.importExportForm.projections.mtm', { code, zone }),\n translateKey: 'mtm', alias: `MTM ${zone}`, code, zone: `${zone}`});\n }\n }\n\n /**\n * Updates the list of systems of coordinates for territory of Quebec\n * push MTM and UTM in the Array\n */\n private back2quebec(): void {\n const projections = this.projections$.value;\n this.pushMtm(projections);\n this.inMtmZone = true;\n }\n\n /**\n * Update the numbers of the zones when application is restarted\n */\n private updateZoneMtmUtm() {\n if (this.inputProj.translateKey === 'mtm') {\n const zone = zoneMtm(this.currentCenterDefaultProj[0]);\n this.inputProj.alias = `MTM ${zone}`;\n const code = zone < 10 ? `EPSG:3218${zone}` : `EPSG:321${80 + zone}`;\n this.inputProj.code = code;\n this.inputProj.zone = `${zone}`;\n this.inputProj.translatedValue = this.languageService.translate.instant('igo.geo.importExportForm.projections.mtm', { code, zone });\n }\n if (this.inputProj.translateKey === 'utm') {\n const zone = zoneUtm(this.currentCenterDefaultProj[0]);\n this.inputProj.alias = `UTM ${zone}`;\n const code = zone < 10 ? `EPSG:3260${zone}` : `EPSG:326${zone}`;\n this.inputProj.code = code;\n this.inputProj.zone = `${zone}`;\n this.inputProj.translatedValue = this.languageService.translate.instant('igo.geo.importExportForm.projections.utm', { code, zone });\n }\n }\n\n /**\n * Compute the position of a current projection in a list. 0 if the projection is not in the list\n * @param translateKey string, translate key of a projection\n * @returns numeric, position of an element in the array\n */\n positionInList(tempInputProj: InputProjections): number {\n const tk = tempInputProj.translateKey;\n const alias = tempInputProj.alias;\n let position; // = undefined;\n let iter = 0;\n this.projections$.value.map((projection) => {\n if (tk) {\n if (tk === projection.translateKey) {\n position = iter;\n }\n }\n else if (alias === projection.alias) {\n position = iter;\n }\n iter++;\n });\n position = position ? position : 0;\n return position;\n }\n\n /**\n * Change the list of projections depending on the projections of Lambert\n * @param coordinates An array of numbers, longitude and latitude\n */\n checkLambert(coordinates: [number, number]) {\n const lambertProjections = this.config.getConfig('projections');\n lambertProjections.forEach(projection => {\n let modifiedProj = this.projections$.value;\n const extent = projection.extent;\n const code = projection.code.match(/\\d+/);\n const currentExtentWGS = olproj.transformExtent(extent, projection.code, this.defaultProj.code);\n if (coordinates[0] < currentExtentWGS[0] || coordinates[0] > currentExtentWGS[2] ||\n coordinates[1] < currentExtentWGS[1] || coordinates[1] > currentExtentWGS[3]) {\n this.inLambert2[code] = false;\n if (this.inputProj.alias === projection.alias) {\n this.inputProj = this.projections$.value[0];\n }\n modifiedProj = modifiedProj.filter(p => p.alias !== projection.alias);\n this.projections$.next(modifiedProj);\n }\n else {\n if (!this.inLambert2[code]) {\n this.projections$.next(modifiedProj.concat(projection));\n this.inLambert2[code] = true;\n }\n }\n });\n }\n}\n","import { Component } from '@angular/core';\nimport { ToolComponent } from '@igo2/common';\n\n@ToolComponent({\n name: 'advancedMap',\n title: 'igo.integration.tools.advancedMap',\n icon: 'toolbox'\n})\n\n/**\n * Tool to handle the advanced map tools\n */\n@Component({\n selector: 'igo-advanced-map-tool',\n templateUrl: './advanced-map-tool.component.html',\n styleUrls: ['./advanced-map-tool.component.scss']\n})\n\nexport class AdvancedMapToolComponent {\n\n}\n","<h4 class=\"nameOfTool\">{{'igo.integration.advanced-map-tool.advanced-swipe.swipe-tool' | translate}}</h4>\n<igo-advanced-swipe></igo-advanced-swipe>\n<mat-divider class=\"advanced-tool-line\"></mat-divider>\n\n<h4 class=\"nameOfTool\">{{'igo.integration.advanced-map-tool.advanced-coordinates.coordinates' | translate}}</h4>\n<igo-advanced-coordinates></igo-advanced-coordinates>\n<mat-divider class=\"advanced-tool-line\"></mat-divider>\n","import {\n NgModule,\n ModuleWithProviders,\n CUSTOM_ELEMENTS_SCHEMA\n} from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { MatIconModule } from '@angular/material/icon';\nimport { MatListModule } from '@angular/material/list';\nimport { MatTabsModule } from '@angular/material/tabs';\nimport { MatSlideToggleModule } from '@angular/material/slide-toggle';\nimport { MatMenuModule } from '@angular/material/menu';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatTooltipModule } from '@angular/material/tooltip';\nimport { IgoLanguageModule } from '@igo2/core';\nimport {\n IgoLayerModule,\n IgoMetadataModule,\n IgoDownloadModule,\n IgoFilterModule,\n IgoImportExportModule\n} from '@igo2/geo';\nimport { IgoContextModule } from '@igo2/context';\nimport { MapDetailsToolComponent } from './map-details-tool/map-details-tool.component';\nimport { MapToolComponent } from './map-tool/map-tool.component';\nimport { MapToolsComponent } from './map-tools/map-tools.component';\nimport { MapLegendToolComponent } from './map-legend/map-legend-tool.component';\nimport { IgoAppWorkspaceModule } from '../workspace/workspace.module';\nimport { AdvancedMapToolComponent } from './advanced-map-tool/advanced-map-tool.component';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatButtonToggleModule } from '@angular/material/button-toggle';\nimport { MatOptionModule } from '@angular/material/core';\nimport { MatDividerModule } from '@angular/material/divider';\nimport { MatInputModule } from '@angular/material/input';\nimport { MatSelectModule } from '@angular/material/select';\nimport { MatCheckboxModule } from '@angular/material/checkbox';\nimport { IgoSpinnerModule } from '@igo2/common';\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\nimport { AdvancedSwipeComponent } from './advanced-map-tool/advanced-swipe/advanced-swipe.component';\nimport { AdvancedCoordinatesComponent } from './advanced-map-tool/advanced-coordinates/advanced-coordinates.component';\n@NgModule({\n imports: [\n FormsModule,\n ReactiveFormsModule,\n MatButtonToggleModule,\n MatDividerModule,\n MatSelectModule,\n MatOptionModule,\n MatFormFieldModule,\n MatInputModule,\n MatCheckboxModule,\n IgoSpinnerModule,\n CommonModule,\n MatTabsModule,\n MatListModule,\n MatIconModule,\n IgoLanguageModule,\n IgoLayerModule,\n IgoMetadataModule,\n IgoDownloadModule,\n IgoImportExportModule,\n IgoFilterModule,\n IgoContextModule,\n IgoAppWorkspaceModule,\n MatSlideToggleModule,\n MatMenuModule,\n MatButtonModule,\n MatTooltipModule\n ],\n declarations: [ AdvancedMapToolComponent, MapToolComponent,\n MapToolsComponent, MapDetailsToolComponent, MapLegendToolComponent, AdvancedSwipeComponent, AdvancedCoordinatesComponent],\n exports: [AdvancedMapToolComponent, MapToolComponent, MapToolsComponent, MapDetailsToolComponent, MapLegendToolComponent],\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\n})\nexport class IgoAppMapModule {\n static forRoot(): ModuleWithProviders<IgoAppMapModule> {\n return {\n ngModule: IgoAppMapModule,\n providers: []\n };\n }\n}\n","import { Injectable } from '@angular/core';\n\nimport { FeatureStore, FeatureWithMeasure } from '@igo2/geo';\nimport { MapState } from '../map/map.state';\n\n/**\n * Service that holds the state of the measure module\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class MeasureState {\n\n /**\n * Store that holds the measures\n */\n public store: FeatureStore<FeatureWithMeasure> = new FeatureStore<FeatureWithMeasure>([], {\n map: this.mapState.map\n });\n\n constructor(private mapState: MapState) {\n\n this.mapState.map.layers$.subscribe((layers) => {\n if ((layers.filter(l => l.id.startsWith('igo-measures-')).length === 0)) {\n this.store.deleteMany(this.store.all());\n this.mapState.map.ol.getOverlays().getArray()\n .filter(overlay => (overlay as any).options.className.includes('igo-map-tooltip'))\n .map(overlay => this.mapState.map.ol.removeOverlay(overlay));\n }\n });\n }\n\n}\n","import {\n Component,\n ChangeDetectionStrategy\n} from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\nimport { FeatureStore, FeatureWithMeasure, IgoMap } from '@igo2/geo';\nimport { MapState } from '../../map/map.state';\nimport { MeasureState } from '../measure.state';\n\n/**\n * Tool to measure lengths and areas\n */\n@ToolComponent({\n name: 'measurer',\n title: 'igo.integration.tools.measurer',\n icon: 'ruler'\n})\n@Component({\n selector: 'igo-measurer-tool',\n templateUrl: './measurer-tool.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class MeasurerToolComponent {\n\n /**\n * Map to measure on\n * @internal\n */\n get store(): FeatureStore<FeatureWithMeasure> { return this.measureState.store; }\n\n /**\n * Map to measure on\n * @internal\n */\n get map(): IgoMap { return this.mapState.map; }\n\n constructor(\n private measureState: MeasureState,\n private mapState: MapState\n ) {}\n\n}\n","<igo-measurer [store]=\"store\" [map]=\"map\"></igo-measurer>\n","import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';\n\nimport { IgoMeasurerModule } from '@igo2/geo';\n\nimport { MeasurerToolComponent } from './measurer-tool.component';\n\n/**\n * @ignore\n */\n@NgModule({\n imports: [\n IgoMeasurerModule\n ],\n declarations: [MeasurerToolComponent],\n exports: [MeasurerToolComponent],\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\n})\nexport class IgoAppMeasurerToolModule {}\n","import { NgModule } from '@angular/core';\n\nimport { IgoAppMeasurerToolModule } from './measurer-tool/measurer-tool.module';\n\n@NgModule({\n imports: [],\n declarations: [],\n exports: [\n IgoAppMeasurerToolModule\n ]\n})\nexport class IgoAppMeasureModule {}\n","import { Component } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\nimport { IgoMap } from '@igo2/geo';\n\nimport { MapState } from '../../map/map.state';\n\n@ToolComponent({\n name: 'print',\n title: 'igo.integration.tools.print',\n icon: 'printer'\n})\n@Component({\n selector: 'igo-print-tool',\n templateUrl: './print-tool.component.html'\n})\nexport class PrintToolComponent {\n get map(): IgoMap {\n return this.mapState.map;\n }\n\n constructor(private mapState: MapState) {}\n}\n","<igo-print [map]=\"map\"></igo-print>\n","import {\n NgModule,\n ModuleWithProviders,\n CUSTOM_ELEMENTS_SCHEMA\n} from '@angular/core';\n\nimport { IgoPrintModule } from '@igo2/geo';\nimport { PrintToolComponent } from './print-tool/print-tool.component';\n\n@NgModule({\n imports: [IgoPrintModule],\n declarations: [PrintToolComponent],\n exports: [PrintToolComponent],\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\n})\nexport class IgoAppPrintModule {\n static forRoot(): ModuleWithProviders<IgoAppPrintModule> {\n return {\n ngModule: IgoAppPrintModule,\n providers: []\n };\n }\n}\n","import { Injectable } from '@angular/core';\n\nimport { EntityRecord, EntityStore, EntityStoreFilterCustomFuncStrategy, EntityStoreStrategyFuncOptions } from '@igo2/common';\nimport { ConfigService, StorageService } from '@igo2/core';\nimport { SearchResult, SearchSourceService, SearchSource, CommonVectorStyleOptions } from '@igo2/geo';\nimport { BehaviorSubject, Subscription } from 'rxjs';\n\n/**\n * Service that holds the state of the search module\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class SearchState {\n public searchOverlayStyle: CommonVectorStyleOptions = {};\n public searchOverlayStyleSelection: CommonVectorStyleOptions = {};\n public searchOverlayStyleFocus: CommonVectorStyleOptions = {};\n\n public focusedOrResolution$$: Subscription;\n public selectedOrResolution$$: Subscription;\n\n readonly searchTermSplitter$: BehaviorSubject<string> = new BehaviorSubject('|');\n\n readonly searchTerm$: BehaviorSubject<string> = new BehaviorSubject(undefined);\n\n readonly searchType$: BehaviorSubject<string> = new BehaviorSubject(undefined);\n\n readonly searchDisabled$: BehaviorSubject<boolean> = new BehaviorSubject(false);\n\n readonly searchResultsGeometryEnabled$: BehaviorSubject<boolean> = new BehaviorSubject(false);\n\n readonly searchSettingsChange$: BehaviorSubject<boolean> = new BehaviorSubject(undefined);\n\n readonly selectedResult$: BehaviorSubject<SearchResult> = new BehaviorSubject(undefined);\n\n /**\n * Store that holds the search results\n */\n readonly store: EntityStore<SearchResult> = new EntityStore<SearchResult>([]);\n\n /**\n * Search types currently enabled in the search source service\n */\n get searchTypes(): string[] {\n return this.searchSourceService\n .getEnabledSources()\n .map((source: SearchSource) => (source.constructor as any).type);\n }\n\n constructor(\n private searchSourceService: SearchSourceService,\n private storageService: StorageService,\n private configService: ConfigService) {\n const searchOverlayStyle = this.configService.getConfig('searchOverlayStyle') as {\n base?: CommonVectorStyleOptions,\n selection?: CommonVectorStyleOptions,\n focus?: CommonVectorStyleOptions\n };\n if (searchOverlayStyle) {\n this.searchOverlayStyle = searchOverlayStyle.base;\n this.searchOverlayStyleSelection = searchOverlayStyle.selection;\n this.searchOverlayStyleFocus = searchOverlayStyle.focus;\n }\n\n const searchResultsGeometryEnabled = this.storageService.get('searchResultsGeometryEnabled') as boolean;\n if (searchResultsGeometryEnabled) {\n this.searchResultsGeometryEnabled$.next(searchResultsGeometryEnabled);\n }\n this.store.addStrategy(this.createCustomFilterTermStrategy(), false);\n }\n\n private createCustomFilterTermStrategy(): EntityStoreFilterCustomFuncStrategy {\n const filterClauseFunc = (record: EntityRecord<SearchResult>) => {\n return record.entity.meta.score === 100;\n };\n return new EntityStoreFilterCustomFuncStrategy({filterClauseFunc} as EntityStoreStrategyFuncOptions);\n }\n\n /**\n * Activate custom strategy\n *\n */\n activateCustomFilterTermStrategy() {\n const strategy = this.store.getStrategyOfType(EntityStoreFilterCustomFuncStrategy);\n if (strategy !== undefined) {\n strategy.activate();\n }\n }\n\n /**\n * Deactivate custom strategy\n *\n */\n deactivateCustomFilterTermStrategy() {\n const strategy = this.store.getStrategyOfType(EntityStoreFilterCustomFuncStrategy);\n if (strategy !== undefined) {\n strategy.deactivate();\n }\n }\n\n enableSearch() {\n this.searchDisabled$.next(false);\n }\n\n disableSearch() {\n this.searchDisabled$.next(true);\n }\n\n setSearchTerm(searchTerm: string) {\n this.searchTerm$.next(searchTerm);\n }\n\n setSearchType(searchType: string) {\n this.searchSourceService.enableSourcesByType(searchType);\n this.searchType$.next(searchType);\n }\n\n setSearchSettingsChange() {\n this.searchSettingsChange$.next(true);\n }\n\n setSelectedResult(result: SearchResult) {\n this.selectedResult$.next(result);\n }\n\n setSearchResultsGeometryStatus(value) {\n this.storageService.set('searchResultsGeometryEnabled', value);\n this.searchResultsGeometryEnabled$.next(value);\n }\n}\n","import { Directive, Self, OnInit, OnDestroy, HostListener } from '@angular/core';\nimport { Subscription } from 'rxjs';\n\nimport { SearchBarComponent } from '@igo2/geo';\nimport { SearchState } from '../search.state';\n\n@Directive({\n selector: '[igoSearchBarBinding]'\n})\nexport class SearchBarBindingDirective implements OnInit, OnDestroy {\n\n get searchTerm(): string { return this.searchState.searchTerm$.value; }\n get searchType(): string { return this.searchState.searchType$.value; }\n\n private searchTerm$$: Subscription;\n private searchType$$: Subscription;\n private searchDisabled$$: Subscription;\n\n constructor(\n @Self() private component: SearchBarComponent,\n private searchState: SearchState\n ) {}\n\n ngOnInit() {\n this.searchTerm$$ = this.searchState.searchTerm$.subscribe((searchTerm: string) => {\n if (searchTerm !== undefined && searchTerm !== null) {\n this.component.setTerm(searchTerm);\n }\n });\n\n this.searchType$$ = this.searchState.searchType$.subscribe((searchType: string) => {\n if (searchType !== undefined && searchType !== null) {\n this.component.setSearchType(searchType);\n }\n });\n\n this.searchDisabled$$ = this.searchState.searchDisabled$.subscribe((searchDisabled: boolean) => {\n this.component.disabled = searchDisabled;\n });\n }\n\n ngOnDestroy() {\n this.searchTerm$$.unsubscribe();\n this.searchType$$.unsubscribe();\n this.searchDisabled$$.unsubscribe();\n }\n\n @HostListener('searchTermChange', ['$event'])\n onSearchTermChange(searchTerm?: string) {\n if (searchTerm !== this.searchTerm) {\n this.searchState.setSearchTerm(searchTerm);\n }\n }\n\n @HostListener('searchTypeChange', ['$event'])\n onSearchTypeChange(searchType?: string) {\n if (searchType !== this.searchType) {\n this.searchState.setSearchType(searchType);\n }\n }\n}\n","import { NgModule } from '@angular/core';\n\nimport { IgoSearchModule } from '@igo2/geo';\n\nimport { SearchBarBindingDirective } from './search-bar-binding.directive';\n\n/**\n * @ignore\n */\n@NgModule({\n imports: [IgoSearchModule],\n declarations: [SearchBarBindingDirective],\n exports: [SearchBarBindingDirective],\n})\nexport class IgoAppSearchBarModule {}\n","<div *ngIf=\"!store || store.stateView.empty\" style=\"margin: 10px;\">\n <section class=\"mat-typography\">\n <h4><strong>{{ 'igo.integration.searchResultsTool.noResults' | translate }}</strong></h4>\n <p><strong>{{ 'igo.integration.searchResultsTool.doSearch' | translate }}</strong></p>\n <div [innerHTML]=\"'igo.integration.searchResultsTool.examples' | translate | sanitizeHtml\"></div>\n</section>\n</div>\n\n<igo-flexible\n *ngIf=\"store && (store.stateView.empty$ | async)===false\"\n #topPanel\n initial=\"100%\"\n initialMobile=\"100%\"\n collapsed=\"calc(100% - 58px)\"\n collapsedMobile=\"calc(100% - 58px)\"\n expanded=\"60%\"\n expandedMobile=\"60%\"\n [state]=\"(feature$ | async) ? topPanelState : 'initial'\">\n\n <div class=\"igo-content\">\n <igo-search-results\n [store]=\"store\"\n [showIcons]=\"showIcons\"\n [term]=\"term\"\n [termSplitter]=\"termSplitter\"\n [settingsChange$]=\"settingsChange$\"\n placeholder=\"false\"\n (resultFocus)=\"onResultFocus($event)\"\n (resultSelect)=\"onResultSelect($event)\"\n (resultUnfocus)=\"onResultUnfocus($event)\"\n (resultMouseenter)=\"onResultFocus($event)\"\n (resultMouseleave)=\"onResultUnfocus($event)\"\n (moreResults)=\"onSearch($event)\">\n <ng-template #igoSearchItemToolbar let-result=\"result\">\n <igo-search-add-button\n [map]=\"map\"\n [layer]=\"result\">\n </igo-search-add-button>\n </ng-template>\n </igo-search-results>\n </div>\n\n <div igoFlexibleFill class=\"igo-content\">\n <igo-panel [title]=\"featureTitle\" *ngIf=\"feature$ | async\">\n\n <button\n mat-icon-button\n panelLeftButton\n class=\"igo-icon-button\"\n (click)=\"toggleTopPanel()\">\n <mat-icon [svgIcon]=\"(topPanelState$ | async) === 'collapsed' ? 'arrow-up' : 'arrow-down'\"></mat-icon>\n </button>\n\n <button\n *ngIf=\"feature.geometry\"\n mat-icon-button\n panelRightButton\n class=\"igo-icon-button\"\n [matTooltip]=\"((isSelectedResultOutOfView$ | async) ? 'igo.integration.searchResultsTool.zoomOnFeatureTooltipOutOfView' : 'igo.integration.searchResultsTool.zoomOnFeatureTooltip') | translate\"\n matTooltipShowDelay=\"500\"\n (click)=\"zoomToFeatureExtent()\">\n <mat-icon\n [matBadge]=\"(isSelectedResultOutOfView$ | async) ? '!' : ''\"\n matBadgeColor=\"accent\"\n matBadgeSize=\"small\"\n [matBadgeHidden]=\"(isSelectedResultOutOfView$ | async)===false\" \n svgIcon=\"magnify-plus-outline\"></mat-icon>\n </button>\n\n <igo-feature-details\n igoFeatureDetailsDirective\n [feature]=\"feature$ | async\"\n [map]=\"map\"\n [toolbox]=\"toolState.toolbox\"\n (routingEvent)=\"getRoute()\">\n </igo-feature-details>\n </igo-panel>\n </div>\n\n</igo-flexible>\n","import {\n Component,\n ChangeDetectionStrategy,\n Input,\n OnInit,\n ElementRef,\n OnDestroy\n} from '@angular/core';\nimport { Observable, BehaviorSubject, Subscription, combineLatest } from 'rxjs';\nimport { debounceTime, map } from 'rxjs/operators';\nimport olFormatGeoJSON from 'ol/format/GeoJSON';\nimport olFeature from 'ol/Feature';\nimport olPoint from 'ol/geom/Point';\nimport type { default as OlGeometry } from 'ol/geom/Geometry';\n\nimport pointOnFeature from '@turf/point-on-feature';\n\nimport { ConfigService } from '@igo2/core';\n\nimport {\n EntityStore,\n ToolComponent,\n FlexibleState,\n getEntityTitle,\n FlexibleComponent,\n EntityState\n} from '@igo2/common';\n\nimport {\n FEATURE,\n Feature,\n FeatureMotion,\n SearchResult,\n IgoMap,\n moveToOlFeatures,\n Research,\n featuresAreTooDeepInView,\n featureToOl,\n featureFromOl,\n getCommonVectorStyle,\n getCommonVectorSelectedStyle,\n computeOlFeaturesExtent,\n featuresAreOutOfView\n} from '@igo2/geo';\n\nimport { MapState } from '../../map/map.state';\n\nimport { SearchState } from '../search.state';\nimport { ToolState } from '../../tool/tool.state';\nimport { DirectionState } from '../../directions/directions.state';\n\n/**\n * Tool to browse the search results\n */\n@ToolComponent({\n name: 'searchResults',\n title: 'igo.integration.tools.searchResults',\n icon: 'magnify'\n})\n@Component({\n selector: 'igo-search-results-tool',\n templateUrl: './search-results-tool.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SearchResultsToolComponent implements OnInit, OnDestroy {\n /**\n * to show hide results icons\n */\n @Input() showIcons: boolean = true;\n\n private hasFeatureEmphasisOnSelection: boolean = false;\n\n private showResultsGeometries$$: Subscription;\n private getRoute$$: Subscription;\n private shownResultsGeometries: Feature[] = [];\n private shownResultsEmphasisGeometries: Feature[] = [];\n private focusedResult$: BehaviorSubject<SearchResult> = new BehaviorSubject(\n undefined\n );\n public isSelectedResultOutOfView$ = new BehaviorSubject(false);\n private isSelectedResultOutOfView$$: Subscription;\n private abstractFocusedResult: Feature;\n private abstractSelectedResult: Feature;\n\n /**\n * Store holding the search results\n * @internal\n */\n get store(): EntityStore<SearchResult> {\n return this.searchState.store;\n }\n\n /**\n * Map to display the results on\n * @internal\n */\n get map(): IgoMap {\n return this.mapState.map;\n }\n\n get featureTitle(): string {\n return this.feature ? getEntityTitle(this.feature) : undefined;\n }\n\n get feature$(): Observable<Feature> {\n return this.store.stateView\n .firstBy$((e) => e.state.focused)\n .pipe(\n map(\n (element) =>\n (this.feature = element\n ? (element.entity.data as Feature)\n : undefined)\n )\n );\n }\n\n public feature: Feature;\n\n public term = '';\n private searchTerm$$: Subscription;\n\n public settingsChange$ = new BehaviorSubject<boolean>(undefined);\n\n public topPanelState$ = new BehaviorSubject<FlexibleState>('initial');\n private topPanelState$$: Subscription;\n\n @Input()\n set topPanelState(value: FlexibleState) {\n this.topPanelState$.next(value);\n }\n get topPanelState(): FlexibleState {\n return this.topPanelState$.value;\n }\n\n get termSplitter(): string {\n return this.searchState.searchTermSplitter$.value;\n }\n\n private format = new olFormatGeoJSON();\n\n constructor(\n private mapState: MapState,\n private searchState: SearchState,\n private elRef: ElementRef,\n public toolState: ToolState,\n private directionState: DirectionState,\n configService: ConfigService\n ) {\n this.hasFeatureEmphasisOnSelection = configService.getConfig(\n 'hasFeatureEmphasisOnSelection'\n );\n }\n\n ngOnInit() {\n this.searchTerm$$ = this.searchState.searchTerm$.subscribe(\n (searchTerm: string) => {\n if (searchTerm !== undefined && searchTerm !== null) {\n this.term = searchTerm;\n }\n }\n );\n\n for (const res of this.store.stateView.all$().value) {\n if (this.store.state.get(res.entity).selected === true) {\n this.topPanelState = 'expanded';\n }\n }\n\n this.searchState.searchSettingsChange$.subscribe(() => {\n this.settingsChange$.next(true);\n });\n\n this.topPanelState$$ = this.topPanelState$.subscribe(() => {\n const igoList = this.computeElementRef()[0];\n const selected = this.computeElementRef()[1];\n if (selected) {\n setTimeout(() => {\n // To be sure the flexible component has been displayed yet\n if (!this.isScrolledIntoView(igoList, selected)) {\n this.adjustTopPanel(igoList, selected);\n }\n }, FlexibleComponent.transitionTime + 50);\n }\n });\n\n if (this.hasFeatureEmphasisOnSelection) {\n if (!this.searchState.focusedOrResolution$$) {\n this.searchState.focusedOrResolution$$ = combineLatest([\n this.focusedResult$,\n this.map.viewController.resolution$\n ]).subscribe((bunch: [SearchResult<Feature>, number]) =>\n this.buildResultEmphasis(bunch[0], 'focused')\n );\n }\n\n if (!this.searchState.selectedOrResolution$$) {\n this.searchState.selectedOrResolution$$ = combineLatest([\n this.searchState.selectedResult$,\n this.map.viewController.resolution$\n ]).subscribe((bunch: [SearchResult<Feature>, number]) =>\n this.buildResultEmphasis(bunch[0], 'selected')\n );\n }\n }\n this.monitorResultOutOfView();\n\n this.showResultsGeometries$$ = combineLatest([\n this.searchState.searchResultsGeometryEnabled$,\n this.store.stateView.all$(),\n this.focusedResult$,\n this.searchState.selectedResult$,\n this.searchState.searchTerm$,\n this.map.viewController.resolution$\n ]).subscribe((bunch: [boolean, { entity: SearchResult, state: EntityState }[], SearchResult, SearchResult, string, number]) => {\n\n const searchResultsGeometryEnabled = bunch[0];\n const searchResults = bunch[1];\n\n if (this.hasFeatureEmphasisOnSelection) {\n this.clearFeatureEmphasis('shown');\n }\n this.shownResultsGeometries.map(result => this.map.queryResultsOverlay.removeFeature(result));\n const featureToHandleGeom = searchResults\n .filter(result =>\n result.entity.meta.dataType === FEATURE &&\n result.entity.data.geometry &&\n !result.state.selected &&\n !result.state.focused);\n\n featureToHandleGeom.map(result => {\n if (searchResultsGeometryEnabled) {\n result.entity.data.meta.style =\n getCommonVectorStyle(\n Object.assign(\n {},\n { feature: result.entity.data as Feature | olFeature<OlGeometry> },\n this.searchState.searchOverlayStyle,\n result.entity.style?.base ? result.entity.style.base : {}\n ));\n this.shownResultsGeometries.push(result.entity.data as Feature);\n this.map.queryResultsOverlay.addFeature(result.entity.data as Feature, FeatureMotion.None);\n if (this.hasFeatureEmphasisOnSelection) {\n this.buildResultEmphasis(result.entity as SearchResult<Feature>, 'shown');\n }\n }\n });\n });\n }\n\n private monitorResultOutOfView() {\n this.isSelectedResultOutOfView$$ = combineLatest([\n this.map.viewController.state$,\n this.searchState.selectedResult$\n ])\n .pipe(debounceTime(100))\n .subscribe((bunch) => {\n const selectedResult = bunch[1] as SearchResult<Feature>;\n if (!selectedResult) {\n this.isSelectedResultOutOfView$.next(false);\n return;\n }\n if (selectedResult.data.geometry) {\n const selectedOlFeature = featureToOl(\n selectedResult.data,\n this.map.projection\n );\n const selectedOlFeatureExtent = computeOlFeaturesExtent(this.map, [\n selectedOlFeature\n ]);\n this.isSelectedResultOutOfView$.next(\n featuresAreOutOfView(this.map, selectedOlFeatureExtent)\n );\n }\n });\n }\n\n private buildResultEmphasis(\n result: SearchResult<Feature>,\n trigger: 'selected' | 'focused' | 'shown' | undefined\n ) {\n if (trigger !== 'shown') {\n this.clearFeatureEmphasis(trigger);\n }\n if (!result || !result.data.geometry) {\n return;\n }\n const myOlFeature = featureToOl(result.data, this.map.projection);\n const olGeometry = myOlFeature.getGeometry();\n if (featuresAreTooDeepInView(this.map, olGeometry.getExtent() as [number, number, number, number], 0.0025)) {\n const extent = olGeometry.getExtent();\n const x = extent[0] + (extent[2] - extent[0]) / 2;\n const y = extent[1] + (extent[3] - extent[1]) / 2;\n const feature1 = new olFeature({\n name: `${trigger}AbstractResult'`,\n geometry: new olPoint([x, y])\n });\n const abstractResult = featureFromOl(feature1, this.map.projection);\n\n let computedStyle;\n let zIndexOffset = 0;\n\n switch (trigger) {\n case 'focused':\n computedStyle = getCommonVectorSelectedStyle(\n Object.assign({},\n { feature: abstractResult },\n this.searchState.searchOverlayStyleFocus,\n result.style?.focus ? result.style.focus : {}));\n zIndexOffset = 2;\n break;\n case 'shown':\n computedStyle = getCommonVectorStyle(Object.assign({},\n { feature: abstractResult },\n this.searchState.searchOverlayStyle,\n result.style?.base ? result.style.base : {}));\n break;\n case 'selected':\n computedStyle = getCommonVectorSelectedStyle(\n Object.assign({},\n { feature: abstractResult },\n this.searchState.searchOverlayStyleSelection,\n result.style?.selection ? result.style.selection : {}));\n zIndexOffset = 1;\n break;\n }\n abstractResult.meta.style = computedStyle;\n abstractResult.meta.style.setZIndex(2000 + zIndexOffset);\n this.map.searchResultsOverlay.addFeature(abstractResult, FeatureMotion.None);\n if (trigger === 'focused') {\n this.abstractFocusedResult = abstractResult;\n }\n if (trigger === 'selected') {\n this.abstractSelectedResult = abstractResult;\n }\n if (trigger === 'shown') {\n this.shownResultsEmphasisGeometries.push(abstractResult);\n }\n } else {\n this.clearFeatureEmphasis(trigger);\n }\n }\n\n private clearFeatureEmphasis(trigger: 'selected' | 'focused' | 'shown') {\n if (trigger === 'focused' && this.abstractFocusedResult) {\n this.map.searchResultsOverlay.removeFeature(this.abstractFocusedResult);\n this.abstractFocusedResult = undefined;\n }\n if (trigger === 'selected' && this.abstractSelectedResult) {\n this.map.searchResultsOverlay.removeFeature(this.abstractSelectedResult);\n this.abstractSelectedResult = undefined;\n }\n if (trigger === 'shown') {\n this.shownResultsEmphasisGeometries.map(shownResult => this.map.searchResultsOverlay.removeFeature(shownResult));\n this.shownResultsEmphasisGeometries = [];\n }\n }\n\n ngOnDestroy() {\n this.topPanelState$$.unsubscribe();\n this.searchTerm$$.unsubscribe();\n if (this.isSelectedResultOutOfView$$) {\n this.isSelectedResultOutOfView$$.unsubscribe();\n }\n if (this.showResultsGeometries$$) {\n this.showResultsGeometries$$.unsubscribe();\n }\n if (this.getRoute$$) {\n this.getRoute$$.unsubscribe();\n }\n }\n\n /**\n * Try to add a feature to the map when it's being focused\n * @internal\n * @param result A search result that could be a feature\n */\n onResultFocus(result: SearchResult) {\n this.focusedResult$.next(result);\n if (result.meta.dataType === FEATURE && result.data.geometry) {\n result.data.meta.style = getCommonVectorSelectedStyle(\n Object.assign({},\n { feature: result.data as Feature | olFeature<OlGeometry> },\n this.searchState.searchOverlayStyleFocus,\n result.style?.focus ? result.style.focus : {}));\n\n const feature = this.map.searchResultsOverlay.dataSource.ol.getFeatureById(result.meta.id);\n if (feature) {\n feature.setStyle(result.data.meta.style);\n return;\n }\n this.map.searchResultsOverlay.addFeature(result.data as Feature, FeatureMotion.None);\n }\n }\n\n onResultUnfocus(result: SearchResult) {\n this.focusedResult$.next(undefined);\n if (result.meta.dataType !== FEATURE) {\n return;\n }\n\n if (this.store.state.get(result).selected === true) {\n const feature = this.map.searchResultsOverlay.dataSource.ol.getFeatureById(result.meta.id);\n if (feature) {\n const style = getCommonVectorSelectedStyle(\n Object.assign({},\n { feature: result.data as Feature | olFeature<OlGeometry> },\n this.searchState.searchOverlayStyleFocus,\n result.style?.focus ? result.style.focus : {}));\n feature.setStyle(style);\n }\n return;\n }\n this.map.searchResultsOverlay.removeFeature(result.data as Feature);\n }\n\n /**\n * Try to add a feature to the map when it's being selected\n * @internal\n * @param result A search result that could be a feature or some layer options\n */\n onResultSelect(result: SearchResult) {\n this.map.searchResultsOverlay.dataSource.ol.clear();\n this.tryAddFeatureToMap(result);\n this.searchState.setSelectedResult(result);\n\n if (this.topPanelState === 'expanded') {\n const igoList = this.computeElementRef()[0];\n const selected = this.computeElementRef()[1];\n setTimeout(() => {\n // To be sure the flexible component has been displayed yet\n if (!this.isScrolledIntoView(igoList, selected)) {\n this.adjustTopPanel(igoList, selected);\n }\n }, FlexibleComponent.transitionTime + 50);\n }\n\n if (this.topPanelState === 'initial') {\n this.topPanelState = 'expanded';\n }\n }\n\n onSearch(event: { research: Research; results: SearchResult[] }) {\n const results = event.results;\n const newResults = this.store.entities$.value\n .filter((result: SearchResult) => result.source !== event.research.source)\n .concat(results);\n\n this.store.load(newResults);\n\n for (const res of this.store.all()) {\n if (\n this.store.state.get(res).focused === true &&\n this.store.state.get(res).selected !== true\n ) {\n this.store.state.update(res, { focused: false }, true);\n }\n }\n\n setTimeout(() => {\n const igoList = this.elRef.nativeElement.querySelector('igo-list');\n let moreResults;\n event.research.request.subscribe((source) => {\n if (!source[0] || !source[0].source) {\n moreResults = null;\n } else if (source[0].source.getId() === 'icherche') {\n moreResults = igoList.querySelector('.icherche .moreResults');\n } else if (source[0].source.getId() === 'ilayer') {\n moreResults = igoList.querySelector('.ilayer .moreResults');\n } else if (source[0].source.getId() === 'nominatim') {\n moreResults = igoList.querySelector('.nominatim .moreResults');\n } else {\n moreResults = igoList.querySelector('.' + source[0].source.getId() + ' .moreResults');\n }\n\n if (\n moreResults !== null &&\n !this.isScrolledIntoView(igoList, moreResults)\n ) {\n igoList.scrollTop =\n moreResults.offsetTop +\n moreResults.offsetHeight -\n igoList.clientHeight;\n }\n });\n }, 250);\n }\n\n computeElementRef() {\n const items = document.getElementsByTagName('igo-search-results-item');\n const igoList = this.elRef.nativeElement.getElementsByTagName(\n 'igo-list'\n )[0];\n let selectedItem;\n // eslint-disable-next-line\n for (let i = 0; i < items.length; i++) {\n if (items[i].className.includes('igo-list-item-selected')) {\n selectedItem = items[i];\n }\n }\n return [igoList, selectedItem];\n }\n\n adjustTopPanel(elemSource, elem) {\n if (!this.isScrolledIntoView(elemSource, elem)) {\n elemSource.scrollTop =\n elem.offsetTop +\n elem.children[0].offsetHeight -\n elemSource.clientHeight;\n }\n }\n\n toggleTopPanel() {\n if (this.topPanelState === 'expanded') {\n this.topPanelState = 'collapsed';\n } else {\n this.topPanelState = 'expanded';\n }\n }\n\n zoomToFeatureExtent() {\n if (this.feature.geometry) {\n const localOlFeature = this.format.readFeature(this.feature, {\n dataProjection: this.feature.projection,\n featureProjection: this.map.projection\n });\n moveToOlFeatures(this.map, [localOlFeature], FeatureMotion.Zoom);\n }\n }\n\n /**\n * Try to add a feature to the map overlay\n * @param result A search result that could be a feature\n */\n private tryAddFeatureToMap(result: SearchResult) {\n if (result.meta.dataType !== FEATURE) {\n return undefined;\n }\n const feature = (result as SearchResult<Feature>).data;\n\n // Somethimes features have no geometry. It happens with some GetFeatureInfo\n if (!feature.geometry) {\n return;\n }\n\n feature.meta.style = getCommonVectorSelectedStyle(\n Object.assign({},\n { feature },\n this.searchState.searchOverlayStyleSelection,\n result.style?.selection ? result.style.selection : {}));\n\n this.map.searchResultsOverlay.addFeature(feature);\n }\n\n isScrolledIntoView(elemSource, elem) {\n const padding = 6;\n const docViewTop = elemSource.scrollTop;\n const docViewBottom = docViewTop + elemSource.clientHeight;\n\n const elemTop = elem.offsetTop;\n const elemBottom = elemTop + elem.clientHeight + padding;\n return elemBottom <= docViewBottom && elemTop >= docViewTop;\n }\n\n getRoute() {\n this.toolState.toolbox.activateTool('directions');\n this.directionState.stopsStore.clearStops();\n setTimeout(() => {\n let routingCoordLoaded = false;\n if (this.getRoute$$) { this.getRoute$$.unsubscribe(); }\n this.getRoute$$ = this.directionState.stopsStore.storeInitialized$.subscribe((init: boolean) => {\n if (this.directionState.stopsStore.storeInitialized$.value && !routingCoordLoaded) {\n routingCoordLoaded = true;\n const stop = this.directionState.stopsStore.all().find((e) => e.position === 1);\n let coord;\n if (this.feature.geometry) {\n if (this.feature.geometry.type === 'Point') {\n coord = [this.feature.geometry.coordinates[0], this.feature.geometry.coordinates[1]];\n } else {\n const point = pointOnFeature(this.feature.geometry);\n coord = [point.geometry.coordinates[0], point.geometry.coordinates[1]];\n }\n }\n stop.text = this.featureTitle;\n stop.coordinates = coord;\n this.directionState.stopsStore.update(stop);\n }\n });\n }, 250);\n }\n}\n","import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatIconModule } from '@angular/material/icon';\nimport { MatBadgeModule } from '@angular/material/badge';\nimport { MatTooltipModule } from '@angular/material/tooltip';\n\nimport { IgoLanguageModule } from '@igo2/core';\nimport { IgoFlexibleModule, IgoCustomHtmlModule, IgoPanelModule } from '@igo2/common';\nimport {\n IgoFeatureModule,\n IgoSearchModule,\n IgoFeatureDetailsModule\n} from '@igo2/geo';\n\nimport { SearchResultsToolComponent } from './search-results-tool.component';\n\n/**\n * @ignore\n */\n@NgModule({\n imports: [\n CommonModule,\n MatIconModule,\n MatBadgeModule,\n MatTooltipModule,\n MatButtonModule,\n IgoLanguageModule,\n IgoFeatureModule,\n IgoSearchModule,\n IgoFlexibleModule,\n IgoPanelModule,\n IgoFeatureDetailsModule,\n IgoCustomHtmlModule\n ],\n declarations: [SearchResultsToolComponent],\n exports: [SearchResultsToolComponent],\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\n})\nexport class IgoAppSearchResultsToolModule {}\n","import { NgModule } from '@angular/core';\n\nimport { IgoAppSearchBarModule } from './search-bar/search-bar.module';\nimport { IgoAppSearchResultsToolModule } from './search-results-tool/search-results-tool.module';\n\n@NgModule({\n imports: [],\n declarations: [],\n exports: [\n IgoAppSearchBarModule,\n IgoAppSearchResultsToolModule\n ],\n})\nexport class IgoAppSearchModule {}\n","import { Component } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\n\n@ToolComponent({\n name: 'ogcFilter',\n title: 'igo.integration.tools.ogcFilter',\n icon: 'filter'\n})\n@Component({\n selector: 'igo-ogc-filter-tool',\n templateUrl: './ogc-filter-tool.component.html'\n})\nexport class OgcFilterToolComponent {\n constructor() {}\n}\n","<igo-ogc-filterable-list igoOgcFilterableListBinding></igo-ogc-filterable-list>\n\n\n","import { Component } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\n\n@ToolComponent({\n name: 'timeFilter',\n title: 'igo.integration.tools.timeFilter',\n icon: 'history'\n})\n@Component({\n selector: 'igo-time-filter-tool',\n templateUrl: './time-filter-tool.component.html'\n})\nexport class TimeFilterToolComponent {\n constructor() {}\n}\n","<igo-time-filter-list igoTimeFilterListBinding></igo-time-filter-list>\n","<igo-panel>\n <igo-spatial-filter-type\n [store]=\"spatialListStore\"\n [selectedQueryType]=\"queryType\"\n [zone]=\"zone\"\n [layers]=\"activeLayers\"\n (eventType)=\"getOutputType($event)\"\n (eventQueryType)=\"getOutputQueryType($event)\"\n (zoneChange)=\"onZoneChange($event)\"\n (zoneWithBufferChange)=\"onZoneChange($event, true)\"\n (bufferChange)=\"buffer = $event\"\n (measureUnitChange)=\"measureUnit = $event\">\n </igo-spatial-filter-type>\n\n <igo-spatial-filter-item\n [type]=\"type\"\n [queryType]=\"queryType\"\n [map]=\"map\"\n [zone]=\"zone\"\n [loading]=\"loading\"\n [store]=\"store\"\n [layers]=\"activeLayers\"\n [allLayers]=\"layers\"\n [thematicLength]=\"thematicLength\"\n (radiusEvent)=\"buffer = $event\"\n (bufferEvent)=\"buffer = $event\"\n (measureUnitChange)=\"measureUnit = $event\"\n (freehandControl)=\"freehandDrawIsActive = $event\"\n (drawZoneEvent)=\"zone = $event\"\n (zoneWithBufferChange)=\"onZoneChange($event, true)\"\n (itemTypeChange)=\"itemType = $event\"\n (thematicChange)=\"thematics = $event\"\n (toggleSearch)=\"getOutputToggleSearch()\"\n (clearButtonEvent)=\"clearMap()\"\n (clearSearchEvent)=\"getOutputClearSearch()\"\n (export)=\"activateExportTool()\"\n (openWorkspace)=\"activateWorkspace()\"\n (entityChange)=\"activateWorkspace($event)\">\n </igo-spatial-filter-item>\n</igo-panel>\n\n<igo-panel>\n <ng-container *ngIf=\"selectedFeature$ | async as feature\">\n <igo-feature-details [feature]=\"feature\"></igo-feature-details>\n </ng-container>\n</igo-panel>","import { Component, Input, ChangeDetectionStrategy, ChangeDetectorRef, OnDestroy, OnInit } from '@angular/core';\nimport { MatIconRegistry } from '@angular/material/icon';\nimport { Observable, forkJoin, Subject } from 'rxjs';\nimport { tap, take, takeUntil } from 'rxjs/operators';\n\nimport {\n IgoMap,\n DataSourceService,\n LayerService,\n Feature,\n moveToOlFeatures,\n FeatureMotion,\n ClusterDataSource,\n featureToOl,\n DataSource,\n QueryableDataSourceOptions,\n SpatialFilterService,\n SpatialFilterType,\n SpatialFilterItemType,\n SpatialFilterQueryType,\n SpatialFilterThematic,\n Layer,\n createOverlayMarkerStyle,\n ExportOptions,\n MeasureLengthUnit\n} from '@igo2/geo';\nimport { EntityStore, ToolComponent } from '@igo2/common';\nimport olFormatGeoJSON from 'ol/format/GeoJSON';\nimport olSourceVector from 'ol/source/Vector';\nimport olSourceCluster from 'ol/source/Cluster';\nimport type { default as OlGeometry } from 'ol/geom/Geometry';\nimport { BehaviorSubject } from 'rxjs';\nimport { MapState } from '../../map/map.state';\nimport { ImportExportMode, ImportExportState } from './../../import-export/import-export.state';\nimport * as olstyle from 'ol/style';\nimport { MessageService, LanguageService } from '@igo2/core';\nimport { ToolState } from '../../tool/tool.state';\nimport { WorkspaceState } from '../../workspace/workspace.state';\nimport { EventsKey } from 'ol/events';\n\n/**\n * Tool to apply spatial filter\n */\n@ToolComponent({\n name: 'spatialFilter',\n title: 'igo.integration.tools.spatialFilter',\n icon: 'selection-marker'\n})\n/**\n * Spatial Filter Type\n */\n@Component({\n selector: 'igo-spatial-filter-tool',\n templateUrl: './spatial-filter-tool.component.html',\n styleUrls: ['./spatial-filter-tool.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SpatialFilterToolComponent implements OnInit, OnDestroy {\n get map(): IgoMap {\n return this.mapState.map;\n }\n\n @Input() type: SpatialFilterType;\n @Input() itemType: SpatialFilterItemType = SpatialFilterItemType.Address;\n @Input() freehandDrawIsActive: boolean;\n\n public layers: Layer[] = [];\n public activeLayers: Layer[] = [];\n\n public queryType: SpatialFilterQueryType;\n public thematics: SpatialFilterThematic[];\n public zone: Feature;\n public zoneWithBuffer: Feature;\n public buffer = 0;\n\n public iterator = 1;\n\n public selectedFeature$: BehaviorSubject<Feature> = new BehaviorSubject(\n undefined\n );\n\n private format = new olFormatGeoJSON();\n\n public store: EntityStore<Feature> = new EntityStore<Feature>([]); // Store to print results at the end\n\n public spatialListStore: EntityStore<Feature> = new EntityStore<Feature>([]);\n\n public loading = false;\n\n public thematicLength = 0;\n\n public measureUnit: MeasureLengthUnit = MeasureLengthUnit.Meters;\n private unsubscribe$ = new Subject<void>();\n\n private moveendKey: EventsKey;\n\n constructor(\n private matIconRegistry: MatIconRegistry,\n private spatialFilterService: SpatialFilterService,\n private dataSourceService: DataSourceService,\n private layerService: LayerService,\n private mapState: MapState,\n private messageService: MessageService,\n private languageService: LanguageService,\n private importExportState: ImportExportState,\n private toolState: ToolState,\n private workspaceState: WorkspaceState,\n private cdRef: ChangeDetectorRef\n ) {}\n\n ngOnInit() {\n for (const layer of this.map.layers) {\n if (layer.title && layer.title.includes(this.languageService.translate.instant('igo.geo.spatialFilter.spatialFilter'))) {\n this.layers.push(layer);\n }\n }\n }\n\n ngOnDestroy() {\n this.unsubscribe$.next();\n this.unsubscribe$.complete();\n }\n\n getOutputType(event: SpatialFilterType) {\n this.type = event;\n this.queryType = undefined;\n }\n\n getOutputQueryType(event: SpatialFilterQueryType) {\n this.queryType = event;\n if (this.queryType) {\n this.loadFilterList();\n }\n }\n\n activateExportTool() {\n const ids = [];\n const re = new RegExp('^Zone \\\\d+');\n for (const layer of this.layers) {\n if (!layer.title.match(re)) {\n ids.push(layer.id);\n }\n }\n this.importExportState.setMode(ImportExportMode.export);\n this.importExportState.setsExportOptions({ layers: ids } as ExportOptions);\n this.toolState.toolbox.activateTool('importExport');\n }\n\n activateWorkspace(record?) {\n let layerToOpenWks;\n this.workspaceState.store.entities$.pipe(takeUntil(this.unsubscribe$)).subscribe(() => {\n if (!record && this.activeLayers.length && this.workspaceState.store.all().length > 1) {\n if (this.itemType === SpatialFilterItemType.Thematics) {\n for (const thematic of this.thematics) {\n if (!thematic.zeroResults) {\n layerToOpenWks = this.activeLayers.find(layer => layer.title.includes(thematic.name + ' ' + this.iterator.toString()));\n break;\n }\n }\n } else {\n const title = 'Adresses ' + this.iterator.toString();\n this.activeLayers.forEach((layer) => {\n if (layer.title.includes(title)) {\n layerToOpenWks = layer;\n }\n });\n }\n\n if (layerToOpenWks) {\n this.workspaceState.workspacePanelExpanded = true;\n this.workspaceState.setActiveWorkspaceById(layerToOpenWks.id);\n }\n } else if (record && this.activeLayers.length && this.workspaceState.store.all().length > 1) {\n this.selectWorkspaceEntity(record);\n this.moveendKey = this.map.ol.on('moveend', () => {\n this.selectWorkspaceEntity(record);\n });\n }\n });\n }\n\n private selectWorkspaceEntity(record) {\n this.workspaceState.store.all().forEach(workspace => {\n workspace.entityStore.state.updateAll({selected: false});\n if (workspace.title.includes(record.added[0].meta.title)) {\n this.workspaceState.setActiveWorkspaceById(workspace.id);\n workspace.entityStore.state.updateMany(record.added, {selected: true});\n }\n });\n }\n\n private loadFilterList() {\n this.spatialFilterService\n .loadFilterList(this.queryType)\n .pipe(takeUntil(this.unsubscribe$))\n .subscribe((features: Feature[]) => {\n features.sort((a, b) => {\n if (a.properties.nom < b.properties.nom) {\n return -1;\n }\n if (a.properties.nom > b.properties.nom) {\n return 1;\n }\n return 0;\n });\n this.spatialListStore.clear();\n this.spatialListStore.load(features);\n });\n }\n\n getOutputToggleSearch() {\n this.loadThematics();\n }\n\n getOutputClearSearch() {\n this.zone = undefined;\n this.queryType = undefined;\n }\n\n clearMap() {\n this.map.removeLayers(this.layers);\n this.layers = [];\n this.activeLayers = [];\n this.thematicLength = 0;\n this.iterator = 1;\n if (this.type === SpatialFilterType.Predefined) {\n this.zone = undefined;\n this.queryType = undefined;\n }\n }\n\n private loadThematics() {\n this.loading = true;\n let zeroResults = true;\n let thematics;\n if (this.buffer === 0 || this.type === SpatialFilterType.Point) {\n this.tryAddFeaturesToMap([this.zone]);\n }\n if (this.itemType !== SpatialFilterItemType.Thematics) {\n const theme: SpatialFilterThematic = {\n name: ''\n };\n thematics = [theme];\n } else {\n thematics = this.thematics;\n }\n if (this.measureUnit === MeasureLengthUnit.Kilometers && this.type !== SpatialFilterType.Point) {\n this.buffer = this.buffer * 1000;\n }\n if (this.type === SpatialFilterType.Polygon) {\n this.buffer = 0; // to avoid buffer enter a second time in terrAPI\n }\n\n const observables$: Observable<Feature[]>[] = [];\n thematics.forEach(thematic => {\n observables$.push(\n this.spatialFilterService\n .loadFilterItem(\n this.zone,\n this.itemType,\n this.queryType,\n thematic,\n this.buffer\n )\n .pipe(\n tap((features: Feature[]) => {\n this.store.insertMany(features);\n const featuresPoint: Feature[] = [];\n const featuresLinePoly: Feature[] = [];\n let idPoint;\n let idLinePoly;\n features.forEach(feature => {\n if (feature.geometry.type === 'Point') {\n feature.properties.longitude = feature.geometry.coordinates[0];\n feature.properties.latitude = feature.geometry.coordinates[1];\n featuresPoint.push(feature);\n idPoint = feature.meta.id;\n } else {\n featuresLinePoly.push(feature);\n idLinePoly = feature.meta.id;\n }\n });\n\n this.tryAddPointToMap(featuresPoint, idPoint);\n this.tryAddLayerToMap(featuresLinePoly, idLinePoly);\n if (features.length) {\n zeroResults = false;\n this.thematicLength += 1;\n thematic.zeroResults = false;\n this.cdRef.detectChanges();\n } else {\n thematic.zeroResults = true;\n }\n\n if (features.length >= 10000) {\n this.messageService.alert(\n this.languageService.translate.instant(\n 'igo.geo.spatialFilter.maxSizeAlert'\n ),\n this.languageService.translate.instant(\n 'igo.geo.spatialFilter.warning'\n ),\n { timeOut: 10000 }\n );\n }\n })\n )\n );\n });\n\n forkJoin(observables$).pipe(takeUntil(this.unsubscribe$)).subscribe(() => {\n this.loading = false;\n if (zeroResults) {\n this.messageService.alert(\n this.languageService.translate.instant(\n 'igo.geo.spatialFilter.zeroResults'\n ),\n this.languageService.translate.instant(\n 'igo.geo.spatialFilter.warning'\n ),\n { timeOut: 10000 }\n );\n }\n });\n }\n\n onZoneChange(feature: Feature, buffer?: boolean) {\n this.zone = feature;\n if (feature) {\n buffer ? this.tryAddFeaturesToMap([feature], true) : this.tryAddFeaturesToMap([feature]);\n this.zoomToFeatureExtent(feature);\n }\n }\n\n /**\n * Try to add zone feature to the map overlay\n */\n public tryAddFeaturesToMap(features: Feature[], buffer?: boolean) {\n let i = 1;\n for (const feature of features) {\n if (this.type === SpatialFilterType.Predefined) {\n for (const layer of this.layers) {\n if (\n layer.options._internal &&\n layer.options._internal.code === feature.properties.code &&\n !buffer\n ) {\n if (!layer.title?.startsWith('Zone')) {\n const index = this.layers.indexOf(layer);\n this.layers.splice(index, 1);\n }\n return;\n }\n if (layer.title?.startsWith('Zone')) {\n this.activeLayers = [];\n const index = this.layers.indexOf(layer);\n this.layers.splice(index, 1);\n this.map.removeLayer(layer);\n }\n }\n } else {\n if (buffer) {\n for (const layer of this.activeLayers) {\n if (this.activeLayers.length === 1 && layer.title?.startsWith('Zone')) {\n const index = this.layers.indexOf(layer);\n this.layers.splice(index, 1);\n this.map.removeLayer(layer);\n }\n }\n }\n this.activeLayers = [];\n }\n for (const layer of this.layers) {\n if (layer.title?.startsWith('Zone')) {\n i++;\n }\n }\n this.dataSourceService\n .createAsyncDataSource({\n type: 'vector',\n queryable: true\n } as QueryableDataSourceOptions)\n .pipe(take(1))\n .subscribe((dataSource: DataSource) => {\n const olLayer = this.layerService.createLayer({\n title: ('Zone ' + i + ' - ' + this.languageService.translate.instant(\n 'igo.geo.spatialFilter.spatialFilter'\n )) as string,\n workspace: { enabled: true },\n _internal: {\n code:\n this.type === SpatialFilterType.Predefined\n ? feature.properties.code\n : undefined\n },\n source: dataSource,\n visible: true,\n style: (_feature, resolution) => {\n const coordinates = (features[0] as any).coordinates;\n return new olstyle.Style({\n image: new olstyle.Circle({\n radius: coordinates\n ? this.buffer /\n Math.cos((Math.PI / 180) * coordinates[1]) /\n resolution\n : undefined,\n fill: new olstyle.Fill({\n color: 'rgba(200, 200, 20, 0.2)'\n }),\n stroke: new olstyle.Stroke({\n width: 1,\n color: 'orange'\n })\n }),\n stroke: new olstyle.Stroke({\n width: 1,\n color: 'orange'\n }),\n fill: new olstyle.Fill({\n color: 'rgba(200, 200, 20, 0.2)'\n })\n });\n }\n });\n const featuresOl = features.map(f => {\n return featureToOl(f, this.map.projection);\n });\n if (this.type !== SpatialFilterType.Predefined) {\n const type = this.type === SpatialFilterType.Point ? 'Cercle' : 'Polygone';\n featuresOl[0].set('nom', 'Zone', true);\n featuresOl[0].set('type', type, true);\n }\n const ol = dataSource.ol as olSourceVector<OlGeometry> | olSourceCluster;\n ol.addFeatures(featuresOl);\n this.map.addLayer(olLayer);\n this.layers.push(olLayer);\n this.activeLayers.push(olLayer);\n this.cdRef.detectChanges();\n });\n }\n }\n\n /**\n * Try to add point features to the map\n * Necessary to create clusters\n */\n private tryAddPointToMap(features: Feature[], id) {\n let i = 1;\n if (features.length) {\n if (this.map === undefined) {\n return;\n }\n for (const layer of this.layers) {\n if (layer.title?.startsWith(features[0].meta.title)) {\n i++;\n }\n }\n this.dataSourceService\n .createAsyncDataSource({\n type: 'cluster',\n id,\n queryable: true,\n distance: 120,\n meta: {\n title: 'Cluster'\n }\n } as QueryableDataSourceOptions)\n .pipe(take(1))\n .subscribe((dataSource: ClusterDataSource) => {\n const icon = features[0].meta.icon;\n let style: olstyle.Style;\n if (!icon) {\n style = createOverlayMarkerStyle();\n } else {\n style = this.createSvgIcon(icon) || createOverlayMarkerStyle();\n }\n\n const olLayer = this.layerService.createLayer({\n title: (features[0].meta.title + ' ' + i + ' - ' + this.languageService.translate.instant(\n 'igo.geo.spatialFilter.spatialFilter'\n )) as string,\n source: dataSource,\n visible: true,\n style\n });\n\n const featuresOl = features.map(feature => {\n return featureToOl(feature, this.map.projection);\n });\n const ol = dataSource.ol as olSourceCluster;\n ol.getSource().addFeatures(featuresOl);\n if (this.layers.find(layer => layer.id === olLayer.id)) {\n this.map.removeLayer(\n this.layers.find(layer => layer.id === olLayer.id)\n );\n i = i - 1;\n olLayer.title = (features[0].meta.title + ' ' + i + ' - ' + this.languageService.translate.instant(\n 'igo.geo.spatialFilter.spatialFilter'\n )) as string;\n olLayer.options.title = olLayer.title;\n }\n this.iterator = i;\n this.map.addLayer(olLayer);\n this.layers.push(olLayer);\n this.pushLayer(olLayer);\n this.cdRef.detectChanges();\n });\n }\n }\n\n private createSvgIcon(icon): olstyle.Style {\n let style: olstyle.Style;\n this.matIconRegistry.getNamedSvgIcon(icon).subscribe(svgObj => {\n const xmlSerializer = new XMLSerializer();\n svgObj.setAttribute('width', '30');\n svgObj.setAttribute('height', '30');\n svgObj.setAttribute('fill', 'rgba(0, 128, 255)');\n svgObj.setAttribute('stroke', 'white');\n const svg = xmlSerializer.serializeToString(svgObj);\n style = new olstyle.Style({\n image: new olstyle.Icon({\n src: 'data:image/svg+xml;utf8,' + svg\n })\n });\n });\n return style;\n }\n /**\n * Try to add line or polygon features to the map\n */\n private tryAddLayerToMap(features: Feature[], id) {\n let i = 1;\n if (features.length) {\n if (this.map === undefined) {\n return;\n }\n for (const layer of this.layers) {\n if (layer.title?.startsWith(features[0].meta.title)) {\n i++;\n }\n }\n this.dataSourceService\n .createAsyncDataSource({\n type: 'vector',\n id,\n queryable: true\n } as QueryableDataSourceOptions)\n .pipe(take(1))\n .subscribe((dataSource: DataSource) => {\n const olLayer = this.layerService.createLayer({\n title: (features[0].meta.title + ' ' + i + ' - ' + this.languageService.translate.instant(\n 'igo.geo.spatialFilter.spatialFilter'\n )) as string,\n source: dataSource,\n visible: true\n });\n const featuresOl = features.map(feature => {\n return featureToOl(feature, this.map.projection);\n });\n const ol = dataSource.ol as olSourceVector<OlGeometry>;\n ol.addFeatures(featuresOl);\n if (this.layers.find(layer => layer.id === olLayer.id)) {\n this.map.removeLayer(\n this.layers.find(layer => layer.id === olLayer.id)\n );\n i = i - 1;\n olLayer.title = (features[0].meta.title + ' ' + i + ' - ' + this.languageService.translate.instant(\n 'igo.geo.spatialFilter.spatialFilter'\n )) as string;\n olLayer.options.title = olLayer.title;\n }\n this.map.addLayer(olLayer);\n this.layers.push(olLayer);\n this.pushLayer(olLayer);\n this.cdRef.detectChanges();\n });\n }\n }\n\n zoomToFeatureExtent(feature) {\n if (feature) {\n const olFeature = this.format.readFeature(feature, {\n dataProjection: feature.projection,\n featureProjection: this.map.projection\n });\n moveToOlFeatures(this.map, [olFeature], FeatureMotion.Zoom);\n }\n }\n\n pushLayer(layer) {\n for (const lay of this.activeLayers) {\n if (lay.id === layer.id) {\n return;\n }\n }\n\n this.activeLayers.push(layer);\n }\n}\n","import {\n trigger,\n state,\n style,\n transition,\n animate,\n AnimationTriggerMetadata\n} from '@angular/animations';\n\nexport function toolSlideInOut(\n speed = '300ms',\n type = 'ease-in-out'\n): AnimationTriggerMetadata {\n return trigger('toolSlideInOut', [\n state(\n 'enter',\n style({\n transform: 'translateX(100%)'\n })\n ),\n transition('void => enter', animate(speed + ' ' + type))\n ]);\n}\n","import { Component } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\nimport { MapState } from '../../map/map.state';\nimport { IgoMap, Layer } from '@igo2/geo';\nimport { toolSlideInOut } from './active-time-filter-tool.animation';\n\n@ToolComponent({\n name: 'activeTimeFilter',\n title: 'igo.integration.tools.timeFilter',\n icon: 'history',\n parent: 'mapTools'\n})\n@Component({\n selector: 'igo-active-time-filter-tool',\n templateUrl: './active-time-filter-tool.component.html',\n animations: [toolSlideInOut()]\n})\nexport class ActiveTimeFilterToolComponent {\n\n get map(): IgoMap {\n return this.mapState.map;\n }\n\n get layer(): Layer {\n for (const lay of this.map.layers) {\n if (lay.options.active === true) {\n return lay;\n }\n }\n return;\n }\n\n public animate = 'enter';\n\n constructor(public mapState: MapState) {}\n}\n","<igo-time-filter-item\n [map]=\"map\"\n [layer]=\"layer\"\n [header]=\"false\"\n [@toolSlideInOut]=\"animate\">\n</igo-time-filter-item>\n","import {\n trigger,\n state,\n style,\n transition,\n animate,\n AnimationTriggerMetadata\n} from '@angular/animations';\n\nexport function toolSlideInOut(\n speed = '300ms',\n type = 'ease-in-out'\n): AnimationTriggerMetadata {\n return trigger('toolSlideInOut', [\n state(\n 'enter',\n style({\n transform: 'translateX(100%)'\n })\n ),\n transition('void => enter', animate(speed + ' ' + type))\n ]);\n}\n","import { Component } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\nimport { MapState } from '../../map/map.state';\nimport { Layer, IgoMap } from '@igo2/geo';\n\nimport { toolSlideInOut } from './active-ogc-filter-tool.animation';\n\n@ToolComponent({\n name: 'activeOgcFilter',\n title: 'igo.integration.tools.ogcFilter',\n icon: 'filter',\n parent: 'mapTools'\n})\n@Component({\n selector: 'igo-active-ogc-filter-tool',\n templateUrl: './active-ogc-filter-tool.component.html',\n animations: [toolSlideInOut()]\n})\nexport class ActiveOgcFilterToolComponent {\n\n get map(): IgoMap {\n return this.mapState.map;\n }\n\n get layer(): Layer {\n for (const lay of this.map.layers) {\n if (lay.options.active === true) {\n return lay;\n }\n }\n return;\n }\n\n public animate = 'enter';\n\n constructor(public mapState: MapState) {}\n}\n","<igo-ogc-filterable-item\n [map]=\"map\"\n [layer]=\"layer\"\n [header]=\"false\"\n [@toolSlideInOut]=\"animate\">\n</igo-ogc-filterable-item>\n\n\n","import {\n NgModule,\n ModuleWithProviders,\n CUSTOM_ELEMENTS_SCHEMA\n} from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\nimport { IgoFilterModule, IgoQueryModule } from '@igo2/geo';\nimport { OgcFilterToolComponent } from './ogc-filter-tool/ogc-filter-tool.component';\nimport { TimeFilterToolComponent } from './time-filter-tool/time-filter-tool.component';\nimport { SpatialFilterToolComponent } from './spatial-filter-tool/spatial-filter-tool.component';\nimport { ActiveTimeFilterToolComponent } from './active-time-filter-tool/active-time-filter-tool.component';\nimport { ActiveOgcFilterToolComponent } from './active-ogc-filter-tool/active-ogc-filter-tool.component';\n\n@NgModule({\n imports: [IgoFilterModule, IgoQueryModule, CommonModule],\n declarations: [\n OgcFilterToolComponent,\n ActiveOgcFilterToolComponent,\n TimeFilterToolComponent,\n ActiveTimeFilterToolComponent,\n SpatialFilterToolComponent\n ],\n exports: [\n OgcFilterToolComponent,\n ActiveOgcFilterToolComponent,\n TimeFilterToolComponent,\n ActiveTimeFilterToolComponent,\n SpatialFilterToolComponent\n ],\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\n})\nexport class IgoAppFilterModule {\n static forRoot(): ModuleWithProviders<IgoAppFilterModule> {\n return {\n ngModule: IgoAppFilterModule,\n providers: []\n };\n }\n}\n","<p></p>\n<igo-interactive-tour\n mat-raised-button\n tourToStart=\"global\"\n menuIsOpen=true\n styleButton=\"raised\"\n [discoverTitleInLocale$]=\"discoverTitleInLocale$\">\n</igo-interactive-tour>\n\n<button *ngIf=\"auth.authenticated && trainingGuideURLs && trainingGuideURLs.length === 1\"\n class=\"training-guide-button\"\n mat-raised-button\n tooltip-position=\"below\"\n matTooltipShowDelay=\"500\"\n [disabled]=\"loading\"\n [matTooltip]=\"'igo.integration.aboutTool.trainingGuideTooltip' | translate\"\n (click)=\"openGuide()\">\n <span>{{'igo.integration.aboutTool.trainingGuide' | translate}}</span>\n <mat-icon svgIcon=\"file-document\"></mat-icon>\n</button>\n\n<button *ngIf=\"auth.authenticated && trainingGuideURLs && trainingGuideURLs.length > 1\"\n class=\"training-guide-button\"\n mat-raised-button\n tooltip-position=\"below\"\n matTooltipShowDelay=\"500\"\n [disabled]=\"loading\"\n [matTooltip]=\"'igo.integration.aboutTool.trainingGuideTooltip' | translate\"\n [matMenuTriggerFor]=\"menu\">\n <span>{{'igo.integration.aboutTool.trainingGuide' | translate}}</span>\n <mat-icon svgIcon=\"file-document\"></mat-icon>\n</button>\n\n<mat-menu #menu=\"matMenu\">\n <button *ngFor=\"let guide of trainingGuideURLs\" mat-menu-item (click)=\"openGuide(guide)\">{{formatFileName(guide)}}</button>\n</mat-menu>\n\n<igo-custom-html *ngIf=\"headerHtml !== ''\" class=\"mat-typography\"\n [html]=\"headerHtml | translate\">\n</igo-custom-html>\n\n<igo-custom-html class=\"mat-typography\"\n [html]=\"html | translate: {version: version}\">\n</igo-custom-html>\n","import { ChangeDetectorRef, Component, Input, OnInit } from '@angular/core';\n\nimport { ToolComponent } from '@igo2/common';\nimport { ConfigService, LanguageService, Version } from '@igo2/core';\nimport { of } from 'rxjs';\nimport type { Observable } from 'rxjs';\nimport { AuthService } from '@igo2/auth';\nimport { HttpClient } from '@angular/common/http';\n\n@ToolComponent({\n name: 'about',\n title: 'igo.integration.tools.about',\n icon: 'help-circle'\n})\n@Component({\n selector: 'igo-about-tool',\n templateUrl: './about-tool.component.html',\n styleUrls: ['./about-tool.component.scss']\n})\nexport class AboutToolComponent implements OnInit {\n @Input()\n get headerHtml() {\n return this._headerHtml;\n }\n set headerHtml(value: string) {\n this._headerHtml = Array.isArray(value) ? value.join('\\n') : value;\n }\n\n @Input()\n get html() {\n return this._html;\n }\n set html(value: string) {\n this._html = Array.isArray(value) ? value.join('\\n') : value;\n }\n private _discoverTitleInLocale: string = 'IGO';\n public discoverTitleInLocale$: Observable<string> = of(this._discoverTitleInLocale);\n\n @Input()\n get discoverTitleInLocale() {\n return this._discoverTitleInLocale;\n }\n set discoverTitleInLocale(value: string) {\n this._discoverTitleInLocale = value;\n this.discoverTitleInLocale$ = of(value);\n }\n\n @Input() trainingGuideURLs;\n\n public version: Version;\n private _html: string = 'igo.integration.aboutTool.html';\n private _headerHtml: string = this.languageService.translate.instant('igo.integration.aboutTool.headerHtml');\n\n private baseUrlProfil;\n private baseUrlGuide;\n\n public loading = false;\n\n constructor(\n public configService: ConfigService,\n public auth: AuthService,\n private http: HttpClient,\n private cdRef: ChangeDetectorRef,\n private languageService: LanguageService) {\n this.version = configService.getConfig('version');\n this.baseUrlProfil = configService.getConfig('context.url') + '/user/igo?';\n this.baseUrlGuide = configService.getConfig('depot.url') + '/projects/Documentation/files/';\n }\n\n ngOnInit() {\n if (this.auth.authenticated && this.configService.getConfig('context.url')) {\n this.http.get(this.baseUrlProfil).subscribe((profil) => {\n const recast = profil as any;\n this.trainingGuideURLs = recast.guides;\n this.cdRef.detectChanges();\n });\n } else if (\n this.auth.authenticated &&\n !this.configService.getConfig('context.url') &&\n this.configService.getConfig('depot.trainingGuides')) {\n this.trainingGuideURLs = this.configService.getConfig('depot.trainingGuides');\n }\n }\n\n openGuide(guide?) {\n this.loading = true;\n const url = guide ?\n this.baseUrlGuide + guide + '?' :\n this.baseUrlGuide + this.trainingGuideURLs[0] + '?';\n this.http\n .get(url, {\n responseType: 'blob'\n })\n .subscribe(() => {\n this.loading = false;\n window.open(url, '_blank');\n this.cdRef.detectChanges();\n });\n }\n\n formatFileName(name: string) {\n name = name.split('_').join(' ');\n const index = name.indexOf('.');\n name = name.slice(0, index);\n return name;\n }\n}\n","import {\n NgModule,\n ModuleWithProviders,\n CUSTOM_ELEMENTS_SCHEMA\n} from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { MatTooltipModule } from '@angular/material/tooltip';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatIconModule } from '@angular/material/icon';\nimport { MatMenuModule } from '@angular/material/menu';\n\nimport { IgoLanguageModule } from '@igo2/core';\nimport { IgoCustomHtmlModule, IgoInteractiveTourModule } from '@igo2/common';\n\nimport { AboutToolComponent } from './about-tool/about-tool.component';\n\n@NgModule({\n imports: [\n IgoLanguageModule,\n IgoCustomHtmlModule,\n MatButtonModule,\n MatTooltipModule,\n MatIconModule,\n MatMenuModule,\n IgoInteractiveTourModule,\n CommonModule\n ],\n declarations: [AboutToolComponent],\n exports: [AboutToolComponent],\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\n})\nexport class IgoAppAboutModule {\n static forRoot(): ModuleWithProviders<IgoAppAboutModule> {\n return {\n ngModule: IgoAppAboutModule,\n providers: []\n };\n }\n}\n","import { NgModule } from '@angular/core';\n\n@NgModule({\n imports: [],\n declarations: [],\n exports: []\n})\nexport class IgoAppStorageModule {}\n","import { NgModule } from '@angular/core';\n\nimport { IgoAppAnalyticsModule } from './analytics/analytics.module';\nimport { IgoAppContextModule } from './context/context.module';\nimport { IgoAppCatalogModule } from './catalog/catalog.module';\nimport { IgoAppDirectionsModule } from './directions/directions.module';\nimport { IgoAppDrawModule } from './draw/draw.module';\nimport { IgoAppWorkspaceModule } from './workspace/workspace.module';\nimport { IgoAppImportExportModule } from './import-export/import-export.module';\nimport { IgoAppMapModule } from './map/map.module';\nimport { IgoAppMeasureModule } from './measure/measure.module';\nimport { IgoAppPrintModule } from './print/print.module';\nimport { IgoAppSearchModule } from './search/search.module';\nimport { IgoAppFilterModule } from './filter/filter.module';\nimport { IgoAppAboutModule } from './about/about.module';\nimport { IgoAppStorageModule } from './storage/storage.module';\n\n@NgModule({\n imports: [],\n declarations: [],\n exports: [\n IgoAppStorageModule,\n IgoAppAnalyticsModule,\n IgoAppContextModule,\n IgoAppCatalogModule,\n IgoAppDirectionsModule,\n IgoAppDrawModule,\n IgoAppWorkspaceModule,\n IgoAppImportExportModule,\n IgoAppMapModule,\n IgoAppMeasureModule,\n IgoAppPrintModule,\n IgoAppSearchModule,\n IgoAppFilterModule,\n IgoAppAboutModule\n ]\n})\nexport class IgoIntegrationModule {}\n","import { NgModule } from '@angular/core';\n\n@NgModule({\n imports: [],\n declarations: [],\n exports: []\n})\nexport class IgoAppToolModule {}\n","import { Injectable } from '@angular/core';\n\nimport { BehaviorSubject } from 'rxjs';\n\nimport { LanguageService } from '@igo2/core';\nimport { Tool, ToolService } from '@igo2/common';\nimport { ContextService, DetailedContext } from '@igo2/context';\n\nimport { ToolState } from '../tool/tool.state';\n\n/**\n * Service that holds the state of the context module\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class ContextState {\n /**\n * Observable of the active context\n */\n context$: BehaviorSubject<DetailedContext> = new BehaviorSubject(undefined);\n\n constructor(\n private contextService: ContextService,\n private toolService: ToolService,\n private toolState: ToolState,\n private languageService: LanguageService\n ) {\n this.contextService.context$.subscribe((context: DetailedContext) => {\n this.onContextChange(context);\n });\n this.contextService.toolsChanged$.subscribe((context: DetailedContext) => {\n this.updateTools(context);\n });\n }\n\n /**\n * Set the active context\n * @param context Detailed context\n */\n private setContext(context: DetailedContext) {\n this.updateTools(context);\n this.context$.next(context);\n }\n\n /**\n * Update the tool state with the context's tools\n * @param context Detailed context\n */\n private updateTools(context: DetailedContext) {\n const toolbox = this.toolState.toolbox;\n\n const tools = [];\n const contextTools = context.tools || [];\n contextTools.forEach((contextTool: Tool) => {\n const baseTool = this.toolService.getTool(contextTool.name);\n if (baseTool === undefined) {\n return;\n }\n\n const options = Object.assign(\n {},\n baseTool.options || {},\n contextTool.options || {}\n );\n const tool = Object.assign({}, baseTool, contextTool, { options });\n tools.push(tool);\n });\n\n tools.forEach((tool) => {\n if (tool.parent) {\n const parentIndex = tools.findIndex((el) => el.name === tool.parent);\n if (parentIndex !== -1) {\n tools[parentIndex].children = [];\n tools[parentIndex].children.push(tool.name);\n }\n }\n });\n\n toolbox.setTools(tools);\n toolbox.setToolbar(context.toolbar || []);\n\n // TODO: This is a patch so the context service can work without\n // injecting the ToolState or without being completely refactored\n this.contextService.setTools([].concat(tools));\n this.contextService.setToolbar(context.toolbar || []);\n }\n\n /**\n * Set a new context and update the tool state\n * @param context Detailed context\n */\n private onContextChange(context: DetailedContext) {\n if (context === undefined) {\n return;\n }\n this.setContext(context);\n }\n}\n","import { Injectable } from '@angular/core';\nimport { skip } from 'rxjs/operators';\n\nimport { AnalyticsService } from '@igo2/core';\nimport { AuthService } from '@igo2/auth';\n\nimport { ContextState } from '../context/context.state';\nimport { SearchState } from '../search/search.state';\nimport { ToolState } from '../tool/tool.state';\n\n/**\n * Service that holds the state of the search module\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class AnalyticsListenerService {\n /**\n * Toolbox that holds main tools\n */\n\n constructor(\n private analyticsService: AnalyticsService,\n private authService: AuthService,\n private contextState: ContextState,\n private searchState: SearchState,\n private toolState: ToolState\n ) {}\n\n listen() {\n this.listenUser();\n this.listenContext();\n this.listenTool();\n this.listenSearch();\n }\n\n listenUser() {\n this.authService.authenticate$.subscribe(() => {\n const tokenDecoded = this.authService.decodeToken() || {};\n if (tokenDecoded.user) {\n this.authService\n .getProfils()\n .subscribe(profils =>\n this.analyticsService.setUser(tokenDecoded.user, profils.profils)\n );\n } else {\n this.analyticsService.setUser();\n }\n });\n }\n\n listenContext() {\n this.contextState.context$.subscribe(context => {\n if (context) {\n this.analyticsService.trackEvent('context', 'activateContext', context.id || context.uri);\n }\n });\n }\n\n listenTool() {\n this.toolState.toolbox.activeTool$.pipe(skip(1)).subscribe(tool => {\n if (tool) {\n this.analyticsService.trackEvent('tool', 'activateTool', tool.name);\n }\n });\n }\n\n listenSearch() {\n this.searchState.searchTerm$.pipe(skip(1)).subscribe((searchTerm: string) => {\n if (searchTerm !== undefined && searchTerm !== null) {\n this.analyticsService.trackSearch(searchTerm, this.searchState.store.count);\n }\n });\n }\n}\n","import { Injectable } from '@angular/core';\n\nimport { EntityStore } from '@igo2/common';\nimport { ConfigService } from '@igo2/core';\nimport { CommonVectorStyleOptions, SearchResult } from '@igo2/geo';\n\n/**\n * Service that holds the state of the query module\n */\n@Injectable({\n providedIn: 'root'\n})\nexport class QueryState {\n /**\n * Store that holds the query results\n */\n public store: EntityStore<SearchResult> = new EntityStore<SearchResult>([]);\n public queryOverlayStyle: CommonVectorStyleOptions = {};\n public queryOverlayStyleSelection: CommonVectorStyleOptions = {};\n public queryOverlayStyleFocus: CommonVectorStyleOptions = {};\n\n constructor(private configService: ConfigService) {\n const queryOverlayStyle = this.configService.getConfig('queryOverlayStyle') as {\n base?: CommonVectorStyleOptions,\n selection?: CommonVectorStyleOptions,\n focus?: CommonVectorStyleOptions\n };\n if (queryOverlayStyle) {\n this.queryOverlayStyle = queryOverlayStyle.base;\n this.queryOverlayStyleSelection = queryOverlayStyle.selection;\n this.queryOverlayStyleFocus = queryOverlayStyle.focus;\n }\n }\n}\n","/*\n * Public API Surface of tools\n */\n\nexport * from './lib/integration.module';\nexport * from './lib/about/about.module';\nexport * from './lib/analytics/analytics.module';\nexport * from './lib/storage/storage.module';\nexport * from './lib/context/context.module';\nexport * from './lib/catalog/catalog.module';\n\nexport * from './lib/directions/directions.module';\nexport * from './lib/draw/draw.module';\nexport * from './lib/workspace/workspace.module';\nexport * from './lib/filter/filter.module';\nexport * from './lib/import-export/import-export.module';\nexport * from './lib/map/map.module';\nexport * from './lib/measure/measure.module';\nexport * from './lib/print/print.module';\nexport * from './lib/search/search.module';\nexport * from './lib/tool/tool.module';\n\nexport * from './lib/about';\nexport * from './lib/analytics';\nexport * from './lib/context';\nexport * from './lib/catalog';\nexport * from './lib/directions';\nexport * from './lib/draw';\nexport * from './lib/workspace';\nexport * from './lib/filter';\nexport * from './lib/import-export';\nexport * from './lib/map';\nexport * from './lib/measure';\nexport * from './lib/print';\nexport * from './lib/search';\nexport * from './lib/tool';\nexport * from './lib/storage';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["toolSlideInOut"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAOa,qBAAqB;;0FAArB,qBAAqB;uEAArB,qBAAqB;2EAJvB,EAAE;uFAIA,qBAAqB;cALjC,QAAQ;eAAC;gBACR,OAAO,EAAE,EAAE;gBACX,YAAY,EAAE,EAAE;gBAChB,OAAO,EAAE,EAAE;aACZ;;;ICDW;AAAZ,WAAY,gBAAgB;IAC1B,mCAAe,CAAA;IACf,uCAAmB,CAAA;AACrB,CAAC,EAHW,gBAAgB,KAAhB,gBAAgB,QAG3B;IAEW;AAAZ,WAAY,gBAAgB;IAC1B,qCAAiB,CAAA;IACjB,qCAAiB,CAAA;AACnB,CAAC,EAHW,gBAAgB,KAAhB,gBAAgB,QAG3B;AAED;;;MAMa,iBAAiB;IAH9B;QAKW,sBAAiB,GAAsC,IAAI,eAAe,CAAC,gBAAgB,CAAC,KAAK,CAAC,CAAC;QACnG,kBAAa,GAAsC,IAAI,eAAe,CAAC,gBAAgB,CAAC,MAAM,CAAC,CAAC;QAChG,mBAAc,GAAmC,IAAI,eAAe,CAAC,SAAS,CAAC,CAAC;KAc1F;IAZC,mBAAmB,CAAC,IAAsB;QACxC,IAAI,CAAC,iBAAiB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;KACnC;IAED,OAAO,CAAC,IAAsB;QAC5B,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;KAC/B;IAED,iBAAiB,CAAC,aAA4B;QAC1C,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;KACzC;;kF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B,EAAE,CAAC;QAG3D,MAAM,iBAAiB,GAAG,IAAI,CAAC,aAAa,CAAC,SAAS,CAAC,mBAAmB,CAIzE,CAAC;QACF,IAAI,iBAAiB,EAAE;YACrB,IAAI,CAAC,iBAAiB,GAAG,iBAAiB,CAAC,IAAI,CAAC;YAChD,IAAI,CAAC,0BAA0B,GAAG,iBAAiB,CAAC,SAAS,CAAC;YAC9D,IAAI,CAAC,sBAAsB,GAAG,iBAAiB,CAAC,KAAK,CAAC;SACvD;KACF;;oEApBU,UAAU;gEAAV,UAAU,WAAV,UAAU,mBAFT,MAAM;uFAEP,UAAU;cAHtB,UAAU;eAAC;gBACV,UAAU,EAAE,MAAM;aACnB;;;ACXD;;;;ACAA;;;;;;"}
|
|
1
|
+
{"version":3,"file":"igo2-integration.js","sources":["../../../packages/integration/src/lib/analytics/analytics.module.ts","../../../packages/integration/src/lib/import-export/import-export.state.ts","../../../packages/integration/src/lib/tool/tool.state.ts","../../../packages/integration/src/lib/context/context-editor-tool/context-editor-tool.component.ts","../../../packages/integration/src/lib/context/context-editor-tool/context-editor-tool.component.html","../../../packages/integration/src/lib/map/map.state.ts","../../../packages/integration/src/lib/context/context-manager-tool/context-manager-tool.component.ts","../../../packages/integration/src/lib/context/context-manager-tool/context-manager-tool.component.html","../../../packages/integration/src/lib/context/context-permission-manager-tool/context-permission-manager-tool.component.ts","../../../packages/integration/src/lib/context/context-permission-manager-tool/context-permission-manager-tool.component.html","../../../packages/integration/src/lib/map/layer-list-tool.state.ts","../../../packages/integration/src/lib/context/context-share-tool/context-share-tool.component.ts","../../../packages/integration/src/lib/context/context-share-tool/context-share-tool.component.html","../../../packages/integration/src/lib/context/context.module.ts","../../../packages/integration/src/lib/catalog/catalog.state.ts","../../../packages/integration/src/lib/catalog/catalog-library-tool/catalog-library-tool.component.ts","../../../packages/integration/src/lib/catalog/catalog-library-tool/catalog-library-tool.component.html","../../../packages/integration/src/lib/catalog/catalog-library-tool/catalog-library-tool.module.ts","../../../packages/integration/src/lib/catalog/catalog-browser-tool/catalog-browser-tool.component.html","../../../packages/integration/src/lib/catalog/catalog-browser-tool/catalog-browser-tool.component.ts","../../../packages/integration/src/lib/catalog/catalog-browser-tool/catalog-browser-tool.module.ts","../../../packages/integration/src/lib/catalog/catalog.module.ts","../../../packages/integration/src/lib/directions/directions.state.ts","../../../packages/integration/src/lib/context/context.state.ts","../../../packages/integration/src/lib/directions/directions-tool/directions-tool.component.ts","../../../packages/integration/src/lib/directions/directions-tool/directions-tool.component.html","../../../packages/integration/src/lib/directions/directions.module.ts","../../../packages/integration/src/lib/draw/draw.state.ts","../../../packages/integration/src/lib/draw/drawing-tool/drawing-tool.component.ts","../../../packages/integration/src/lib/draw/drawing-tool/drawing-tool.component.html","../../../packages/integration/src/lib/draw/draw.module.ts","../../../packages/integration/src/lib/workspace/shared/workspace.utils.ts","../../../packages/integration/src/lib/storage/storage.state.ts","../../../packages/integration/src/lib/workspace/shared/feature-actions.service.ts","../../../packages/integration/src/lib/workspace/shared/wfs-actions.service.ts","../../../packages/integration/src/lib/workspace/shared/edition-actions.service.ts","../../../packages/integration/src/lib/workspace/workspace.state.ts","../../../packages/integration/src/lib/workspace/workspace-button/workspace-button.component.html","../../../packages/integration/src/lib/workspace/workspace-button/workspace-button.component.ts","../../../packages/integration/src/lib/workspace/workspace.module.ts","../../../packages/integration/src/lib/import-export/import-export-tool/import-export-tool.component.html","../../../packages/integration/src/lib/import-export/import-export-tool/import-export-tool.component.ts","../../../packages/integration/src/lib/import-export/import-export.module.ts","../../../packages/integration/src/lib/map/map-details-tool/map-details-tool.component.html","../../../packages/integration/src/lib/map/map-details-tool/map-details-tool.component.ts","../../../packages/integration/src/lib/map/map-tool/map-tool.component.html","../../../packages/integration/src/lib/map/map-tool/map-tool.component.ts","../../../packages/integration/src/lib/map/map-tools/map-tools.component.html","../../../packages/integration/src/lib/map/map-tools/map-tools.component.ts","../../../packages/integration/src/lib/map/map-legend/map-legend-tool.component.html","../../../packages/integration/src/lib/map/map-legend/map-legend-tool.component.ts","../../../packages/integration/src/lib/map/advanced-map-tool/advanced-swipe/advanced-swipe.component.html","../../../packages/integration/src/lib/map/advanced-map-tool/advanced-swipe/advanced-swipe.component.ts","../../../packages/integration/src/lib/map/advanced-map-tool/advanced-coordinates/advanced-coordinates.component.html","../../../packages/integration/src/lib/map/advanced-map-tool/advanced-coordinates/advanced-coordinates.component.ts","../../../packages/integration/src/lib/map/advanced-map-tool/advanced-map-tool.component.ts","../../../packages/integration/src/lib/map/advanced-map-tool/advanced-map-tool.component.html","../../../packages/integration/src/lib/map/map-proximity.state.ts","../../../packages/integration/src/lib/map/map-proximity-tool/map-proximity-tool.component.html","../../../packages/integration/src/lib/map/map-proximity-tool/map-proximity-tool.component.ts","../../../packages/integration/src/lib/map/map.module.ts","../../../packages/integration/src/lib/measure/measure.state.ts","../../../packages/integration/src/lib/measure/measurer-tool/measurer-tool.component.ts","../../../packages/integration/src/lib/measure/measurer-tool/measurer-tool.component.html","../../../packages/integration/src/lib/measure/measurer-tool/measurer-tool.module.ts","../../../packages/integration/src/lib/measure/measure.module.ts","../../../packages/integration/src/lib/print/print-tool/print-tool.component.ts","../../../packages/integration/src/lib/print/print-tool/print-tool.component.html","../../../packages/integration/src/lib/print/print.module.ts","../../../packages/integration/src/lib/search/search.state.ts","../../../packages/integration/src/lib/search/search-bar/search-bar-binding.directive.ts","../../../packages/integration/src/lib/search/search-bar/search-bar.module.ts","../../../packages/integration/src/lib/search/search-results-tool/search-results-tool.component.html","../../../packages/integration/src/lib/search/search-results-tool/search-results-tool.component.ts","../../../packages/integration/src/lib/search/search-results-tool/search-results-tool.module.ts","../../../packages/integration/src/lib/search/search.module.ts","../../../packages/integration/src/lib/filter/ogc-filter-tool/ogc-filter-tool.component.ts","../../../packages/integration/src/lib/filter/ogc-filter-tool/ogc-filter-tool.component.html","../../../packages/integration/src/lib/filter/time-filter-tool/time-filter-tool.component.ts","../../../packages/integration/src/lib/filter/time-filter-tool/time-filter-tool.component.html","../../../packages/integration/src/lib/filter/spatial-filter-tool/spatial-filter-tool.component.html","../../../packages/integration/src/lib/filter/spatial-filter-tool/spatial-filter-tool.component.ts","../../../packages/integration/src/lib/filter/active-time-filter-tool/active-time-filter-tool.animation.ts","../../../packages/integration/src/lib/filter/active-time-filter-tool/active-time-filter-tool.component.ts","../../../packages/integration/src/lib/filter/active-time-filter-tool/active-time-filter-tool.component.html","../../../packages/integration/src/lib/filter/active-ogc-filter-tool/active-ogc-filter-tool.animation.ts","../../../packages/integration/src/lib/filter/active-ogc-filter-tool/active-ogc-filter-tool.component.ts","../../../packages/integration/src/lib/filter/active-ogc-filter-tool/active-ogc-filter-tool.component.html","../../../packages/integration/src/lib/filter/filter.module.ts","../../../packages/integration/src/lib/about/about-tool/about-tool.component.html","../../../packages/integration/src/lib/about/about-tool/about-tool.component.ts","../../../packages/integration/src/lib/about/about.module.ts","../../../packages/integration/src/lib/storage/storage.module.ts","../../../packages/integration/src/lib/integration.module.ts","../../../packages/integration/src/lib/tool/tool.module.ts","../../../packages/integration/src/lib/analytics/analytics-listener.service.ts","../../../packages/integration/src/lib/search/query.state.ts","../../../packages/integration/src/public_api.ts","../../../packages/integration/src/igo2-integration.ts"],"sourcesContent":["import { NgModule } from '@angular/core';\r\n\r\n@NgModule({\r\n imports: [],\r\n declarations: [],\r\n exports: []\r\n})\r\nexport class IgoAppAnalyticsModule {}\r\n","import { Injectable } from '@angular/core';\r\n\r\nimport { BehaviorSubject } from 'rxjs';\r\nimport { ExportOptions } from '@igo2/geo';\r\n\r\nexport enum ImportExportType {\r\n layer = 'layer',\r\n context = 'context'\r\n}\r\n\r\nexport enum ImportExportMode {\r\n import = 'import',\r\n export = 'export'\r\n}\r\n\r\n/**\r\n * Service that holds the state of the importExport module\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ImportExportState {\r\n\r\n readonly importExportType$: BehaviorSubject<ImportExportType> = new BehaviorSubject(ImportExportType.layer);\r\n readonly selectedMode$: BehaviorSubject<ImportExportMode> = new BehaviorSubject(ImportExportMode.import);\r\n readonly exportOptions$: BehaviorSubject<ExportOptions> = new BehaviorSubject(undefined);\r\n\r\n setImportExportType(type: ImportExportType) {\r\n this.importExportType$.next(type);\r\n }\r\n\r\n setMode(mode: ImportExportMode) {\r\n this.selectedMode$.next(mode);\r\n }\r\n\r\n setsExportOptions(exportOptions: ExportOptions) {\r\n this.exportOptions$.next(exportOptions);\r\n }\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\nimport { Toolbox, ToolService } from '@igo2/common';\r\n\r\nimport { ExportOptions } from '@igo2/geo';\r\nimport { BehaviorSubject } from 'rxjs';\r\nimport { ImportExportMode, ImportExportState } from '../import-export/import-export.state';\r\n\r\n/**\r\n * Service that holds the state of the search module\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ToolState {\r\n get toolbox(): Toolbox {\r\n return this.toolService.toolbox;\r\n }\r\n\r\n public openSidenav$: BehaviorSubject<boolean> = new BehaviorSubject(undefined);\r\n\r\n constructor(\r\n private toolService: ToolService,\r\n private importExportState: ImportExportState\r\n ) {}\r\n\r\n toolToActivateFromOptions(toolToActivate: { tool: string; options: {[key: string]: any} }) {\r\n if (!toolToActivate) { return; }\r\n if (toolToActivate.tool === 'importExport') {\r\n let exportOptions: ExportOptions = this.importExportState.exportOptions$.value;\r\n if (!exportOptions) {\r\n exportOptions = {\r\n layers: toolToActivate.options.layers,\r\n featureInMapExtent: toolToActivate.options.featureInMapExtent\r\n };\r\n } else {\r\n exportOptions.layers = toolToActivate.options.layers;\r\n exportOptions.featureInMapExtent = toolToActivate.options.featureInMapExtent;\r\n }\r\n this.importExportState.setsExportOptions(exportOptions);\r\n this.importExportState.setMode(ImportExportMode.export);\r\n }\r\n\r\n if (this.toolbox.getTool(toolToActivate.tool)) {\r\n this.toolbox.activateTool(toolToActivate.tool);\r\n this.openSidenav$.next(true);\r\n }\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport { ToolState } from '../../tool/tool.state';\r\n\r\n@ToolComponent({\r\n name: 'contextEditor',\r\n title: 'igo.integration.tools.contexts',\r\n icon: 'star',\r\n parent: 'contextManager'\r\n})\r\n@Component({\r\n selector: 'igo-context-editor-tool',\r\n templateUrl: './context-editor-tool.component.html'\r\n})\r\nexport class ContextEditorToolComponent {\r\n\r\n constructor(private toolState: ToolState) {}\r\n\r\n submitSuccessed() {\r\n this.toolState.toolbox.activatePreviousTool();\r\n }\r\n}\r\n","<igo-context-edit\r\n igoContextEditBinding\r\n (submitSuccessed)=\"submitSuccessed()\"\r\n></igo-context-edit>\r\n","import { Injectable } from '@angular/core';\r\nimport { StorageService } from '@igo2/core';\r\n\r\nimport { IgoMap, MapService, ProjectionService } from '@igo2/geo';\r\n// import { BehaviorSubject } from 'rxjs';\r\n\r\n/**\r\n * Service that holds the state of the map module\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class MapState {\r\n\r\n // public mapCenter$ = new BehaviorSubject<boolean>(false);\r\n get showAllLegendsValue(): boolean {\r\n return this._legendToolShowAll;\r\n }\r\n\r\n set showAllLegendsValue(value) {\r\n this._legendToolShowAll = value;\r\n }\r\n private _legendToolShowAll: boolean;\r\n\r\n /**\r\n * Active map\r\n */\r\n get map(): IgoMap { return this._map; }\r\n private _map: IgoMap;\r\n\r\n constructor(\r\n private mapService: MapService,\r\n private projectionService: ProjectionService, // Don't remove this or it'll never be injected,\r\n private storageService: StorageService\r\n ) {\r\n this._map = new IgoMap({\r\n controls: {\r\n scaleLine: true,\r\n attribution: {\r\n collapsed: true\r\n }\r\n }\r\n },\r\n this.storageService);\r\n\r\n this.mapService.setMap(this.map);\r\n }\r\n}\r\n","import { Component, Input } from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\n\r\nimport { ToolState } from '../../tool/tool.state';\r\nimport { MapState } from '../../map/map.state';\r\nimport { IgoMap } from '@igo2/geo';\r\n\r\n@ToolComponent({\r\n name: 'contextManager',\r\n title: 'igo.integration.tools.contexts',\r\n icon: 'star'\r\n})\r\n@Component({\r\n selector: 'igo-context-manager-tool',\r\n templateUrl: './context-manager-tool.component.html'\r\n})\r\nexport class ContextManagerToolComponent {\r\n\r\n @Input() toolToOpenOnContextChange: string = 'mapTools';\r\n\r\n get map(): IgoMap { return this.mapState.map; }\r\n\r\n constructor(private toolState: ToolState, private mapState: MapState) {}\r\n\r\n editContext() {\r\n this.toolState.toolbox.activateTool('contextEditor');\r\n }\r\n\r\n managePermissions() {\r\n this.toolState.toolbox.activateTool('contextPermissionManager');\r\n }\r\n}\r\n","<igo-context-list\r\n igoContextListBinding\r\n [map]=\"map\"\r\n (edit)=\"editContext()\"\r\n (managePermissions)=\"managePermissions()\">\r\n</igo-context-list>\r\n","import { Component } from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\n\r\n@ToolComponent({\r\n name: 'contextPermissionManager',\r\n title: 'igo.integration.tools.contexts',\r\n icon: 'star',\r\n parent: 'contextManager'\r\n})\r\n@Component({\r\n selector: 'igo-context-permission-manager-tool',\r\n templateUrl: './context-permission-manager-tool.component.html'\r\n})\r\nexport class ContextPermissionManagerToolComponent {}\r\n","<igo-context-permissions igoContextPermissionsBinding></igo-context-permissions>\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject } from 'rxjs';\r\nimport { LayerListControlsOptions } from '@igo2/geo';\r\n\r\n/**\r\n * Service that holds the state of layer list tool values\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class LayerListToolState {\r\n\r\n readonly keyword$: BehaviorSubject<string> = new BehaviorSubject('');\r\n readonly sortAlpha$: BehaviorSubject<boolean> = new BehaviorSubject(undefined);\r\n readonly onlyVisible$: BehaviorSubject<boolean> = new BehaviorSubject(undefined);\r\n readonly selectedTab$: BehaviorSubject<number> = new BehaviorSubject(undefined);\r\n\r\n setKeyword(keyword: string) {\r\n this.keyword$.next(keyword);\r\n }\r\n\r\n setSortAlpha(sort: boolean) {\r\n this.sortAlpha$.next(sort);\r\n }\r\n\r\n setOnlyVisible(onlyVisible: boolean) {\r\n this.onlyVisible$.next(onlyVisible);\r\n }\r\n\r\n setSelectedTab(tab: number) {\r\n this.selectedTab$.next(tab);\r\n }\r\n\r\n getLayerListControls(): LayerListControlsOptions {\r\n return {\r\n keyword: this.keyword$.value,\r\n onlyVisible: this.onlyVisible$.value,\r\n sortAlpha: this.sortAlpha$.value\r\n };\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport { IgoMap, LayerListControlsOptions } from '@igo2/geo';\r\n\r\nimport { MapState } from '../../map/map.state';\r\nimport { LayerListToolState } from '../../map/layer-list-tool.state';\r\n\r\n@ToolComponent({\r\n name: 'shareMap',\r\n title: 'igo.integration.tools.shareMap',\r\n icon: 'share-variant'\r\n})\r\n@Component({\r\n selector: 'igo-context-share-tool',\r\n templateUrl: './context-share-tool.component.html'\r\n})\r\nexport class ContextShareToolComponent {\r\n\r\n get map(): IgoMap { return this.mapState.map; }\r\n\r\n get layerListControls(): LayerListControlsOptions { return this.layerListToolState.getLayerListControls(); }\r\n\r\n constructor(\r\n private mapState: MapState,\r\n private layerListToolState: LayerListToolState\r\n ) {}\r\n}\r\n","<igo-share-map\r\n [map]=\"map\"></igo-share-map>\r\n","import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';\r\n\r\nimport { IgoContextModule } from '@igo2/context';\r\n\r\nimport { ContextEditorToolComponent } from './context-editor-tool/context-editor-tool.component';\r\nimport { ContextManagerToolComponent } from './context-manager-tool/context-manager-tool.component';\r\nimport { ContextPermissionManagerToolComponent } from './context-permission-manager-tool/context-permission-manager-tool.component';\r\nimport { ContextShareToolComponent } from './context-share-tool/context-share-tool.component';\r\n\r\n@NgModule({\r\n imports: [IgoContextModule],\r\n declarations: [\r\n ContextEditorToolComponent,\r\n ContextManagerToolComponent,\r\n ContextPermissionManagerToolComponent,\r\n ContextShareToolComponent\r\n ],\r\n exports: [\r\n ContextEditorToolComponent,\r\n ContextManagerToolComponent,\r\n ContextPermissionManagerToolComponent,\r\n ContextShareToolComponent\r\n ],\r\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\r\n})\r\nexport class IgoAppContextModule {}\r\n","import { Injectable } from '@angular/core';\r\n\r\nimport { AuthService } from '@igo2/auth';\r\nimport { EntityStore } from '@igo2/common';\r\nimport { Catalog, CatalogItem } from '@igo2/geo';\r\n\r\n/**\r\n * Service that holds the state of the catalog module\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CatalogState {\r\n\r\n /**\r\n * Store that contains all the catalogs\r\n */\r\n get catalogStore(): EntityStore<Catalog> { return this._catalogStore; }\r\n private _catalogStore: EntityStore<Catalog>;\r\n\r\n /**\r\n * Catalog -> Catalog items store mapping\r\n */\r\n private catalogItemsStores = new Map<string, EntityStore<CatalogItem>>();\r\n\r\n constructor(authService: AuthService) {\r\n this._catalogStore = new EntityStore([]);\r\n\r\n authService.authenticate$.subscribe(() => {\r\n this.clearCatalogItemsStores();\r\n });\r\n }\r\n\r\n /**\r\n * Get a catalog's items store\r\n * @param catalog Catalog\r\n * @returns Store that contains the catalog items\r\n */\r\n getCatalogItemsStore(catalog: Catalog): EntityStore<CatalogItem> {\r\n return this.catalogItemsStores.get(catalog.id as string);\r\n }\r\n\r\n /**\r\n * Bind a catalog items store to a catalog\r\n * @param catalog Catalog\r\n * @param store Catalog items store\r\n */\r\n setCatalogItemsStore(catalog: Catalog, store: EntityStore<CatalogItem>) {\r\n this.catalogItemsStores.set(catalog.id as string, store);\r\n }\r\n\r\n /**\r\n * Clear all catalog items stores\r\n */\r\n clearCatalogItemsStores() {\r\n this.catalogItemsStores.clear();\r\n }\r\n}\r\n","import { Component, OnInit, ChangeDetectionStrategy, Input } from '@angular/core';\r\nimport { take } from 'rxjs/operators';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\n\r\nimport { EntityStore } from '@igo2/common';\r\nimport { Catalog, CatalogService } from '@igo2/geo';\r\nimport { StorageService } from '@igo2/core';\r\n\r\nimport { ToolState } from '../../tool/tool.state';\r\nimport { CatalogState } from '../catalog.state';\r\n\r\n/**\r\n * Tool to browse the list of available catalogs.\r\n */\r\n@ToolComponent({\r\n name: 'catalog',\r\n title: 'igo.integration.tools.catalog',\r\n icon: 'layers-plus'\r\n})\r\n@Component({\r\n selector: 'igo-catalog-library-tool',\r\n templateUrl: './catalog-library-tool.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class CatalogLibraryToolComponent implements OnInit {\r\n /**\r\n * Store that contains the catalogs\r\n * @internal\r\n */\r\n get store(): EntityStore<Catalog> {\r\n return this.catalogState.catalogStore;\r\n }\r\n\r\n /**\r\n * Determine if the form to add a catalog is allowed\r\n */\r\n @Input() addCatalogAllowed: boolean = false;\r\n\r\n /**\r\n * List of predefined catalogs\r\n */\r\n @Input() predefinedCatalogs: Catalog[] = [];\r\n\r\n constructor(\r\n private catalogService: CatalogService,\r\n private catalogState: CatalogState,\r\n private toolState: ToolState,\r\n private storageService: StorageService\r\n ) {}\r\n\r\n /**\r\n * @internal\r\n */\r\n ngOnInit() {\r\n if (this.store.count === 0) {\r\n this.loadCatalogs();\r\n }\r\n }\r\n\r\n /**\r\n * When the selected catalog changes, toggle the the CatalogBrowser tool.\r\n * @internal\r\n * @param event Select event\r\n */\r\n onCatalogSelectChange(event: { selected: boolean; catalog: Catalog }) {\r\n if (event.selected === false) {\r\n return;\r\n }\r\n this.toolState.toolbox.activateTool('catalogBrowser');\r\n }\r\n\r\n /**\r\n * Get all the available catalogs from the CatalogService and\r\n * load them into the store.\r\n */\r\n private loadCatalogs() {\r\n this.catalogService.loadCatalogs().pipe(take(1)).subscribe((catalogs: Catalog[]) => {\r\n this.store.clear();\r\n this.store.load(catalogs.concat((this.storageService.get('addedCatalogs') || []) as Catalog[]));\r\n });\r\n }\r\n}\r\n","<igo-catalog-library\r\n [predefinedCatalogs]=\"predefinedCatalogs\"\r\n [addCatalogAllowed]=\"addCatalogAllowed\"\r\n [store]=\"store\"\r\n (catalogSelectChange)=\"onCatalogSelectChange($event)\">\r\n</igo-catalog-library>\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';\r\n\r\nimport { IgoCatalogLibraryModule } from '@igo2/geo';\r\nimport { CatalogLibraryToolComponent } from './catalog-library-tool.component';\r\n\r\n/**\r\n * @ignore\r\n */\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n IgoCatalogLibraryModule\r\n ],\r\n declarations: [CatalogLibraryToolComponent],\r\n exports: [CatalogLibraryToolComponent],\r\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\r\n})\r\nexport class IgoAppCatalogLibraryToolModule {}\r\n","<igo-catalog-browser\r\n *ngIf=\"store$ | async as store\"\r\n [catalog]=\"catalog\"\r\n [store]=\"store\"\r\n [map]=\"map\"\r\n [toggleCollapsedGroup]=\"toggleCollapsedGroup\">\r\n</igo-catalog-browser>\r\n","import {\r\n Component,\r\n Input,\r\n OnInit,\r\n OnDestroy,\r\n ChangeDetectionStrategy\r\n} from '@angular/core';\r\n\r\nimport { BehaviorSubject, Subscription } from 'rxjs';\r\nimport { take } from 'rxjs/operators';\r\n\r\nimport { EntityRecord, EntityStore, ToolComponent } from '@igo2/common';\r\nimport { AuthService } from '@igo2/auth';\r\n\r\nimport {\r\n IgoMap,\r\n Catalog,\r\n CatalogItem,\r\n CatalogItemState,\r\n CatalogService\r\n} from '@igo2/geo';\r\n\r\nimport { MapState } from '../../map/map.state';\r\nimport { CatalogState } from '../catalog.state';\r\n\r\n/**\r\n * Tool to browse a catalog's groups and layers and display them to a map.\r\n */\r\n@ToolComponent({\r\n name: 'catalogBrowser',\r\n title: 'igo.integration.tools.catalog',\r\n icon: 'photo-browser',\r\n parent: 'catalog'\r\n})\r\n@Component({\r\n selector: 'igo-catalog-browser-tool',\r\n templateUrl: './catalog-browser-tool.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class CatalogBrowserToolComponent implements OnInit, OnDestroy {\r\n catalog: Catalog;\r\n\r\n /**\r\n * Store that contains the catalog items\r\n * @internal\r\n */\r\n store$ = new BehaviorSubject<EntityStore<CatalogItem, CatalogItemState>>(\r\n undefined\r\n );\r\n\r\n /**\r\n * Subscription to the selected catalog\r\n */\r\n private catalog$$: Subscription;\r\n\r\n /**\r\n * Subscription for authentication\r\n */\r\n private authenticate$$: Subscription;\r\n\r\n /**\r\n * Whether a group can be toggled when it's collapsed\r\n */\r\n @Input() toggleCollapsedGroup: boolean = true;\r\n\r\n /**\r\n * Map to add layers to\r\n * @internal\r\n */\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n\r\n constructor(\r\n private catalogService: CatalogService,\r\n private catalogState: CatalogState,\r\n private mapState: MapState,\r\n private authService: AuthService\r\n ) {}\r\n\r\n /**\r\n * @internal\r\n */\r\n ngOnInit() {\r\n const catalogStore = this.catalogState.catalogStore;\r\n this.catalog$$ = catalogStore.stateView\r\n .firstBy$(\r\n (record: EntityRecord<Catalog>) => record.state.selected === true\r\n )\r\n .subscribe((record: EntityRecord<Catalog>) => {\r\n if (record && record.entity) {\r\n const catalog = record.entity;\r\n this.catalog = catalog;\r\n }\r\n });\r\n\r\n this.authenticate$$ = this.authService.authenticate$.subscribe(() => {\r\n this.loadCatalogItems(this.catalog);\r\n });\r\n }\r\n\r\n /**\r\n * @internal\r\n */\r\n ngOnDestroy() {\r\n this.catalog$$.unsubscribe();\r\n this.authenticate$$.unsubscribe();\r\n }\r\n\r\n /**\r\n * Get the selected catalog's items from the CatalogService and\r\n * load them into the store.\r\n * @param catalog Selected catalog\r\n */\r\n private loadCatalogItems(catalog: Catalog) {\r\n let store = this.catalogState.getCatalogItemsStore(catalog);\r\n if (store !== undefined) {\r\n this.store$.next(store);\r\n return;\r\n }\r\n\r\n store = new EntityStore<CatalogItem>([]);\r\n this.catalogState.setCatalogItemsStore(catalog, store);\r\n this.catalogService\r\n .loadCatalogItems(catalog)\r\n .pipe(take(1))\r\n .subscribe((items: CatalogItem[]) => {\r\n store.load(items);\r\n this.store$.next(store);\r\n });\r\n }\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';\r\n\r\nimport { IgoCatalogBrowserModule } from '@igo2/geo';\r\nimport { CatalogBrowserToolComponent } from './catalog-browser-tool.component';\r\n\r\n/**\r\n * @ignore\r\n */\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n IgoCatalogBrowserModule\r\n ],\r\n declarations: [CatalogBrowserToolComponent],\r\n exports: [CatalogBrowserToolComponent],\r\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\r\n})\r\nexport class IgoAppCatalogBrowserToolModule {}\r\n","import { NgModule } from '@angular/core';\r\n\r\nimport { IgoAppCatalogLibraryToolModule } from './catalog-library-tool/catalog-library-tool.module';\r\nimport { IgoAppCatalogBrowserToolModule } from './catalog-browser-tool/catalog-browser-tool.module';\r\n\r\n@NgModule({\r\n imports: [],\r\n exports: [\r\n IgoAppCatalogLibraryToolModule,\r\n IgoAppCatalogBrowserToolModule\r\n ],\r\n declarations: []\r\n})\r\nexport class IgoAppCatalogModule {}\r\n","import { Injectable } from '@angular/core';\r\n\r\nimport { AnyLayerOptions, StopsStore, StopsFeatureStore, RoutesFeatureStore, StepFeatureStore } from '@igo2/geo';\r\nimport { Subject } from 'rxjs';\r\nimport { MapState } from '../map/map.state';\r\n\r\n/**\r\n * Service that holds the state of the direction module\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class DirectionState {\r\n\r\n public zoomToActiveRoute$: Subject<void> = new Subject();\r\n\r\n /**\r\n * Store that holds the stop\r\n */\r\n public stopsStore: StopsStore = new StopsStore([]);\r\n\r\n /**\r\n * Store that holds the driving stops as feature\r\n */\r\n public stopsFeatureStore: StopsFeatureStore = new StopsFeatureStore([], {\r\n map: this.mapState.map\r\n });\r\n\r\n /**\r\n * Store that holds the driving route as feature\r\n */\r\n public routesFeatureStore: RoutesFeatureStore = new RoutesFeatureStore([], {\r\n map: this.mapState.map\r\n });\r\n\r\n public stepFeatureStore: StepFeatureStore = new StepFeatureStore([], {\r\n map: this.mapState.map\r\n });\r\n\r\n public debounceTime: number = 200;\r\n\r\n constructor(private mapState: MapState) {\r\n\r\n this.mapState.map.ol.once('rendercomplete', () => {\r\n this.stopsFeatureStore.empty$.subscribe((empty) => {\r\n if (this.stopsFeatureStore.layer?.options) {\r\n (this.stopsFeatureStore.layer.options as AnyLayerOptions).showInLayerList = !empty;\r\n }\r\n });\r\n this.routesFeatureStore.empty$.subscribe((empty) => {\r\n if (this.routesFeatureStore.layer?.options) {\r\n (this.routesFeatureStore.layer.options as AnyLayerOptions).showInLayerList = !empty;\r\n }\r\n });\r\n });\r\n\r\n this.mapState.map.layers$.subscribe(() => {\r\n if (!this.mapState.map.getLayerById('igo-direction-stops-layer')) {\r\n this.stopsStore.deleteMany(this.stopsStore.all());\r\n this.stopsFeatureStore.deleteMany(this.stopsFeatureStore.all()); // not necessary\r\n }\r\n if (!this.mapState.map.getLayerById('igo-direction-route-layer')) {\r\n this.routesFeatureStore.deleteMany(this.routesFeatureStore.all());\r\n }\r\n });\r\n }\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\nimport { BehaviorSubject } from 'rxjs';\r\n\r\nimport { LanguageService } from '@igo2/core';\r\nimport { Tool, ToolService } from '@igo2/common';\r\nimport { ContextService, DetailedContext } from '@igo2/context';\r\n\r\nimport { ToolState } from '../tool/tool.state';\r\n\r\n/**\r\n * Service that holds the state of the context module\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ContextState {\r\n /**\r\n * Observable of the active context\r\n */\r\n context$: BehaviorSubject<DetailedContext> = new BehaviorSubject(undefined);\r\n\r\n constructor(\r\n private contextService: ContextService,\r\n private toolService: ToolService,\r\n private toolState: ToolState,\r\n private languageService: LanguageService\r\n ) {\r\n this.contextService.context$.subscribe((context: DetailedContext) => {\r\n this.onContextChange(context);\r\n });\r\n this.contextService.toolsChanged$.subscribe((context: DetailedContext) => {\r\n this.updateTools(context);\r\n });\r\n }\r\n\r\n /**\r\n * Set the active context\r\n * @param context Detailed context\r\n */\r\n private setContext(context: DetailedContext) {\r\n this.updateTools(context);\r\n this.context$.next(context);\r\n }\r\n\r\n /**\r\n * Update the tool state with the context's tools\r\n * @param context Detailed context\r\n */\r\n private updateTools(context: DetailedContext) {\r\n const toolbox = this.toolState.toolbox;\r\n\r\n const tools = [];\r\n const contextTools = context.tools || [];\r\n contextTools.forEach((contextTool: Tool) => {\r\n const baseTool = this.toolService.getTool(contextTool.name);\r\n if (baseTool === undefined) {\r\n return;\r\n }\r\n\r\n const options = Object.assign(\r\n {},\r\n baseTool.options || {},\r\n contextTool.options || {}\r\n );\r\n const tool = Object.assign({}, baseTool, contextTool, { options });\r\n tools.push(tool);\r\n });\r\n\r\n tools.forEach((tool) => {\r\n if (tool.parent) {\r\n const parentIndex = tools.findIndex((el) => el.name === tool.parent);\r\n if (parentIndex !== -1) {\r\n tools[parentIndex].children = [];\r\n tools[parentIndex].children.push(tool.name);\r\n }\r\n }\r\n });\r\n\r\n toolbox.setTools(tools);\r\n toolbox.setToolbar(context.toolbar || []);\r\n\r\n // TODO: This is a patch so the context service can work without\r\n // injecting the ToolState or without being completely refactored\r\n this.contextService.setTools([].concat(tools));\r\n this.contextService.setToolbar(context.toolbar || []);\r\n }\r\n\r\n /**\r\n * Set a new context and update the tool state\r\n * @param context Detailed context\r\n */\r\n private onContextChange(context: DetailedContext) {\r\n if (context === undefined) {\r\n return;\r\n }\r\n this.setContext(context);\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { AuthService } from '@igo2/auth';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport { LanguageService, MessageService, StorageScope, StorageService } from '@igo2/core';\r\nimport { IgoMap, RoutesFeatureStore, StopsFeatureStore, StopsStore, StepFeatureStore } from '@igo2/geo';\r\nimport { Subject } from 'rxjs';\r\nimport { ContextState } from '../../context/context.state';\r\n\r\nimport { MapState } from '../../map/map.state';\r\nimport { DirectionState } from '../directions.state';\r\n\r\n@ToolComponent({\r\n name: 'directions',\r\n title: 'igo.integration.tools.directions',\r\n icon: 'directions'\r\n})\r\n@Component({\r\n selector: 'igo-directions-tool',\r\n templateUrl: './directions-tool.component.html'\r\n})\r\nexport class DirectionsToolComponent implements OnInit {\r\n\r\n public currentContextUri: string;\r\n /**\r\n * stops\r\n * @internal\r\n */\r\n get stopsStore(): StopsStore { return this.directionState.stopsStore; }\r\n\r\n get debounceTime(): number { return this.directionState.debounceTime; }\r\n\r\n /**\r\n * stops\r\n * @internal\r\n */\r\n get stopsFeatureStore(): StopsFeatureStore { return this.directionState.stopsFeatureStore; }\r\n\r\n /**\r\n * routes\r\n * @internal\r\n */\r\n get routesFeatureStore(): RoutesFeatureStore { return this.directionState.routesFeatureStore; }\r\n\r\n /**\r\n * step store\r\n * @internal\r\n */\r\n get stepFeatureStore(): StepFeatureStore { return this.directionState.stepFeatureStore; }\r\n\r\n /**\r\n * step store\r\n * @internal\r\n */\r\n get zoomToActiveRoute$(): Subject<void> { return this.directionState.zoomToActiveRoute$; }\r\n\r\n\r\n /**\r\n * Map to measure on\r\n * @internal\r\n */\r\n get map(): IgoMap { return this.mapState.map; }\r\n\r\n constructor(\r\n private directionState: DirectionState,\r\n private mapState: MapState,\r\n private languageService: LanguageService,\r\n private messageService: MessageService,\r\n private storageService: StorageService,\r\n public contextState: ContextState,\r\n private authService: AuthService\r\n ) {}\r\n\r\n ngOnInit(): void {\r\n const warningShown = this.storageService.get('direction.warning.shown') as boolean;\r\n if (!warningShown) {\r\n const translate = this.languageService.translate;\r\n const title = translate.instant(\r\n 'igo.integration.directions.warning.title'\r\n );\r\n const msg = translate.instant('igo.integration.directions.warning.message');\r\n this.messageService.info(msg, title, { timeOut: 20000 });\r\n this.storageService.set('direction.warning.shown', true, StorageScope.SESSION);\r\n }\r\n this.contextState.context$.subscribe(c => {\r\n if (!this.authService.authenticated) {\r\n this.currentContextUri = c.uri;\r\n }\r\n });\r\n }\r\n\r\n}\r\n","<igo-directions\r\n [contextUri]=\"currentContextUri\"\r\n [debounceTime]=\"debounceTime\"\r\n [stopsStore]=\"stopsStore\"\r\n [stopsFeatureStore]=\"stopsFeatureStore\"\r\n [stepFeatureStore]=\"stepFeatureStore\"\r\n [routesFeatureStore]=\"routesFeatureStore\"\r\n [zoomToActiveRoute$]=\"zoomToActiveRoute$\"> \r\n</igo-directions>","import {\r\n NgModule,\r\n ModuleWithProviders,\r\n CUSTOM_ELEMENTS_SCHEMA\r\n} from '@angular/core';\r\n\r\nimport { IgoDirectionsModule } from '@igo2/geo';\r\nimport { DirectionsToolComponent } from './directions-tool/directions-tool.component';\r\n\r\n@NgModule({\r\n imports: [IgoDirectionsModule],\r\n declarations: [DirectionsToolComponent],\r\n exports: [DirectionsToolComponent],\r\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\r\n})\r\nexport class IgoAppDirectionsModule {\r\n static forRoot(): ModuleWithProviders<IgoAppDirectionsModule> {\r\n return {\r\n ngModule: IgoAppDirectionsModule,\r\n providers: []\r\n };\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\nimport { FeatureStore, Feature } from '@igo2/geo';\r\nimport { MapState } from '../map/map.state';\r\n\r\n/**\r\n * Service that holds the state of the measure module\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class DrawState {\r\n\r\n /**\r\n * Store that holds the measures\r\n */\r\n public store: FeatureStore<Feature> = new FeatureStore<Feature>([], {\r\n map: this.mapState.map\r\n });\r\n\r\n constructor(private mapState: MapState) {\r\n\r\n this.mapState.map.layers$.subscribe(() => {\r\n if (!this.mapState.map.getLayerById('igo-draw-layer')) {\r\n this.store.deleteMany(this.store.all());\r\n }\r\n });\r\n }\r\n\r\n}\r\n","import {\r\n Component,\r\n ChangeDetectionStrategy\r\n } from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport { FeatureStore, Feature, IgoMap } from '@igo2/geo';\r\nimport { MapState } from '../../map/map.state';\r\nimport { DrawState } from '../draw.state';\r\n\r\n/**\r\n * Tool to measure lengths and areas\r\n */\r\n@ToolComponent({\r\n name: 'draw',\r\n title: 'igo.integration.tools.draw',\r\n icon: 'draw'\r\n})\r\n@Component({\r\n selector: 'igo-drawing-tool',\r\n templateUrl: './drawing-tool.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class DrawingToolComponent {\r\n\r\n/**\r\n * Map to measure on\r\n * @internal\r\n */\r\nget store(): FeatureStore<Feature> { return this.drawState.store; }\r\n\r\n/**\r\n * Map to measure on\r\n * @internal\r\n */\r\nget map(): IgoMap { return this.mapState.map; }\r\n\r\nconstructor(\r\n private drawState: DrawState,\r\n private mapState: MapState\r\n) {}\r\n\r\n}\r\n","<igo-draw [store]=\"store\" [map]=\"map\"></igo-draw>\r\n","import { NgModule } from '@angular/core';\r\n\r\nimport { IgoDrawingToolModule } from '@igo2/geo';\r\nimport { DrawingToolComponent } from './drawing-tool/drawing-tool.component';\r\n\r\n@NgModule({\r\n imports: [IgoDrawingToolModule],\r\n declarations: [DrawingToolComponent],\r\n exports: [\r\n DrawingToolComponent\r\n ]\r\n})\r\nexport class IgoAppDrawModule {}\r\n","import {\r\n FeatureMotion,\r\n FeatureStoreSelectionStrategy,\r\n FeatureWorkspace,\r\n WfsWorkspace,\r\n EditionWorkspace\r\n} from '@igo2/geo';\r\n\r\n\r\nexport function handleZoomAuto(workspace: FeatureWorkspace | WfsWorkspace | EditionWorkspace, storageService) {\r\n const zoomStrategy = workspace.entityStore\r\n .getStrategyOfType(FeatureStoreSelectionStrategy) as FeatureStoreSelectionStrategy;\r\n zoomStrategy.setMotion(storageService.get('zoomAuto') as boolean ? FeatureMotion.Default : FeatureMotion.None);\r\n}\r\n\r\n\r\n","import { Injectable } from '@angular/core';\r\n\r\nimport { StorageService } from '@igo2/core';\r\n\r\n/**\r\n * Service that holds the state of storage service\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class StorageState {\r\n get storageService(): StorageService {\r\n return this.igoStorageService;\r\n }\r\n\r\n constructor(private igoStorageService: StorageService) {}\r\n}\r\n","import { Injectable, OnDestroy } from '@angular/core';\r\n\r\nimport {\r\n Action,\r\n EntityStoreFilterCustomFuncStrategy,\r\n EntityStoreFilterSelectionStrategy\r\n} from '@igo2/common';\r\n\r\nimport { BehaviorSubject, Subscription } from 'rxjs';\r\nimport {\r\n FeatureWorkspace,\r\n mapExtentStrategyActiveToolTip,\r\n noElementSelected,\r\n ExportOptions\r\n} from '@igo2/geo';\r\nimport { StorageService, StorageServiceEvent, StorageServiceEventEnum, LanguageService, MediaService} from '@igo2/core';\r\nimport { StorageState } from '../../storage/storage.state';\r\nimport { map, skipWhile } from 'rxjs/operators';\r\nimport { ToolState } from '../../tool/tool.state';\r\nimport { handleZoomAuto } from './workspace.utils';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class FeatureActionsService implements OnDestroy {\r\n\r\n public maximize$: BehaviorSubject<boolean> = new BehaviorSubject(\r\n this.storageService.get('workspaceMaximize') as boolean\r\n );\r\n\r\n zoomAuto$: BehaviorSubject<boolean> = new BehaviorSubject(false);\r\n private storageChange$$: Subscription;\r\n\r\n get storageService(): StorageService {\r\n return this.storageState.storageService;\r\n }\r\n\r\n get zoomAuto(): boolean {\r\n return this.storageService.get('zoomAuto') as boolean;\r\n }\r\n\r\n constructor(\r\n private storageState: StorageState,\r\n public languageService: LanguageService,\r\n private toolState: ToolState,\r\n private mediaService: MediaService\r\n ) {}\r\n\r\n ngOnDestroy(): void {\r\n if (this.storageChange$$) {\r\n this.storageChange$$.unsubscribe();\r\n }\r\n }\r\n\r\n loadActions(\r\n workspace: FeatureWorkspace,\r\n rowsInMapExtentCheckCondition$: BehaviorSubject<boolean>,\r\n selectOnlyCheckCondition$: BehaviorSubject<boolean>\r\n ) {\r\n const actions = this.buildActions(\r\n workspace,\r\n rowsInMapExtentCheckCondition$,\r\n selectOnlyCheckCondition$\r\n );\r\n workspace.actionStore.load(actions);\r\n }\r\n\r\n buildActions(\r\n workspace: FeatureWorkspace,\r\n rowsInMapExtentCheckCondition$: BehaviorSubject<boolean>,\r\n selectOnlyCheckCondition$: BehaviorSubject<boolean>\r\n ): Action[] {\r\n this.zoomAuto$.next(this.zoomAuto);\r\n this.storageChange$$ = this.storageService.storageChange$\r\n .pipe(\r\n skipWhile(\r\n (storageChange: StorageServiceEvent) =>\r\n storageChange.key !== 'zoomAuto' || storageChange.event === StorageServiceEventEnum.CLEARED\r\n )\r\n )\r\n .subscribe(() => {\r\n this.zoomAuto$.next(this.zoomAuto);\r\n handleZoomAuto(workspace, this.storageService);\r\n });\r\n return [\r\n {\r\n id: 'zoomAuto',\r\n checkbox: true,\r\n title: 'igo.integration.workspace.zoomAuto.title',\r\n tooltip: 'igo.integration.workspace.zoomAuto.tooltip',\r\n checkCondition: this.zoomAuto$,\r\n handler: () => {\r\n handleZoomAuto(workspace, this.storageService);\r\n this.storageService.set(\r\n 'zoomAuto',\r\n !this.storageService.get('zoomAuto') as boolean\r\n );\r\n }\r\n },\r\n {\r\n id: 'filterInMapExtent',\r\n checkbox: true,\r\n title: 'igo.integration.workspace.inMapExtent.title',\r\n tooltip: mapExtentStrategyActiveToolTip(workspace),\r\n checkCondition: rowsInMapExtentCheckCondition$,\r\n handler: () => rowsInMapExtentCheckCondition$.next(!rowsInMapExtentCheckCondition$.value)\r\n },\r\n {\r\n id: 'selectedOnly',\r\n checkbox: true,\r\n title: 'igo.integration.workspace.selected.title',\r\n tooltip: 'igo.integration.workspace.selected.tooltip',\r\n checkCondition: selectOnlyCheckCondition$,\r\n handler: () => selectOnlyCheckCondition$.next(!selectOnlyCheckCondition$.value)\r\n },\r\n {\r\n id: 'clearselection',\r\n icon: 'select-off',\r\n title: 'igo.integration.workspace.clearSelection.title',\r\n tooltip: 'igo.integration.workspace.clearSelection.tooltip',\r\n handler: (ws: FeatureWorkspace) => {\r\n ws.entityStore.state.updateMany(ws.entityStore.view.all(), {\r\n selected: false\r\n });\r\n },\r\n args: [workspace],\r\n availability: (ws: FeatureWorkspace) => noElementSelected(ws)\r\n },\r\n {\r\n id: 'featureDownload',\r\n icon: 'file-export',\r\n title: 'igo.integration.workspace.download.title',\r\n tooltip: 'igo.integration.workspace.download.tooltip',\r\n handler: (ws: FeatureWorkspace) => {\r\n const filterStrategy = ws.entityStore.getStrategyOfType(\r\n EntityStoreFilterCustomFuncStrategy\r\n );\r\n const filterSelectionStrategy = ws.entityStore.getStrategyOfType(\r\n EntityStoreFilterSelectionStrategy\r\n );\r\n const layersWithSelection = filterSelectionStrategy.active\r\n ? [ws.layer.id]\r\n : [];\r\n this.toolState.toolToActivateFromOptions({\r\n tool: 'importExport',\r\n options: {\r\n layers: [ws.layer.id],\r\n featureInMapExtent: filterStrategy.active,\r\n layersWithSelection\r\n } as ExportOptions\r\n });\r\n },\r\n args: [workspace]\r\n },\r\n {\r\n id: 'maximize',\r\n title: this.languageService.translate.instant('igo.integration.workspace.maximize'),\r\n tooltip: this.languageService.translate.instant(\r\n 'igo.integration.workspace.maximizeTooltip'\r\n ),\r\n icon: 'resize',\r\n display: () => {\r\n return this.maximize$.pipe(map((v) => !v && !this.mediaService.isMobile()));\r\n },\r\n handler: () => {\r\n if (!this.mediaService.isMobile()) {\r\n this.maximize$.next(true);\r\n }\r\n },\r\n },\r\n {\r\n id: 'standardExtent',\r\n title: this.languageService.translate.instant(\r\n 'igo.integration.workspace.standardExtent'\r\n ),\r\n tooltip: this.languageService.translate.instant(\r\n 'igo.integration.workspace.standardExtentTooltip'\r\n ),\r\n icon: 'resize',\r\n display: () => {\r\n return this.maximize$.pipe(map((v) => v && !this.mediaService.isMobile()));\r\n },\r\n handler: () => {\r\n this.maximize$.next(false);\r\n }\r\n }\r\n ];\r\n }\r\n}\r\n","import { Inject, Injectable, OnDestroy } from '@angular/core';\r\n\r\nimport {\r\n Action,\r\n EntityStoreFilterCustomFuncStrategy,\r\n EntityStoreFilterSelectionStrategy,\r\n Widget\r\n} from '@igo2/common';\r\n\r\nimport { BehaviorSubject, Subscription } from 'rxjs';\r\nimport {\r\n WfsWorkspace,\r\n mapExtentStrategyActiveToolTip,\r\n noElementSelected,\r\n ExportOptions,\r\n OgcFilterWidget,\r\n OgcFilterableDataSource,\r\n} from '@igo2/geo';\r\nimport { StorageService, StorageServiceEvent, StorageServiceEventEnum, LanguageService, MediaService} from '@igo2/core';\r\nimport { StorageState } from '../../storage/storage.state';\r\nimport { map, skipWhile } from 'rxjs/operators';\r\nimport { ToolState } from '../../tool/tool.state';\r\nimport { handleZoomAuto } from './workspace.utils';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class WfsActionsService implements OnDestroy {\r\n\r\n public maximize$: BehaviorSubject<boolean> = new BehaviorSubject(\r\n this.storageService.get('workspaceMaximize') as boolean\r\n );\r\n\r\n selectOnlyCheckCondition$: BehaviorSubject<boolean> = new BehaviorSubject(false);\r\n // rowsInMapExtentCheckCondition$: BehaviorSubject<boolean> = new BehaviorSubject(true);\r\n zoomAuto$: BehaviorSubject<boolean> = new BehaviorSubject(false);\r\n private storageChange$$: Subscription;\r\n\r\n get storageService(): StorageService {\r\n return this.storageState.storageService;\r\n }\r\n\r\n get zoomAuto(): boolean {\r\n return this.storageService.get('zoomAuto') as boolean;\r\n }\r\n\r\n constructor(\r\n @Inject(OgcFilterWidget) private ogcFilterWidget: Widget,\r\n private storageState: StorageState,\r\n public languageService: LanguageService,\r\n private mediaService: MediaService,\r\n private toolState: ToolState) {}\r\n\r\n ngOnDestroy(): void {\r\n if (this.storageChange$$) {\r\n this.storageChange$$.unsubscribe();\r\n }\r\n }\r\n\r\n loadActions(\r\n workspace: WfsWorkspace,\r\n rowsInMapExtentCheckCondition$: BehaviorSubject<boolean>,\r\n selectOnlyCheckCondition$: BehaviorSubject<boolean>\r\n ) {\r\n const actions = this.buildActions(\r\n workspace,\r\n rowsInMapExtentCheckCondition$,\r\n selectOnlyCheckCondition$\r\n );\r\n workspace.actionStore.load(actions);\r\n }\r\n\r\n buildActions(\r\n workspace: WfsWorkspace,\r\n rowsInMapExtentCheckCondition$: BehaviorSubject<boolean>,\r\n selectOnlyCheckCondition$: BehaviorSubject<boolean>\r\n ): Action[] {\r\n this.zoomAuto$.next(this.zoomAuto);\r\n this.storageChange$$ = this.storageService.storageChange$\r\n .pipe(skipWhile((storageChange: StorageServiceEvent) =>\r\n storageChange?.key !== 'zoomAuto' || storageChange?.event === StorageServiceEventEnum.CLEARED))\r\n .subscribe(() => {\r\n this.zoomAuto$.next(this.zoomAuto);\r\n handleZoomAuto(workspace, this.storageService);\r\n });\r\n const actions = [\r\n {\r\n id: 'zoomAuto',\r\n checkbox: true,\r\n title: 'igo.integration.workspace.zoomAuto.title',\r\n tooltip: 'igo.integration.workspace.zoomAuto.tooltip',\r\n checkCondition: this.zoomAuto$,\r\n handler: () => {\r\n handleZoomAuto(workspace, this.storageService);\r\n this.storageService.set('zoomAuto', !this.storageService.get('zoomAuto') as boolean);\r\n }\r\n },\r\n {\r\n id: 'filterInMapExtent',\r\n checkbox: true,\r\n title: 'igo.integration.workspace.inMapExtent.title',\r\n tooltip: mapExtentStrategyActiveToolTip(workspace),\r\n checkCondition: rowsInMapExtentCheckCondition$,\r\n handler: () => rowsInMapExtentCheckCondition$.next(!rowsInMapExtentCheckCondition$.value)\r\n },\r\n {\r\n id: 'selectedOnly',\r\n checkbox: true,\r\n title: 'igo.integration.workspace.selected.title',\r\n tooltip: 'igo.integration.workspace.selected.title',\r\n checkCondition: selectOnlyCheckCondition$,\r\n handler: () => selectOnlyCheckCondition$.next(!selectOnlyCheckCondition$.value)\r\n },\r\n {\r\n id: 'clearselection',\r\n icon: 'select-off',\r\n title: 'igo.integration.workspace.clearSelection.title',\r\n tooltip: 'igo.integration.workspace.clearSelection.tooltip',\r\n handler: (ws: WfsWorkspace) => {\r\n ws.entityStore.state.updateMany(ws.entityStore.view.all(), { selected: false });\r\n },\r\n args: [workspace],\r\n availability: (ws: WfsWorkspace) => noElementSelected(ws)\r\n },\r\n {\r\n id: 'wfsDownload',\r\n icon: 'file-export',\r\n title: 'igo.integration.workspace.download.title',\r\n tooltip: 'igo.integration.workspace.download.tooltip',\r\n handler: (ws: WfsWorkspace) => {\r\n const filterStrategy = ws.entityStore.getStrategyOfType(EntityStoreFilterCustomFuncStrategy);\r\n const filterSelectionStrategy = ws.entityStore.getStrategyOfType(EntityStoreFilterSelectionStrategy);\r\n const layersWithSelection = filterSelectionStrategy.active ? [ws.layer.id] : [];\r\n this.toolState.toolToActivateFromOptions({\r\n tool: 'importExport',\r\n options: { layers: [ws.layer.id], featureInMapExtent: filterStrategy.active, layersWithSelection } as ExportOptions\r\n });\r\n },\r\n args: [workspace]\r\n },\r\n {\r\n id: 'ogcFilter',\r\n icon: 'filter',\r\n title: 'igo.integration.workspace.ogcFilter.title',\r\n tooltip: 'igo.integration.workspace.ogcFilter.tooltip',\r\n handler: (widget: Widget, ws: WfsWorkspace) => {\r\n ws.activateWidget(widget, {\r\n map: ws.map,\r\n layer: ws.layer\r\n });\r\n },\r\n args: [this.ogcFilterWidget, workspace]\r\n },\r\n {\r\n id: 'maximize',\r\n title: this.languageService.translate.instant('igo.integration.workspace.maximize'),\r\n tooltip: this.languageService.translate.instant(\r\n 'igo.integration.workspace.maximizeTooltip'\r\n ),\r\n icon: 'resize',\r\n display: () => {\r\n return this.maximize$.pipe(map((v) => !v && !this.mediaService.isMobile()));\r\n },\r\n handler: () => {\r\n if (!this.mediaService.isMobile()) {\r\n this.maximize$.next(true);\r\n }\r\n },\r\n },\r\n {\r\n id: 'standardExtent',\r\n title: this.languageService.translate.instant(\r\n 'igo.integration.workspace.standardExtent'\r\n ),\r\n tooltip: this.languageService.translate.instant(\r\n 'igo.integration.workspace.standardExtentTooltip'\r\n ),\r\n icon: 'resize',\r\n display: () => {\r\n return this.maximize$.pipe(map((v) => v && !this.mediaService.isMobile()));\r\n },\r\n handler: () => {\r\n this.maximize$.next(false);\r\n }\r\n }\r\n ];\r\n return (workspace.layer.dataSource as OgcFilterableDataSource).ogcFilters$?.value?.enabled ?\r\n actions : actions.filter(action => action.id !== 'ogcFilter');\r\n }\r\n}\r\n","import { Inject, Injectable, OnDestroy } from '@angular/core';\r\n\r\nimport {\r\n Action,\r\n EntityStoreFilterCustomFuncStrategy,\r\n EntityStoreFilterSelectionStrategy,\r\n Widget\r\n} from '@igo2/common';\r\n\r\nimport { BehaviorSubject, Subscription } from 'rxjs';\r\nimport {\r\n EditionWorkspace,\r\n mapExtentStrategyActiveToolTip,\r\n noElementSelected,\r\n ExportOptions,\r\n OgcFilterWidget,\r\n OgcFilterableDataSource,\r\n} from '@igo2/geo';\r\nimport { StorageService, StorageServiceEvent, StorageServiceEventEnum, LanguageService, MediaService} from '@igo2/core';\r\nimport { StorageState } from '../../storage/storage.state';\r\nimport { map, skipWhile } from 'rxjs/operators';\r\nimport { ToolState } from '../../tool/tool.state';\r\nimport { handleZoomAuto } from './workspace.utils';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class EditionActionsService implements OnDestroy {\r\n\r\n public maximize$: BehaviorSubject<boolean> = new BehaviorSubject(\r\n this.storageService.get('workspaceMaximize') as boolean\r\n );\r\n\r\n zoomAuto$: BehaviorSubject<boolean> = new BehaviorSubject(false);\r\n private storageChange$$: Subscription;\r\n\r\n get storageService(): StorageService {\r\n return this.storageState.storageService;\r\n }\r\n\r\n get zoomAuto(): boolean {\r\n return this.storageService.get('zoomAuto') as boolean;\r\n }\r\n\r\n constructor(\r\n @Inject(OgcFilterWidget) private ogcFilterWidget: Widget,\r\n private storageState: StorageState,\r\n public languageService: LanguageService,\r\n private mediaService: MediaService,\r\n private toolState: ToolState) {}\r\n\r\n ngOnDestroy(): void {\r\n if (this.storageChange$$) {\r\n this.storageChange$$.unsubscribe();\r\n }\r\n }\r\n\r\n loadActions(\r\n workspace: EditionWorkspace,\r\n rowsInMapExtentCheckCondition$: BehaviorSubject<boolean>,\r\n selectOnlyCheckCondition$: BehaviorSubject<boolean>\r\n ) {\r\n const actions = this.buildActions(\r\n workspace,\r\n rowsInMapExtentCheckCondition$,\r\n selectOnlyCheckCondition$\r\n );\r\n workspace.actionStore.load(actions);\r\n }\r\n\r\n buildActions(\r\n workspace: EditionWorkspace,\r\n rowsInMapExtentCheckCondition$: BehaviorSubject<boolean>,\r\n selectOnlyCheckCondition$: BehaviorSubject<boolean>\r\n ): Action[] {\r\n this.zoomAuto$.next(this.zoomAuto);\r\n this.storageChange$$ = this.storageService.storageChange$\r\n .pipe(skipWhile((storageChange: StorageServiceEvent) =>\r\n storageChange?.key !== 'zoomAuto' || storageChange?.event === StorageServiceEventEnum.CLEARED))\r\n .subscribe(() => {\r\n this.zoomAuto$.next(this.zoomAuto);\r\n handleZoomAuto(workspace, this.storageService);\r\n });\r\n const actions = [\r\n {\r\n id: 'zoomAuto',\r\n checkbox: true,\r\n title: 'igo.integration.workspace.zoomAuto.title',\r\n tooltip: 'igo.integration.workspace.zoomAuto.tooltip',\r\n checkCondition: this.zoomAuto$,\r\n handler: () => {\r\n handleZoomAuto(workspace, this.storageService);\r\n this.storageService.set('zoomAuto', !this.storageService.get('zoomAuto') as boolean);\r\n }\r\n },\r\n {\r\n id: 'filterInMapExtent',\r\n checkbox: true,\r\n title: 'igo.integration.workspace.inMapExtent.title',\r\n tooltip: mapExtentStrategyActiveToolTip(workspace),\r\n checkCondition: rowsInMapExtentCheckCondition$,\r\n handler: () => rowsInMapExtentCheckCondition$.next(!rowsInMapExtentCheckCondition$.value)\r\n },\r\n {\r\n id: 'selectedOnly',\r\n checkbox: true,\r\n title: 'igo.integration.workspace.selected.title',\r\n tooltip: 'igo.integration.workspace.selected.title',\r\n checkCondition: selectOnlyCheckCondition$,\r\n handler: () => selectOnlyCheckCondition$.next(!selectOnlyCheckCondition$.value)\r\n },\r\n {\r\n id: 'clearselection',\r\n icon: 'select-off',\r\n title: 'igo.integration.workspace.clearSelection.title',\r\n tooltip: 'igo.integration.workspace.clearSelection.tooltip',\r\n handler: (ws: EditionWorkspace) => {\r\n ws.entityStore.state.updateMany(ws.entityStore.view.all(), { selected: false });\r\n },\r\n args: [workspace],\r\n availability: (ws: EditionWorkspace) => noElementSelected(ws)\r\n },\r\n {\r\n id: 'wfsDownload',\r\n icon: 'file-export',\r\n title: 'igo.integration.workspace.download.title',\r\n tooltip: 'igo.integration.workspace.download.tooltip',\r\n handler: (ws: EditionWorkspace) => {\r\n const filterStrategy = ws.entityStore.getStrategyOfType(EntityStoreFilterCustomFuncStrategy);\r\n const filterSelectionStrategy = ws.entityStore.getStrategyOfType(EntityStoreFilterSelectionStrategy);\r\n const layersWithSelection = filterSelectionStrategy.active ? [ws.layer.id] : [];\r\n this.toolState.toolToActivateFromOptions({\r\n tool: 'importExport',\r\n options: { layers: [ws.layer.id], featureInMapExtent: filterStrategy.active, layersWithSelection } as ExportOptions\r\n });\r\n },\r\n args: [workspace]\r\n },\r\n {\r\n id: 'ogcFilter',\r\n icon: 'filter',\r\n title: 'igo.integration.workspace.ogcFilter.title',\r\n tooltip: 'igo.integration.workspace.ogcFilter.tooltip',\r\n handler: (widget: Widget, ws: EditionWorkspace) => {\r\n ws.activateWidget(widget, {\r\n map: ws.map,\r\n layer: ws.layer\r\n });\r\n },\r\n args: [this.ogcFilterWidget, workspace]\r\n },\r\n {\r\n id: 'maximize',\r\n title: this.languageService.translate.instant('igo.integration.workspace.maximize'),\r\n tooltip: this.languageService.translate.instant(\r\n 'igo.integration.workspace.maximizeTooltip'\r\n ),\r\n icon: 'resize',\r\n display: () => {\r\n return this.maximize$.pipe(map((v) => !v && !this.mediaService.isMobile()));\r\n },\r\n handler: () => {\r\n if (!this.mediaService.isMobile()) {\r\n this.maximize$.next(true);\r\n }\r\n },\r\n },\r\n {\r\n id: 'standardExtent',\r\n title: this.languageService.translate.instant(\r\n 'igo.integration.workspace.standardExtent'\r\n ),\r\n tooltip: this.languageService.translate.instant(\r\n 'igo.integration.workspace.standardExtentTooltip'\r\n ),\r\n icon: 'resize',\r\n display: () => {\r\n return this.maximize$.pipe(map((v) => v && !this.mediaService.isMobile()));\r\n },\r\n handler: () => {\r\n this.maximize$.next(false);\r\n }\r\n }\r\n ];\r\n return (workspace.layer.dataSource as OgcFilterableDataSource).ogcFilters$?.value?.enabled ?\r\n actions : actions.filter(action => action.id !== 'ogcFilter');\r\n }\r\n}\r\n","import { Injectable, OnDestroy } from '@angular/core';\r\n\r\nimport { BehaviorSubject, Subscription, Observable, of } from 'rxjs';\r\n\r\nimport {\r\n EntityRecord,\r\n Workspace,\r\n WorkspaceStore,\r\n Widget,\r\n EntityStoreFilterCustomFuncStrategy,\r\n EntityStoreFilterSelectionStrategy,\r\n EntityState } from '@igo2/common';\r\nimport { WfsWorkspace, FeatureWorkspace, EditionWorkspace } from '@igo2/geo';\r\nimport { FeatureActionsService } from './shared/feature-actions.service';\r\nimport { WfsActionsService } from './shared/wfs-actions.service';\r\nimport { StorageService } from '@igo2/core';\r\nimport { EditionActionsService } from './shared/edition-actions.service';\r\n\r\n/**\r\n * Service that holds the state of the workspace module\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class WorkspaceState implements OnDestroy {\r\n\r\n public workspacePanelExpanded: boolean = false;\r\n\r\n readonly workspaceEnabled$: BehaviorSubject<boolean> = new BehaviorSubject<boolean>(false);\r\n readonly rowsInMapExtentCheckCondition$: BehaviorSubject<boolean> = new BehaviorSubject<boolean>(true);\r\n readonly selectOnlyCheckCondition$: BehaviorSubject<boolean> = new BehaviorSubject<boolean>(false);\r\n\r\n readonly workspaceMaximize$: BehaviorSubject<boolean> = new BehaviorSubject(\r\n this.storageService.get('workspaceMaximize') as boolean\r\n );\r\n private actionMaximize$$: Subscription[] = [];\r\n\r\n private rowsInMapExtentCheckCondition$$: Subscription;\r\n private selectOnlyCheckCondition$$: Subscription;\r\n\r\n /** Subscription to the active workspace */\r\n private activeWorkspace$$: Subscription;\r\n\r\n /** Subscription to the active workspace widget */\r\n private activeWorkspaceWidget$$: Subscription;\r\n\r\n /** Active widget observable. Only one may be active for all available workspaces */\r\n readonly activeWorkspaceWidget$: BehaviorSubject<Widget> = new BehaviorSubject<Widget>(undefined);\r\n\r\n /**\r\n * Observable of the active workspace\r\n */\r\n public workspace$ = new BehaviorSubject<Workspace>(undefined);\r\n\r\n /**\r\n * Store that holds all the available workspaces\r\n */\r\n get store(): WorkspaceStore { return this._store; }\r\n private _store: WorkspaceStore;\r\n\r\n get workspaceSelection() {\r\n if (this.workspace$.value) {\r\n return this.workspace$.value?.entityStore.stateView.manyBy((r) => r.state.selected === true);\r\n } else {\r\n return [];\r\n }\r\n }\r\n\r\n get workspaceSelection$(): Observable<EntityRecord<object, EntityState>[]> {\r\n if (this.workspace$.value) {\r\n return this.workspace$.value?.entityStore?.stateView.manyBy$((r) => r.state.selected === true);\r\n } else {\r\n return of([]);\r\n }\r\n }\r\n\r\n constructor(\r\n private featureActionsService: FeatureActionsService,\r\n private wfsActionsService: WfsActionsService,\r\n private editionActionsService: EditionActionsService,\r\n private storageService: StorageService\r\n ) {\r\n this.initWorkspaces();\r\n }\r\n\r\n /**\r\n * Initialize the workspace store. Each time a workspace is activated,\r\n * subscribe to it's active widget. Tracking the active widget is useful\r\n * to make sure only one widget is active at a time.\r\n */\r\n private initWorkspaces() {\r\n this._store = new WorkspaceStore([]);\r\n this._store.stateView\r\n .firstBy$((record: EntityRecord<Workspace>) => record.state.active === true)\r\n .subscribe((record: EntityRecord<Workspace>) => {\r\n const workspace = record ? record.entity : undefined;\r\n this.workspace$.next(workspace);\r\n });\r\n\r\n this._store.stateView.all$()\r\n .subscribe((workspaces: EntityRecord<Workspace>[]) => {\r\n workspaces.map((wks: EntityRecord<Workspace>) => {\r\n if (wks.entity.actionStore.empty) {\r\n if (wks.entity instanceof WfsWorkspace) {\r\n this.wfsActionsService.loadActions(\r\n wks.entity,\r\n this.rowsInMapExtentCheckCondition$,\r\n this.selectOnlyCheckCondition$);\r\n } else if (wks.entity instanceof FeatureWorkspace) {\r\n this.featureActionsService.loadActions(\r\n wks.entity,\r\n this.rowsInMapExtentCheckCondition$,\r\n this.selectOnlyCheckCondition$);\r\n } else if (wks.entity instanceof EditionWorkspace) {\r\n this.editionActionsService.loadActions(\r\n wks.entity,\r\n this.rowsInMapExtentCheckCondition$,\r\n this.selectOnlyCheckCondition$);\r\n }\r\n }\r\n\r\n });\r\n });\r\n\r\n this.actionMaximize$$.push(this.featureActionsService.maximize$.subscribe(maximized => {\r\n this.setWorkspaceIsMaximized(maximized);\r\n }));\r\n\r\n this.actionMaximize$$.push(this.wfsActionsService.maximize$.subscribe(maximized => {\r\n this.setWorkspaceIsMaximized(maximized);\r\n }));\r\n\r\n this.actionMaximize$$.push(this.editionActionsService.maximize$.subscribe(maximized => {\r\n this.setWorkspaceIsMaximized(maximized);\r\n }));\r\n\r\n this.activeWorkspace$$ = this.workspace$\r\n .subscribe((workspace: Workspace) => {\r\n if (this.activeWorkspaceWidget$$ !== undefined) {\r\n this.activeWorkspaceWidget$$.unsubscribe();\r\n this.activeWorkspaceWidget$$ = undefined;\r\n }\r\n\r\n if (workspace !== undefined) {\r\n this.activeWorkspaceWidget$$ = workspace.widget$\r\n .subscribe((widget: Widget) => this.activeWorkspaceWidget$.next(widget));\r\n }\r\n });\r\n\r\n this.rowsInMapExtentCheckCondition$$ = this.rowsInMapExtentCheckCondition$.subscribe((rowsInMapExtent) => {\r\n this._store.stateView.all().map((wks: EntityRecord<Workspace>) => {\r\n if (!wks.entity.actionStore.empty) {\r\n const filterStrategy = wks.entity.entityStore.getStrategyOfType(EntityStoreFilterCustomFuncStrategy);\r\n if (filterStrategy) {\r\n if (rowsInMapExtent) {\r\n filterStrategy.activate();\r\n } else {\r\n filterStrategy.deactivate();\r\n }\r\n }\r\n }\r\n });\r\n });\r\n\r\n this.selectOnlyCheckCondition$$ = this.selectOnlyCheckCondition$.subscribe((selectOnly) => {\r\n this._store.stateView.all().map((wks: EntityRecord<Workspace>) => {\r\n if (!wks.entity.actionStore.empty) {\r\n const filterStrategy = wks.entity.entityStore.getStrategyOfType(EntityStoreFilterSelectionStrategy);\r\n if (filterStrategy) {\r\n if (selectOnly) {\r\n filterStrategy.activate();\r\n } else {\r\n filterStrategy.deactivate();\r\n }\r\n }\r\n }\r\n });\r\n });\r\n }\r\n\r\n private setWorkspaceIsMaximized(maximized: boolean) {\r\n this.storageService.set('workspaceMaximize', maximized);\r\n this.workspaceMaximize$.next(maximized);\r\n }\r\n\r\n public setActiveWorkspaceById(id: string) {\r\n const wksFromId = this.store\r\n .all()\r\n .find(workspace => workspace.id === id);\r\n if (wksFromId) {\r\n this.store.activateWorkspace(wksFromId);\r\n }\r\n }\r\n\r\n public setActiveWorkspaceByTitle(title: string) {\r\n const wksFromTitle = this.store\r\n .all()\r\n .find(workspace => workspace.title === title);\r\n if (wksFromTitle) {\r\n this.store.activateWorkspace(wksFromTitle);\r\n }\r\n }\r\n\r\n /**\r\n * Teardown all the workspaces\r\n * @internal\r\n */\r\n ngOnDestroy() {\r\n this.teardownWorkspaces();\r\n this.actionMaximize$$.map(a => a.unsubscribe());\r\n if (this.rowsInMapExtentCheckCondition$$) {\r\n this.selectOnlyCheckCondition$$.unsubscribe();\r\n }\r\n if (this.selectOnlyCheckCondition$$) {\r\n this.selectOnlyCheckCondition$$.unsubscribe();\r\n }\r\n }\r\n\r\n /**\r\n * Teardown the workspace store and any subscribers\r\n */\r\n private teardownWorkspaces() {\r\n this.store.clear();\r\n if (this.activeWorkspaceWidget$$ !== undefined) {\r\n this.activeWorkspaceWidget$$.unsubscribe();\r\n }\r\n if (this.activeWorkspace$$ !== undefined) {\r\n this.activeWorkspace$$.unsubscribe();\r\n }\r\n }\r\n\r\n}\r\n","<button\r\n *ngIf=\"hasWorkspace$ | async\"\r\n mat-icon-button\r\n tooltip-position=\"below\"\r\n matTooltipShowDelay=\"500\"\r\n [matTooltip]=\"'igo.integration.workspace.toggleWorkspace' | translate\"\r\n [color]=\"color\"\r\n (click)=\"activateWorkspace()\"\r\n >\r\n <mat-icon svgIcon=\"table\"></mat-icon>\r\n</button>\r\n","import { Component, Input, ChangeDetectionStrategy, OnInit, OnDestroy } from '@angular/core';\r\nimport type { Layer } from '@igo2/geo';\r\nimport { WorkspaceState } from '../workspace.state';\r\nimport { BehaviorSubject, combineLatest, Subscription } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'igo-workspace-button',\r\n templateUrl: './workspace-button.component.html',\r\n styleUrls: ['./workspace-button.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class WorkspaceButtonComponent implements OnInit, OnDestroy {\r\n\r\n public hasWorkspace$: BehaviorSubject<boolean> = new BehaviorSubject(false);\r\n private hasWorkspace$$: Subscription;\r\n\r\n private _layer: Layer;\r\n private layer$: BehaviorSubject<Layer> = new BehaviorSubject(undefined);\r\n @Input()\r\n set layer(value: Layer) {\r\n this._layer = value;\r\n this.layer$.next(this._layer);\r\n }\r\n\r\n get layer(): Layer {\r\n return this._layer;\r\n }\r\n\r\n @Input() color: string = 'primary';\r\n\r\n constructor(private workspaceState: WorkspaceState) { }\r\n\r\n ngOnInit(): void {\r\n this.hasWorkspace$$ = combineLatest([this.workspaceState.workspaceEnabled$, this.layer$])\r\n .subscribe(bunch => this.hasWorkspace$.next(bunch[0] && bunch[1]?.options.workspace?.enabled)\r\n );\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.hasWorkspace$$.unsubscribe();\r\n }\r\n\r\n activateWorkspace() {\r\n if (\r\n this.workspaceState.workspace$.value &&\r\n (this.workspaceState.workspace$.value as any).layer.id === this.layer.id &&\r\n this.workspaceState.workspacePanelExpanded) {\r\n this.workspaceState.workspacePanelExpanded = false;\r\n } else {\r\n this.workspaceState.workspacePanelExpanded = true;\r\n this.workspaceState.setActiveWorkspaceById(this.layer.id);\r\n }\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WorkspaceButtonComponent } from './workspace-button/workspace-button.component';\r\nimport { MatButtonModule } from '@angular/material/button';\r\nimport { MatTooltipModule } from '@angular/material/tooltip';\r\nimport { MatIconModule } from '@angular/material/icon';\r\nimport { IgoLanguageModule } from '@igo2/core';\r\nimport { CommonModule } from '@angular/common';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n MatIconModule,\r\n MatButtonModule,\r\n MatTooltipModule,\r\n IgoLanguageModule\r\n ],\r\n declarations: [WorkspaceButtonComponent],\r\n exports: [WorkspaceButtonComponent]\r\n})\r\nexport class IgoAppWorkspaceModule {}\r\n","<mat-tab-group *ngIf=\"importExportShowBothType\" >\r\n <mat-tab [label]=\"'igo.integration.importExportTool.importExportData' | translate\">\r\n <igo-import-export \r\n [map]=\"map\"\r\n [selectFirstProj]=\"selectFirstProj\"\r\n [projectionsLimitations]=\"projectionsLimitations\"\r\n [store]=\"workspaceStore\"\r\n [selectedMode]=\"importExportState.selectedMode$ | async\"\r\n (selectMode)=\"modeChanged($event)\"\r\n [exportOptions$]=\"importExportState.exportOptions$\"\r\n (exportOptionsChange)=\"exportOptionsChange($event)\">\r\n </igo-import-export>\r\n </mat-tab>\r\n <mat-tab [label]=\"'igo.integration.importExportTool.importExportContext' | translate\">\r\n <igo-context-import-export [map]=\"map\"></igo-context-import-export>\r\n </mat-tab>\r\n</mat-tab-group>\r\n\r\n<igo-import-export \r\n *ngIf=\"!importExportShowBothType && importExportType === 'layer'\"\r\n [map]=\"map\"\r\n [store]=\"workspaceStore\"\r\n [selectedMode]=\"importExportState.selectedMode$ | async\"\r\n (selectMode)=\"modeChanged($event)\"\r\n [exportOptions$]=\"importExportState.exportOptions$\"\r\n (exportOptionsChange)=\"exportOptionsChange($event)\">\r\n</igo-import-export>\r\n\r\n<igo-context-import-export \r\n *ngIf=\"!importExportShowBothType && importExportType === 'context'\"\r\n [map]=\"map\">\r\n</igo-context-import-export>","import { Component, ChangeDetectionStrategy, OnInit, Input } from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport type { WorkspaceStore } from '@igo2/common';\r\nimport { IgoMap, ExportOptions, ProjectionsLimitationsOptions } from '@igo2/geo';\r\n\r\nimport { MapState } from '../../map/map.state';\r\nimport { ImportExportMode, ImportExportState, ImportExportType } from '../import-export.state';\r\nimport { WorkspaceState } from '../../workspace/workspace.state';\r\n\r\n@ToolComponent({\r\n name: 'importExport',\r\n title: 'igo.integration.tools.importExport',\r\n icon: 'file-move'\r\n})\r\n@Component({\r\n selector: 'igo-import-export-tool',\r\n templateUrl: './import-export-tool.component.html',\r\n styleUrls: ['./import-export-tool.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ImportExportToolComponent implements OnInit {\r\n\r\n @Input() projectionsLimitations: ProjectionsLimitationsOptions;\r\n\r\n @Input() selectFirstProj: boolean = false;\r\n\r\n /**\r\n * Map to measure on\r\n * @internal\r\n */\r\n get map(): IgoMap { return this.mapState.map; }\r\n\r\n get workspaceStore(): WorkspaceStore {\r\n return this.workspaceState.store;\r\n }\r\n\r\n @Input() importExportType: ImportExportType = ImportExportType.layer;\r\n @Input() importExportShowBothType: boolean = true;\r\n\r\n constructor(\r\n private mapState: MapState,\r\n public importExportState: ImportExportState,\r\n private workspaceState: WorkspaceState,\r\n ) {}\r\n\r\n ngOnInit(): void {\r\n this.selectType();\r\n this.selectMode();\r\n }\r\n\r\n private selectType() {\r\n if (this.importExportType) {\r\n this.importExportState.importExportType$.next(this.importExportType);\r\n }\r\n const userSelectedType = this.importExportState.importExportType$.value;\r\n if (userSelectedType !== undefined) {\r\n this.importExportState.setImportExportType(userSelectedType);\r\n } else {\r\n this.importExportState.setImportExportType(ImportExportType.layer);\r\n }\r\n }\r\n\r\n private selectMode() {\r\n const userSelectedMode = this.importExportState.selectedMode$.value;\r\n if (userSelectedMode !== undefined) {\r\n this.importExportState.setMode(userSelectedMode);\r\n } else {\r\n this.importExportState.setMode(ImportExportMode.import);\r\n\r\n }\r\n }\r\n\r\n public modeChanged(mode: ImportExportMode) {\r\n this.importExportState.setMode(mode);\r\n }\r\n\r\n public exportOptionsChange(exportOptions: ExportOptions) {\r\n this.importExportState.setsExportOptions(exportOptions);\r\n }\r\n\r\n importExportTypeChange(event) {\r\n this.importExportType = event.value;\r\n }\r\n}\r\n","import {\r\n NgModule,\r\n ModuleWithProviders,\r\n CUSTOM_ELEMENTS_SCHEMA\r\n} from '@angular/core';\r\n\r\nimport { IgoImportExportModule } from '@igo2/geo';\r\nimport { ImportExportToolComponent } from './import-export-tool/import-export-tool.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { MatButtonToggleModule } from '@angular/material/button-toggle';\r\nimport { MatTabsModule } from '@angular/material/tabs';\r\n\r\nimport { IgoLanguageModule } from '@igo2/core';\r\nimport { IgoContextImportExportModule } from '@igo2/context';\r\n\r\n@NgModule({\r\n imports: [\r\n IgoImportExportModule,\r\n IgoContextImportExportModule,\r\n CommonModule,\r\n IgoLanguageModule,\r\n MatButtonToggleModule,\r\n MatTabsModule\r\n ],\r\n declarations: [ImportExportToolComponent],\r\n exports: [ImportExportToolComponent],\r\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\r\n})\r\nexport class IgoAppImportExportModule {\r\n static forRoot(): ModuleWithProviders<IgoAppImportExportModule> {\r\n return {\r\n ngModule: IgoAppImportExportModule,\r\n providers: []\r\n };\r\n }\r\n}\r\n","<igo-layer-list class=\"mapDetailsList\" *ngIf=\"(layers$ | async).length; else empty\"\r\n [map]=\"map\"\r\n igoLayerListBinding\r\n [excludeBaseLayers]=\"excludeBaseLayers\"\r\n [layerFilterAndSortOptions]=\"layerFilterAndSortOptions\"\r\n [expandLegendOfVisibleLayers]=\"expandLegendOfVisibleLayers\"\r\n [toggleLegendOnVisibilityChange]=\"toggleLegendOnVisibilityChange\"\r\n [updateLegendOnResolutionChange]=\"updateLegendOnResolutionChange\"\r\n floatLabel=\"never\"\r\n [queryBadge]=\"queryBadge\">\r\n\r\n <ng-template #igoLayerItemToolbar let-layer=\"layer\">\r\n <!-- <igo-download-button [layer]=\"layer\"></igo-download-button> -->\r\n <igo-workspace-button [layer]=\"layer\"></igo-workspace-button>\r\n <igo-export-button [layer]=\"layer\" (click)=\"activateExport(layer)\"></igo-export-button>\r\n <igo-ogc-filter-button [header]=\"ogcButton\" [layer]=\"layer\"></igo-ogc-filter-button>\r\n <igo-time-filter-button [header]=\"timeButton\" [layer]=\"layer\"></igo-time-filter-button>\r\n <igo-track-feature-button [trackFeature]=\"true\" [layer]=\"layer\"></igo-track-feature-button>\r\n <igo-metadata-button [layer]=\"layer\"></igo-metadata-button>\r\n </ng-template>\r\n\r\n</igo-layer-list>\r\n\r\n<ng-template #empty>\r\n <mat-list *ngIf=\"delayedShowEmptyMapContent\">\r\n <p class=\"map-empty mat-typography\">\r\n {{'igo.integration.mapTool.empty' | translate}}</p>\r\n <p *ngIf=\"layerAdditionAllowed && (searchToolInToolbar || catalogToolInToolbar || contextToolInToolbar)\" class=\"map-empty mat-typography\">\r\n {{'igo.integration.mapTool.customize' | translate}}</p>\r\n <mat-list-item *ngIf=\"layerAdditionAllowed && searchToolInToolbar\">\r\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%' preserveAspectRatio='xMidYMid meet' focusable='false'> <path d='M9.5,3A6.5,6.5 0 0,1 16,9.5C16,11.11 15.41,12.59 14.44,13.73L14.71,14H15.5L20.5,19L19,20.5L14,15.5V14.71L13.73,14.44C12.59,15.41 11.11,16 9.5,16A6.5,6.5 0 0,1 3,9.5A6.5,6.5 0 0,1 9.5,3M9.5,5C7,5 5,7 5,9.5C5,12 7,14 9.5,14C12,14 14,12 14,9.5C14,7 12,5 9.5,5Z'> </path> </svg></mat-icon>\r\n <h4 matLine class=\"search-tool mat-typography\" (click)=\"searchEmit()\">\r\n {{'igo.integration.mapTool.search-tool' | translate}}\r\n </h4>\r\n </mat-list-item>\r\n <mat-list-item *ngIf=\"layerAdditionAllowed && catalogToolInToolbar\">\r\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%' preserveAspectRatio='xMidYMid meet' focusable='false'> <path d='M17,14H19V17H22V19H19V22H17V19H14V17H17V14M11,16L2,9L11,2L20,9L11,16M11,18.54L12,17.75V18C12,18.71 12.12,19.39 12.35,20L11,21.07L2,14.07L3.62,12.81L11,18.54Z'></path> </svg></mat-icon>\r\n <h4 matLine class=\"catalog-tool mat-typography\" (click)=\"catalogEmit()\">\r\n {{'igo.integration.mapTool.catalog-tool' | translate}}\r\n </h4>\r\n </mat-list-item>\r\n <mat-list-item *ngIf=\"layerAdditionAllowed && contextToolInToolbar\">\r\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%' preserveAspectRatio='xMidYMid meet' focusable='false'> <path d='M12,17.27L18.18,21L16.54,13.97L22,9.24L14.81,8.62L12,2L9.19,8.62L2,9.24L7.45,13.97L5.82,21L12,17.27Z'></path> </svg></mat-icon>\r\n <h4 matLine class=\"context-tool mat-typography\" (click)=\"contextEmit()\">\r\n {{'igo.integration.mapTool.context-tool' | translate}}\r\n </h4>\r\n </mat-list-item>\r\n </mat-list>\r\n</ng-template>\r\n","import { Component, Input, OnInit, ChangeDetectorRef } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { map } from 'rxjs/operators';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport {\r\n LayerListControlsEnum,\r\n Layer,\r\n IgoMap,\r\n LayerListControlsOptions,\r\n SearchSourceService,\r\n sourceCanSearch,\r\n ExportOptions\r\n} from '@igo2/geo';\r\n\r\nimport { ToolState } from './../../tool/tool.state';\r\nimport { MapState } from './../map.state';\r\nimport { ImportExportMode, ImportExportState } from '../../import-export/import-export.state';\r\n\r\n@ToolComponent({\r\n name: 'mapDetails',\r\n title: 'igo.integration.tools.map',\r\n icon: 'map'\r\n})\r\n@Component({\r\n selector: 'igo-map-details-tool',\r\n templateUrl: './map-details-tool.component.html',\r\n styleUrls: ['./map-details-tool.component.scss']\r\n})\r\nexport class MapDetailsToolComponent implements OnInit {\r\n public delayedShowEmptyMapContent: boolean = false;\r\n\r\n @Input() toggleLegendOnVisibilityChange: boolean = false;\r\n\r\n @Input() expandLegendOfVisibleLayers: boolean = false;\r\n\r\n @Input() updateLegendOnResolutionChange: boolean = false;\r\n\r\n @Input() ogcButton: boolean = true;\r\n\r\n @Input() timeButton: boolean = true;\r\n\r\n @Input() layerListControls: LayerListControlsOptions = {};\r\n\r\n @Input() queryBadge: boolean = false;\r\n\r\n @Input() layerAdditionAllowed: boolean = true;\r\n\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n\r\n get layers$(): Observable<Layer[]> {\r\n return this.map.layers$.pipe(\r\n map((layers) =>\r\n layers.filter(\r\n (layer) =>\r\n layer.showInLayerList !== false &&\r\n (!this.excludeBaseLayers || !layer.baseLayer)\r\n )\r\n )\r\n );\r\n }\r\n\r\n get excludeBaseLayers(): boolean {\r\n return this.layerListControls.excludeBaseLayers || false;\r\n }\r\n\r\n get layerFilterAndSortOptions(): any {\r\n const filterSortOptions = Object.assign(\r\n {\r\n showToolbar: LayerListControlsEnum.default\r\n },\r\n this.layerListControls\r\n );\r\n\r\n switch (this.layerListControls.showToolbar) {\r\n case LayerListControlsEnum.always:\r\n filterSortOptions.showToolbar = LayerListControlsEnum.always;\r\n break;\r\n case LayerListControlsEnum.never:\r\n filterSortOptions.showToolbar = LayerListControlsEnum.never;\r\n break;\r\n default:\r\n break;\r\n }\r\n return filterSortOptions;\r\n }\r\n\r\n get searchToolInToolbar(): boolean {\r\n return (\r\n this.toolState.toolbox.getToolbar().indexOf('searchResults') !== -1 &&\r\n this.searchSourceService\r\n .getSources()\r\n .filter(sourceCanSearch)\r\n .filter((s) => s.available && s.getType() === 'Layer').length > 0\r\n );\r\n }\r\n\r\n get catalogToolInToolbar(): boolean {\r\n return this.toolState.toolbox.getToolbar().indexOf('catalog') !== -1;\r\n }\r\n\r\n get contextToolInToolbar(): boolean {\r\n return this.toolState.toolbox.getToolbar().indexOf('contextManager') !== -1;\r\n }\r\n\r\n constructor(\r\n private mapState: MapState,\r\n private toolState: ToolState,\r\n private searchSourceService: SearchSourceService,\r\n private cdRef: ChangeDetectorRef,\r\n private importExportState: ImportExportState\r\n ) {}\r\n\r\n ngOnInit(): void {\r\n // prevent message to be shown too quickly. Waiting for layers\r\n setTimeout(() => {\r\n this.delayedShowEmptyMapContent = true;\r\n this.cdRef.detectChanges();\r\n }, 250);\r\n }\r\n\r\n searchEmit() {\r\n this.toolState.toolbox.activateTool('searchResults');\r\n }\r\n\r\n catalogEmit() {\r\n this.toolState.toolbox.activateTool('catalog');\r\n }\r\n\r\n contextEmit() {\r\n this.toolState.toolbox.activateTool('contextManager');\r\n }\r\n\r\n activateExport(layer: Layer) {\r\n let id = layer.id;\r\n if (layer.options.workspace?.workspaceId) {\r\n id = layer.options.workspace.workspaceId !== layer.id ? layer.options.workspace.workspaceId : layer.id;\r\n }\r\n this.importExportState.setsExportOptions({ layers: [id] } as ExportOptions);\r\n this.importExportState.setMode(ImportExportMode.export);\r\n this.toolState.toolbox.activateTool('importExport');\r\n }\r\n}\r\n","<mat-tab-group>\r\n\r\n <mat-tab [label]=\"'igo.integration.tools.map' | translate\">\r\n <igo-layer-list\r\n [map]=\"map\"\r\n igoLayerListBinding\r\n [excludeBaseLayers]=\"excludeBaseLayers\"\r\n [layerFilterAndSortOptions]=\"layerFilterAndSortOptions\"\r\n [expandLegendOfVisibleLayers]=\"expandLegendOfVisibleLayers\"\r\n [toggleLegendOnVisibilityChange]=\"toggleLegendOnVisibilityChange\"\r\n [updateLegendOnResolutionChange]=\"updateLegendOnResolutionChange\"\r\n [floatLabel]=\"false\"\r\n [queryBadge]=\"queryBadge\">\r\n\r\n <ng-template #igoLayerItemToolbar let-layer=\"layer\">\r\n <!-- <igo-download-button [layer]=\"layer\"></igo-download-button> -->\r\n <igo-workspace-button [layer]=\"layer\"></igo-workspace-button>\r\n <igo-export-button [layer]=\"layer\" (click)=\"activateExport(layer)\"></igo-export-button>\r\n <igo-ogc-filter-button [header]=\"ogcButton\" [layer]=\"layer\"></igo-ogc-filter-button>\r\n <igo-time-filter-button [header]=\"timeButton\" [layer]=\"layer\"></igo-time-filter-button>\r\n <igo-track-feature-button [trackFeature]=\"true\" [layer]=\"layer\"></igo-track-feature-button>\r\n <igo-metadata-button [layer]=\"layer\"></igo-metadata-button>\r\n </ng-template>\r\n\r\n </igo-layer-list>\r\n </mat-tab>\r\n\r\n <mat-tab [label]=\"'igo.integration.tools.contexts' | translate\">\r\n <igo-context-list igoContextListBinding></igo-context-list>\r\n </mat-tab>\r\n\r\n</mat-tab-group>\r\n","import { Component, ChangeDetectionStrategy, Input } from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport {\r\n LayerListControlsEnum,\r\n LayerListControlsOptions,\r\n IgoMap,\r\n ExportOptions,\r\n Layer\r\n} from '@igo2/geo';\r\nimport { MapState } from './../map.state';\r\nimport { ImportExportMode, ImportExportState } from '../../import-export/import-export.state';\r\nimport { ToolState } from '../../tool/tool.state';\r\n\r\n/**\r\n * Tool to browse a map's layers or to choose a different map\r\n */\r\n@ToolComponent({\r\n name: 'map',\r\n title: 'igo.integration.tools.map',\r\n icon: 'map'\r\n})\r\n@Component({\r\n selector: 'igo-map-tool',\r\n templateUrl: './map-tool.component.html',\r\n styleUrls: ['./map-tool.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class MapToolComponent {\r\n @Input() toggleLegendOnVisibilityChange: boolean = false;\r\n\r\n @Input() expandLegendOfVisibleLayers: boolean = false;\r\n\r\n @Input() updateLegendOnResolutionChange: boolean = false;\r\n\r\n @Input() ogcButton: boolean = true;\r\n\r\n @Input() timeButton: boolean = true;\r\n\r\n @Input() layerListControls: LayerListControlsOptions = {};\r\n\r\n @Input() queryBadge: boolean = false;\r\n\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n\r\n get excludeBaseLayers(): boolean {\r\n return this.layerListControls.excludeBaseLayers || false;\r\n }\r\n\r\n get layerFilterAndSortOptions(): any {\r\n const filterSortOptions = Object.assign(\r\n {\r\n showToolbar: LayerListControlsEnum.default\r\n },\r\n this.layerListControls\r\n );\r\n\r\n switch (this.layerListControls.showToolbar) {\r\n case LayerListControlsEnum.always:\r\n filterSortOptions.showToolbar = LayerListControlsEnum.always;\r\n break;\r\n case LayerListControlsEnum.never:\r\n filterSortOptions.showToolbar = LayerListControlsEnum.never;\r\n break;\r\n default:\r\n break;\r\n }\r\n return filterSortOptions;\r\n }\r\n\r\n constructor(\r\n private mapState: MapState,\r\n private toolState: ToolState,\r\n private importExportState: ImportExportState\r\n ) {}\r\n\r\n activateExport(layer: Layer) {\r\n let id = layer.id;\r\n if (layer.options.workspace?.workspaceId) {\r\n id = layer.options.workspace.workspaceId !== layer.id ? layer.options.workspace.workspaceId : layer.id;\r\n }\r\n this.importExportState.setsExportOptions({ layers: [id] } as ExportOptions);\r\n this.importExportState.setMode(ImportExportMode.export);\r\n this.toolState.toolbox.activateTool('importExport');\r\n }\r\n}\r\n","<mat-tab-group\r\n #tabGroup\r\n [selectedIndex]=\"layerListToolState.selectedTab$ | async\"\r\n (selectedTabChange)=\"tabChanged($event)\">\r\n\r\n <mat-tab [label]=\"'igo.integration.tools.layers' | translate\">\r\n <igo-layer-list *ngIf=\"(layers$ | async).length !== 0; else emptyLayers\"\r\n igoLayerListBinding\r\n [excludeBaseLayers]=\"excludeBaseLayers\"\r\n [layerFilterAndSortOptions]=\"layerFilterAndSortOptions\"\r\n [expandLegendOfVisibleLayers]=\"expandLegendOfVisibleLayers\"\r\n [toggleLegendOnVisibilityChange]=\"toggleLegendOnVisibilityChange\"\r\n [updateLegendOnResolutionChange]=\"updateLegendOnResolutionChange\"\r\n [floatLabel]=\"false\"\r\n [queryBadge]=\"queryBadge\"\r\n [map]=\"map\"\r\n (appliedFilterAndSort)= onLayerListChange($event)>\r\n\r\n <ng-template #igoLayerItemToolbar let-layer=\"layer\">\r\n <igo-metadata-button [layer]=\"layer\"></igo-metadata-button>\r\n <igo-track-feature-button [trackFeature]=\"true\" [layer]=\"layer\"></igo-track-feature-button>\r\n <igo-time-filter-button *ngIf=\"isTimeFilterButton(layer)\" [header]=\"timeButton\" [layer]=\"layer\"\r\n (click)=\"activateTimeFilter()\"></igo-time-filter-button>\r\n <igo-ogc-filter-button *ngIf=\"isOGCFilterButton(layer)\" [header]=\"ogcButton\" [layer]=\"layer\"\r\n (click)=\"activateOgcFilter()\"></igo-ogc-filter-button>\r\n <igo-export-button *ngIf=\"isExportButton(layer)\" [layer]=\"layer\" (click)=\"activateExport(layer)\"></igo-export-button>\r\n <igo-workspace-button [layer]=\"layer\"></igo-workspace-button>\r\n </ng-template>\r\n </igo-layer-list>\r\n </mat-tab>\r\n\r\n <mat-tab [label]=\"'igo.integration.tools.legend' | translate\">\r\n <igo-layer-legend-list *ngIf=\"showAllLegend()\"\r\n igoLayerLegendListBinding\r\n [allowShowAllLegends]=\"allowShowAllLegends\"\r\n [showAllLegendsValue]=\"(showAllLegendsValue$ | async)\"\r\n (allLegendsShown)=\"onShowAllLegends($event)\"\r\n [excludeBaseLayers]=\"excludeBaseLayers\"\r\n [updateLegendOnResolutionChange]=\"updateLegendOnResolutionChange\">\r\n </igo-layer-legend-list>\r\n <ng-template *ngIf=\"(layers$ | async).length !== 0; else emptyLayers\"></ng-template>\r\n\r\n <p class=\"map-empty mat-typography\"\r\n *ngIf=\"!allowShowAllLegends && (layers$ | async).length !== 0 && (visibleOrInRangeLayers$ | async).length === 0\">\r\n {{ ((visibleLayers$ | async).length) ? ('igo.integration.mapTool.noLayersInRange' | translate) : ('igo.integration.mapTool.noLayersVisible' | translate) }}\r\n </p>\r\n </mat-tab>\r\n\r\n <ng-template #emptyLayers>\r\n <mat-list *ngIf=\"delayedShowEmptyMapContent\">\r\n <p class=\"map-empty mat-typography\">\r\n {{'igo.integration.mapTool.empty' | translate}}</p>\r\n <p *ngIf=\"layerAdditionAllowed && (searchToolInToolbar || catalogToolInToolbar || contextToolInToolbar)\"\r\n class=\"map-empty mat-typography\">\r\n {{'igo.integration.mapTool.customize' | translate}}</p>\r\n\r\n <mat-list-item *ngIf=\"layerAdditionAllowed && searchToolInToolbar\">\r\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%'\r\n preserveAspectRatio='xMidYMid meet' focusable='false'>\r\n <path\r\n d='M9.5,3A6.5,6.5 0 0,1 16,9.5C16,11.11 15.41,12.59 14.44,13.73L14.71,14H15.5L20.5,19L19,20.5L14,15.5V14.71L13.73,14.44C12.59,15.41 11.11,16 9.5,16A6.5,6.5 0 0,1 3,9.5A6.5,6.5 0 0,1 9.5,3M9.5,5C7,5 5,7 5,9.5C5,12 7,14 9.5,14C12,14 14,12 14,9.5C14,7 12,5 9.5,5Z'>\r\n </path>\r\n </svg></mat-icon>\r\n <h4 matLine class=\"search-tool mat-typography\" (click)=\"searchEmit()\">\r\n {{'igo.integration.mapTool.search-tool' | translate}}\r\n </h4>\r\n </mat-list-item>\r\n <mat-list-item *ngIf=\"layerAdditionAllowed && catalogToolInToolbar\">\r\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%'\r\n preserveAspectRatio='xMidYMid meet' focusable='false'>\r\n <path\r\n d='M17,14H19V17H22V19H19V22H17V19H14V17H17V14M11,16L2,9L11,2L20,9L11,16M11,18.54L12,17.75V18C12,18.71 12.12,19.39 12.35,20L11,21.07L2,14.07L3.62,12.81L11,18.54Z'>\r\n </path>\r\n </svg></mat-icon>\r\n <h4 matLine class=\"catalog-tool mat-typography\" (click)=\"catalogEmit()\">\r\n {{'igo.integration.mapTool.catalog-tool' | translate}}\r\n </h4>\r\n </mat-list-item>\r\n <mat-list-item *ngIf=\"layerAdditionAllowed && contextToolInToolbar\">\r\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%'\r\n preserveAspectRatio='xMidYMid meet' focusable='false'>\r\n <path\r\n d='M12,17.27L18.18,21L16.54,13.97L22,9.24L14.81,8.62L12,2L9.19,8.62L2,9.24L7.45,13.97L5.82,21L12,17.27Z'>\r\n </path>\r\n </svg></mat-icon>\r\n <h4 matLine class=\"context-tool mat-typography\" (click)=\"contextEmit()\">\r\n {{'igo.integration.mapTool.context-tool' | translate}}\r\n </h4>\r\n </mat-list-item>\r\n </mat-list>\r\n </ng-template>\r\n</mat-tab-group>\r\n","import {\r\n Component,\r\n ChangeDetectionStrategy,\r\n Input,\r\n OnInit,\r\n ViewChild,\r\n OnDestroy\r\n} from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport {\r\n LayerListControlsEnum,\r\n LayerListControlsOptions,\r\n IgoMap,\r\n SearchSourceService,\r\n sourceCanSearch,\r\n Layer,\r\n ExportOptions,\r\n VectorLayer\r\n} from '@igo2/geo';\r\n\r\nimport { LayerListToolState } from '../layer-list-tool.state';\r\nimport { MatTabChangeEvent } from '@angular/material/tabs';\r\nimport { ToolState } from '../../tool/tool.state';\r\nimport { MapState } from '../map.state';\r\nimport { BehaviorSubject, Observable, Subscription, combineLatest } from 'rxjs';\r\nimport { map, debounceTime } from 'rxjs/operators';\r\nimport { ImportExportMode, ImportExportState } from '../../import-export/import-export.state';\r\n/**\r\n * Tool to browse a map's layers or to choose a different map\r\n */\r\n@ToolComponent({\r\n name: 'mapTools',\r\n title: 'igo.integration.tools.map',\r\n icon: 'map'\r\n})\r\n@Component({\r\n selector: 'igo-map-tools',\r\n templateUrl: './map-tools.component.html',\r\n styleUrls: ['./map-tools.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class MapToolsComponent implements OnInit, OnDestroy {\r\n layers$: BehaviorSubject<Layer[]> = new BehaviorSubject([]);\r\n showAllLegendsValue$: BehaviorSubject<boolean> = new BehaviorSubject(false);\r\n\r\n private resolution$$: Subscription;\r\n private visibleOrInRangeLayers$$: Subscription;\r\n public delayedShowEmptyMapContent: boolean = false;\r\n\r\n @Input() allowShowAllLegends: boolean = false;\r\n\r\n @Input() showAllLegendsValue: boolean = false;\r\n\r\n @Input() toggleLegendOnVisibilityChange: boolean = false;\r\n\r\n @Input() expandLegendOfVisibleLayers: boolean = false;\r\n\r\n @Input() updateLegendOnResolutionChange: boolean = false;\r\n\r\n @Input() selectedTabAtOpening: string;\r\n\r\n @Input() ogcButton: boolean = true;\r\n\r\n @Input() timeButton: boolean = true;\r\n\r\n @Input() layerAdditionAllowed: boolean = true;\r\n\r\n @Input()\r\n get layerListControls(): LayerListControlsOptions {\r\n return this._layerListControls;\r\n }\r\n set layerListControls(value: LayerListControlsOptions) {\r\n const stateOptions = this.layerListToolState.getLayerListControls();\r\n const stateKeyword = stateOptions.keyword;\r\n const stateOnlyVisible = stateOptions.onlyVisible;\r\n const stateSortAlpha = stateOptions.sortAlpha;\r\n\r\n value.keyword = stateKeyword !== '' ? stateKeyword : value.keyword;\r\n value.onlyVisible =\r\n stateOnlyVisible !== undefined ? stateOnlyVisible : value.onlyVisible;\r\n value.sortAlpha =\r\n stateSortAlpha !== undefined ? stateSortAlpha : value.sortAlpha;\r\n\r\n value.onlyVisible =\r\n value.onlyVisible === undefined ? false : value.onlyVisible;\r\n value.sortAlpha = value.sortAlpha === undefined ? false : value.sortAlpha;\r\n\r\n this._layerListControls = value;\r\n }\r\n private _layerListControls = {};\r\n\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n\r\n @Input() queryBadge: boolean = false;\r\n\r\n get visibleOrInRangeLayers$(): Observable<Layer[]> {\r\n return this.layers$.pipe(\r\n map((layers) =>\r\n layers.filter(\r\n (layer) => layer.visible$.value && layer.isInResolutionsRange$.value\r\n )\r\n )\r\n );\r\n }\r\n\r\n get visibleLayers$(): Observable<Layer[]> {\r\n return this.layers$.pipe(\r\n map((layers) => layers.filter((layer) => layer.visible$.value))\r\n );\r\n }\r\n\r\n get excludeBaseLayers(): boolean {\r\n return this.layerListControls.excludeBaseLayers || false;\r\n }\r\n\r\n get layerFilterAndSortOptions(): LayerListControlsOptions {\r\n const filterSortOptions = Object.assign(\r\n {\r\n showToolbar: LayerListControlsEnum.default\r\n },\r\n this.layerListControls\r\n );\r\n\r\n switch (this.layerListControls.showToolbar) {\r\n case LayerListControlsEnum.always:\r\n filterSortOptions.showToolbar = LayerListControlsEnum.always;\r\n break;\r\n case LayerListControlsEnum.never:\r\n filterSortOptions.showToolbar = LayerListControlsEnum.never;\r\n break;\r\n default:\r\n break;\r\n }\r\n return filterSortOptions;\r\n }\r\n\r\n @ViewChild('tabGroup', { static: true }) tabGroup;\r\n\r\n get searchToolInToolbar(): boolean {\r\n return (\r\n this.toolState.toolbox.getToolbar().indexOf('searchResults') !== -1 &&\r\n this.searchSourceService\r\n .getSources()\r\n .filter(sourceCanSearch)\r\n .filter((s) => s.available && s.getType() === 'Layer').length > 0\r\n );\r\n }\r\n\r\n get catalogToolInToolbar(): boolean {\r\n return this.toolState.toolbox.getToolbar().indexOf('catalog') !== -1;\r\n }\r\n\r\n get contextToolInToolbar(): boolean {\r\n return this.toolState.toolbox.getToolbar().indexOf('contextManager') !== -1;\r\n }\r\n\r\n constructor(\r\n public layerListToolState: LayerListToolState,\r\n private toolState: ToolState,\r\n public mapState: MapState,\r\n private searchSourceService: SearchSourceService,\r\n private importExportState: ImportExportState\r\n ) {}\r\n\r\n ngOnInit(): void {\r\n this.selectedTab();\r\n this.resolution$$ = combineLatest([\r\n this.map.layers$,\r\n this.map.viewController.resolution$\r\n ])\r\n .pipe(debounceTime(10))\r\n .subscribe((bunch: [Layer[], number]) => {\r\n this.layers$.next(\r\n bunch[0].filter(\r\n (layer) =>\r\n layer.showInLayerList !== false &&\r\n (!this.excludeBaseLayers || !layer.baseLayer)\r\n )\r\n );\r\n });\r\n\r\n if (this.allowShowAllLegends) {\r\n this.mapState.showAllLegendsValue =\r\n this.mapState.showAllLegendsValue !== undefined\r\n ? this.mapState.showAllLegendsValue\r\n : this.showAllLegendsValue || false;\r\n this.showAllLegendsValue$.next(this.mapState.showAllLegendsValue);\r\n } else {\r\n this.showAllLegendsValue$.next(false);\r\n }\r\n\r\n // prevent message to be shown too quickly. Waiting for layers\r\n setTimeout(() => (this.delayedShowEmptyMapContent = true), 250);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.resolution$$.unsubscribe();\r\n if (this.visibleOrInRangeLayers$$) {\r\n this.visibleOrInRangeLayers$$.unsubscribe();\r\n }\r\n }\r\n\r\n onShowAllLegends(event) {\r\n this.mapState.showAllLegendsValue = event;\r\n this.showAllLegendsValue$.next(event);\r\n }\r\n\r\n private selectedTab() {\r\n const userSelectedTab = this.layerListToolState.selectedTab$.value;\r\n if (userSelectedTab !== undefined) {\r\n this.layerListToolState.setSelectedTab(userSelectedTab);\r\n } else {\r\n if (this.selectedTabAtOpening === 'legend') {\r\n this.layerListToolState.setSelectedTab(1);\r\n } else {\r\n this.layerListToolState.setSelectedTab(0);\r\n }\r\n }\r\n }\r\n\r\n public tabChanged(tab: MatTabChangeEvent) {\r\n this.layerListToolState.setSelectedTab(tab.index);\r\n this.layers$.next(\r\n this.map.layers.filter(\r\n (layer) =>\r\n layer.showInLayerList !== false &&\r\n (!this.excludeBaseLayers || !layer.baseLayer)\r\n )\r\n );\r\n }\r\n\r\n onLayerListChange(appliedFilters: LayerListControlsOptions) {\r\n this.layerListToolState.setKeyword(appliedFilters.keyword);\r\n this.layerListToolState.setSortAlpha(appliedFilters.sortAlpha);\r\n this.layerListToolState.setOnlyVisible(appliedFilters.onlyVisible);\r\n }\r\n\r\n showAllLegend() {\r\n if (this.layers$.getValue().length === 0) {\r\n return false;\r\n } else if (\r\n this.layers$.getValue().length !== 0 &&\r\n this.allowShowAllLegends === false\r\n ) {\r\n let visibleOrInRangeLayers;\r\n this.visibleOrInRangeLayers$$ = this.visibleOrInRangeLayers$.subscribe((value) => {\r\n value.length === 0\r\n ? (visibleOrInRangeLayers = false)\r\n : (visibleOrInRangeLayers = true);\r\n });\r\n\r\n if (visibleOrInRangeLayers === false) {\r\n return false;\r\n }\r\n }\r\n return true;\r\n }\r\n\r\n activateExport(layer: Layer) {\r\n let id = layer.id;\r\n if (layer.options.workspace?.workspaceId) {\r\n id = layer.options.workspace.workspaceId !== layer.id ? layer.options.workspace.workspaceId : layer.id;\r\n }\r\n this.importExportState.setsExportOptions({ layers: [id] } as ExportOptions);\r\n this.importExportState.setMode(ImportExportMode.export);\r\n this.toolState.toolbox.activateTool('importExport');\r\n }\r\n\r\n activateTimeFilter() {\r\n this.toolState.toolbox.activateTool('activeTimeFilter');\r\n }\r\n\r\n activateOgcFilter() {\r\n this.toolState.toolbox.activateTool('activeOgcFilter');\r\n }\r\n\r\n searchEmit() {\r\n this.toolState.toolbox.activateTool('searchResults');\r\n }\r\n\r\n catalogEmit() {\r\n this.toolState.toolbox.activateTool('catalog');\r\n }\r\n\r\n contextEmit() {\r\n this.toolState.toolbox.activateTool('contextManager');\r\n }\r\n\r\n isTimeFilterButton(layer): boolean {\r\n const options = layer.dataSource.options;\r\n return this.timeButton && options.timeFilterable && options.timeFilter;\r\n }\r\n\r\n isOGCFilterButton(layer): boolean {\r\n const options = layer.dataSource.options;\r\n return this.ogcButton && options.ogcFilters && options.ogcFilters.enabled &&\r\n (options.ogcFilters.pushButtons || options.ogcFilters.checkboxes || options.ogcFilters.radioButtons\r\n || options.ogcFilters.select || options.ogcFilters.autocomplete || options.ogcFilters.editable);\r\n }\r\n\r\n isExportButton(layer: Layer): boolean {\r\n if (\r\n (layer instanceof VectorLayer && layer.exportable === true) ||\r\n (layer.dataSource.options.download && layer.dataSource.options.download.url) ||\r\n (layer.options.workspace?.enabled && layer.options.workspace?.workspaceId !== layer.id))\r\n {\r\n return true;\r\n }\r\n return false;\r\n }\r\n}\r\n","<igo-layer-legend-list *ngIf=\"showAllLegend()\"\r\n igoLayerLegendListBinding\r\n [excludeBaseLayers]=\"excludeBaseLayers\"\r\n [allowShowAllLegends]=\"allowShowAllLegends\"\r\n [updateLegendOnResolutionChange]=\"updateLegendOnResolutionChange\"\r\n [showAllLegendsValue]=\"(showAllLegendsValue$ | async)\"\r\n (allLegendsShown)=\"onShowAllLegends($event)\">\r\n</igo-layer-legend-list>\r\n<ng-template *ngIf=\"(layers$ | async).length !== 0; else emptyLayers\"></ng-template>\r\n\r\n<p class=\"map-empty mat-typography\"\r\n *ngIf=\"!allowShowAllLegends && (layers$ | async).length !== 0 && (visibleOrInRangeLayers$ | async).length === 0\">\r\n {{ ((visibleLayers$ | async).length) ? ('igo.integration.mapTool.noLayersInRange' | translate) : ('igo.integration.mapTool.noLayersVisible' | translate) }}\r\n</p>\r\n\r\n\r\n<ng-template #emptyLayers>\r\n <mat-list *ngIf=\"delayedShowEmptyMapContent\">\r\n <p class=\"map-empty mat-typography\">\r\n {{'igo.integration.mapTool.empty' | translate}}</p>\r\n <p *ngIf=\"layerAdditionAllowed && (searchToolInToolbar || catalogToolInToolbar || contextToolInToolbar)\" class=\"map-empty mat-typography\">\r\n {{'igo.integration.mapTool.customize' | translate}}</p>\r\n\r\n <mat-list-item *ngIf=\"layerAdditionAllowed && searchToolInToolbar\">\r\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%' preserveAspectRatio='xMidYMid meet' focusable='false'> <path d='M9.5,3A6.5,6.5 0 0,1 16,9.5C16,11.11 15.41,12.59 14.44,13.73L14.71,14H15.5L20.5,19L19,20.5L14,15.5V14.71L13.73,14.44C12.59,15.41 11.11,16 9.5,16A6.5,6.5 0 0,1 3,9.5A6.5,6.5 0 0,1 9.5,3M9.5,5C7,5 5,7 5,9.5C5,12 7,14 9.5,14C12,14 14,12 14,9.5C14,7 12,5 9.5,5Z'> </path> </svg></mat-icon>\r\n <h4 matLine class=\"search-tool mat-typography\" (click)=\"searchEmit()\">\r\n {{'igo.integration.mapTool.search-tool' | translate}}\r\n </h4>\r\n </mat-list-item>\r\n <mat-list-item *ngIf=\"layerAdditionAllowed && catalogToolInToolbar\">\r\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%' preserveAspectRatio='xMidYMid meet' focusable='false'> <path d='M17,14H19V17H22V19H19V22H17V19H14V17H17V14M11,16L2,9L11,2L20,9L11,16M11,18.54L12,17.75V18C12,18.71 12.12,19.39 12.35,20L11,21.07L2,14.07L3.62,12.81L11,18.54Z'></path> </svg></mat-icon>\r\n <h4 matLine class=\"catalog-tool mat-typography\" (click)=\"catalogEmit()\">\r\n {{'igo.integration.mapTool.catalog-tool' | translate}}\r\n </h4>\r\n </mat-list-item>\r\n <mat-list-item *ngIf=\"layerAdditionAllowed && contextToolInToolbar\">\r\n <mat-icon mat-list-icon> <svg viewBox='0 0 24 24' fit='' height='100%' width='100%' preserveAspectRatio='xMidYMid meet' focusable='false'> <path d='M12,17.27L18.18,21L16.54,13.97L22,9.24L14.81,8.62L12,2L9.19,8.62L2,9.24L7.45,13.97L5.82,21L12,17.27Z'></path> </svg></mat-icon>\r\n <h4 matLine class=\"context-tool mat-typography\" (click)=\"contextEmit()\">\r\n {{'igo.integration.mapTool.context-tool' | translate}}\r\n </h4>\r\n </mat-list-item>\r\n </mat-list>\r\n</ng-template>\r\n","import {\r\n Component,\r\n Input,\r\n OnInit,\r\n OnDestroy,\r\n ChangeDetectorRef\r\n} from '@angular/core';\r\nimport { Observable, Subscription, BehaviorSubject, ReplaySubject, combineLatest } from 'rxjs';\r\nimport { map, debounceTime } from 'rxjs/operators';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport {\r\n Layer,\r\n IgoMap,\r\n LayerListControlsOptions,\r\n SearchSourceService,\r\n sourceCanSearch\r\n} from '@igo2/geo';\r\n\r\nimport { ToolState } from './../../tool/tool.state';\r\nimport { MapState } from './../map.state';\r\n\r\n@ToolComponent({\r\n name: 'mapLegend',\r\n title: 'igo.integration.tools.legend',\r\n icon: 'format-list-bulleted-type'\r\n})\r\n@Component({\r\n selector: 'igo-map-legend-tool',\r\n templateUrl: './map-legend-tool.component.html',\r\n styleUrls: ['./map-legend-tool.component.scss']\r\n})\r\nexport class MapLegendToolComponent implements OnInit, OnDestroy {\r\n public delayedShowEmptyMapContent: boolean = false;\r\n\r\n layers$: BehaviorSubject<Layer[]> = new BehaviorSubject([]);\r\n showAllLegendsValue$: BehaviorSubject<boolean> = new BehaviorSubject(false);\r\n change$ = new ReplaySubject<void>(1);\r\n\r\n private resolution$$: Subscription;\r\n private visibleOrInRangeLayers$$: Subscription;\r\n\r\n @Input() updateLegendOnResolutionChange: boolean = false;\r\n\r\n @Input() layerAdditionAllowed: boolean = true;\r\n\r\n @Input() allowShowAllLegends: boolean = false;\r\n\r\n @Input() showAllLegendsValue: boolean = false;\r\n\r\n @Input() layerListControls: LayerListControlsOptions = {};\r\n\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n\r\n get visibleOrInRangeLayers$(): Observable<Layer[]> {\r\n return this.layers$.pipe(\r\n map(layers =>\r\n layers.filter(\r\n layer => layer.visible$.value && layer.isInResolutionsRange$.value\r\n )\r\n )\r\n );\r\n }\r\n\r\n get visibleLayers$(): Observable<Layer[]> {\r\n return this.layers$.pipe(\r\n map(layers => layers.filter(layer => layer.visible$.value))\r\n );\r\n }\r\n\r\n get excludeBaseLayers(): boolean {\r\n return this.layerListControls.excludeBaseLayers || false;\r\n }\r\n\r\n get searchToolInToolbar(): boolean {\r\n return (\r\n this.toolState.toolbox.getToolbar().indexOf('searchResults') !== -1 &&\r\n this.searchSourceService\r\n .getSources()\r\n .filter(sourceCanSearch)\r\n .filter(s => s.available && s.getType() === 'Layer').length > 0\r\n );\r\n }\r\n\r\n get catalogToolInToolbar(): boolean {\r\n return this.toolState.toolbox.getToolbar().indexOf('catalog') !== -1;\r\n }\r\n\r\n get contextToolInToolbar(): boolean {\r\n return this.toolState.toolbox.getToolbar().indexOf('contextManager') !== -1;\r\n }\r\n constructor(\r\n private mapState: MapState,\r\n private toolState: ToolState,\r\n private searchSourceService: SearchSourceService,\r\n private cdRef: ChangeDetectorRef\r\n ) {}\r\n\r\n ngOnInit(): void {\r\n this.resolution$$ = combineLatest([\r\n this.map.layers$,\r\n this.map.viewController.resolution$\r\n ])\r\n .pipe(debounceTime(10))\r\n .subscribe((bunch: [Layer[], number]) => {\r\n this.layers$.next(\r\n bunch[0].filter(\r\n layer =>\r\n layer.showInLayerList !== false &&\r\n (!this.excludeBaseLayers || !layer.baseLayer)\r\n )\r\n );\r\n });\r\n\r\n if (this.allowShowAllLegends) {\r\n this.mapState.showAllLegendsValue =\r\n this.mapState.showAllLegendsValue !== undefined\r\n ? this.mapState.showAllLegendsValue\r\n : this.showAllLegendsValue || false;\r\n this.showAllLegendsValue$.next(this.mapState.showAllLegendsValue);\r\n } else {\r\n this.showAllLegendsValue$.next(false);\r\n }\r\n\r\n // prevent message to be shown too quickly. Waiting for layers\r\n setTimeout(() => {\r\n this.delayedShowEmptyMapContent = true;\r\n this.cdRef.detectChanges();\r\n }, 250);\r\n }\r\n\r\n onShowAllLegends(event) {\r\n this.mapState.showAllLegendsValue = event;\r\n this.showAllLegendsValue$.next(event);\r\n }\r\n\r\n showAllLegend() {\r\n if (this.layers$.getValue().length === 0) {\r\n return false;\r\n } else if (\r\n this.layers$.getValue().length !== 0 &&\r\n this.allowShowAllLegends === false\r\n ) {\r\n let visibleOrInRangeLayers;\r\n this.visibleOrInRangeLayers$$ = this.visibleOrInRangeLayers$.subscribe(value => {\r\n value.length === 0\r\n ? (visibleOrInRangeLayers = false)\r\n : (visibleOrInRangeLayers = true);\r\n });\r\n\r\n if (visibleOrInRangeLayers === false) {\r\n return false;\r\n }\r\n }\r\n return true;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.resolution$$.unsubscribe();\r\n if (this.visibleOrInRangeLayers$$) {\r\n this.visibleOrInRangeLayers$$.unsubscribe();\r\n }\r\n }\r\n\r\n searchEmit() {\r\n this.toolState.toolbox.activateTool('searchResults');\r\n }\r\n\r\n catalogEmit() {\r\n this.toolState.toolbox.activateTool('catalog');\r\n }\r\n\r\n contextEmit() {\r\n this.toolState.toolbox.activateTool('contextManager');\r\n }\r\n}\r\n","<div *ngIf=\"userControlledLayerList.length; else noLayersBlock\" class=\"igo-swipe-select-container\">\r\n <form class=\"igo-form\" [formGroup]=\"form\">\r\n <mat-form-field>\r\n <mat-label>{{'igo.integration.advanced-map-tool.advanced-swipe.swipe-select' | translate}}</mat-label>\r\n <mat-select formControlName=\"layers\" multiple>\r\n <mat-option [value]=\"1\" (click)=\"selectAll(e)\" #e>\r\n {{'igo.integration.advanced-map-tool.advanced-swipe.selectAll' | translate}}\r\n </mat-option>\r\n <mat-divider></mat-divider>\r\n <mat-option *ngFor=\"let layer of userControlledLayerList\" [value]=\"layer\" (click)=\"applyNewLayers(e)\">{{layer.title}}</mat-option>\r\n </mat-select>\r\n </mat-form-field>\r\n </form>\r\n\r\n <mat-slide-toggle class=\"swipe-toggle mat-typography\"\r\n [checked]=\"swipe\"\r\n [labelPosition]=\"'before'\"\r\n (change)=\"startSwipe($event.checked)\">\r\n {{'igo.integration.advanced-map-tool.advanced-swipe.swipe' | translate}}\r\n </mat-slide-toggle> \r\n</div>\r\n\r\n<ng-template #noLayersBlock>\r\n <mat-list>\r\n <p class=\"map-empty mat-typography\">\r\n {{'igo.integration.advanced-map-tool.advanced-swipe.empty' | translate}}</p>\r\n <p class=\"map-empty mat-typography\">\r\n {{'igo.integration.advanced-map-tool.advanced-swipe.customize' | translate}}</p>\r\n <mat-list-item>\r\n <mat-icon mat-list-icon svgIcon=\"magnify\"></mat-icon>\r\n <h4 matLine class=\"search-tool mat-typography\" (click)=\"searchEmit()\">\r\n {{'igo.integration.advanced-map-tool.advanced-swipe.search-tool' | translate}}\r\n </h4>\r\n </mat-list-item>\r\n <mat-list-item>\r\n <mat-icon mat-list-icon svgIcon=\"layers-plus\"></mat-icon>\r\n <h4 matLine class=\"catalog-tool mat-typography\" (click)=\"catalogEmit()\">\r\n {{'igo.integration.advanced-map-tool.advanced-swipe.catalog-tool' | translate}}\r\n </h4>\r\n </mat-list-item>\r\n <mat-list-item>\r\n <mat-icon mat-list-icon svgIcon=\"star\"></mat-icon>\r\n <h4 matLine class=\"context-tool mat-typography\" (click)=\"contextEmit()\">\r\n {{'igo.integration.advanced-map-tool.advanced-swipe.context-tool' | translate}}\r\n </h4>\r\n </mat-list-item>\r\n </mat-list>\r\n</ng-template>\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { FormGroup, FormBuilder, Validators } from '@angular/forms';\r\nimport { ContextService, DetailedContext } from '@igo2/context';\r\nimport { IgoMap, Layer, VectorLayer } from '@igo2/geo';\r\nimport { MapState } from '../../map.state';\r\nimport { ToolState } from '../../../tool/tool.state';\r\n\r\n@Component({\r\n selector: 'igo-advanced-swipe',\r\n templateUrl: './advanced-swipe.component.html',\r\n styleUrls: ['./advanced-swipe.component.scss']\r\n})\r\n\r\nexport class AdvancedSwipeComponent implements OnInit, OnDestroy {\r\n public swipe: boolean = false;\r\n public layerList: Layer[];\r\n public userControlledLayerList: Layer[];\r\n public form: FormGroup;\r\n public layers: VectorLayer[];\r\n public res: DetailedContext;\r\n public listForSwipe: Layer[];\r\n\r\n /**\r\n * Get an active map state\r\n */\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n\r\n constructor(\r\n public mapState: MapState,\r\n private contextService: ContextService,\r\n private formBuilder: FormBuilder,\r\n private toolState: ToolState) {\r\n this.buildForm();\r\n }\r\n\r\n /**\r\n * Get the list of layers for swipe\r\n * @internal\r\n */\r\n ngOnInit() {\r\n this.map.layers$.subscribe(ll => this.userControlledLayerList = ll.filter(layer =>\r\n (!layer.baseLayer && layer.showInLayerList && layer.displayed)));\r\n }\r\n\r\n /**\r\n * Desactivate the swipe\r\n * @internal\r\n */\r\n ngOnDestroy(){\r\n this.swipe = false;\r\n this.map.swipeEnabled$.next(this.swipe);\r\n }\r\n\r\n /**\r\n * Build a form for choise of the layers\r\n */\r\n private buildForm() {\r\n this.form = this.formBuilder.group({\r\n layers: ['', [Validators.required]]\r\n });\r\n }\r\n\r\n /**\r\n * Activate the swipe, send a list of layers for a swipe-tool\r\n */\r\n startSwipe(toggle: boolean){\r\n this.swipe = toggle;\r\n this.map.swipeEnabled$.next(toggle);\r\n this.listForSwipe = [];\r\n for (const layer of this.form.value.layers) {\r\n this.listForSwipe.push(layer);\r\n }\r\n this.map.selectedFeatures$.next(this.listForSwipe);\r\n }\r\n\r\n /**\r\n * Restart a swipe for a new layers-list\r\n */\r\n applyNewLayers(e) {\r\n this.startSwipe(false); // l'approche KISS\r\n this.startSwipe(true);\r\n if (e._selected) {e._selected = false; }\r\n const allLayers = this.userControlledLayerList.length;\r\n const selectedLayers = this.form.controls.layers.value.length;\r\n if (selectedLayers === allLayers){\r\n e._selected = true;\r\n }\r\n }\r\n\r\n /**\r\n * Select all list of layers and restart a tool\r\n */\r\n selectAll(e) {\r\n if (e._selected) {\r\n this.form.controls.layers.setValue(this.userControlledLayerList);\r\n e._selected = true;\r\n }\r\n else {\r\n this.form.controls.layers.setValue([]);\r\n }\r\n this.startSwipe(false);\r\n this.startSwipe(true);\r\n }\r\n\r\n /**\r\n * Open search tool\r\n */\r\n searchEmit() {\r\n this.toolState.toolbox.activateTool('searchResults');\r\n }\r\n\r\n /**\r\n * Open catalog\r\n */\r\n catalogEmit() {\r\n this.toolState.toolbox.activateTool('catalog');\r\n }\r\n\r\n /**\r\n * Open context manager\r\n */\r\n contextEmit() {\r\n this.toolState.toolbox.activateTool('contextManager');\r\n }\r\n}\r\n","<mat-form-field *ngIf=\"units; else elseBlock\" class=\"coordinates\">\r\n <textarea #textArea matInput readonly rows=\"1\"\r\n [placeholder]=\"'igo.integration.advanced-map-tool.advanced-coordinates.lon' | translate\"\r\n [value]=\"coordinates[0]\"></textarea>\r\n</mat-form-field>\r\n<ng-template #elseBlock >\r\n <mat-form-field class=\"coordinates\">\r\n <textarea #textArea matInput readonly rows=\"1\"\r\n [placeholder]=\"'igo.integration.advanced-map-tool.advanced-coordinates.est' | translate\"\r\n [value]=\"coordinates[0]\"></textarea></mat-form-field>\r\n</ng-template>\r\n\r\n<mat-form-field *ngIf=\"units; else elseBlock2\" class=\"coordinates2\">\r\n <textarea #textArea matInput readonly rows=\"1\"\r\n [placeholder]=\"'igo.integration.advanced-map-tool.advanced-coordinates.lat' | translate\"\r\n [value]=\"coordinates[1]\"></textarea>\r\n</mat-form-field>\r\n<ng-template #elseBlock2 >\r\n <mat-form-field class=\"coordinates2\"> <textarea #textArea matInput readonly rows=\"1\"\r\n [placeholder]=\"'igo.integration.advanced-map-tool.advanced-coordinates.nord' | translate\"\r\n [value]=\"coordinates[1]\"></textarea></mat-form-field>\r\n</ng-template>\r\n\r\n<button class=\"igo-form-button-group\"\r\n mat-raised-button\r\n (click)=\"copyTextToClipboard()\">\r\n <mat-icon svgIcon=\"content-copy\"></mat-icon>\r\n {{ 'igo.integration.advanced-map-tool.advanced-coordinates.copy' | translate }}\r\n</button>\r\n\r\n<form class=\"igo-form\" [formGroup]=\"form\">\r\n <mat-form-field class=\"igo-input-container\">\r\n <mat-label>{{'igo.integration.advanced-map-tool.advanced-coordinates.coordSystem' | translate}}</mat-label>\r\n <mat-select [(value)]=\"inputProj\">\r\n <mat-option matTooltipShowDelay=\"500\"\r\n *ngFor=\"let projection of (projections$ | async)\"\r\n [value]=\"projection\"\r\n (click)=\"$event.stopPropagation()\">\r\n {{projection.translatedValue || projection.alias }}\r\n </mat-option>\r\n </mat-select>\r\n </mat-form-field>\r\n <mat-slide-toggle class=\"center-toggle mat-typography\"\r\n [checked]=\"center\"\r\n [labelPosition]=\"'before'\"\r\n (change)=\"displayCenter($event.checked)\">\r\n {{'igo.integration.advanced-map-tool.advanced-coordinates.center' | translate}}\r\n </mat-slide-toggle> \r\n</form>\r\n\r\n<p class=\"igo-zoom mat-typography\">{{'igo.integration.advanced-map-tool.advanced-coordinates.zoom' | translate}} {{map.viewController.getZoom() }}</p>\r\n<p class=\"igo-zoom mat-typography\">{{'igo.integration.advanced-map-tool.advanced-coordinates.scale' | translate}} {{ formattedScale$ | async }}</p>\r\n<p class=\"igo-zoom mat-typography\">{{'igo.integration.advanced-map-tool.advanced-coordinates.resolution' | translate}} {{map.viewController.getResolution() | number: '1.0-0' }}</p>","import { ChangeDetectorRef, Component, OnDestroy, OnInit, Input } from '@angular/core';\r\nimport { formatScale, IgoMap, InputProjections, ProjectionsLimitationsOptions } from '@igo2/geo';\r\nimport { MapState } from '../../map.state';\r\nimport { Clipboard } from '@igo2/utils';\r\nimport { MessageService, LanguageService, StorageService, StorageScope, ConfigService } from '@igo2/core';\r\nimport { BehaviorSubject, combineLatest, Subscription } from 'rxjs';\r\nimport { FormBuilder, FormGroup, Validators } from '@angular/forms';\r\nimport { debounceTime } from 'rxjs/operators';\r\nimport { zoneMtm, zoneUtm, computeProjectionsConstraints } from '@igo2/geo';\r\nimport * as olproj from 'ol/proj';\r\n/**\r\n * Tool to display the coordinates and a cursor of the center of the map\r\n */\r\n@Component({\r\n selector: 'igo-advanced-coordinates',\r\n templateUrl: './advanced-coordinates.component.html',\r\n styleUrls: ['./advanced-coordinates.component.scss']\r\n})\r\nexport class AdvancedCoordinatesComponent implements OnInit, OnDestroy {\r\n public formattedScale$: BehaviorSubject<string> = new BehaviorSubject('');\r\n public projections$: BehaviorSubject<InputProjections[]> = new BehaviorSubject([]);\r\n public form: FormGroup;\r\n public coordinates: string[];\r\n private currentCenterDefaultProj: [number, number];\r\n public center: boolean = this.storageService.get('centerToggle') as boolean;\r\n private inMtmZone: boolean = true;\r\n private inLambert2 = {32198: true, 3798: true};\r\n private mapState$$: Subscription;\r\n private _projectionsLimitations: ProjectionsLimitationsOptions = {};\r\n private projectionsConstraints: ProjectionsLimitationsOptions;\r\n private defaultProj: InputProjections = {\r\n translatedValue: this.languageService.translate.instant('igo.geo.importExportForm.projections.wgs84', { code: 'EPSG:4326' }),\r\n translateKey: 'wgs84', alias: 'WGS84', code: 'EPSG:4326', zone: ''\r\n };\r\n private currentZones = { utm: undefined, mtm: undefined };\r\n public units: boolean = true;\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n\r\n get inputProj(): InputProjections {\r\n return this.form.get('inputProj').value;\r\n }\r\n set inputProj(value: InputProjections) {\r\n this.form.patchValue({ inputProj: value });\r\n }\r\n get projectionsLimitations(): ProjectionsLimitationsOptions {\r\n return this._projectionsLimitations || {};\r\n }\r\n\r\n @Input()\r\n set projectionsLimitations(value: ProjectionsLimitationsOptions) {\r\n this._projectionsLimitations = value;\r\n }\r\n\r\n constructor(\r\n public mapState: MapState,\r\n private languageService: LanguageService,\r\n private messageService: MessageService,\r\n private cdRef: ChangeDetectorRef,\r\n private storageService: StorageService,\r\n private config: ConfigService,\r\n private formBuilder: FormBuilder) {\r\n this.computeProjections();\r\n this.buildForm();\r\n }\r\n\r\n /**\r\n * Listen a state of the map, a state of a form, update the coordinates\r\n */\r\n ngOnInit(): void {\r\n this.mapState$$ = combineLatest([this.map.viewController.state$.pipe(debounceTime(50)), this.form.valueChanges])\r\n .subscribe(() => {\r\n this.setScaleValue(this.map);\r\n this.currentCenterDefaultProj = this.map.viewController.getCenter(this.defaultProj.code);\r\n const currentMtmZone = zoneMtm(this.currentCenterDefaultProj[0]);\r\n const currentUtmZone = zoneUtm(this.currentCenterDefaultProj[0]);\r\n if (!this.inMtmZone && currentMtmZone !== this.currentZones.mtm) {\r\n this.back2quebec();\r\n }\r\n let zoneChange = false;\r\n if (currentMtmZone !== this.currentZones.mtm) {\r\n this.currentZones.mtm = currentMtmZone;\r\n zoneChange = true;\r\n }\r\n if (currentUtmZone !== this.currentZones.utm) {\r\n this.currentZones.utm = currentUtmZone;\r\n zoneChange = true;\r\n }\r\n if (zoneChange) {\r\n this.updateProjectionsZoneChange();\r\n }\r\n this.checkLambert(this.currentCenterDefaultProj);\r\n this.coordinates = this.getCoordinates();\r\n this.cdRef.detectChanges();\r\n this.storageService.set('currentProjection', this.inputProj, StorageScope.SESSION);\r\n });\r\n\r\n const tempInputProj = this.storageService.get('currentProjection') as InputProjections;\r\n this.inputProj = this.projections$.value[0];\r\n if (tempInputProj !== null)\r\n {\r\n const pos = this.positionInList(tempInputProj);\r\n this.inputProj = this.projections$.value[pos];\r\n this.updateZoneMtmUtm();\r\n }\r\n this.map.mapCenter$.next(this.center);\r\n this.coordinates = this.getCoordinates();\r\n this.currentCenterDefaultProj = this.map.viewController.getCenter(this.defaultProj.code);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.map.mapCenter$.next(false);\r\n this.mapState$$.unsubscribe();\r\n }\r\n\r\n setScaleValue(map: IgoMap) {\r\n this.formattedScale$.next(': ~ 1 / ' + formatScale(map.viewController.getScale()));\r\n }\r\n /**\r\n * Coordinates of the center of the map on the appropriate systeme of coordinates\r\n * @returns Array of two numbers\r\n */\r\n getCoordinates(): string[] {\r\n this.currentZones.mtm = zoneMtm(this.currentCenterDefaultProj[0]);\r\n this.currentZones.utm = zoneUtm(this.currentCenterDefaultProj[0]);\r\n let coord;\r\n const code = this.inputProj.code;\r\n let decimal = 2;\r\n if (code.includes('EPSG:4326') || code.includes('EPSG:4269')) {\r\n decimal = 5;\r\n }\r\n this.units = (code === 'EPSG:4326' || code === 'EPSG:4269');\r\n coord = this.map.viewController.getCenter(code).map(c => c.toFixed(decimal));\r\n return coord;\r\n }\r\n\r\n /**\r\n * Copy the coordinates to a clipboard\r\n */\r\n copyTextToClipboard(): void {\r\n const successful = Clipboard.copy(this.coordinates.toString());\r\n if (successful) {\r\n const translate = this.languageService.translate;\r\n const title = translate.instant(\r\n 'igo.integration.advanced-map-tool.advanced-coordinates.copyTitle'\r\n );\r\n const msg = translate.instant('igo.integration.advanced-map-tool.advanced-coordinates.copyMsg');\r\n this.messageService.success(msg, title);\r\n }\r\n }\r\n\r\n /**\r\n * Display a cursor on the center of the map\r\n */\r\n displayCenter(toggle: boolean): void {\r\n this.center = toggle;\r\n this.map.mapCenter$.next(toggle);\r\n this.storageService.set('centerToggle', toggle, StorageScope.SESSION);\r\n }\r\n\r\n /**\r\n * Builder of the form\r\n */\r\n private buildForm(): void {\r\n this.form = this.formBuilder.group({\r\n inputProj: ['', [Validators.required]]\r\n });\r\n }\r\n\r\n /**\r\n * Update list of projections after changing of the state of the map\r\n */\r\n private updateProjectionsZoneChange(): void {\r\n let modifiedProj = this.projections$.value;\r\n const translate = this.languageService.translate;\r\n modifiedProj.map(p => {\r\n if (p.translateKey === 'mtm') {\r\n const zone = zoneMtm(this.currentCenterDefaultProj[0]);\r\n if (zone) {\r\n const code = zone < 10 ? `EPSG:3218${zone}` : `EPSG:321${80 + zone}`;\r\n p.alias = `MTM ${zone}`;\r\n p.code = code;\r\n p.zone = `${zone}`;\r\n p.translatedValue = translate.instant('igo.geo.importExportForm.projections.mtm', p);\r\n }\r\n else {\r\n p.alias = '';\r\n this.inMtmZone = false;\r\n if (this.inputProj.translateKey === 'mtm') {\r\n this.inputProj = this.projections$.value[0];\r\n }\r\n }\r\n }\r\n if (p.translateKey === 'utm') {\r\n const zone = zoneUtm(this.currentCenterDefaultProj[0]);\r\n const code = `EPSG:326${zone}`;\r\n p.alias = `UTM ${zone}`;\r\n p.code = code;\r\n p.zone = `${zone}`;\r\n p.translatedValue = translate.instant('igo.geo.importExportForm.projections.utm', p);\r\n }\r\n });\r\n modifiedProj = modifiedProj.filter(p => p.alias !== '');\r\n this.projections$.next(modifiedProj);\r\n }\r\n\r\n /**\r\n * Create a list of currents projections\r\n */\r\n private computeProjections(): void {\r\n this.projectionsConstraints = computeProjectionsConstraints(this.projectionsLimitations);\r\n const projections: InputProjections[] = [];\r\n\r\n if (!this.currentCenterDefaultProj) {\r\n this.currentCenterDefaultProj = this.map.viewController.getCenter(this.defaultProj.code);\r\n }\r\n\r\n const translate = this.languageService.translate;\r\n if (this.projectionsConstraints.wgs84) {\r\n projections.push({\r\n translatedValue: translate.instant('igo.geo.importExportForm.projections.wgs84', { code: 'EPSG:4326' }),\r\n translateKey: 'wgs84', alias: 'WGS84', code: 'EPSG:4326', zone: ''\r\n });\r\n }\r\n\r\n if (this.projectionsConstraints.nad83) {\r\n projections.push({\r\n translatedValue: translate.instant('igo.geo.importExportForm.projections.nad83', { code: 'EPSG:4269' }),\r\n translateKey: 'nad83', alias: 'NAD83', code: 'EPSG:4269', zone: ''\r\n });\r\n }\r\n\r\n if (this.projectionsConstraints.webMercator) {\r\n projections.push({\r\n translatedValue: translate.instant('igo.geo.importExportForm.projections.webMercator', { code: 'EPSG:3857' }),\r\n translateKey: 'webMercator', alias: 'Web Mercator', code: 'EPSG:3857', zone: ''\r\n });\r\n }\r\n if (this.projectionsConstraints.mtm) {\r\n // Quebec\r\n const zone = zoneMtm(this.currentCenterDefaultProj[0]);\r\n if (zone) {\r\n this.inMtmZone = true;\r\n const code = zone < 10 ? `EPSG:3218${zone}` : `EPSG:321${80 + zone}`;\r\n projections.splice(3, 0, {\r\n translatedValue: this.languageService.translate.instant('igo.geo.importExportForm.projections.mtm', { code, zone }),\r\n translateKey: 'mtm', alias: `MTM ${zone}`, code, zone: `${zone}`\r\n });\r\n }\r\n else {\r\n this.inMtmZone = false;\r\n }\r\n }\r\n if (this.projectionsConstraints.utm) {\r\n const order = this.inMtmZone ? 4 : 3;\r\n const zone = zoneUtm(this.currentCenterDefaultProj[0]);\r\n const code = zone < 10 ? `EPSG:3260${zone}` : `EPSG:326${zone}`;\r\n projections.splice(order, 0, {\r\n translatedValue: this.languageService.translate.instant('igo.geo.importExportForm.projections.utm', { code, zone }),\r\n translateKey: 'utm', alias: `UTM ${zone}`, code, zone: `${zone}`\r\n });\r\n }\r\n let configProjection = [];\r\n if (this.projectionsConstraints.projFromConfig) {\r\n configProjection = this.config.getConfig('projections') || [];\r\n }\r\n this.projections$.next(projections.concat(configProjection));\r\n }\r\n\r\n /**\r\n * Push the MTM in the array of systeme of coordinates\r\n * @param projections Array of the InputProjections\r\n */\r\n private pushMtm(projections: Array<InputProjections>): void {\r\n if (this.projectionsConstraints.mtm) {\r\n const zone = zoneMtm(this.currentCenterDefaultProj[0]);\r\n const code = zone < 10 ? `EPSG:3218${zone}` : `EPSG:321${80 + zone}`;\r\n projections.splice(3, 0, {\r\n translatedValue: this.languageService.translate.instant('igo.geo.importExportForm.projections.mtm', { code, zone }),\r\n translateKey: 'mtm', alias: `MTM ${zone}`, code, zone: `${zone}`});\r\n }\r\n }\r\n\r\n /**\r\n * Updates the list of systems of coordinates for territory of Quebec\r\n * push MTM and UTM in the Array\r\n */\r\n private back2quebec(): void {\r\n const projections = this.projections$.value;\r\n this.pushMtm(projections);\r\n this.inMtmZone = true;\r\n }\r\n\r\n /**\r\n * Update the numbers of the zones when application is restarted\r\n */\r\n private updateZoneMtmUtm() {\r\n if (this.inputProj.translateKey === 'mtm') {\r\n const zone = zoneMtm(this.currentCenterDefaultProj[0]);\r\n this.inputProj.alias = `MTM ${zone}`;\r\n const code = zone < 10 ? `EPSG:3218${zone}` : `EPSG:321${80 + zone}`;\r\n this.inputProj.code = code;\r\n this.inputProj.zone = `${zone}`;\r\n this.inputProj.translatedValue = this.languageService.translate.instant('igo.geo.importExportForm.projections.mtm', { code, zone });\r\n }\r\n if (this.inputProj.translateKey === 'utm') {\r\n const zone = zoneUtm(this.currentCenterDefaultProj[0]);\r\n this.inputProj.alias = `UTM ${zone}`;\r\n const code = zone < 10 ? `EPSG:3260${zone}` : `EPSG:326${zone}`;\r\n this.inputProj.code = code;\r\n this.inputProj.zone = `${zone}`;\r\n this.inputProj.translatedValue = this.languageService.translate.instant('igo.geo.importExportForm.projections.utm', { code, zone });\r\n }\r\n }\r\n\r\n /**\r\n * Compute the position of a current projection in a list. 0 if the projection is not in the list\r\n * @param translateKey string, translate key of a projection\r\n * @returns numeric, position of an element in the array\r\n */\r\n positionInList(tempInputProj: InputProjections): number {\r\n const tk = tempInputProj.translateKey;\r\n const alias = tempInputProj.alias;\r\n let position; // = undefined;\r\n let iter = 0;\r\n this.projections$.value.map((projection) => {\r\n if (tk) {\r\n if (tk === projection.translateKey) {\r\n position = iter;\r\n }\r\n }\r\n else if (alias === projection.alias) {\r\n position = iter;\r\n }\r\n iter++;\r\n });\r\n position = position ? position : 0;\r\n return position;\r\n }\r\n\r\n /**\r\n * Change the list of projections depending on the projections of Lambert\r\n * @param coordinates An array of numbers, longitude and latitude\r\n */\r\n checkLambert(coordinates: [number, number]) {\r\n const lambertProjections = this.config.getConfig('projections');\r\n lambertProjections.forEach(projection => {\r\n let modifiedProj = this.projections$.value;\r\n const extent = projection.extent;\r\n const code = projection.code.match(/\\d+/);\r\n const currentExtentWGS = olproj.transformExtent(extent, projection.code, this.defaultProj.code);\r\n if (coordinates[0] < currentExtentWGS[0] || coordinates[0] > currentExtentWGS[2] ||\r\n coordinates[1] < currentExtentWGS[1] || coordinates[1] > currentExtentWGS[3]) {\r\n this.inLambert2[code] = false;\r\n if (this.inputProj.alias === projection.alias) {\r\n this.inputProj = this.projections$.value[0];\r\n }\r\n modifiedProj = modifiedProj.filter(p => p.alias !== projection.alias);\r\n this.projections$.next(modifiedProj);\r\n }\r\n else {\r\n if (!this.inLambert2[code]) {\r\n this.projections$.next(modifiedProj.concat(projection));\r\n this.inLambert2[code] = true;\r\n }\r\n }\r\n });\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ToolComponent } from '@igo2/common';\r\nimport { MapState } from '../map.state';\r\n\r\n@ToolComponent({\r\n name: 'advancedMap',\r\n title: 'igo.integration.tools.advancedMap',\r\n icon: 'toolbox'\r\n})\r\n\r\n/**\r\n * Tool to handle the advanced map tools\r\n */\r\n@Component({\r\n selector: 'igo-advanced-map-tool',\r\n templateUrl: './advanced-map-tool.component.html',\r\n styleUrls: ['./advanced-map-tool.component.scss']\r\n})\r\n\r\nexport class AdvancedMapToolComponent {\r\n\r\n get tracking$() {\r\n return this.mapState.map.geolocationController.tracking$;\r\n }\r\n get followPosition$() {\r\n return this.mapState.map.geolocationController.followPosition$;\r\n }\r\n\r\n constructor(\r\n public mapState: MapState) {}\r\n\r\n toggleTracking(value) {\r\n this.mapState.map.geolocationController.tracking = value;\r\n }\r\n\r\n toggleFollow(value) {\r\n this.mapState.map.geolocationController.followPosition = value;\r\n }\r\n}\r\n","<h4 class=\"nameOfTool\">{{'igo.integration.advanced-map-tool.advanced-swipe.swipe-tool' | translate}}</h4>\r\n<igo-advanced-swipe></igo-advanced-swipe>\r\n<mat-divider class=\"advanced-tool-line\"></mat-divider>\r\n\r\n<h4 class=\"nameOfTool\">{{'igo.integration.advanced-map-tool.advanced-coordinates.coordinates' | translate}}</h4>\r\n<igo-advanced-coordinates></igo-advanced-coordinates>\r\n<mat-divider class=\"advanced-tool-line\"></mat-divider>\r\n\r\n<h4 class=\"nameOfTool\">{{'igo.integration.advanced-map-tool.geolocation.title' | translate}}</h4>\r\n\r\n<div class=\"igo-input-container\">\r\n <div class=\"geolocation-slide-toggle-container mat-typography\">\r\n <mat-slide-toggle \r\n class=\"geolocation-option mat-typography\"\r\n [checked]=\"tracking$ | async\"\r\n [labelPosition]=\"'before'\"\r\n (change)=\"toggleTracking($event.checked)\">\r\n {{'igo.integration.advanced-map-tool.geolocation.tracking' | translate}}\r\n </mat-slide-toggle>\r\n\r\n <mat-slide-toggle\r\n class=\"geolocation-option mat-typography\"\r\n [disabled]=\"(tracking$ | async) !== true\"\r\n [checked]=\"followPosition$ | async\"\r\n [labelPosition]=\"'before'\"\r\n (change)=\"toggleFollow($event.checked)\">\r\n {{'igo.integration.advanced-map-tool.geolocation.follow' | translate}}\r\n </mat-slide-toggle>\r\n </div>\r\n</div>","import { Injectable } from '@angular/core';\r\n\r\nimport {\r\n FeatureStore, Feature, IgoMap,\r\n featureFromOl, measureOlGeometryLength, Layer, QueryableDataSourceOptions, FEATURE, roundCoordTo, QueryableDataSource, MapGeolocationState\r\n} from '@igo2/geo';\r\nimport { BehaviorSubject, combineLatest, interval, Subscription } from 'rxjs';\r\nimport { debounceTime } from 'rxjs/operators';\r\nimport { MapState } from '../map/map.state';\r\n\r\nimport GeoJSON from 'ol/format/GeoJSON';\r\nimport { uuid } from '@igo2/utils';\r\n\r\nimport olLayerVector from 'ol/layer/Vector';\r\nimport olVectorSource from 'ol/source/Vector';\r\nimport Geometry from 'ol/geom/Geometry';\r\nimport olLineString from 'ol/geom/LineString';\r\nimport * as olProj from 'ol/proj';\r\n/**\r\n * Service that holds the state of the direction module\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class MapProximityState {\r\n\r\n public enabled$: BehaviorSubject<boolean> = new BehaviorSubject<boolean>(false);\r\n public proximityRadiusValue$: BehaviorSubject<number> = new BehaviorSubject<number>(30);\r\n public proximitylocationType$: BehaviorSubject<string> = new BehaviorSubject<string>('geolocation');\r\n public proximityFeatureStore: FeatureStore<Feature> = new FeatureStore<Feature>([], { map: this.mapState.map });\r\n private subs$$: Subscription[] = [];\r\n public currentPositionCoordinate$: BehaviorSubject<[number, number]> = new BehaviorSubject(undefined);\r\n\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n\r\n constructor(private mapState: MapState) {\r\n\r\n this.mapState.map.ol.once('rendercomplete', () => {\r\n this.subscribeProximityMonitor();\r\n });\r\n }\r\n\r\n\r\n subscribeProximityMonitor() {\r\n this.subs$$.push(combineLatest([\r\n this.enabled$,\r\n this.proximitylocationType$,\r\n this.proximityRadiusValue$,\r\n interval(5000),\r\n this.map.geolocationController.position$\r\n ])\r\n .pipe(debounceTime(750))\r\n .subscribe((bunch: [boolean, string, number, number, MapGeolocationState]) => {\r\n this.proximityFeatureStore.clear();\r\n const enabled = bunch[0];\r\n const layers = this.map.layers;\r\n const currentPos = this.map.geolocationController.position$.value;\r\n const locationType = bunch[1];\r\n const proximityRadiusValue = bunch[2];\r\n\r\n if (!enabled) {\r\n return;\r\n }\r\n\r\n\r\n let coord: number[];\r\n if (locationType === 'geolocation') {\r\n if (!currentPos || !currentPos.position) {\r\n return;\r\n }\r\n\r\n coord = olProj.transform(currentPos.position, currentPos.projection, this.map.projection);\r\n this.map.mapCenter$.next(false);\r\n } else {\r\n coord = this.map.viewController.getCenter();;\r\n this.map.mapCenter$.next(true);\r\n }\r\n\r\n const coordLonLat = olProj.transform(coord, this.map.projection, 'EPSG:4269');\r\n const roundedCoordLonLat = roundCoordTo(coordLonLat as [number, number], 6);\r\n this.currentPositionCoordinate$.next(roundedCoordLonLat);\r\n\r\n const layersToMonitor = layers\r\n .filter(layer =>\r\n layer.ol instanceof olLayerVector &&\r\n (layer.dataSource as QueryableDataSource).options.queryable &&\r\n layer.visible &&\r\n layer.isInResolutionsRange);\r\n\r\n layersToMonitor.map(layerToMonitor => {\r\n const layerSource = layerToMonitor.ol.getSource() as olVectorSource<Geometry>;\r\n\r\n // Mostly for polygon features.\r\n const olFeaturesAtCoordinate = layerSource.getFeaturesAtCoordinate(coord);\r\n if (olFeaturesAtCoordinate && olFeaturesAtCoordinate.length) {\r\n olFeaturesAtCoordinate.map(olFeatureAtCoordinate => {\r\n const featureAtThisPosition = featureFromOl(olFeatureAtCoordinate, this.map.projection);\r\n let title = this.getQueryTitle(featureAtThisPosition, layerToMonitor);\r\n // todo handle imported layers without querytitle? prompt title or detect first column?\r\n this.addFeatureToStore(layerToMonitor, coord, featureAtThisPosition, title, 0);\r\n });\r\n } else {\r\n // compute proximity for remaining sources\r\n const closestOlFeature = layerSource.getClosestFeatureToCoordinate(coord);\r\n if (closestOlFeature) {\r\n const closestOlGeom = closestOlFeature.getGeometry();\r\n const closestFeature = featureFromOl(closestOlFeature, this.map.projection);\r\n const geometryClosestPoint = closestOlGeom.getClosestPoint(coord);\r\n const linebetween = new olLineString([coord, geometryClosestPoint]);\r\n const lineLength = measureOlGeometryLength(linebetween, 'EPSG:3857');\r\n if (lineLength <= proximityRadiusValue) {\r\n let title = this.getQueryTitle(closestFeature, layerToMonitor);\r\n // todo handle imported layers without querytitle? prompt title or detect first column?\r\n this.addFeatureToStore(layerToMonitor, coord, closestFeature, title, lineLength);\r\n }\r\n }\r\n }\r\n });\r\n\r\n }));\r\n }\r\n\r\n /**\r\n * Add a feature with proximity properties to the store\r\n * @internal\r\n */\r\n private addFeatureToStore(layer: Layer, coordFromCalculatedDistance, feature: Feature, title, distance) {\r\n const featureId = uuid();\r\n const projection = this.map.ol.getView().getProjection();\r\n const olGeometry = feature.ol.getGeometry() as Geometry;\r\n const geometry = new GeoJSON().writeGeometryObject(olGeometry, {\r\n featureProjection: projection,\r\n dataProjection: projection\r\n }) as any;\r\n this.proximityFeatureStore.update({\r\n type: FEATURE,\r\n geometry,\r\n projection: projection.getCode(),\r\n properties: {...feature.properties,...{\r\n id: featureId,\r\n element: title,\r\n distance,\r\n coordFromCalculatedDistance,\r\n layerSrcId: layer.id,\r\n layerSrcTitle: layer.title\r\n }},\r\n meta: {\r\n id: featureId\r\n }\r\n });\r\n }\r\n\r\n getQueryTitle(feature: Feature, layer: Layer): string {\r\n let title;\r\n if (layer.options?.source?.options) {\r\n const dataSourceOptions = layer.options.source\r\n .options as QueryableDataSourceOptions;\r\n if (dataSourceOptions.queryTitle) {\r\n title = this.getLabelMatch(feature, dataSourceOptions.queryTitle);\r\n }\r\n }\r\n return title;\r\n }\r\n\r\n getLabelMatch(feature: Feature, labelMatch): string {\r\n let label = labelMatch;\r\n const labelToGet = Array.from(labelMatch.matchAll(/\\$\\{([^\\{\\}]+)\\}/g));\r\n\r\n labelToGet.forEach(v => {\r\n label = label.replace(v[0], feature.properties[v[1]]);\r\n });\r\n\r\n // Nothing done? check feature's attribute\r\n if (labelToGet.length === 0 && label === labelMatch) {\r\n label = feature.properties[labelMatch] || labelMatch;\r\n }\r\n return label;\r\n }\r\n}\r\n","<igo-entity-table #table class=\"table-compact\" [store]=\"mapProximityState.proximityFeatureStore\" [template]=\"tableTemplate\"></igo-entity-table>\r\n<br>\r\n<mat-form-field *ngIf=\"mapProximityState.currentPositionCoordinate$ | async as coord\" class=\"coordinates\">\r\n <textarea #textArea matInput readonly rows=\"1\"\r\n [placeholder]=\"'igo.integration.map-proximity-tool.lon' | translate\"\r\n [value]=\"coord[0]\"></textarea>\r\n</mat-form-field>\r\n<mat-form-field *ngIf=\"mapProximityState.currentPositionCoordinate$ | async as coord2\" class=\"coordinates2\">\r\n <textarea #textArea matInput readonly rows=\"1\"\r\n [placeholder]=\"'igo.integration.map-proximity-tool.lat' | translate\"\r\n [value]=\"coord2[1]\"></textarea>\r\n</mat-form-field>\r\n\r\n<button *ngIf=\"(mapProximityState.currentPositionCoordinate$ | async) && (mapProximityState.currentPositionCoordinate$ | async).length\" mat-icon-button\r\n (click)=\"copyTextToClipboard()\">\r\n <mat-icon svgIcon=\"content-copy\"></mat-icon>\r\n</button>\r\n<div class=\"title-container\">\r\n <mat-label class=\"title mat-typography\">{{'igo.integration.map-proximity-tool.method' | translate}}</mat-label>\r\n</div>\r\n<div class=\"igo-input-container mat-typography\">\r\n <mat-radio-group (change)=\"onLocationTypeChange($event)\">\r\n <mat-radio-button [checked]=\"(mapProximityState.proximitylocationType$|async)==='geolocation'\" value=\"geolocation\">{{'igo.integration.map-proximity-tool.geolocation' | translate}}</mat-radio-button>\r\n <mat-radio-button [checked]=\"(mapProximityState.proximitylocationType$|async)==='mapCenter'\" value=\"mapCenter\">{{'igo.integration.map-proximity-tool.mapCenter' | translate}}</mat-radio-button>\r\n </mat-radio-group>\r\n</div>\r\n\r\n<div class=\"radius-unit\"> \r\n \r\n <mat-form-field appearance=\"outline\" class=\"measure-field\" floatLabel=\"always\">\r\n <mat-label>{{'igo.integration.map-proximity-tool.radiusM' | translate}}</mat-label>\r\n <input type=\"number\" pattern=\"[0-9]*\" [(ngModel)]=\"maxDistance\" matInput placeholder=\"{{'igo.integration.map-proximity-tool.radiusM' | translate}}\">\r\n </mat-form-field>\r\n\r\n \r\n</div>","import { Component, OnDestroy, OnInit, ViewChild } from '@angular/core';\r\nimport { MatRadioChange } from '@angular/material/radio';\r\nimport { EntityTableComponent, EntityTableTemplate, ToolComponent } from '@igo2/common';\r\nimport { LanguageService, MessageService } from '@igo2/core';\r\nimport { Feature, IgoMap } from '@igo2/geo';\r\nimport { NumberUtils, Clipboard } from '@igo2/utils';\r\nimport { Subscription } from 'rxjs';\r\nimport { MapProximityState } from '../map-proximity.state';\r\nimport { MapState } from '../map.state';\r\n@ToolComponent({\r\n name: 'map-proximity',\r\n title: 'igo.integration.tools.closestFeature',\r\n icon: 'radius'\r\n})\r\n\r\n/**\r\n * Tool to handle the advanced map tools\r\n */\r\n@Component({\r\n selector: 'igo-map-proximity-tool',\r\n templateUrl: './map-proximity-tool.component.html',\r\n styleUrls: ['./map-proximity-tool.component.scss']\r\n})\r\n\r\nexport class MapProximityToolComponent implements OnInit, OnDestroy {\r\n\r\n private subs$$: Subscription[] = [];\r\n @ViewChild('table', { static: true }) table: EntityTableComponent;\r\n\r\n get maxDistance() {\r\n return this.mapProximityState.proximityRadiusValue$.value;\r\n }\r\n set maxDistance(value: number) {\r\n this.mapProximityState.proximityRadiusValue$.next(value);\r\n }\r\n\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n public userDefinedMapCenter: boolean;\r\n public userDefinedFollowPosition: boolean;\r\n /**\r\n * Table template\r\n * @internal\r\n */\r\n public tableTemplate: EntityTableTemplate = {\r\n selection: true,\r\n selectMany: false,\r\n selectionCheckbox: false,\r\n sort: true,\r\n columns: [\r\n {\r\n name: 'element',\r\n title: this.languageService.translate.instant('igo.integration.map-proximity-tool.feature'),\r\n valueAccessor: (localFeature: Feature) => {\r\n return localFeature.properties.element;\r\n }\r\n },\r\n {\r\n name: 'distance',\r\n title: this.languageService.translate.instant('igo.integration.map-proximity-tool.distance'),\r\n valueAccessor: (localFeature: Feature) => {\r\n return `${NumberUtils.roundToNDecimal(localFeature.properties.distance, 1)}m`;\r\n }\r\n }\r\n ]\r\n };\r\n\r\n constructor(\r\n public mapState: MapState,\r\n public mapProximityState: MapProximityState,\r\n private languageService: LanguageService,\r\n private messageService: MessageService) {\r\n }\r\n\r\n ngOnInit(): void {\r\n this.mapProximityState.enabled$.next(true);\r\n this.userDefinedFollowPosition = this.map.geolocationController.followPosition === true;\r\n this.userDefinedMapCenter = this.map.mapCenter$.value === true;\r\n\r\n this.subs$$.push(this.mapProximityState.proximitylocationType$.subscribe(v => {\r\n this.map.mapCenter$.next(v !== 'geolocation');\r\n if (v === 'geolocation') {\r\n this.map.geolocationController.followPosition = true;\r\n } else {\r\n this.map.geolocationController.followPosition = false;\r\n }\r\n }));\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.mapProximityState.enabled$.next(false);\r\n this.map.mapCenter$.next(this.userDefinedMapCenter);\r\n this.subs$$.map(s => s.unsubscribe());\r\n this.map.geolocationController.followPosition = this.userDefinedFollowPosition;\r\n }\r\n\r\n onLocationTypeChange(e: MatRadioChange) {\r\n this.mapProximityState.proximitylocationType$.next(e.value);\r\n }\r\n\r\n /**\r\n * Copy the coordinates to a clipboard\r\n */\r\n copyTextToClipboard(): void {\r\n\r\n const successful = Clipboard.copy(this.mapProximityState.currentPositionCoordinate$?.value.toString());\r\n if (successful) {\r\n const translate = this.languageService.translate;\r\n const title = translate.instant(\r\n 'igo.integration.map-proximity-tool.copyTitle'\r\n );\r\n const msg = translate.instant('igo.integration.map-proximity-tool.copyMsg');\r\n this.messageService.success(msg, title);\r\n }\r\n }\r\n}\r\n","import {\r\n NgModule,\r\n ModuleWithProviders,\r\n CUSTOM_ELEMENTS_SCHEMA\r\n} from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { MatIconModule } from '@angular/material/icon';\r\nimport { MatListModule } from '@angular/material/list';\r\nimport { MatTabsModule } from '@angular/material/tabs';\r\nimport { MatSlideToggleModule } from '@angular/material/slide-toggle';\r\nimport { MatMenuModule } from '@angular/material/menu';\r\nimport { MatButtonModule } from '@angular/material/button';\r\nimport { MatTooltipModule } from '@angular/material/tooltip';\r\nimport { IgoLanguageModule } from '@igo2/core';\r\nimport {\r\n IgoLayerModule,\r\n IgoMetadataModule,\r\n IgoDownloadModule,\r\n IgoFilterModule,\r\n IgoImportExportModule\r\n} from '@igo2/geo';\r\nimport { IgoContextModule } from '@igo2/context';\r\nimport { MapDetailsToolComponent } from './map-details-tool/map-details-tool.component';\r\nimport { MapToolComponent } from './map-tool/map-tool.component';\r\nimport { MapToolsComponent } from './map-tools/map-tools.component';\r\nimport { MapLegendToolComponent } from './map-legend/map-legend-tool.component';\r\nimport { IgoAppWorkspaceModule } from '../workspace/workspace.module';\r\nimport { AdvancedMapToolComponent } from './advanced-map-tool/advanced-map-tool.component';\r\nimport { MatFormFieldModule } from '@angular/material/form-field';\r\nimport { MatButtonToggleModule } from '@angular/material/button-toggle';\r\nimport { MatOptionModule } from '@angular/material/core';\r\nimport { MatDividerModule } from '@angular/material/divider';\r\nimport { MatInputModule } from '@angular/material/input';\r\nimport { MatSelectModule } from '@angular/material/select';\r\nimport { MatCheckboxModule } from '@angular/material/checkbox';\r\nimport { IgoEntityTableModule, IgoSpinnerModule } from '@igo2/common';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { AdvancedSwipeComponent } from './advanced-map-tool/advanced-swipe/advanced-swipe.component';\r\nimport { AdvancedCoordinatesComponent } from './advanced-map-tool/advanced-coordinates/advanced-coordinates.component';\r\nimport { MatRadioModule } from '@angular/material/radio';\r\nimport { MapProximityToolComponent } from './map-proximity-tool/map-proximity-tool.component';\r\n\r\n@NgModule({\r\n imports: [\r\n FormsModule,\r\n ReactiveFormsModule,\r\n MatButtonToggleModule,\r\n MatDividerModule,\r\n MatSelectModule,\r\n MatOptionModule,\r\n MatFormFieldModule,\r\n MatInputModule,\r\n MatCheckboxModule,\r\n IgoSpinnerModule,\r\n CommonModule,\r\n MatTabsModule,\r\n MatListModule,\r\n MatIconModule,\r\n IgoLanguageModule,\r\n IgoLayerModule,\r\n IgoMetadataModule,\r\n IgoDownloadModule,\r\n IgoImportExportModule,\r\n IgoFilterModule,\r\n MatRadioModule,\r\n IgoContextModule,\r\n IgoAppWorkspaceModule,\r\n MatSlideToggleModule,\r\n MatMenuModule,\r\n MatButtonModule,\r\n MatTooltipModule,\r\n IgoEntityTableModule\r\n ],\r\n declarations: [ AdvancedMapToolComponent, MapProximityToolComponent, MapToolComponent,\r\n MapToolsComponent, MapDetailsToolComponent, MapLegendToolComponent, AdvancedSwipeComponent, AdvancedCoordinatesComponent],\r\n exports: [AdvancedMapToolComponent, MapProximityToolComponent, MapToolComponent,\r\n MapToolsComponent, MapDetailsToolComponent, MapLegendToolComponent],\r\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\r\n})\r\nexport class IgoAppMapModule {\r\n static forRoot(): ModuleWithProviders<IgoAppMapModule> {\r\n return {\r\n ngModule: IgoAppMapModule,\r\n providers: []\r\n };\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\nimport { FeatureStore, FeatureWithMeasure } from '@igo2/geo';\r\nimport { MapState } from '../map/map.state';\r\n\r\n/**\r\n * Service that holds the state of the measure module\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class MeasureState {\r\n\r\n /**\r\n * Store that holds the measures\r\n */\r\n public store: FeatureStore<FeatureWithMeasure> = new FeatureStore<FeatureWithMeasure>([], {\r\n map: this.mapState.map\r\n });\r\n\r\n constructor(private mapState: MapState) {\r\n\r\n this.mapState.map.layers$.subscribe((layers) => {\r\n if ((layers.filter(l => l.id.startsWith('igo-measures-')).length === 0)) {\r\n this.store.deleteMany(this.store.all());\r\n this.mapState.map.ol.getOverlays().getArray()\r\n .filter(overlay => (overlay as any).options.className.includes('igo-map-tooltip'))\r\n .map(overlay => this.mapState.map.ol.removeOverlay(overlay));\r\n }\r\n });\r\n }\r\n\r\n}\r\n","import {\r\n Component,\r\n ChangeDetectionStrategy\r\n} from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport { FeatureStore, FeatureWithMeasure, IgoMap } from '@igo2/geo';\r\nimport { MapState } from '../../map/map.state';\r\nimport { MeasureState } from '../measure.state';\r\n\r\n/**\r\n * Tool to measure lengths and areas\r\n */\r\n@ToolComponent({\r\n name: 'measurer',\r\n title: 'igo.integration.tools.measurer',\r\n icon: 'ruler'\r\n})\r\n@Component({\r\n selector: 'igo-measurer-tool',\r\n templateUrl: './measurer-tool.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class MeasurerToolComponent {\r\n\r\n /**\r\n * Map to measure on\r\n * @internal\r\n */\r\n get store(): FeatureStore<FeatureWithMeasure> { return this.measureState.store; }\r\n\r\n /**\r\n * Map to measure on\r\n * @internal\r\n */\r\n get map(): IgoMap { return this.mapState.map; }\r\n\r\n constructor(\r\n private measureState: MeasureState,\r\n private mapState: MapState\r\n ) {}\r\n\r\n}\r\n","<igo-measurer [store]=\"store\" [map]=\"map\"></igo-measurer>\r\n","import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';\r\n\r\nimport { IgoMeasurerModule } from '@igo2/geo';\r\n\r\nimport { MeasurerToolComponent } from './measurer-tool.component';\r\n\r\n/**\r\n * @ignore\r\n */\r\n@NgModule({\r\n imports: [\r\n IgoMeasurerModule\r\n ],\r\n declarations: [MeasurerToolComponent],\r\n exports: [MeasurerToolComponent],\r\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\r\n})\r\nexport class IgoAppMeasurerToolModule {}\r\n","import { NgModule } from '@angular/core';\r\n\r\nimport { IgoAppMeasurerToolModule } from './measurer-tool/measurer-tool.module';\r\n\r\n@NgModule({\r\n imports: [],\r\n declarations: [],\r\n exports: [\r\n IgoAppMeasurerToolModule\r\n ]\r\n})\r\nexport class IgoAppMeasureModule {}\r\n","import { Component } from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport { IgoMap } from '@igo2/geo';\r\n\r\nimport { MapState } from '../../map/map.state';\r\n\r\n@ToolComponent({\r\n name: 'print',\r\n title: 'igo.integration.tools.print',\r\n icon: 'printer'\r\n})\r\n@Component({\r\n selector: 'igo-print-tool',\r\n templateUrl: './print-tool.component.html'\r\n})\r\nexport class PrintToolComponent {\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n\r\n constructor(private mapState: MapState) {}\r\n}\r\n","<igo-print [map]=\"map\"></igo-print>\r\n","import {\r\n NgModule,\r\n ModuleWithProviders,\r\n CUSTOM_ELEMENTS_SCHEMA\r\n} from '@angular/core';\r\n\r\nimport { IgoPrintModule } from '@igo2/geo';\r\nimport { PrintToolComponent } from './print-tool/print-tool.component';\r\n\r\n@NgModule({\r\n imports: [IgoPrintModule],\r\n declarations: [PrintToolComponent],\r\n exports: [PrintToolComponent],\r\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\r\n})\r\nexport class IgoAppPrintModule {\r\n static forRoot(): ModuleWithProviders<IgoAppPrintModule> {\r\n return {\r\n ngModule: IgoAppPrintModule,\r\n providers: []\r\n };\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\nimport { EntityRecord, EntityStore, EntityStoreFilterCustomFuncStrategy, EntityStoreStrategyFuncOptions } from '@igo2/common';\r\nimport { ConfigService, StorageService } from '@igo2/core';\r\nimport { SearchResult, SearchSourceService, SearchSource, CommonVectorStyleOptions } from '@igo2/geo';\r\nimport { BehaviorSubject, Subscription } from 'rxjs';\r\n\r\n/**\r\n * Service that holds the state of the search module\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SearchState {\r\n public searchOverlayStyle: CommonVectorStyleOptions = {};\r\n public searchOverlayStyleSelection: CommonVectorStyleOptions = {};\r\n public searchOverlayStyleFocus: CommonVectorStyleOptions = {};\r\n\r\n public focusedOrResolution$$: Subscription;\r\n public selectedOrResolution$$: Subscription;\r\n\r\n readonly searchTermSplitter$: BehaviorSubject<string> = new BehaviorSubject('|');\r\n\r\n readonly searchTerm$: BehaviorSubject<string> = new BehaviorSubject(undefined);\r\n\r\n readonly searchType$: BehaviorSubject<string> = new BehaviorSubject(undefined);\r\n\r\n readonly searchDisabled$: BehaviorSubject<boolean> = new BehaviorSubject(false);\r\n\r\n readonly searchResultsGeometryEnabled$: BehaviorSubject<boolean> = new BehaviorSubject(false);\r\n\r\n readonly searchSettingsChange$: BehaviorSubject<boolean> = new BehaviorSubject(undefined);\r\n\r\n readonly selectedResult$: BehaviorSubject<SearchResult> = new BehaviorSubject(undefined);\r\n\r\n /**\r\n * Store that holds the search results\r\n */\r\n readonly store: EntityStore<SearchResult> = new EntityStore<SearchResult>([]);\r\n\r\n /**\r\n * Search types currently enabled in the search source service\r\n */\r\n get searchTypes(): string[] {\r\n return this.searchSourceService\r\n .getEnabledSources()\r\n .map((source: SearchSource) => (source.constructor as any).type);\r\n }\r\n\r\n constructor(\r\n private searchSourceService: SearchSourceService,\r\n private storageService: StorageService,\r\n private configService: ConfigService) {\r\n const searchOverlayStyle = this.configService.getConfig('searchOverlayStyle') as {\r\n base?: CommonVectorStyleOptions,\r\n selection?: CommonVectorStyleOptions,\r\n focus?: CommonVectorStyleOptions\r\n };\r\n if (searchOverlayStyle) {\r\n this.searchOverlayStyle = searchOverlayStyle.base;\r\n this.searchOverlayStyleSelection = searchOverlayStyle.selection;\r\n this.searchOverlayStyleFocus = searchOverlayStyle.focus;\r\n }\r\n\r\n const searchResultsGeometryEnabled = this.storageService.get('searchResultsGeometryEnabled') as boolean;\r\n if (searchResultsGeometryEnabled) {\r\n this.searchResultsGeometryEnabled$.next(searchResultsGeometryEnabled);\r\n }\r\n this.store.addStrategy(this.createCustomFilterTermStrategy(), false);\r\n }\r\n\r\n private createCustomFilterTermStrategy(): EntityStoreFilterCustomFuncStrategy {\r\n const filterClauseFunc = (record: EntityRecord<SearchResult>) => {\r\n return record.entity.meta.score === 100;\r\n };\r\n return new EntityStoreFilterCustomFuncStrategy({filterClauseFunc} as EntityStoreStrategyFuncOptions);\r\n }\r\n\r\n /**\r\n * Activate custom strategy\r\n *\r\n */\r\n activateCustomFilterTermStrategy() {\r\n const strategy = this.store.getStrategyOfType(EntityStoreFilterCustomFuncStrategy);\r\n if (strategy !== undefined) {\r\n strategy.activate();\r\n }\r\n }\r\n\r\n /**\r\n * Deactivate custom strategy\r\n *\r\n */\r\n deactivateCustomFilterTermStrategy() {\r\n const strategy = this.store.getStrategyOfType(EntityStoreFilterCustomFuncStrategy);\r\n if (strategy !== undefined) {\r\n strategy.deactivate();\r\n }\r\n }\r\n\r\n enableSearch() {\r\n this.searchDisabled$.next(false);\r\n }\r\n\r\n disableSearch() {\r\n this.searchDisabled$.next(true);\r\n }\r\n\r\n setSearchTerm(searchTerm: string) {\r\n this.searchTerm$.next(searchTerm);\r\n }\r\n\r\n setSearchType(searchType: string) {\r\n this.searchSourceService.enableSourcesByType(searchType);\r\n this.searchType$.next(searchType);\r\n }\r\n\r\n setSearchSettingsChange() {\r\n this.searchSettingsChange$.next(true);\r\n }\r\n\r\n setSelectedResult(result: SearchResult) {\r\n this.selectedResult$.next(result);\r\n }\r\n\r\n setSearchResultsGeometryStatus(value) {\r\n this.storageService.set('searchResultsGeometryEnabled', value);\r\n this.searchResultsGeometryEnabled$.next(value);\r\n }\r\n}\r\n","import { Directive, Self, OnInit, OnDestroy, HostListener } from '@angular/core';\r\nimport { Subscription } from 'rxjs';\r\n\r\nimport { SearchBarComponent } from '@igo2/geo';\r\nimport { SearchState } from '../search.state';\r\n\r\n@Directive({\r\n selector: '[igoSearchBarBinding]'\r\n})\r\nexport class SearchBarBindingDirective implements OnInit, OnDestroy {\r\n\r\n get searchTerm(): string { return this.searchState.searchTerm$.value; }\r\n get searchType(): string { return this.searchState.searchType$.value; }\r\n\r\n private searchTerm$$: Subscription;\r\n private searchType$$: Subscription;\r\n private searchDisabled$$: Subscription;\r\n\r\n constructor(\r\n @Self() private component: SearchBarComponent,\r\n private searchState: SearchState\r\n ) {}\r\n\r\n ngOnInit() {\r\n this.searchTerm$$ = this.searchState.searchTerm$.subscribe((searchTerm: string) => {\r\n if (searchTerm !== undefined && searchTerm !== null) {\r\n this.component.setTerm(searchTerm);\r\n }\r\n });\r\n\r\n this.searchType$$ = this.searchState.searchType$.subscribe((searchType: string) => {\r\n if (searchType !== undefined && searchType !== null) {\r\n this.component.setSearchType(searchType);\r\n }\r\n });\r\n\r\n this.searchDisabled$$ = this.searchState.searchDisabled$.subscribe((searchDisabled: boolean) => {\r\n this.component.disabled = searchDisabled;\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this.searchTerm$$.unsubscribe();\r\n this.searchType$$.unsubscribe();\r\n this.searchDisabled$$.unsubscribe();\r\n }\r\n\r\n @HostListener('searchTermChange', ['$event'])\r\n onSearchTermChange(searchTerm?: string) {\r\n if (searchTerm !== this.searchTerm) {\r\n this.searchState.setSearchTerm(searchTerm);\r\n }\r\n }\r\n\r\n @HostListener('searchTypeChange', ['$event'])\r\n onSearchTypeChange(searchType?: string) {\r\n if (searchType !== this.searchType) {\r\n this.searchState.setSearchType(searchType);\r\n }\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\n\r\nimport { IgoSearchModule } from '@igo2/geo';\r\n\r\nimport { SearchBarBindingDirective } from './search-bar-binding.directive';\r\n\r\n/**\r\n * @ignore\r\n */\r\n@NgModule({\r\n imports: [IgoSearchModule],\r\n declarations: [SearchBarBindingDirective],\r\n exports: [SearchBarBindingDirective],\r\n})\r\nexport class IgoAppSearchBarModule {}\r\n","<div *ngIf=\"(!store || store.stateView.empty) && (debouncedEmpty$ | async) \" style=\"margin: 10px;\">\r\n <section class=\"mat-typography\">\r\n <h4><strong>{{ 'igo.integration.searchResultsTool.noResults' | translate }}</strong></h4>\r\n <p><strong>{{ 'igo.integration.searchResultsTool.doSearch' | translate }}</strong></p>\r\n <div [innerHTML]=\"'igo.integration.searchResultsTool.examples' | translate | sanitizeHtml\"></div>\r\n</section>\r\n</div>\r\n\r\n<igo-flexible\r\n *ngIf=\"store && (store.stateView.empty$ | async)===false\"\r\n #topPanel\r\n initial=\"100%\"\r\n initialMobile=\"100%\"\r\n collapsed=\"calc(100% - 58px)\"\r\n collapsedMobile=\"calc(100% - 58px)\"\r\n expanded=\"60%\"\r\n expandedMobile=\"60%\"\r\n [state]=\"(feature$ | async) ? topPanelState : 'initial'\">\r\n\r\n <div class=\"igo-content\">\r\n <igo-search-results\r\n [store]=\"store\"\r\n [showIcons]=\"showIcons\"\r\n [term]=\"term\"\r\n [termSplitter]=\"termSplitter\"\r\n [settingsChange$]=\"settingsChange$\"\r\n placeholder=\"false\"\r\n (resultFocus)=\"onResultFocus($event)\"\r\n (resultSelect)=\"onResultSelect($event)\"\r\n (resultUnfocus)=\"onResultUnfocus($event)\"\r\n (resultMouseenter)=\"onResultFocus($event)\"\r\n (resultMouseleave)=\"onResultUnfocus($event)\"\r\n (moreResults)=\"onSearch($event)\">\r\n <ng-template #igoSearchItemToolbar let-result=\"result\">\r\n <igo-search-add-button\r\n [map]=\"map\"\r\n [layer]=\"result\">\r\n </igo-search-add-button>\r\n </ng-template>\r\n </igo-search-results>\r\n </div>\r\n\r\n <div igoFlexibleFill class=\"igo-content\">\r\n <igo-panel [title]=\"featureTitle\" *ngIf=\"feature$ | async\">\r\n\r\n <button\r\n mat-icon-button\r\n panelLeftButton\r\n class=\"igo-icon-button\"\r\n (click)=\"toggleTopPanel()\">\r\n <mat-icon [svgIcon]=\"(topPanelState$ | async) === 'collapsed' ? 'arrow-up' : 'arrow-down'\"></mat-icon>\r\n </button>\r\n\r\n <button\r\n *ngIf=\"feature.geometry\"\r\n mat-icon-button\r\n panelRightButton\r\n class=\"igo-icon-button\"\r\n [matTooltip]=\"((isSelectedResultOutOfView$ | async) ? 'igo.integration.searchResultsTool.zoomOnFeatureTooltipOutOfView' : 'igo.integration.searchResultsTool.zoomOnFeatureTooltip') | translate\"\r\n matTooltipShowDelay=\"500\"\r\n (click)=\"zoomToFeatureExtent()\">\r\n <mat-icon\r\n [matBadge]=\"(isSelectedResultOutOfView$ | async) ? '!' : ''\"\r\n matBadgeColor=\"accent\"\r\n matBadgeSize=\"small\"\r\n [matBadgeHidden]=\"(isSelectedResultOutOfView$ | async)===false\" \r\n svgIcon=\"magnify-plus-outline\"></mat-icon>\r\n </button>\r\n\r\n <igo-feature-details\r\n igoFeatureDetailsDirective\r\n [feature]=\"feature$ | async\"\r\n [map]=\"map\"\r\n [toolbox]=\"toolState.toolbox\"\r\n (routingEvent)=\"getRoute()\">\r\n </igo-feature-details>\r\n </igo-panel>\r\n </div>\r\n\r\n</igo-flexible>\r\n","import {\r\n Component,\r\n ChangeDetectionStrategy,\r\n Input,\r\n OnInit,\r\n ElementRef,\r\n OnDestroy\r\n} from '@angular/core';\r\nimport { Observable, BehaviorSubject, Subscription, combineLatest } from 'rxjs';\r\nimport { debounceTime, map } from 'rxjs/operators';\r\nimport olFormatGeoJSON from 'ol/format/GeoJSON';\r\nimport olFeature from 'ol/Feature';\r\nimport olPoint from 'ol/geom/Point';\r\nimport type { default as OlGeometry } from 'ol/geom/Geometry';\r\n\r\nimport pointOnFeature from '@turf/point-on-feature';\r\nimport * as olProj from 'ol/proj';\r\nimport { ConfigService } from '@igo2/core';\r\n\r\nimport {\r\n EntityStore,\r\n ToolComponent,\r\n FlexibleState,\r\n getEntityTitle,\r\n FlexibleComponent,\r\n EntityState\r\n} from '@igo2/common';\r\n\r\nimport {\r\n FEATURE,\r\n Feature,\r\n FeatureMotion,\r\n SearchResult,\r\n IgoMap,\r\n moveToOlFeatures,\r\n Research,\r\n featuresAreTooDeepInView,\r\n featureToOl,\r\n featureFromOl,\r\n getCommonVectorStyle,\r\n getCommonVectorSelectedStyle,\r\n computeOlFeaturesExtent,\r\n featuresAreOutOfView,\r\n roundCoordTo\r\n} from '@igo2/geo';\r\n\r\nimport { MapState } from '../../map/map.state';\r\n\r\nimport { SearchState } from '../search.state';\r\nimport { ToolState } from '../../tool/tool.state';\r\nimport { DirectionState } from '../../directions/directions.state';\r\n\r\n/**\r\n * Tool to browse the search results\r\n */\r\n@ToolComponent({\r\n name: 'searchResults',\r\n title: 'igo.integration.tools.searchResults',\r\n icon: 'magnify'\r\n})\r\n@Component({\r\n selector: 'igo-search-results-tool',\r\n templateUrl: './search-results-tool.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SearchResultsToolComponent implements OnInit, OnDestroy {\r\n /**\r\n * to show hide results icons\r\n */\r\n @Input() showIcons: boolean = true;\r\n\r\n /**\r\n * Determine the top panel default state\r\n */\r\n @Input() topPanelStateDefault: string = 'expanded';\r\n\r\n private hasFeatureEmphasisOnSelection: boolean = false;\r\n\r\n private showResultsGeometries$$: Subscription;\r\n private getRoute$$: Subscription;\r\n private shownResultsGeometries: Feature[] = [];\r\n private shownResultsEmphasisGeometries: Feature[] = [];\r\n private focusedResult$: BehaviorSubject<SearchResult> = new BehaviorSubject(\r\n undefined\r\n );\r\n public isSelectedResultOutOfView$ = new BehaviorSubject(false);\r\n private isSelectedResultOutOfView$$: Subscription;\r\n private abstractFocusedResult: Feature;\r\n private abstractSelectedResult: Feature;\r\n\r\n public debouncedEmpty$ :BehaviorSubject<boolean> = new BehaviorSubject(true);\r\n private debouncedEmpty$$: Subscription;\r\n\r\n /**\r\n * Store holding the search results\r\n * @internal\r\n */\r\n get store(): EntityStore<SearchResult> {\r\n return this.searchState.store;\r\n }\r\n\r\n /**\r\n * Map to display the results on\r\n * @internal\r\n */\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n\r\n get featureTitle(): string {\r\n return this.feature ? getEntityTitle(this.feature) : undefined;\r\n }\r\n\r\n get feature$(): Observable<Feature> {\r\n return this.store.stateView\r\n .firstBy$((e) => e.state.focused)\r\n .pipe(\r\n map(\r\n (element) =>\r\n (this.feature = element\r\n ? (element.entity.data as Feature)\r\n : undefined)\r\n )\r\n );\r\n }\r\n\r\n public feature: Feature;\r\n\r\n public term = '';\r\n private searchTerm$$: Subscription;\r\n\r\n public settingsChange$ = new BehaviorSubject<boolean>(undefined);\r\n\r\n public topPanelState$ = new BehaviorSubject<FlexibleState>('initial');\r\n private topPanelState$$: Subscription;\r\n\r\n @Input()\r\n set topPanelState(value: FlexibleState) {\r\n this.topPanelState$.next(value);\r\n }\r\n get topPanelState(): FlexibleState {\r\n return this.topPanelState$.value;\r\n }\r\n\r\n get termSplitter(): string {\r\n return this.searchState.searchTermSplitter$.value;\r\n }\r\n\r\n private format = new olFormatGeoJSON();\r\n\r\n constructor(\r\n private mapState: MapState,\r\n private searchState: SearchState,\r\n private elRef: ElementRef,\r\n public toolState: ToolState,\r\n private directionState: DirectionState,\r\n configService: ConfigService\r\n ) {\r\n this.hasFeatureEmphasisOnSelection = configService.getConfig(\r\n 'hasFeatureEmphasisOnSelection'\r\n );\r\n }\r\n\r\n ngOnInit() {\r\n this.searchTerm$$ = this.searchState.searchTerm$.subscribe(\r\n (searchTerm: string) => {\r\n if (searchTerm !== undefined && searchTerm !== null) {\r\n this.term = searchTerm;\r\n }\r\n }\r\n );\r\n\r\n for (const res of this.store.stateView.all$().value) {\r\n if (this.store.state.get(res.entity).selected === true) {\r\n this.topPanelState = 'expanded';\r\n }\r\n }\r\n\r\n this.searchState.searchSettingsChange$.subscribe(() => {\r\n this.settingsChange$.next(true);\r\n });\r\n\r\n this.topPanelState$$ = this.topPanelState$.subscribe(() => {\r\n const igoList = this.computeElementRef()[0];\r\n const selected = this.computeElementRef()[1];\r\n if (selected) {\r\n setTimeout(() => {\r\n // To be sure the flexible component has been displayed yet\r\n if (!this.isScrolledIntoView(igoList, selected)) {\r\n this.adjustTopPanel(igoList, selected);\r\n }\r\n }, FlexibleComponent.transitionTime + 50);\r\n }\r\n });\r\n\r\n if (this.hasFeatureEmphasisOnSelection) {\r\n if (!this.searchState.focusedOrResolution$$) {\r\n this.searchState.focusedOrResolution$$ = combineLatest([\r\n this.focusedResult$,\r\n this.map.viewController.resolution$\r\n ]).subscribe((bunch: [SearchResult<Feature>, number]) =>\r\n this.buildResultEmphasis(bunch[0], 'focused')\r\n );\r\n }\r\n\r\n if (!this.searchState.selectedOrResolution$$) {\r\n this.searchState.selectedOrResolution$$ = combineLatest([\r\n this.searchState.selectedResult$,\r\n this.map.viewController.resolution$\r\n ]).subscribe((bunch: [SearchResult<Feature>, number]) =>\r\n this.buildResultEmphasis(bunch[0], 'selected')\r\n );\r\n }\r\n }\r\n this.monitorResultOutOfView();\r\n\r\n this.showResultsGeometries$$ = combineLatest([\r\n this.searchState.searchResultsGeometryEnabled$,\r\n this.store.stateView.all$(),\r\n this.focusedResult$,\r\n this.searchState.selectedResult$,\r\n this.searchState.searchTerm$,\r\n this.map.viewController.resolution$\r\n ]).subscribe((bunch: [boolean, { entity: SearchResult, state: EntityState }[], SearchResult, SearchResult, string, number]) => {\r\n\r\n const searchResultsGeometryEnabled = bunch[0];\r\n const searchResults = bunch[1];\r\n\r\n if (this.hasFeatureEmphasisOnSelection) {\r\n this.clearFeatureEmphasis('shown');\r\n }\r\n this.shownResultsGeometries.map(result => this.map.queryResultsOverlay.removeFeature(result));\r\n const featureToHandleGeom = searchResults\r\n .filter(result =>\r\n result.entity.meta.dataType === FEATURE &&\r\n result.entity.data.geometry &&\r\n !result.state.selected &&\r\n !result.state.focused);\r\n\r\n featureToHandleGeom.map(result => {\r\n if (searchResultsGeometryEnabled) {\r\n result.entity.data.meta.style =\r\n getCommonVectorStyle(\r\n Object.assign(\r\n {},\r\n { feature: result.entity.data as Feature | olFeature<OlGeometry> },\r\n this.searchState.searchOverlayStyle,\r\n result.entity.style?.base ? result.entity.style.base : {}\r\n ));\r\n this.shownResultsGeometries.push(result.entity.data as Feature);\r\n this.map.queryResultsOverlay.addFeature(result.entity.data as Feature, FeatureMotion.None);\r\n if (this.hasFeatureEmphasisOnSelection) {\r\n this.buildResultEmphasis(result.entity as SearchResult<Feature>, 'shown');\r\n }\r\n }\r\n });\r\n });\r\n\r\n this.debouncedEmpty$$ = this.store.stateView.empty$.pipe(debounceTime(1500)).subscribe(empty => this.debouncedEmpty$.next(empty));\r\n }\r\n\r\n private monitorResultOutOfView() {\r\n this.isSelectedResultOutOfView$$ = combineLatest([\r\n this.map.viewController.state$,\r\n this.searchState.selectedResult$\r\n ])\r\n .pipe(debounceTime(100))\r\n .subscribe((bunch) => {\r\n const selectedResult = bunch[1] as SearchResult<Feature>;\r\n if (!selectedResult) {\r\n this.isSelectedResultOutOfView$.next(false);\r\n return;\r\n }\r\n if (selectedResult.data.geometry) {\r\n const selectedOlFeature = featureToOl(\r\n selectedResult.data,\r\n this.map.projection\r\n );\r\n const selectedOlFeatureExtent = computeOlFeaturesExtent(this.map, [\r\n selectedOlFeature\r\n ]);\r\n this.isSelectedResultOutOfView$.next(\r\n featuresAreOutOfView(this.map, selectedOlFeatureExtent)\r\n );\r\n }\r\n });\r\n }\r\n\r\n private buildResultEmphasis(\r\n result: SearchResult<Feature>,\r\n trigger: 'selected' | 'focused' | 'shown' | undefined\r\n ) {\r\n if (trigger !== 'shown') {\r\n this.clearFeatureEmphasis(trigger);\r\n }\r\n if (!result || !result.data.geometry) {\r\n return;\r\n }\r\n const myOlFeature = featureToOl(result.data, this.map.projection);\r\n const olGeometry = myOlFeature.getGeometry();\r\n if (featuresAreTooDeepInView(this.map, olGeometry.getExtent() as [number, number, number, number], 0.0025)) {\r\n const extent = olGeometry.getExtent();\r\n const x = extent[0] + (extent[2] - extent[0]) / 2;\r\n const y = extent[1] + (extent[3] - extent[1]) / 2;\r\n const feature1 = new olFeature({\r\n name: `${trigger}AbstractResult'`,\r\n geometry: new olPoint([x, y])\r\n });\r\n const abstractResult = featureFromOl(feature1, this.map.projection);\r\n\r\n let computedStyle;\r\n let zIndexOffset = 0;\r\n\r\n switch (trigger) {\r\n case 'focused':\r\n computedStyle = getCommonVectorSelectedStyle(\r\n Object.assign({},\r\n { feature: abstractResult },\r\n this.searchState.searchOverlayStyleFocus,\r\n result.style?.focus ? result.style.focus : {}));\r\n zIndexOffset = 2;\r\n break;\r\n case 'shown':\r\n computedStyle = getCommonVectorStyle(Object.assign({},\r\n { feature: abstractResult },\r\n this.searchState.searchOverlayStyle,\r\n result.style?.base ? result.style.base : {}));\r\n break;\r\n case 'selected':\r\n computedStyle = getCommonVectorSelectedStyle(\r\n Object.assign({},\r\n { feature: abstractResult },\r\n this.searchState.searchOverlayStyleSelection,\r\n result.style?.selection ? result.style.selection : {}));\r\n zIndexOffset = 1;\r\n break;\r\n }\r\n abstractResult.meta.style = computedStyle;\r\n abstractResult.meta.style.setZIndex(2000 + zIndexOffset);\r\n this.map.searchResultsOverlay.addFeature(abstractResult, FeatureMotion.None);\r\n if (trigger === 'focused') {\r\n this.abstractFocusedResult = abstractResult;\r\n }\r\n if (trigger === 'selected') {\r\n this.abstractSelectedResult = abstractResult;\r\n }\r\n if (trigger === 'shown') {\r\n this.shownResultsEmphasisGeometries.push(abstractResult);\r\n }\r\n } else {\r\n this.clearFeatureEmphasis(trigger);\r\n }\r\n }\r\n\r\n private clearFeatureEmphasis(trigger: 'selected' | 'focused' | 'shown') {\r\n if (trigger === 'focused' && this.abstractFocusedResult) {\r\n this.map.searchResultsOverlay.removeFeature(this.abstractFocusedResult);\r\n this.abstractFocusedResult = undefined;\r\n }\r\n if (trigger === 'selected' && this.abstractSelectedResult) {\r\n this.map.searchResultsOverlay.removeFeature(this.abstractSelectedResult);\r\n this.abstractSelectedResult = undefined;\r\n }\r\n if (trigger === 'shown') {\r\n this.shownResultsEmphasisGeometries.map(shownResult => this.map.searchResultsOverlay.removeFeature(shownResult));\r\n this.shownResultsEmphasisGeometries = [];\r\n }\r\n }\r\n\r\n ngOnDestroy() {\r\n this.topPanelState$$.unsubscribe();\r\n this.searchTerm$$.unsubscribe();\r\n if (this.isSelectedResultOutOfView$$) {\r\n this.isSelectedResultOutOfView$$.unsubscribe();\r\n }\r\n if (this.showResultsGeometries$$) {\r\n this.showResultsGeometries$$.unsubscribe();\r\n }\r\n if (this.getRoute$$) {\r\n this.getRoute$$.unsubscribe();\r\n }\r\n if (this.debouncedEmpty$$) {\r\n this.debouncedEmpty$$.unsubscribe();\r\n }\r\n }\r\n\r\n /**\r\n * Try to add a feature to the map when it's being focused\r\n * @internal\r\n * @param result A search result that could be a feature\r\n */\r\n onResultFocus(result: SearchResult) {\r\n this.focusedResult$.next(result);\r\n if (result.meta.dataType === FEATURE && result.data.geometry) {\r\n result.data.meta.style = getCommonVectorSelectedStyle(\r\n Object.assign({},\r\n { feature: result.data as Feature | olFeature<OlGeometry> },\r\n this.searchState.searchOverlayStyleFocus,\r\n result.style?.focus ? result.style.focus : {}));\r\n\r\n const feature = this.map.searchResultsOverlay.dataSource.ol.getFeatureById(result.meta.id);\r\n if (feature) {\r\n feature.setStyle(result.data.meta.style);\r\n return;\r\n }\r\n this.map.searchResultsOverlay.addFeature(result.data as Feature, FeatureMotion.None);\r\n }\r\n }\r\n\r\n onResultUnfocus(result: SearchResult) {\r\n this.focusedResult$.next(undefined);\r\n if (result.meta.dataType !== FEATURE) {\r\n return;\r\n }\r\n\r\n if (this.store.state.get(result).selected === true) {\r\n const feature = this.map.searchResultsOverlay.dataSource.ol.getFeatureById(result.meta.id);\r\n if (feature) {\r\n const style = getCommonVectorSelectedStyle(\r\n Object.assign({},\r\n { feature: result.data as Feature | olFeature<OlGeometry> },\r\n this.searchState.searchOverlayStyleFocus,\r\n result.style?.focus ? result.style.focus : {}));\r\n feature.setStyle(style);\r\n }\r\n return;\r\n }\r\n this.map.searchResultsOverlay.removeFeature(result.data as Feature);\r\n }\r\n\r\n /**\r\n * Try to add a feature to the map when it's being selected\r\n * @internal\r\n * @param result A search result that could be a feature or some layer options\r\n */\r\n onResultSelect(result: SearchResult) {\r\n this.map.searchResultsOverlay.dataSource.ol.clear();\r\n this.tryAddFeatureToMap(result);\r\n this.searchState.setSelectedResult(result);\r\n\r\n if (this.topPanelState === 'initial') {\r\n if (this.topPanelStateDefault !== 'collapsed') {\r\n this.topPanelState = 'expanded';\r\n } else {\r\n this.topPanelState = 'collapsed';\r\n }\r\n }\r\n\r\n if (this.topPanelState === 'expanded') {\r\n const igoList = this.computeElementRef()[0];\r\n const selected = this.computeElementRef()[1];\r\n if (!this.isScrolledIntoView(igoList, selected)) {\r\n this.adjustTopPanel(igoList, selected);\r\n }\r\n }\r\n }\r\n\r\n onSearch(event: { research: Research; results: SearchResult[] }) {\r\n const results = event.results;\r\n const newResults = this.store.entities$.value\r\n .filter((result: SearchResult) => result.source !== event.research.source)\r\n .concat(results);\r\n\r\n this.store.load(newResults);\r\n\r\n for (const res of this.store.all()) {\r\n if (\r\n this.store.state.get(res).focused === true &&\r\n this.store.state.get(res).selected !== true\r\n ) {\r\n this.store.state.update(res, { focused: false }, true);\r\n }\r\n }\r\n\r\n setTimeout(() => {\r\n const igoList = this.elRef.nativeElement.querySelector('igo-list');\r\n let moreResults;\r\n event.research.request.subscribe((source) => {\r\n if (!source[0] || !source[0].source) {\r\n moreResults = null;\r\n } else if (source[0].source.getId() === 'icherche') {\r\n moreResults = igoList.querySelector('.icherche .moreResults');\r\n } else if (source[0].source.getId() === 'ilayer') {\r\n moreResults = igoList.querySelector('.ilayer .moreResults');\r\n } else if (source[0].source.getId() === 'nominatim') {\r\n moreResults = igoList.querySelector('.nominatim .moreResults');\r\n } else {\r\n moreResults = igoList.querySelector('.' + source[0].source.getId() + ' .moreResults');\r\n }\r\n\r\n if (\r\n moreResults !== null &&\r\n !this.isScrolledIntoView(igoList, moreResults)\r\n ) {\r\n igoList.scrollTop =\r\n moreResults.offsetTop +\r\n moreResults.offsetHeight -\r\n igoList.clientHeight;\r\n }\r\n });\r\n }, 250);\r\n }\r\n\r\n computeElementRef() {\r\n const items = document.getElementsByTagName('igo-search-results-item');\r\n const igoList = this.elRef.nativeElement.getElementsByTagName(\r\n 'igo-list'\r\n )[0];\r\n let selectedItem;\r\n // eslint-disable-next-line\r\n for (let i = 0; i < items.length; i++) {\r\n if (items[i].className.includes('igo-list-item-selected')) {\r\n selectedItem = items[i];\r\n }\r\n }\r\n return [igoList, selectedItem];\r\n }\r\n\r\n adjustTopPanel(elemSource, elem) {\r\n if (!this.isScrolledIntoView(elemSource, elem)) {\r\n elemSource.scrollTop =\r\n elem.offsetTop +\r\n elem.children[0].offsetHeight -\r\n elemSource.clientHeight;\r\n }\r\n }\r\n\r\n toggleTopPanel() {\r\n if (this.topPanelState === 'expanded') {\r\n this.topPanelState = 'collapsed';\r\n } else {\r\n this.topPanelState = 'expanded';\r\n }\r\n }\r\n\r\n zoomToFeatureExtent() {\r\n if (this.feature.geometry) {\r\n const localOlFeature = this.format.readFeature(this.feature, {\r\n dataProjection: this.feature.projection,\r\n featureProjection: this.map.projection\r\n });\r\n moveToOlFeatures(this.map, [localOlFeature], FeatureMotion.Zoom);\r\n }\r\n }\r\n\r\n /**\r\n * Try to add a feature to the map overlay\r\n * @param result A search result that could be a feature\r\n */\r\n private tryAddFeatureToMap(result: SearchResult) {\r\n if (result.meta.dataType !== FEATURE) {\r\n return undefined;\r\n }\r\n const feature = (result as SearchResult<Feature>).data;\r\n\r\n // Somethimes features have no geometry. It happens with some GetFeatureInfo\r\n if (!feature.geometry) {\r\n return;\r\n }\r\n\r\n feature.meta.style = getCommonVectorSelectedStyle(\r\n Object.assign({},\r\n { feature },\r\n this.searchState.searchOverlayStyleSelection,\r\n result.style?.selection ? result.style.selection : {}));\r\n\r\n this.map.searchResultsOverlay.addFeature(feature);\r\n }\r\n\r\n isScrolledIntoView(elemSource, elem) {\r\n const padding = 6;\r\n const docViewTop = elemSource.scrollTop;\r\n const docViewBottom = docViewTop + elemSource.clientHeight;\r\n\r\n const elemTop = elem.offsetTop;\r\n const elemBottom = elemTop + elem.clientHeight + padding;\r\n return elemBottom <= docViewBottom && elemTop >= docViewTop;\r\n }\r\n\r\n getRoute() {\r\n this.toolState.toolbox.activateTool('directions');\r\n this.directionState.stopsStore.clearStops();\r\n setTimeout(() => {\r\n let routingCoordLoaded = false;\r\n if (this.getRoute$$) { this.getRoute$$.unsubscribe(); }\r\n this.getRoute$$ = this.directionState.stopsStore.storeInitialized$.subscribe((init: boolean) => {\r\n if (this.directionState.stopsStore.storeInitialized$.value && !routingCoordLoaded) {\r\n routingCoordLoaded = true;\r\n const stop = this.directionState.stopsStore.all().find((e) => e.position === 1);\r\n let coord;\r\n if (this.feature.geometry) {\r\n if (this.feature.geometry.type === 'Point') {\r\n coord = [this.feature.geometry.coordinates[0], this.feature.geometry.coordinates[1]];\r\n } else {\r\n const point = pointOnFeature(this.feature.geometry);\r\n coord = [point.geometry.coordinates[0], point.geometry.coordinates[1]];\r\n }\r\n }\r\n stop.text = this.featureTitle;\r\n stop.coordinates = coord;\r\n this.directionState.stopsStore.update(stop);\r\n if (this.map.geolocationController.position$.value) {\r\n const currentPos = this.map.geolocationController.position$.value;\r\n const stop = this.directionState.stopsStore.all().find((e) => e.position === 0);\r\n const currentCoord = olProj.transform(currentPos.position, currentPos.projection, 'EPSG:4326');\r\n const coord: [number,number] = roundCoordTo([currentCoord[0], currentCoord[1]], 6);\r\n stop.text = coord.join(',');\r\n stop.coordinates = coord;\r\n this.directionState.stopsStore.update(stop);\r\n }\r\n\r\n }\r\n });\r\n }, 250);\r\n }\r\n}\r\n","import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\n\r\nimport { MatButtonModule } from '@angular/material/button';\r\nimport { MatIconModule } from '@angular/material/icon';\r\nimport { MatBadgeModule } from '@angular/material/badge';\r\nimport { MatTooltipModule } from '@angular/material/tooltip';\r\n\r\nimport { IgoLanguageModule } from '@igo2/core';\r\nimport { IgoFlexibleModule, IgoCustomHtmlModule, IgoPanelModule } from '@igo2/common';\r\nimport {\r\n IgoFeatureModule,\r\n IgoSearchModule,\r\n IgoFeatureDetailsModule\r\n} from '@igo2/geo';\r\n\r\nimport { SearchResultsToolComponent } from './search-results-tool.component';\r\n\r\n/**\r\n * @ignore\r\n */\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n MatIconModule,\r\n MatBadgeModule,\r\n MatTooltipModule,\r\n MatButtonModule,\r\n IgoLanguageModule,\r\n IgoFeatureModule,\r\n IgoSearchModule,\r\n IgoFlexibleModule,\r\n IgoPanelModule,\r\n IgoFeatureDetailsModule,\r\n IgoCustomHtmlModule\r\n ],\r\n declarations: [SearchResultsToolComponent],\r\n exports: [SearchResultsToolComponent],\r\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\r\n})\r\nexport class IgoAppSearchResultsToolModule {}\r\n","import { NgModule } from '@angular/core';\r\n\r\nimport { IgoAppSearchBarModule } from './search-bar/search-bar.module';\r\nimport { IgoAppSearchResultsToolModule } from './search-results-tool/search-results-tool.module';\r\n\r\n@NgModule({\r\n imports: [],\r\n declarations: [],\r\n exports: [\r\n IgoAppSearchBarModule,\r\n IgoAppSearchResultsToolModule\r\n ],\r\n})\r\nexport class IgoAppSearchModule {}\r\n","import { Component } from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\n\r\n@ToolComponent({\r\n name: 'ogcFilter',\r\n title: 'igo.integration.tools.ogcFilter',\r\n icon: 'filter'\r\n})\r\n@Component({\r\n selector: 'igo-ogc-filter-tool',\r\n templateUrl: './ogc-filter-tool.component.html'\r\n})\r\nexport class OgcFilterToolComponent {\r\n constructor() {}\r\n}\r\n","<igo-ogc-filterable-list igoOgcFilterableListBinding></igo-ogc-filterable-list>\r\n\r\n\r\n","import { Component } from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\n\r\n@ToolComponent({\r\n name: 'timeFilter',\r\n title: 'igo.integration.tools.timeFilter',\r\n icon: 'history'\r\n})\r\n@Component({\r\n selector: 'igo-time-filter-tool',\r\n templateUrl: './time-filter-tool.component.html'\r\n})\r\nexport class TimeFilterToolComponent {\r\n constructor() {}\r\n}\r\n","<igo-time-filter-list igoTimeFilterListBinding></igo-time-filter-list>\r\n","<igo-panel>\r\n <igo-spatial-filter-type\r\n [store]=\"spatialListStore\"\r\n [selectedQueryType]=\"queryType\"\r\n [zone]=\"zone\"\r\n [layers]=\"activeLayers\"\r\n (eventType)=\"getOutputType($event)\"\r\n (eventQueryType)=\"getOutputQueryType($event)\"\r\n (zoneChange)=\"onZoneChange($event)\"\r\n (zoneWithBufferChange)=\"onZoneChange($event, true)\"\r\n (bufferChange)=\"buffer = $event\"\r\n (measureUnitChange)=\"measureUnit = $event\">\r\n </igo-spatial-filter-type>\r\n\r\n <igo-spatial-filter-item\r\n [type]=\"type\"\r\n [queryType]=\"queryType\"\r\n [map]=\"map\"\r\n [zone]=\"zone\"\r\n [loading]=\"loading\"\r\n [store]=\"store\"\r\n [layers]=\"activeLayers\"\r\n [allLayers]=\"layers\"\r\n [thematicLength]=\"thematicLength\"\r\n (radiusEvent)=\"buffer = $event\"\r\n (bufferEvent)=\"buffer = $event\"\r\n (measureUnitChange)=\"measureUnit = $event\"\r\n (freehandControl)=\"freehandDrawIsActive = $event\"\r\n (drawZoneEvent)=\"zone = $event\"\r\n (zoneWithBufferChange)=\"onZoneChange($event, true)\"\r\n (itemTypeChange)=\"itemType = $event\"\r\n (thematicChange)=\"thematics = $event\"\r\n (toggleSearch)=\"getOutputToggleSearch()\"\r\n (clearButtonEvent)=\"clearMap()\"\r\n (clearSearchEvent)=\"getOutputClearSearch()\"\r\n (export)=\"activateExportTool()\"\r\n (openWorkspace)=\"activateWorkspace()\"\r\n (entityChange)=\"activateWorkspace($event)\">\r\n </igo-spatial-filter-item>\r\n</igo-panel>\r\n\r\n<igo-panel>\r\n <ng-container *ngIf=\"selectedFeature$ | async as feature\">\r\n <igo-feature-details [feature]=\"feature\"></igo-feature-details>\r\n </ng-container>\r\n</igo-panel>","import { Component, Input, ChangeDetectionStrategy, ChangeDetectorRef, OnDestroy, OnInit } from '@angular/core';\r\nimport { MatIconRegistry } from '@angular/material/icon';\r\nimport { Observable, forkJoin, Subject } from 'rxjs';\r\nimport { tap, take, takeUntil } from 'rxjs/operators';\r\n\r\nimport {\r\n IgoMap,\r\n DataSourceService,\r\n LayerService,\r\n Feature,\r\n moveToOlFeatures,\r\n FeatureMotion,\r\n ClusterDataSource,\r\n featureToOl,\r\n DataSource,\r\n QueryableDataSourceOptions,\r\n SpatialFilterService,\r\n SpatialFilterType,\r\n SpatialFilterItemType,\r\n SpatialFilterQueryType,\r\n SpatialFilterThematic,\r\n Layer,\r\n createOverlayMarkerStyle,\r\n ExportOptions,\r\n MeasureLengthUnit\r\n} from '@igo2/geo';\r\nimport { EntityStore, ToolComponent } from '@igo2/common';\r\nimport olFormatGeoJSON from 'ol/format/GeoJSON';\r\nimport olSourceVector from 'ol/source/Vector';\r\nimport olSourceCluster from 'ol/source/Cluster';\r\nimport type { default as OlGeometry } from 'ol/geom/Geometry';\r\nimport { BehaviorSubject } from 'rxjs';\r\nimport { MapState } from '../../map/map.state';\r\nimport { ImportExportMode, ImportExportState } from './../../import-export/import-export.state';\r\nimport * as olstyle from 'ol/style';\r\nimport { MessageService, LanguageService } from '@igo2/core';\r\nimport { ToolState } from '../../tool/tool.state';\r\nimport { WorkspaceState } from '../../workspace/workspace.state';\r\nimport { EventsKey } from 'ol/events';\r\n\r\n/**\r\n * Tool to apply spatial filter\r\n */\r\n@ToolComponent({\r\n name: 'spatialFilter',\r\n title: 'igo.integration.tools.spatialFilter',\r\n icon: 'selection-marker'\r\n})\r\n/**\r\n * Spatial Filter Type\r\n */\r\n@Component({\r\n selector: 'igo-spatial-filter-tool',\r\n templateUrl: './spatial-filter-tool.component.html',\r\n styleUrls: ['./spatial-filter-tool.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SpatialFilterToolComponent implements OnInit, OnDestroy {\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n\r\n @Input() type: SpatialFilterType;\r\n @Input() itemType: SpatialFilterItemType = SpatialFilterItemType.Address;\r\n @Input() freehandDrawIsActive: boolean;\r\n\r\n public layers: Layer[] = [];\r\n public activeLayers: Layer[] = [];\r\n\r\n public queryType: SpatialFilterQueryType;\r\n public thematics: SpatialFilterThematic[];\r\n public zone: Feature;\r\n public zoneWithBuffer: Feature;\r\n public buffer = 0;\r\n\r\n public iterator = 1;\r\n\r\n public selectedFeature$: BehaviorSubject<Feature> = new BehaviorSubject(\r\n undefined\r\n );\r\n\r\n private format = new olFormatGeoJSON();\r\n\r\n public store: EntityStore<Feature> = new EntityStore<Feature>([]); // Store to print results at the end\r\n\r\n public spatialListStore: EntityStore<Feature> = new EntityStore<Feature>([]);\r\n\r\n public loading = false;\r\n\r\n public thematicLength = 0;\r\n\r\n public measureUnit: MeasureLengthUnit = MeasureLengthUnit.Meters;\r\n private unsubscribe$ = new Subject<void>();\r\n\r\n private moveendKey: EventsKey;\r\n\r\n constructor(\r\n private matIconRegistry: MatIconRegistry,\r\n private spatialFilterService: SpatialFilterService,\r\n private dataSourceService: DataSourceService,\r\n private layerService: LayerService,\r\n private mapState: MapState,\r\n private messageService: MessageService,\r\n private languageService: LanguageService,\r\n private importExportState: ImportExportState,\r\n private toolState: ToolState,\r\n private workspaceState: WorkspaceState,\r\n private cdRef: ChangeDetectorRef\r\n ) {}\r\n\r\n ngOnInit() {\r\n for (const layer of this.map.layers) {\r\n if (layer.title && layer.title.includes(this.languageService.translate.instant('igo.geo.spatialFilter.spatialFilter'))) {\r\n this.layers.push(layer);\r\n }\r\n }\r\n }\r\n\r\n ngOnDestroy() {\r\n this.unsubscribe$.next();\r\n this.unsubscribe$.complete();\r\n }\r\n\r\n getOutputType(event: SpatialFilterType) {\r\n this.type = event;\r\n this.queryType = undefined;\r\n }\r\n\r\n getOutputQueryType(event: SpatialFilterQueryType) {\r\n this.queryType = event;\r\n if (this.queryType) {\r\n this.loadFilterList();\r\n }\r\n }\r\n\r\n activateExportTool() {\r\n const ids = [];\r\n const re = new RegExp('^Zone \\\\d+');\r\n for (const layer of this.layers) {\r\n if (!layer.title.match(re)) {\r\n ids.push(layer.id);\r\n }\r\n }\r\n this.importExportState.setMode(ImportExportMode.export);\r\n this.importExportState.setsExportOptions({ layers: ids } as ExportOptions);\r\n this.toolState.toolbox.activateTool('importExport');\r\n }\r\n\r\n activateWorkspace(record?) {\r\n let layerToOpenWks;\r\n this.workspaceState.store.entities$.pipe(takeUntil(this.unsubscribe$)).subscribe(() => {\r\n if (!record && this.activeLayers.length && this.workspaceState.store.all().length > 1) {\r\n if (this.itemType === SpatialFilterItemType.Thematics) {\r\n for (const thematic of this.thematics) {\r\n if (!thematic.zeroResults) {\r\n layerToOpenWks = this.activeLayers.find(layer => layer.title.includes(thematic.name + ' ' + this.iterator.toString()));\r\n break;\r\n }\r\n }\r\n } else {\r\n const title = 'Adresses ' + this.iterator.toString();\r\n this.activeLayers.forEach((layer) => {\r\n if (layer.title.includes(title)) {\r\n layerToOpenWks = layer;\r\n }\r\n });\r\n }\r\n\r\n if (layerToOpenWks) {\r\n this.workspaceState.workspacePanelExpanded = true;\r\n this.workspaceState.setActiveWorkspaceById(layerToOpenWks.id);\r\n }\r\n } else if (record && this.activeLayers.length && this.workspaceState.store.all().length > 1) {\r\n this.selectWorkspaceEntity(record);\r\n this.moveendKey = this.map.ol.on('moveend', () => {\r\n this.selectWorkspaceEntity(record);\r\n });\r\n }\r\n });\r\n }\r\n\r\n private selectWorkspaceEntity(record) {\r\n this.workspaceState.store.all().forEach(workspace => {\r\n workspace.entityStore.state.updateAll({selected: false});\r\n if (workspace.title.includes(record.added[0].meta.title)) {\r\n this.workspaceState.setActiveWorkspaceById(workspace.id);\r\n workspace.entityStore.state.updateMany(record.added, {selected: true});\r\n }\r\n });\r\n }\r\n\r\n private loadFilterList() {\r\n this.spatialFilterService\r\n .loadFilterList(this.queryType)\r\n .pipe(takeUntil(this.unsubscribe$))\r\n .subscribe((features: Feature[]) => {\r\n features.sort((a, b) => {\r\n if (a.properties.nom < b.properties.nom) {\r\n return -1;\r\n }\r\n if (a.properties.nom > b.properties.nom) {\r\n return 1;\r\n }\r\n return 0;\r\n });\r\n this.spatialListStore.clear();\r\n this.spatialListStore.load(features);\r\n });\r\n }\r\n\r\n getOutputToggleSearch() {\r\n this.loadThematics();\r\n }\r\n\r\n getOutputClearSearch() {\r\n this.zone = undefined;\r\n this.queryType = undefined;\r\n }\r\n\r\n clearMap() {\r\n this.map.removeLayers(this.layers);\r\n this.layers = [];\r\n this.activeLayers = [];\r\n this.thematicLength = 0;\r\n this.iterator = 1;\r\n if (this.type === SpatialFilterType.Predefined) {\r\n this.zone = undefined;\r\n this.queryType = undefined;\r\n }\r\n }\r\n\r\n private loadThematics() {\r\n this.loading = true;\r\n let zeroResults = true;\r\n let thematics;\r\n if (this.buffer === 0 || this.type === SpatialFilterType.Point) {\r\n this.tryAddFeaturesToMap([this.zone]);\r\n }\r\n if (this.itemType !== SpatialFilterItemType.Thematics) {\r\n const theme: SpatialFilterThematic = {\r\n name: ''\r\n };\r\n thematics = [theme];\r\n } else {\r\n thematics = this.thematics;\r\n }\r\n if (this.measureUnit === MeasureLengthUnit.Kilometers && this.type !== SpatialFilterType.Point) {\r\n this.buffer = this.buffer * 1000;\r\n }\r\n if (this.type === SpatialFilterType.Polygon) {\r\n this.buffer = 0; // to avoid buffer enter a second time in terrAPI\r\n }\r\n\r\n const observables$: Observable<Feature[]>[] = [];\r\n thematics.forEach(thematic => {\r\n observables$.push(\r\n this.spatialFilterService\r\n .loadFilterItem(\r\n this.zone,\r\n this.itemType,\r\n this.queryType,\r\n thematic,\r\n this.buffer\r\n )\r\n .pipe(\r\n tap((features: Feature[]) => {\r\n this.store.insertMany(features);\r\n const featuresPoint: Feature[] = [];\r\n const featuresLinePoly: Feature[] = [];\r\n let idPoint;\r\n let idLinePoly;\r\n features.forEach(feature => {\r\n if (feature.geometry.type === 'Point') {\r\n feature.properties.longitude = feature.geometry.coordinates[0];\r\n feature.properties.latitude = feature.geometry.coordinates[1];\r\n featuresPoint.push(feature);\r\n idPoint = feature.meta.id;\r\n } else {\r\n featuresLinePoly.push(feature);\r\n idLinePoly = feature.meta.id;\r\n }\r\n });\r\n\r\n this.tryAddPointToMap(featuresPoint, idPoint);\r\n this.tryAddLayerToMap(featuresLinePoly, idLinePoly);\r\n if (features.length) {\r\n zeroResults = false;\r\n this.thematicLength += 1;\r\n thematic.zeroResults = false;\r\n this.cdRef.detectChanges();\r\n } else {\r\n thematic.zeroResults = true;\r\n }\r\n\r\n if (features.length >= 10000) {\r\n this.messageService.alert(\r\n this.languageService.translate.instant(\r\n 'igo.geo.spatialFilter.maxSizeAlert'\r\n ),\r\n this.languageService.translate.instant(\r\n 'igo.geo.spatialFilter.warning'\r\n ),\r\n { timeOut: 10000 }\r\n );\r\n }\r\n })\r\n )\r\n );\r\n });\r\n\r\n forkJoin(observables$).pipe(takeUntil(this.unsubscribe$)).subscribe(() => {\r\n this.loading = false;\r\n if (zeroResults) {\r\n this.messageService.alert(\r\n this.languageService.translate.instant(\r\n 'igo.geo.spatialFilter.zeroResults'\r\n ),\r\n this.languageService.translate.instant(\r\n 'igo.geo.spatialFilter.warning'\r\n ),\r\n { timeOut: 10000 }\r\n );\r\n }\r\n });\r\n }\r\n\r\n onZoneChange(feature: Feature, buffer?: boolean) {\r\n this.zone = feature;\r\n if (feature) {\r\n buffer ? this.tryAddFeaturesToMap([feature], true) : this.tryAddFeaturesToMap([feature]);\r\n this.zoomToFeatureExtent(feature);\r\n }\r\n }\r\n\r\n /**\r\n * Try to add zone feature to the map overlay\r\n */\r\n public tryAddFeaturesToMap(features: Feature[], buffer?: boolean) {\r\n let i = 1;\r\n for (const feature of features) {\r\n if (this.type === SpatialFilterType.Predefined) {\r\n for (const layer of this.layers) {\r\n if (\r\n layer.options._internal &&\r\n layer.options._internal.code === feature.properties.code &&\r\n !buffer\r\n ) {\r\n if (!layer.title?.startsWith('Zone')) {\r\n const index = this.layers.indexOf(layer);\r\n this.layers.splice(index, 1);\r\n }\r\n return;\r\n }\r\n if (layer.title?.startsWith('Zone')) {\r\n this.activeLayers = [];\r\n const index = this.layers.indexOf(layer);\r\n this.layers.splice(index, 1);\r\n this.map.removeLayer(layer);\r\n }\r\n }\r\n } else {\r\n if (buffer) {\r\n for (const layer of this.activeLayers) {\r\n if (this.activeLayers.length === 1 && layer.title?.startsWith('Zone')) {\r\n const index = this.layers.indexOf(layer);\r\n this.layers.splice(index, 1);\r\n this.map.removeLayer(layer);\r\n }\r\n }\r\n }\r\n this.activeLayers = [];\r\n }\r\n for (const layer of this.layers) {\r\n if (layer.title?.startsWith('Zone')) {\r\n i++;\r\n }\r\n }\r\n this.dataSourceService\r\n .createAsyncDataSource({\r\n type: 'vector',\r\n queryable: true\r\n } as QueryableDataSourceOptions)\r\n .pipe(take(1))\r\n .subscribe((dataSource: DataSource) => {\r\n const olLayer = this.layerService.createLayer({\r\n isIgoInternalLayer: true,\r\n title: ('Zone ' + i + ' - ' + this.languageService.translate.instant(\r\n 'igo.geo.spatialFilter.spatialFilter'\r\n )) as string,\r\n workspace: { enabled: true },\r\n _internal: {\r\n code:\r\n this.type === SpatialFilterType.Predefined\r\n ? feature.properties.code\r\n : undefined\r\n },\r\n source: dataSource,\r\n visible: true,\r\n style: (_feature, resolution) => {\r\n const coordinates = (features[0] as any).coordinates;\r\n return new olstyle.Style({\r\n image: new olstyle.Circle({\r\n radius: coordinates\r\n ? this.buffer /\r\n Math.cos((Math.PI / 180) * coordinates[1]) /\r\n resolution\r\n : undefined,\r\n fill: new olstyle.Fill({\r\n color: 'rgba(200, 200, 20, 0.2)'\r\n }),\r\n stroke: new olstyle.Stroke({\r\n width: 1,\r\n color: 'orange'\r\n })\r\n }),\r\n stroke: new olstyle.Stroke({\r\n width: 1,\r\n color: 'orange'\r\n }),\r\n fill: new olstyle.Fill({\r\n color: 'rgba(200, 200, 20, 0.2)'\r\n })\r\n });\r\n }\r\n });\r\n const featuresOl = features.map(f => {\r\n return featureToOl(f, this.map.projection);\r\n });\r\n if (this.type !== SpatialFilterType.Predefined) {\r\n const type = this.type === SpatialFilterType.Point ? 'Cercle' : 'Polygone';\r\n featuresOl[0].set('nom', 'Zone', true);\r\n featuresOl[0].set('type', type, true);\r\n }\r\n const ol = dataSource.ol as olSourceVector<OlGeometry> | olSourceCluster;\r\n ol.addFeatures(featuresOl);\r\n this.map.addLayer(olLayer);\r\n this.layers.push(olLayer);\r\n this.activeLayers.push(olLayer);\r\n this.cdRef.detectChanges();\r\n });\r\n }\r\n }\r\n\r\n /**\r\n * Try to add point features to the map\r\n * Necessary to create clusters\r\n */\r\n private tryAddPointToMap(features: Feature[], id) {\r\n let i = 1;\r\n if (features.length) {\r\n if (this.map === undefined) {\r\n return;\r\n }\r\n for (const layer of this.layers) {\r\n if (layer.title?.startsWith(features[0].meta.title)) {\r\n i++;\r\n }\r\n }\r\n this.dataSourceService\r\n .createAsyncDataSource({\r\n type: 'cluster',\r\n id,\r\n queryable: true,\r\n distance: 120,\r\n meta: {\r\n title: 'Cluster'\r\n }\r\n } as QueryableDataSourceOptions)\r\n .pipe(take(1))\r\n .subscribe((dataSource: ClusterDataSource) => {\r\n const icon = features[0].meta.icon;\r\n let style: olstyle.Style;\r\n if (!icon) {\r\n style = createOverlayMarkerStyle();\r\n } else {\r\n style = this.createSvgIcon(icon) || createOverlayMarkerStyle();\r\n }\r\n\r\n const olLayer = this.layerService.createLayer({\r\n isIgoInternalLayer: true,\r\n title: (features[0].meta.title + ' ' + i + ' - ' + this.languageService.translate.instant(\r\n 'igo.geo.spatialFilter.spatialFilter'\r\n )) as string,\r\n source: dataSource,\r\n visible: true,\r\n style\r\n });\r\n\r\n const featuresOl = features.map(feature => {\r\n return featureToOl(feature, this.map.projection);\r\n });\r\n const ol = dataSource.ol as olSourceCluster;\r\n ol.getSource().addFeatures(featuresOl);\r\n if (this.layers.find(layer => layer.id === olLayer.id)) {\r\n this.map.removeLayer(\r\n this.layers.find(layer => layer.id === olLayer.id)\r\n );\r\n i = i - 1;\r\n olLayer.title = (features[0].meta.title + ' ' + i + ' - ' + this.languageService.translate.instant(\r\n 'igo.geo.spatialFilter.spatialFilter'\r\n )) as string;\r\n olLayer.options.title = olLayer.title;\r\n }\r\n this.iterator = i;\r\n this.map.addLayer(olLayer);\r\n this.layers.push(olLayer);\r\n this.pushLayer(olLayer);\r\n this.cdRef.detectChanges();\r\n });\r\n }\r\n }\r\n\r\n private createSvgIcon(icon): olstyle.Style {\r\n let style: olstyle.Style;\r\n this.matIconRegistry.getNamedSvgIcon(icon).subscribe(svgObj => {\r\n const xmlSerializer = new XMLSerializer();\r\n svgObj.setAttribute('width', '30');\r\n svgObj.setAttribute('height', '30');\r\n svgObj.setAttribute('fill', 'rgba(0, 128, 255)');\r\n svgObj.setAttribute('stroke', 'white');\r\n const svg = xmlSerializer.serializeToString(svgObj);\r\n style = new olstyle.Style({\r\n image: new olstyle.Icon({\r\n src: 'data:image/svg+xml;utf8,' + svg\r\n })\r\n });\r\n });\r\n return style;\r\n }\r\n /**\r\n * Try to add line or polygon features to the map\r\n */\r\n private tryAddLayerToMap(features: Feature[], id) {\r\n let i = 1;\r\n if (features.length) {\r\n if (this.map === undefined) {\r\n return;\r\n }\r\n for (const layer of this.layers) {\r\n if (layer.title?.startsWith(features[0].meta.title)) {\r\n i++;\r\n }\r\n }\r\n this.dataSourceService\r\n .createAsyncDataSource({\r\n type: 'vector',\r\n id,\r\n queryable: true\r\n } as QueryableDataSourceOptions)\r\n .pipe(take(1))\r\n .subscribe((dataSource: DataSource) => {\r\n const olLayer = this.layerService.createLayer({\r\n isIgoInternalLayer: true,\r\n title: (features[0].meta.title + ' ' + i + ' - ' + this.languageService.translate.instant(\r\n 'igo.geo.spatialFilter.spatialFilter'\r\n )) as string,\r\n source: dataSource,\r\n visible: true\r\n });\r\n const featuresOl = features.map(feature => {\r\n return featureToOl(feature, this.map.projection);\r\n });\r\n const ol = dataSource.ol as olSourceVector<OlGeometry>;\r\n ol.addFeatures(featuresOl);\r\n if (this.layers.find(layer => layer.id === olLayer.id)) {\r\n this.map.removeLayer(\r\n this.layers.find(layer => layer.id === olLayer.id)\r\n );\r\n i = i - 1;\r\n olLayer.title = (features[0].meta.title + ' ' + i + ' - ' + this.languageService.translate.instant(\r\n 'igo.geo.spatialFilter.spatialFilter'\r\n )) as string;\r\n olLayer.options.title = olLayer.title;\r\n }\r\n this.map.addLayer(olLayer);\r\n this.layers.push(olLayer);\r\n this.pushLayer(olLayer);\r\n this.cdRef.detectChanges();\r\n });\r\n }\r\n }\r\n\r\n zoomToFeatureExtent(feature) {\r\n if (feature) {\r\n const olFeature = this.format.readFeature(feature, {\r\n dataProjection: feature.projection,\r\n featureProjection: this.map.projection\r\n });\r\n moveToOlFeatures(this.map, [olFeature], FeatureMotion.Zoom);\r\n }\r\n }\r\n\r\n pushLayer(layer) {\r\n for (const lay of this.activeLayers) {\r\n if (lay.id === layer.id) {\r\n return;\r\n }\r\n }\r\n\r\n this.activeLayers.push(layer);\r\n }\r\n}\r\n","import {\r\n trigger,\r\n state,\r\n style,\r\n transition,\r\n animate,\r\n AnimationTriggerMetadata\r\n} from '@angular/animations';\r\n\r\nexport function toolSlideInOut(\r\n speed = '300ms',\r\n type = 'ease-in-out'\r\n): AnimationTriggerMetadata {\r\n return trigger('toolSlideInOut', [\r\n state(\r\n 'enter',\r\n style({\r\n transform: 'translateX(100%)'\r\n })\r\n ),\r\n transition('void => enter', animate(speed + ' ' + type))\r\n ]);\r\n}\r\n","import { Component } from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport { MapState } from '../../map/map.state';\r\nimport { IgoMap, Layer } from '@igo2/geo';\r\nimport { toolSlideInOut } from './active-time-filter-tool.animation';\r\n\r\n@ToolComponent({\r\n name: 'activeTimeFilter',\r\n title: 'igo.integration.tools.timeFilter',\r\n icon: 'history',\r\n parent: 'mapTools'\r\n})\r\n@Component({\r\n selector: 'igo-active-time-filter-tool',\r\n templateUrl: './active-time-filter-tool.component.html',\r\n animations: [toolSlideInOut()]\r\n})\r\nexport class ActiveTimeFilterToolComponent {\r\n\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n\r\n get layer(): Layer {\r\n for (const lay of this.map.layers) {\r\n if (lay.options.active === true) {\r\n return lay;\r\n }\r\n }\r\n return;\r\n }\r\n\r\n public animate = 'enter';\r\n\r\n constructor(public mapState: MapState) {}\r\n}\r\n","<igo-time-filter-item\r\n [map]=\"map\"\r\n [layer]=\"layer\"\r\n [header]=\"false\"\r\n [@toolSlideInOut]=\"animate\">\r\n</igo-time-filter-item>\r\n","import {\r\n trigger,\r\n state,\r\n style,\r\n transition,\r\n animate,\r\n AnimationTriggerMetadata\r\n} from '@angular/animations';\r\n\r\nexport function toolSlideInOut(\r\n speed = '300ms',\r\n type = 'ease-in-out'\r\n): AnimationTriggerMetadata {\r\n return trigger('toolSlideInOut', [\r\n state(\r\n 'enter',\r\n style({\r\n transform: 'translateX(100%)'\r\n })\r\n ),\r\n transition('void => enter', animate(speed + ' ' + type))\r\n ]);\r\n}\r\n","import { Component } from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport { MapState } from '../../map/map.state';\r\nimport { Layer, IgoMap } from '@igo2/geo';\r\n\r\nimport { toolSlideInOut } from './active-ogc-filter-tool.animation';\r\n\r\n@ToolComponent({\r\n name: 'activeOgcFilter',\r\n title: 'igo.integration.tools.ogcFilter',\r\n icon: 'filter',\r\n parent: 'mapTools'\r\n})\r\n@Component({\r\n selector: 'igo-active-ogc-filter-tool',\r\n templateUrl: './active-ogc-filter-tool.component.html',\r\n animations: [toolSlideInOut()]\r\n})\r\nexport class ActiveOgcFilterToolComponent {\r\n\r\n get map(): IgoMap {\r\n return this.mapState.map;\r\n }\r\n\r\n get layer(): Layer {\r\n for (const lay of this.map.layers) {\r\n if (lay.options.active === true) {\r\n return lay;\r\n }\r\n }\r\n return;\r\n }\r\n\r\n public animate = 'enter';\r\n\r\n constructor(public mapState: MapState) {}\r\n}\r\n","<igo-ogc-filterable-item\r\n [map]=\"map\"\r\n [layer]=\"layer\"\r\n [header]=\"false\"\r\n [@toolSlideInOut]=\"animate\">\r\n</igo-ogc-filterable-item>\r\n\r\n\r\n","import {\r\n NgModule,\r\n ModuleWithProviders,\r\n CUSTOM_ELEMENTS_SCHEMA\r\n} from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\n\r\nimport { IgoFilterModule, IgoQueryModule } from '@igo2/geo';\r\nimport { OgcFilterToolComponent } from './ogc-filter-tool/ogc-filter-tool.component';\r\nimport { TimeFilterToolComponent } from './time-filter-tool/time-filter-tool.component';\r\nimport { SpatialFilterToolComponent } from './spatial-filter-tool/spatial-filter-tool.component';\r\nimport { ActiveTimeFilterToolComponent } from './active-time-filter-tool/active-time-filter-tool.component';\r\nimport { ActiveOgcFilterToolComponent } from './active-ogc-filter-tool/active-ogc-filter-tool.component';\r\n\r\n@NgModule({\r\n imports: [IgoFilterModule, IgoQueryModule, CommonModule],\r\n declarations: [\r\n OgcFilterToolComponent,\r\n ActiveOgcFilterToolComponent,\r\n TimeFilterToolComponent,\r\n ActiveTimeFilterToolComponent,\r\n SpatialFilterToolComponent\r\n ],\r\n exports: [\r\n OgcFilterToolComponent,\r\n ActiveOgcFilterToolComponent,\r\n TimeFilterToolComponent,\r\n ActiveTimeFilterToolComponent,\r\n SpatialFilterToolComponent\r\n ],\r\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\r\n})\r\nexport class IgoAppFilterModule {\r\n static forRoot(): ModuleWithProviders<IgoAppFilterModule> {\r\n return {\r\n ngModule: IgoAppFilterModule,\r\n providers: []\r\n };\r\n }\r\n}\r\n","<p></p>\r\n<igo-interactive-tour\r\n mat-raised-button\r\n tourToStart=\"global\"\r\n menuIsOpen=true\r\n styleButton=\"raised\"\r\n [discoverTitleInLocale$]=\"discoverTitleInLocale$\">\r\n</igo-interactive-tour>\r\n\r\n<button *ngIf=\"auth.authenticated && trainingGuideURLs && trainingGuideURLs.length === 1\"\r\n class=\"training-guide-button\"\r\n mat-raised-button\r\n tooltip-position=\"below\"\r\n matTooltipShowDelay=\"500\"\r\n [disabled]=\"loading\"\r\n [matTooltip]=\"'igo.integration.aboutTool.trainingGuideTooltip' | translate\"\r\n (click)=\"openGuide()\">\r\n <span>{{'igo.integration.aboutTool.trainingGuide' | translate}}</span>\r\n <mat-icon svgIcon=\"file-document\"></mat-icon>\r\n</button>\r\n\r\n<button *ngIf=\"auth.authenticated && trainingGuideURLs && trainingGuideURLs.length > 1\"\r\n class=\"training-guide-button\"\r\n mat-raised-button\r\n tooltip-position=\"below\"\r\n matTooltipShowDelay=\"500\"\r\n [disabled]=\"loading\"\r\n [matTooltip]=\"'igo.integration.aboutTool.trainingGuideTooltip' | translate\"\r\n [matMenuTriggerFor]=\"menu\">\r\n <span>{{'igo.integration.aboutTool.trainingGuide' | translate}}</span>\r\n <mat-icon svgIcon=\"file-document\"></mat-icon>\r\n</button>\r\n\r\n<mat-menu #menu=\"matMenu\">\r\n <button *ngFor=\"let guide of trainingGuideURLs\" mat-menu-item (click)=\"openGuide(guide)\">{{formatFileName(guide)}}</button>\r\n</mat-menu>\r\n\r\n<igo-custom-html *ngIf=\"headerHtml !== ''\" class=\"mat-typography\"\r\n [html]=\"headerHtml | translate\">\r\n</igo-custom-html>\r\n\r\n<igo-custom-html class=\"mat-typography\"\r\n [html]=\"html | translate: {version: version}\">\r\n</igo-custom-html>\r\n","import { ChangeDetectorRef, Component, Input, OnInit } from '@angular/core';\r\n\r\nimport { ToolComponent } from '@igo2/common';\r\nimport { ConfigService, LanguageService, Version } from '@igo2/core';\r\nimport { of } from 'rxjs';\r\nimport type { Observable } from 'rxjs';\r\nimport { AuthService } from '@igo2/auth';\r\nimport { HttpClient } from '@angular/common/http';\r\n\r\n@ToolComponent({\r\n name: 'about',\r\n title: 'igo.integration.tools.about',\r\n icon: 'help-circle'\r\n})\r\n@Component({\r\n selector: 'igo-about-tool',\r\n templateUrl: './about-tool.component.html',\r\n styleUrls: ['./about-tool.component.scss']\r\n})\r\nexport class AboutToolComponent implements OnInit {\r\n @Input()\r\n get headerHtml() {\r\n return this._headerHtml;\r\n }\r\n set headerHtml(value: string) {\r\n this._headerHtml = Array.isArray(value) ? value.join('\\n') : value;\r\n }\r\n\r\n @Input()\r\n get html() {\r\n return this._html;\r\n }\r\n set html(value: string) {\r\n this._html = Array.isArray(value) ? value.join('\\n') : value;\r\n }\r\n private _discoverTitleInLocale: string = 'IGO';\r\n public discoverTitleInLocale$: Observable<string> = of(this._discoverTitleInLocale);\r\n\r\n @Input()\r\n get discoverTitleInLocale() {\r\n return this._discoverTitleInLocale;\r\n }\r\n set discoverTitleInLocale(value: string) {\r\n this._discoverTitleInLocale = value;\r\n this.discoverTitleInLocale$ = of(value);\r\n }\r\n\r\n @Input() trainingGuideURLs;\r\n\r\n public version: Version;\r\n private _html: string = 'igo.integration.aboutTool.html';\r\n private _headerHtml: string = this.languageService.translate.instant('igo.integration.aboutTool.headerHtml');\r\n\r\n private baseUrlProfil;\r\n private baseUrlGuide;\r\n\r\n public loading = false;\r\n\r\n constructor(\r\n public configService: ConfigService,\r\n public auth: AuthService,\r\n private http: HttpClient,\r\n private cdRef: ChangeDetectorRef,\r\n private languageService: LanguageService) {\r\n this.version = configService.getConfig('version');\r\n this.baseUrlProfil = configService.getConfig('storage.url');\r\n this.baseUrlGuide = configService.getConfig('depot.url') + configService.getConfig('depot.guideUrl');\r\n }\r\n\r\n ngOnInit() {\r\n if (this.auth.authenticated && this.configService.getConfig('context.url')) {\r\n this.http.get(this.baseUrlProfil).subscribe((profil) => {\r\n const recast = profil as any;\r\n this.trainingGuideURLs = recast.guides;\r\n this.cdRef.detectChanges();\r\n });\r\n } else if (\r\n this.auth.authenticated &&\r\n !this.configService.getConfig('context.url') &&\r\n this.configService.getConfig('depot.trainingGuides')) {\r\n this.trainingGuideURLs = this.configService.getConfig('depot.trainingGuides');\r\n }\r\n }\r\n\r\n openGuide(guide?) {\r\n this.loading = true;\r\n const url = guide ?\r\n this.baseUrlGuide + guide + '?' :\r\n this.baseUrlGuide + this.trainingGuideURLs[0] + '?';\r\n this.http\r\n .get(url, {\r\n responseType: 'blob'\r\n })\r\n .subscribe(() => {\r\n this.loading = false;\r\n window.open(url, '_blank');\r\n this.cdRef.detectChanges();\r\n });\r\n }\r\n\r\n formatFileName(name: string) {\r\n name = name.split('_').join(' ');\r\n const index = name.indexOf('.');\r\n name = name.slice(0, index);\r\n return name;\r\n }\r\n}\r\n","import {\r\n NgModule,\r\n ModuleWithProviders,\r\n CUSTOM_ELEMENTS_SCHEMA\r\n} from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { MatTooltipModule } from '@angular/material/tooltip';\r\nimport { MatButtonModule } from '@angular/material/button';\r\nimport { MatIconModule } from '@angular/material/icon';\r\nimport { MatMenuModule } from '@angular/material/menu';\r\n\r\nimport { IgoLanguageModule } from '@igo2/core';\r\nimport { IgoCustomHtmlModule, IgoInteractiveTourModule } from '@igo2/common';\r\n\r\nimport { AboutToolComponent } from './about-tool/about-tool.component';\r\n\r\n@NgModule({\r\n imports: [\r\n IgoLanguageModule,\r\n IgoCustomHtmlModule,\r\n MatButtonModule,\r\n MatTooltipModule,\r\n MatIconModule,\r\n MatMenuModule,\r\n IgoInteractiveTourModule,\r\n CommonModule\r\n ],\r\n declarations: [AboutToolComponent],\r\n exports: [AboutToolComponent],\r\n schemas: [CUSTOM_ELEMENTS_SCHEMA]\r\n})\r\nexport class IgoAppAboutModule {\r\n static forRoot(): ModuleWithProviders<IgoAppAboutModule> {\r\n return {\r\n ngModule: IgoAppAboutModule,\r\n providers: []\r\n };\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\n\r\n@NgModule({\r\n imports: [],\r\n declarations: [],\r\n exports: []\r\n})\r\nexport class IgoAppStorageModule {}\r\n","import { NgModule } from '@angular/core';\r\n\r\nimport { IgoAppAnalyticsModule } from './analytics/analytics.module';\r\nimport { IgoAppContextModule } from './context/context.module';\r\nimport { IgoAppCatalogModule } from './catalog/catalog.module';\r\nimport { IgoAppDirectionsModule } from './directions/directions.module';\r\nimport { IgoAppDrawModule } from './draw/draw.module';\r\nimport { IgoAppWorkspaceModule } from './workspace/workspace.module';\r\nimport { IgoAppImportExportModule } from './import-export/import-export.module';\r\nimport { IgoAppMapModule } from './map/map.module';\r\nimport { IgoAppMeasureModule } from './measure/measure.module';\r\nimport { IgoAppPrintModule } from './print/print.module';\r\nimport { IgoAppSearchModule } from './search/search.module';\r\nimport { IgoAppFilterModule } from './filter/filter.module';\r\nimport { IgoAppAboutModule } from './about/about.module';\r\nimport { IgoAppStorageModule } from './storage/storage.module';\r\n\r\n@NgModule({\r\n imports: [],\r\n declarations: [],\r\n exports: [\r\n IgoAppStorageModule,\r\n IgoAppAnalyticsModule,\r\n IgoAppContextModule,\r\n IgoAppCatalogModule,\r\n IgoAppDirectionsModule,\r\n IgoAppDrawModule,\r\n IgoAppWorkspaceModule,\r\n IgoAppImportExportModule,\r\n IgoAppMapModule,\r\n IgoAppMeasureModule,\r\n IgoAppPrintModule,\r\n IgoAppSearchModule,\r\n IgoAppFilterModule,\r\n IgoAppAboutModule\r\n ]\r\n})\r\nexport class IgoIntegrationModule {}\r\n","import { NgModule } from '@angular/core';\r\n\r\n@NgModule({\r\n imports: [],\r\n declarations: [],\r\n exports: []\r\n})\r\nexport class IgoAppToolModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { skip } from 'rxjs/operators';\r\n\r\nimport { AnalyticsService } from '@igo2/core';\r\nimport { AuthService } from '@igo2/auth';\r\n\r\nimport { ContextState } from '../context/context.state';\r\nimport { SearchState } from '../search/search.state';\r\nimport { ToolState } from '../tool/tool.state';\r\n\r\n/**\r\n * Service that holds the state of the search module\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class AnalyticsListenerService {\r\n /**\r\n * Toolbox that holds main tools\r\n */\r\n\r\n constructor(\r\n private analyticsService: AnalyticsService,\r\n private authService: AuthService,\r\n private contextState: ContextState,\r\n private searchState: SearchState,\r\n private toolState: ToolState\r\n ) {}\r\n\r\n listen() {\r\n this.listenUser();\r\n this.listenContext();\r\n this.listenTool();\r\n this.listenSearch();\r\n }\r\n\r\n listenUser() {\r\n this.authService.authenticate$.subscribe(() => {\r\n const tokenDecoded = this.authService.decodeToken() || {};\r\n if (tokenDecoded.user) {\r\n this.authService\r\n .getProfils()\r\n .subscribe(profils =>\r\n this.analyticsService.setUser(tokenDecoded.user, profils.profils)\r\n );\r\n } else {\r\n this.analyticsService.setUser();\r\n }\r\n });\r\n }\r\n\r\n listenContext() {\r\n this.contextState.context$.subscribe(context => {\r\n if (context) {\r\n this.analyticsService.trackEvent('context', 'activateContext', context.id || context.uri);\r\n }\r\n });\r\n }\r\n\r\n listenTool() {\r\n this.toolState.toolbox.activeTool$.pipe(skip(1)).subscribe(tool => {\r\n if (tool) {\r\n this.analyticsService.trackEvent('tool', 'activateTool', tool.name);\r\n }\r\n });\r\n }\r\n\r\n listenSearch() {\r\n this.searchState.searchTerm$.pipe(skip(1)).subscribe((searchTerm: string) => {\r\n if (searchTerm !== undefined && searchTerm !== null) {\r\n this.analyticsService.trackSearch(searchTerm, this.searchState.store.count);\r\n }\r\n });\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\nimport { EntityStore } from '@igo2/common';\r\nimport { ConfigService } from '@igo2/core';\r\nimport { CommonVectorStyleOptions, SearchResult } from '@igo2/geo';\r\n\r\n/**\r\n * Service that holds the state of the query module\r\n */\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class QueryState {\r\n /**\r\n * Store that holds the query results\r\n */\r\n public store: EntityStore<SearchResult> = new EntityStore<SearchResult>([]);\r\n public queryOverlayStyle: CommonVectorStyleOptions = {};\r\n public queryOverlayStyleSelection: CommonVectorStyleOptions = {};\r\n public queryOverlayStyleFocus: CommonVectorStyleOptions = {};\r\n\r\n constructor(private configService: ConfigService) {\r\n const queryOverlayStyle = this.configService.getConfig('queryOverlayStyle') as {\r\n base?: CommonVectorStyleOptions,\r\n selection?: CommonVectorStyleOptions,\r\n focus?: CommonVectorStyleOptions\r\n };\r\n if (queryOverlayStyle) {\r\n this.queryOverlayStyle = queryOverlayStyle.base;\r\n this.queryOverlayStyleSelection = queryOverlayStyle.selection;\r\n this.queryOverlayStyleFocus = queryOverlayStyle.focus;\r\n }\r\n }\r\n}\r\n","/*\r\n * Public API Surface of tools\r\n */\r\n\r\nexport * from './lib/integration.module';\r\nexport * from './lib/about/about.module';\r\nexport * from './lib/analytics/analytics.module';\r\nexport * from './lib/storage/storage.module';\r\nexport * from './lib/context/context.module';\r\nexport * from './lib/catalog/catalog.module';\r\n\r\nexport * from './lib/directions/directions.module';\r\nexport * from './lib/draw/draw.module';\r\nexport * from './lib/workspace/workspace.module';\r\nexport * from './lib/filter/filter.module';\r\nexport * from './lib/import-export/import-export.module';\r\nexport * from './lib/map/map.module';\r\nexport * from './lib/measure/measure.module';\r\nexport * from './lib/print/print.module';\r\nexport * from './lib/search/search.module';\r\nexport * from './lib/tool/tool.module';\r\n\r\nexport * from './lib/about';\r\nexport * from './lib/analytics';\r\nexport * from './lib/context';\r\nexport * from './lib/catalog';\r\nexport * from './lib/directions';\r\nexport * from './lib/draw';\r\nexport * from './lib/workspace';\r\nexport * from './lib/filter';\r\nexport * from './lib/import-export';\r\nexport * from './lib/map';\r\nexport * from './lib/measure';\r\nexport * from './lib/print';\r\nexport * from './lib/search';\r\nexport * from './lib/tool';\r\nexport * from './lib/storage';\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["olproj","GeoJSON","toolSlideInOut"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAOa,qBAAqB;;0FAArB,qBAAqB;uEAArB,qBAAqB;2EAJvB,EAAE;uFAIA,qBAAqB;cALjC,QAAQ;eAAC;gBACR,OAAO,EAAE,EAAE;gBACX,YAAY,EAAE,EAAE;gBAChB,OAAO,EAAE,EAAE;aACZ;;;ICDW;AAAZ,WAAY,gBAAgB;IAC1B,mCAAe,CAAA;IACf,uCAAmB,CAAA;AACrB,CAAC,EAHW,gBAAgB,KAAhB,gBAAgB,QAG3B;IAEW;AAAZ,WAAY,gBAAgB;IAC1B,qCAAiB,CAAA;IACjB,qCAAiB,CAAA;AACnB,CAAC,EAHW,gBAAgB,KAAhB,gBAAgB,QAG3B;AAED;;;MAMa,iBAAiB;IAH9B;QAKW,sBAAiB,GAAsC,IAAI,eAAe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