@igo2/geo 19.0.0-next.3 → 19.0.0-next.30

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.
Files changed (105) hide show
  1. package/fesm2022/igo2-geo.mjs +3491 -2628
  2. package/fesm2022/igo2-geo.mjs.map +1 -1
  3. package/lib/catalog/catalog-library/add-catalog-dialog.component.d.ts +10 -16
  4. package/lib/catalog/catalog-library/catalog-library-item.component.d.ts +3 -3
  5. package/lib/catalog/catalog-library/catalog-library.component.d.ts +4 -3
  6. package/lib/catalog/catalog-library/catalog-library.module.d.ts +4 -4
  7. package/lib/catalog/catalog.module.d.ts +2 -2
  8. package/lib/datasource/shared/capabilities.service.d.ts +2 -1
  9. package/lib/datasource/shared/datasource.service.d.ts +5 -2
  10. package/lib/datasource/shared/datasources/datasource.d.ts +21 -3
  11. package/lib/datasource/shared/datasources/datasource.interface.d.ts +5 -0
  12. package/lib/datasource/shared/datasources/wfs-datasource.d.ts +4 -1
  13. package/lib/datasource/shared/datasources/wfs-datasource.interface.d.ts +1 -1
  14. package/lib/datasource/shared/datasources/wms-datasource.d.ts +16 -4
  15. package/lib/datasource/shared/datasources/wms-datasource.interface.d.ts +1 -0
  16. package/lib/datasource/shared/datasources/wms-wfs.utils.d.ts +3 -2
  17. package/lib/datasource/shared/options/options-api.service.d.ts +1 -0
  18. package/lib/directions/shared/directions.service.d.ts +0 -1
  19. package/lib/feature/shared/feature.interfaces.d.ts +4 -5
  20. package/lib/feature/shared/feature.utils.d.ts +1 -1
  21. package/lib/filter/ogc-filter-time/ogc-filter-time.component.d.ts +1 -0
  22. package/lib/filter/shared/date.utils.d.ts +9 -0
  23. package/lib/filter/shared/filter.utils.d.ts +26 -0
  24. package/lib/filter/shared/ogc-filter.d.ts +0 -7
  25. package/lib/filter/shared/ogc-filter.interface.d.ts +9 -2
  26. package/lib/filter/shared/ogc-filter.service.d.ts +4 -2
  27. package/lib/filter/shared/time-filter.interface.d.ts +2 -2
  28. package/lib/filter/time-filter-form/time-filter-form.component.d.ts +10 -5
  29. package/lib/filter/time-filter-item/time-filter-item.component.d.ts +1 -0
  30. package/lib/geometry/shared/geometry.utils.d.ts +5 -0
  31. package/lib/import-export/shared/export.service.d.ts +1 -1
  32. package/lib/layer/shared/layer.service.d.ts +2 -4
  33. package/lib/layer/shared/layers/image-layer.d.ts +2 -2
  34. package/lib/layer/shared/layers/layer-group.d.ts +1 -0
  35. package/lib/layer/shared/layers/linked/linked-layer.d.ts +1 -0
  36. package/lib/layer/shared/layers/linked/linked-layer.interface.d.ts +2 -1
  37. package/lib/layer/shared/layers/vector-layer.d.ts +17 -27
  38. package/lib/layer/shared/layers/vector-layer.interface.d.ts +3 -2
  39. package/lib/layer/utils/image-watcher.d.ts +2 -2
  40. package/lib/layer/utils/index.d.ts +1 -0
  41. package/lib/layer/utils/layer-options.utils.d.ts +12 -0
  42. package/lib/map/baselayers-switcher/mini-basemap.component.d.ts +2 -4
  43. package/lib/offline/geoDB/configFileToGeoDB.service.d.ts +2 -4
  44. package/lib/offline/geoDB/geoDB.d.ts +36 -0
  45. package/lib/offline/geoDB/index.d.ts +1 -1
  46. package/lib/offline/layerDB/index.d.ts +1 -1
  47. package/lib/offline/layerDB/{layerDB.service.d.ts → layerDB.d.ts} +9 -11
  48. package/lib/offline/offline.provider.d.ts +2 -0
  49. package/lib/offline/shared/geo-network.service.d.ts +2 -4
  50. package/lib/offline/shared/indexed-db.interface.d.ts +16 -0
  51. package/lib/offline/shared/indexed-db.utils.d.ts +4 -0
  52. package/lib/query/shared/query-search-source.d.ts +1 -1
  53. package/lib/search/search-bar/search-bar.component.d.ts +2 -1
  54. package/lib/search/search-settings/search-settings.component.d.ts +8 -2
  55. package/lib/search/shared/sources/cadastre.d.ts +1 -1
  56. package/lib/search/shared/sources/coordinates.d.ts +1 -1
  57. package/lib/search/shared/sources/icherche.d.ts +4 -2
  58. package/lib/search/shared/sources/ilayer.d.ts +1 -1
  59. package/lib/search/shared/sources/nominatim.d.ts +1 -1
  60. package/lib/search/shared/sources/source.d.ts +3 -1
  61. package/lib/search/shared/sources/storedqueries.d.ts +2 -2
  62. package/lib/search/shared/sources/workspace.d.ts +1 -1
  63. package/lib/workspace/shared/edition-workspace.service.d.ts +2 -1
  64. package/lib/workspace/shared/index.d.ts +1 -0
  65. package/lib/workspace/shared/workspace.interface.d.ts +4 -0
  66. package/lib/workspace/widgets/interactive-selection/interactive-selection.component.d.ts +58 -0
  67. package/lib/workspace/widgets/widgets.d.ts +7 -0
  68. package/lib/workspace/workspace-selector/workspace-selector.directive.d.ts +3 -0
  69. package/locale/en.geo.json +33 -4
  70. package/locale/fr.geo.json +32 -3
  71. package/package.json +23 -20
  72. package/src/geo.theme.scss +15 -0
  73. package/src/lib/catalog/catalog-browser/catalog-browser.theming.scss +1 -1
  74. package/src/lib/directions/directions-inputs/directions-inputs.theming.scss +2 -2
  75. package/src/lib/directions/directions.theming.scss +2 -5
  76. package/src/lib/draw/draw.theming.scss +2 -17
  77. package/src/lib/layer/layer-legend/layer-legend.theme.scss +1 -10
  78. package/src/lib/layer/layer-list-tool/layer-list-tool.theming.scss +1 -13
  79. package/src/lib/layer/layer.theming.scss +1 -13
  80. package/src/lib/map/map-browser/map-browser.theming.scss +2 -28
  81. package/src/lib/map/map.theming.scss +2 -6
  82. package/src/lib/search/search-bar/search-bar.theming.scss +0 -24
  83. package/src/lib/search/search.theming.scss +1 -3
  84. package/style/style.css +4 -0
  85. package/lib/offline/geoDB/geoDB.service.d.ts +0 -36
  86. package/src/geo-theme.scss +0 -23
  87. package/src/lib/directions/directions-results/directions-results.theming.scss +0 -10
  88. package/src/lib/feature/feature-details/feature-details.theming.scss +0 -16
  89. package/src/lib/feature/feature.theming.scss +0 -4
  90. package/src/lib/filter/filter.theming.scss +0 -13
  91. package/src/lib/filter/ogc-filter-selection/ogc-filter-selection.theming.scss +0 -18
  92. package/src/lib/filter/time-filter-form/time-filter-form.theming.scss +0 -5
  93. package/src/lib/layer/layer-group/layer-group.theme.scss +0 -28
  94. package/src/lib/layer/layer-item/layer-item.theme.scss +0 -36
  95. package/src/lib/layer/layer-list/layer-list.theme.scss +0 -51
  96. package/src/lib/layer/layer-unavailable/layer-unavailable.theme.scss +0 -19
  97. package/src/lib/layer/layer-viewer/_layer-viewer.theme.scss +0 -16
  98. package/src/lib/layer/layer-visibility-button/layer-visibility-button.theme.scss +0 -27
  99. package/src/lib/map/menu-button/menu-button.theming.scss +0 -20
  100. package/src/lib/map/zoom-button/zoom-button.theming.scss +0 -32
  101. package/src/lib/measure/measure.theming.scss +0 -5
  102. package/src/lib/measure/measurer/measurer.theming.scss +0 -26
  103. package/src/lib/search/search-results/search-results-item.theme.scss +0 -20
  104. package/src/lib/workspace/confirmation-popup/confirmation-popup.theming.scss +0 -14
  105. package/src/lib/workspace/workspace.theming.scss +0 -6
@@ -4,7 +4,6 @@ import { MessageService } from '@igo2/core/message';
4
4
  import { Observable } from 'rxjs';
5
5
  import { DataSourceService } from '../../datasource/shared/datasource.service';
6
6
  import { AnyDataSourceOptions, AnyDataSourceOptionsWithParams, ArcGISRestDataSourceOptions, WMTSDataSourceOptions } from '../../datasource/shared/datasources';
7
- import { LayerDBService } from '../../offline/layerDB/layerDB.service';
8
7
  import { GeoNetworkService } from '../../offline/shared/geo-network.service';
9
8
  import { StyleService } from '../../style/style-service/style.service';
10
9
  import { AnyLayer, AnyLayerItemOptions, AnyLayerOptions, Layer, LayerGroupOptions } from './layers';
@@ -16,10 +15,9 @@ export declare class LayerService {
16
15
  private dataSourceService;
17
16
  private messageService;
18
17
  private geoNetworkService?;
19
- private layerDBService?;
20
18
  private authInterceptor?;
21
19
  unavailableLayers: AnyLayerItemOptions[];
22
- constructor(http: HttpClient, styleService: StyleService, dataSourceService: DataSourceService, messageService: MessageService, geoNetworkService?: GeoNetworkService, layerDBService?: LayerDBService, authInterceptor?: AuthInterceptor);
20
+ constructor(http: HttpClient, styleService: StyleService, dataSourceService: DataSourceService, messageService: MessageService, geoNetworkService?: GeoNetworkService, authInterceptor?: AuthInterceptor);
23
21
  createLayers(layersOption: AnyLayerOptions[], contextUri?: string): Observable<(AnyLayer | undefined)[]>;
24
22
  createLayer(layerOptions: AnyLayerItemOptions): Layer;
25
23
  createAsyncLayer(options: AnyLayerItemOptions, detailedContextUri?: string): Observable<Layer | undefined>;
@@ -37,6 +35,6 @@ export declare class LayerService {
37
35
  deleteUnavailableLayers(anyLayerOptions: AnyLayerItemOptions): void;
38
36
  sourceOptionsWithParams(sourceOptions: AnyDataSourceOptions): sourceOptions is AnyDataSourceOptionsWithParams;
39
37
  sourceOptionsWithLayer(sourceOptions: AnyDataSourceOptions): sourceOptions is ArcGISRestDataSourceOptions | WMTSDataSourceOptions;
40
- static ɵfac: i0.ɵɵFactoryDeclaration<LayerService, [null, null, null, null, { optional: true; }, { optional: true; }, { optional: true; }]>;
38
+ static ɵfac: i0.ɵɵFactoryDeclaration<LayerService, [null, null, null, null, { optional: true; }, { optional: true; }]>;
41
39
  static ɵprov: i0.ɵɵInjectableDeclaration<LayerService>;
42
40
  }
@@ -9,14 +9,14 @@ import { ImageLayerOptions } from './image-layer.interface';
9
9
  import { Layer } from './layer';
10
10
  import { LayerType } from './layer.interface';
11
11
  export declare class ImageLayer extends Layer {
12
- messageService: MessageService;
12
+ messageService?: MessageService;
13
13
  authInterceptor?: AuthInterceptor;
14
14
  type: LayerType;
15
15
  dataSource: WMSDataSource | ImageArcGISRestDataSource;
16
16
  options: ImageLayerOptions;
17
17
  ol: olLayerImage<olSourceImage>;
18
18
  private watcher;
19
- constructor(options: ImageLayerOptions, messageService: MessageService, authInterceptor?: AuthInterceptor);
19
+ constructor(options: ImageLayerOptions, messageService?: MessageService, authInterceptor?: AuthInterceptor);
20
20
  protected createOlLayer(): olLayerImage<olSourceImage>;
21
21
  init(map: MapBase | undefined): void;
22
22
  remove(): void;
@@ -4,6 +4,7 @@ import type { MapBase } from '../../../map/shared/map.abstract';
4
4
  import { type AnyLayer } from './any-layer';
5
5
  import { LayerGroupBase } from './layer-base';
6
6
  import { type LayerGroupOptions } from './layer-group.interface';
7
+ export declare const ID_GROUP_PREFIX = "local-group_";
7
8
  export declare class LayerGroup extends LayerGroupBase {
8
9
  children: AnyLayer[] | null;
9
10
  options: LayerGroupOptions;
@@ -32,4 +32,5 @@ export declare class Linked {
32
32
  private handleChange;
33
33
  private handleDisplayChange;
34
34
  private findChildren;
35
+ private handleRefreshChanges;
35
36
  }
@@ -27,6 +27,7 @@ export declare enum LinkedProperties {
27
27
  MINRESOLUTION = "minResolution",
28
28
  MAXRESOLUTION = "maxResolution",
29
29
  ZINDEX = "zIndex",
30
- TIMEFILTER = "timeFilter"
30
+ TIMEFILTER = "timeFilter",
31
+ REFRESH = "refresh"
31
32
  }
32
33
  export {};
@@ -1,6 +1,6 @@
1
1
  import { AuthInterceptor } from '@igo2/auth';
2
2
  import { MessageService } from '@igo2/core/message';
3
- import olFeature from 'ol/Feature';
3
+ import OlFeature from 'ol/Feature';
4
4
  import { Extent } from 'ol/extent';
5
5
  import olLayerVector from 'ol/layer/Vector';
6
6
  import olProjection from 'ol/proj/Projection';
@@ -11,10 +11,7 @@ import { FeatureDataSource } from '../../../datasource/shared/datasources/featur
11
11
  import { WebSocketDataSource } from '../../../datasource/shared/datasources/websocket-datasource';
12
12
  import { WFSDataSource } from '../../../datasource/shared/datasources/wfs-datasource';
13
13
  import { WFSDataSourceOptions } from '../../../datasource/shared/datasources/wfs-datasource.interface';
14
- import type { MapBase } from '../../../map/shared/map.abstract';
15
- import { MapExtent } from '../../../map/shared/map.interface';
16
- import { GeoDBService } from '../../../offline/geoDB/geoDB.service';
17
- import { LayerDBService } from '../../../offline/layerDB/layerDB.service';
14
+ import type { MapBase, MapExtent } from '../../../map/shared';
18
15
  import { GeoNetworkService } from '../../../offline/shared/geo-network.service';
19
16
  import { Layer } from './layer';
20
17
  import { LayerType } from './layer.interface';
@@ -23,13 +20,9 @@ export declare class VectorLayer extends Layer {
23
20
  messageService?: MessageService;
24
21
  authInterceptor?: AuthInterceptor;
25
22
  private geoNetworkService?;
26
- geoDBService?: GeoDBService;
27
- layerDBService?: LayerDBService;
28
23
  type: LayerType;
29
- private previousLoadExtent;
30
- private previousLoadResolution;
31
- private previousOgcFilters;
32
- private xhrAccumulator;
24
+ private lastRequest;
25
+ private ongoingRequests;
33
26
  dataSource: FeatureDataSource | WFSDataSource | ArcGISRestDataSource | WebSocketDataSource | ClusterDataSource;
34
27
  options: VectorLayerOptions;
35
28
  ol: olLayerVector<olSourceVector>;
@@ -37,27 +30,30 @@ export declare class VectorLayer extends Layer {
37
30
  private trackFeatureListenerId;
38
31
  get browsable(): boolean;
39
32
  get exportable(): boolean;
40
- constructor(options: VectorLayerOptions, messageService?: MessageService, authInterceptor?: AuthInterceptor, geoNetworkService?: GeoNetworkService, geoDBService?: GeoDBService, layerDBService?: LayerDBService);
33
+ constructor(options: VectorLayerOptions, messageService?: MessageService, authInterceptor?: AuthInterceptor, geoNetworkService?: GeoNetworkService);
41
34
  protected createOlLayer(): olLayerVector<olSourceVector>;
35
+ private handleIdbStorage;
36
+ private handlePreload;
42
37
  remove(): void;
43
38
  private removeLayerFromIDB;
44
39
  private maintainOptionsInIdb;
45
40
  private maintainFeaturesInIdb;
46
- protected flash(feature: any): void;
41
+ protected flash(feature: OlFeature): void;
47
42
  init(map: MapBase | undefined): void;
48
43
  setExtent(extent: MapExtent): void;
49
44
  onUnwatch(): void;
50
45
  stopAnimation(): void;
51
46
  enableTrackFeature(id: string | number): void;
52
47
  centerMapOnFeature(id: string | number): void;
53
- trackFeature(id: any, feat: any): void;
48
+ trackFeature(id: string | number, feat: {
49
+ feature: OlFeature;
50
+ }): void;
54
51
  disableTrackFeature(): void;
55
52
  /**
56
53
  * Custom loader for a WFS datasource
57
54
  * @internal
58
55
  * @param vectorSource the vector source to be created
59
56
  * @param options olOptions from source
60
- * @param interceptor the interceptor of the data
61
57
  * @param extent the extent of the requested data
62
58
  * @param resolution the current resolution
63
59
  * @param proj the projection to retrieve the data
@@ -65,7 +61,10 @@ export declare class VectorLayer extends Layer {
65
61
  * @param failure failure callback
66
62
  * @param randomParam random parameter to ensure cache is not causing problems in retrieving new data
67
63
  */
68
- customWFSLoader(vectorSource: olSourceVector, options: WFSDataSourceOptions, interceptor: AuthInterceptor, extent: Extent, resolution: number, proj: olProjection, success: (features: olFeature[]) => void, failure: () => void, randomParam?: boolean): void;
64
+ customWFSLoader(vectorSource: olSourceVector, options: WFSDataSourceOptions, extent: Extent, resolution: number, proj: olProjection, success: (features: OlFeature[]) => void, failure: () => void, randomParam?: boolean): void;
65
+ private abortRequests;
66
+ private getProjection;
67
+ private batchGetFeatures;
69
68
  /**
70
69
  * Custom loader to get feature from a WFS datasource
71
70
  * @internal
@@ -78,24 +77,15 @@ export declare class VectorLayer extends Layer {
78
77
  * @param failure failure callback
79
78
  */
80
79
  private getFeatures;
80
+ private removeRequest;
81
+ private handleOnLoad;
81
82
  /**
82
83
  * Custom loader for vector layer.
83
84
  * @internal
84
85
  * @param vectorSource the vector source to be created
85
86
  * @param url the url string or function to retrieve the data
86
87
  * @param extent the extent of the requested data
87
- * @param resolution the current resolution
88
88
  * @param projection the projection to retrieve the data
89
89
  */
90
90
  private customLoader;
91
- /**
92
- * Custom loader for vector layer.
93
- * @internal
94
- * @param vectorSource the vector source to be created
95
- * @param layerID the url string or function to retrieve the data
96
- * @param extent the extent of the requested data
97
- * @param resolution the current resolution
98
- * @param projection the projection to retrieve the data
99
- */
100
- private customIDBLoader;
101
91
  }
@@ -32,8 +32,9 @@ export interface VectorLayerOptions extends LayerOptions {
32
32
  }
33
33
  export interface IdbInfo {
34
34
  storeToIdb: boolean;
35
- contextUri: string;
36
- firstLoad: boolean;
35
+ contextUri?: string;
36
+ /** Interface restricted for system usage. You don't need to set a value */
37
+ firstLoad?: boolean;
37
38
  }
38
39
  export interface VectorAnimation {
39
40
  duration?: number;
@@ -2,12 +2,12 @@ import { MessageService } from '@igo2/core/message';
2
2
  import { Watcher } from '@igo2/utils';
3
3
  import type { ImageLayer } from '../shared/layers/image-layer';
4
4
  export declare class ImageWatcher extends Watcher {
5
+ private messageService?;
5
6
  protected id: string;
6
7
  protected loaded: number;
7
8
  protected loading: number;
8
9
  private source;
9
- private messageService;
10
- constructor(layer: ImageLayer, messageService: MessageService);
10
+ constructor(layer: ImageLayer, messageService?: MessageService);
11
11
  protected watch(): void;
12
12
  protected unwatch(): void;
13
13
  private handleLoadStart;
@@ -1,5 +1,6 @@
1
1
  export * from './image-watcher';
2
2
  export * from './layer.utils';
3
+ export * from './layer-options.utils';
3
4
  export * from './tile-watcher';
4
5
  export * from './outputLegend';
5
6
  export * from './vector-watcher';
@@ -0,0 +1,12 @@
1
+ import { AnyLayerOptions } from '../shared';
2
+ export declare function mergeLayersOptions(layersOptionsTree: AnyLayerOptions[], layersOptions: AnyLayerOptions[]): AnyLayerOptions[];
3
+ export declare function getLayerOptionIdentifier(layerOptions: AnyLayerOptions): string | undefined;
4
+ /**
5
+ * Recursively finds the parent ID of a target layer option within a tree structure.
6
+ *
7
+ * @param tree - The array of layer options representing the tree structure.
8
+ * @param target - The target layer option whose parent ID is to be found.
9
+ * @param path - The current path of IDs traversed during the search (used internally).
10
+ * @returns The parent ID as a dot-separated string, or undefined if no parent is found.
11
+ */
12
+ export declare function findParentId(tree: AnyLayerOptions[], target: AnyLayerOptions, path?: string[]): string | undefined;
@@ -1,9 +1,9 @@
1
- import { AfterViewInit, ApplicationRef, OnDestroy } from '@angular/core';
1
+ import { AfterViewInit, ApplicationRef } from '@angular/core';
2
2
  import { Layer } from '../../layer/shared';
3
3
  import { LayerService } from '../../layer/shared/layer.service';
4
4
  import { IgoMap } from '../shared/map';
5
5
  import * as i0 from "@angular/core";
6
- export declare class MiniBaseMapComponent implements AfterViewInit, OnDestroy {
6
+ export declare class MiniBaseMapComponent implements AfterViewInit {
7
7
  private layerService;
8
8
  private appRef;
9
9
  map: IgoMap;
@@ -18,9 +18,7 @@ export declare class MiniBaseMapComponent implements AfterViewInit, OnDestroy {
18
18
  basemap: IgoMap;
19
19
  constructor(layerService: LayerService, appRef: ApplicationRef);
20
20
  ngAfterViewInit(): void;
21
- ngOnDestroy(): void;
22
21
  changeBaseLayer(baseLayer: Layer): void;
23
- private handleMainMapViewChange;
24
22
  private handleBaseLayerChanged;
25
23
  private handleLinkedBaseLayer;
26
24
  static ɵfac: i0.ɵɵFactoryDeclaration<MiniBaseMapComponent, never>;
@@ -1,13 +1,11 @@
1
1
  import { HttpClient } from '@angular/common/http';
2
2
  import { MessageService } from '@igo2/core/message';
3
- import { GeoDBService } from './geoDB.service';
4
3
  import * as i0 from "@angular/core";
5
4
  export declare class ConfigFileToGeoDBService {
6
5
  private http;
7
- private geoDBService;
8
6
  private messageService;
9
- constructor(http: HttpClient, geoDBService: GeoDBService, messageService: MessageService);
10
- load(url: string): void;
7
+ constructor(http: HttpClient, messageService: MessageService);
8
+ load(urlFile: string): void;
11
9
  private isZip;
12
10
  static ɵfac: i0.ɵɵFactoryDeclaration<ConfigFileToGeoDBService, never>;
13
11
  static ɵprov: i0.ɵɵInjectableDeclaration<ConfigFileToGeoDBService>;
@@ -0,0 +1,36 @@
1
+ import { Observable } from 'rxjs';
2
+ import { InsertSourceInsertDBEnum } from './geoDB.enums';
3
+ import { GeoDBData } from './geoDB.interface';
4
+ export declare class GeoDB {
5
+ private db$;
6
+ private compression;
7
+ collisionsMap: Map<string | number, string[]>;
8
+ _newData: number;
9
+ private revertObservablesSubscription;
10
+ constructor();
11
+ /**
12
+ * Only blob can be compressed
13
+ * @param url
14
+ * @param regionID
15
+ * @param object object to handle
16
+ * @param insertSource type of event user or system
17
+ * @param insertEvent Name of the event where the insert has been triggered
18
+ * @returns
19
+ */
20
+ update(url: string, regionID: number | string, object: object | Blob, insertSource: InsertSourceInsertDBEnum, insertEvent: string): Observable<GeoDBData>;
21
+ private customUpdate;
22
+ add(geoDBData: GeoDBData): Observable<GeoDBData>;
23
+ put(geoDBData: GeoDBData): Observable<GeoDBData>;
24
+ getGeoDBData(url: string): Observable<GeoDBData>;
25
+ get(url: string): Observable<object | Blob>;
26
+ delete(key: string): Observable<object>;
27
+ /** @deprecated Use delete method instead*/
28
+ deleteByKey(key: string): Observable<object>;
29
+ getRegionCountByID(id: number): Observable<number>;
30
+ getRegionByID(id: number): Observable<GeoDBData[]>;
31
+ deleteByRegionID(id: number): Observable<void[]>;
32
+ resetCounters(): void;
33
+ resetCollisionsMap(): void;
34
+ revertCollisions(): void;
35
+ get newData(): number;
36
+ }
@@ -1,4 +1,4 @@
1
1
  export * from './geoDB.enums';
2
2
  export * from './geoDB.interface';
3
- export * from './geoDB.service';
3
+ export * from './geoDB';
4
4
  export * from './configFileToGeoDB.service';
@@ -1,2 +1,2 @@
1
1
  export * from './layerDB.interface';
2
- export * from './layerDB.service';
2
+ export * from './layerDB';
@@ -1,18 +1,16 @@
1
- import { NgxIndexedDBService } from 'ngx-indexed-db';
2
1
  import { Observable } from 'rxjs';
3
2
  import { LayerDBData } from './layerDB.interface';
4
- import * as i0 from "@angular/core";
5
- export declare class LayerDBService {
6
- private ngxIndexedDBService;
7
- readonly dbName: string;
8
- constructor(ngxIndexedDBService: NgxIndexedDBService);
3
+ export declare class LayerDB {
4
+ private db$;
5
+ constructor();
9
6
  /**
10
7
  * This method allow to update the stored layer into the indexeddb (layerData)
11
8
  * @param layerDBData
12
9
  * @returns
13
10
  */
14
- update(layerDBData: LayerDBData): Observable<any>;
11
+ update(layerDBData: LayerDBData): Observable<LayerDBData>;
15
12
  private customUpdate;
13
+ add(layerDBData: LayerDBData): Observable<LayerDBData>;
16
14
  /**
17
15
  * This method retrieve an idb layer definition
18
16
  * @param layerId
@@ -21,16 +19,16 @@ export declare class LayerDBService {
21
19
  getByID(layerId: string): Observable<LayerDBData>;
22
20
  /**
23
21
  * This method delete an idb layer definition
24
- * @param layerId
22
+ * @param key
25
23
  * @returns
26
24
  */
27
- deleteByKey(layerId: string): Observable<void>;
25
+ delete(key: string): Observable<object>;
26
+ /** @deprecated Use delete method instead*/
27
+ deleteByKey(key: string): Observable<object>;
28
28
  /**
29
29
  * This method retrive all idb layer definition
30
30
  * @param layerId
31
31
  * @returns
32
32
  */
33
33
  getAll(): Observable<LayerDBData[]>;
34
- static ɵfac: i0.ɵɵFactoryDeclaration<LayerDBService, [{ optional: true; }]>;
35
- static ɵprov: i0.ɵɵInjectableDeclaration<LayerDBService>;
36
34
  }
@@ -1,3 +1,5 @@
1
1
  import { EnvironmentProviders } from '@angular/core';
2
2
  import { IOfflineOptions } from './offline.interface';
3
+ /** Ensure to create the indexDB on app initialisation and provide
4
+ * GeoNetworkService, ConfigFileToGeoDBService */
3
5
  export declare function provideOffline(options: IOfflineOptions): EnvironmentProviders;
@@ -2,7 +2,6 @@ import { HttpClient } from '@angular/common/http';
2
2
  import { NetworkService } from '@igo2/core/network';
3
3
  import { Type } from 'ol/format/Feature';
4
4
  import { Observable } from 'rxjs';
5
- import { GeoDBService } from '../geoDB/geoDB.service';
6
5
  import * as i0 from "@angular/core";
7
6
  export declare enum ResponseType {
8
7
  Arraybuffer = "arraybuffer",
@@ -17,13 +16,12 @@ export interface SimpleGetOptions {
17
16
  export declare class GeoNetworkService {
18
17
  private http;
19
18
  private networkService;
20
- geoDBService?: GeoDBService;
21
19
  private networkOnline;
22
- constructor(http: HttpClient, networkService: NetworkService, geoDBService?: GeoDBService);
20
+ constructor(http: HttpClient, networkService: NetworkService);
23
21
  get(url: string, simpleGetOptions: SimpleGetOptions): Observable<any>;
24
22
  private getOnline;
25
23
  private getOffline;
26
24
  isOnline(): boolean;
27
- static ɵfac: i0.ɵɵFactoryDeclaration<GeoNetworkService, [null, null, { optional: true; }]>;
25
+ static ɵfac: i0.ɵɵFactoryDeclaration<GeoNetworkService, never>;
28
26
  static ɵprov: i0.ɵɵInjectableDeclaration<GeoNetworkService>;
29
27
  }
@@ -0,0 +1,16 @@
1
+ import { DBSchema } from 'idb';
2
+ import { GeoDBData } from '../geoDB/geoDB.interface';
3
+ import { LayerDBData } from '../layerDB/layerDB.interface';
4
+ export interface IgoDBSchema extends DBSchema {
5
+ geoData: {
6
+ value: GeoDBData;
7
+ key: string;
8
+ indexes: {
9
+ 'regionID-idx': string;
10
+ };
11
+ };
12
+ layerData: {
13
+ value: LayerDBData;
14
+ key: string;
15
+ };
16
+ }
@@ -0,0 +1,4 @@
1
+ import { IDBPDatabase } from 'idb';
2
+ import { Observable } from 'rxjs';
3
+ import { IgoDBSchema } from './indexed-db.interface';
4
+ export declare function createIndexedDb(): Observable<IDBPDatabase<IgoDBSchema>>;
@@ -11,7 +11,7 @@ export declare class QuerySearchSource extends SearchSource {
11
11
  constructor(options: SearchSourceOptions);
12
12
  getId(): string;
13
13
  getType(): string;
14
- protected getDefaultOptions(): SearchSourceOptions;
14
+ protected getEffectiveOptions(): SearchSourceOptions;
15
15
  static ɵfac: i0.ɵɵFactoryDeclaration<QuerySearchSource, never>;
16
16
  static ɵprov: i0.ɵɵInjectableDeclaration<QuerySearchSource>;
17
17
  }
@@ -79,6 +79,7 @@ export declare class SearchBarComponent implements OnInit, OnDestroy {
79
79
  get disabled(): boolean;
80
80
  readonly disabled$: BehaviorSubject<boolean>;
81
81
  pointerSummaryEnabled: boolean;
82
+ allowResetSearchSourcesOptions: boolean;
82
83
  searchResultsGeometryEnabled: boolean;
83
84
  /**
84
85
  * When reverse coordinates status change
@@ -228,5 +229,5 @@ export declare class SearchBarComponent implements OnInit, OnDestroy {
228
229
  */
229
230
  private onResearchCompleted;
230
231
  static ɵfac: i0.ɵɵFactoryDeclaration<SearchBarComponent, never>;
231
- static ɵcmp: i0.ɵɵComponentDeclaration<SearchBarComponent, "igo-search-bar", never, { "searchTypes": { "alias": "searchTypes"; "required": false; }; "withDivider": { "alias": "withDivider"; "required": false; }; "searchType": { "alias": "searchType"; "required": false; }; "term": { "alias": "term"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "pointerSummaryEnabled": { "alias": "pointerSummaryEnabled"; "required": false; }; "searchResultsGeometryEnabled": { "alias": "searchResultsGeometryEnabled"; "required": false; }; "reverseSearchCoordsFormatEnabled": { "alias": "reverseSearchCoordsFormatEnabled"; "required": false; }; "floatLabel": { "alias": "floatLabel"; "required": false; }; "appearance": { "alias": "appearance"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "label": { "alias": "label"; "required": false; }; "color": { "alias": "color"; "required": false; }; "termSplitter": { "alias": "termSplitter"; "required": false; }; "debounce": { "alias": "debounce"; "required": false; }; "minLength": { "alias": "minLength"; "required": false; }; "searchSelector": { "alias": "searchSelector"; "required": false; }; "searchSettings": { "alias": "searchSettings"; "required": false; }; "forceNA": { "alias": "forceNA"; "required": false; }; "store": { "alias": "store"; "required": false; }; }, { "pointerSummaryStatus": "pointerSummaryStatus"; "searchResultsGeometryStatus": "searchResultsGeometryStatus"; "reverseSearchCoordsFormatStatus": "reverseSearchCoordsFormatStatus"; "searchTermChange": "searchTermChange"; "search": "search"; "searchTypeChange": "searchTypeChange"; "clearFeature": "clearFeature"; "searchSettingsChange": "searchSettingsChange"; }, never, never, true, never>;
232
+ static ɵcmp: i0.ɵɵComponentDeclaration<SearchBarComponent, "igo-search-bar", never, { "searchTypes": { "alias": "searchTypes"; "required": false; }; "withDivider": { "alias": "withDivider"; "required": false; }; "searchType": { "alias": "searchType"; "required": false; }; "term": { "alias": "term"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "pointerSummaryEnabled": { "alias": "pointerSummaryEnabled"; "required": false; }; "allowResetSearchSourcesOptions": { "alias": "allowResetSearchSourcesOptions"; "required": false; }; "searchResultsGeometryEnabled": { "alias": "searchResultsGeometryEnabled"; "required": false; }; "reverseSearchCoordsFormatEnabled": { "alias": "reverseSearchCoordsFormatEnabled"; "required": false; }; "floatLabel": { "alias": "floatLabel"; "required": false; }; "appearance": { "alias": "appearance"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "label": { "alias": "label"; "required": false; }; "color": { "alias": "color"; "required": false; }; "termSplitter": { "alias": "termSplitter"; "required": false; }; "debounce": { "alias": "debounce"; "required": false; }; "minLength": { "alias": "minLength"; "required": false; }; "searchSelector": { "alias": "searchSelector"; "required": false; }; "searchSettings": { "alias": "searchSettings"; "required": false; }; "forceNA": { "alias": "forceNA"; "required": false; }; "store": { "alias": "store"; "required": false; }; }, { "pointerSummaryStatus": "pointerSummaryStatus"; "searchResultsGeometryStatus": "searchResultsGeometryStatus"; "reverseSearchCoordsFormatStatus": "reverseSearchCoordsFormatStatus"; "searchTermChange": "searchTermChange"; "search": "search"; "searchTypeChange": "searchTypeChange"; "clearFeature": "clearFeature"; "searchSettingsChange": "searchSettingsChange"; }, never, never, true, never>;
232
233
  }
@@ -1,7 +1,9 @@
1
1
  import { EventEmitter, OnInit } from '@angular/core';
2
2
  import { MatCheckboxChange } from '@angular/material/checkbox';
3
3
  import { MatRadioChange } from '@angular/material/radio';
4
+ import { FormDialogService } from '@igo2/common/form';
4
5
  import { MediaService } from '@igo2/core/media';
6
+ import { MessageService } from '@igo2/core/message';
5
7
  import { StorageService } from '@igo2/core/storage';
6
8
  import { SearchSourceService } from '../shared/search-source.service';
7
9
  import { SearchSource } from '../shared/sources/source';
@@ -16,6 +18,8 @@ import * as i0 from "@angular/core";
16
18
  * more than one search source enabled.
17
19
  */
18
20
  export declare class SearchSettingsComponent implements OnInit {
21
+ private formDialogService;
22
+ private messageService;
19
23
  private searchSourceService;
20
24
  private mediaService;
21
25
  private storageService;
@@ -28,6 +32,7 @@ export declare class SearchSettingsComponent implements OnInit {
28
32
  pointerSummaryEnabled: boolean;
29
33
  searchResultsGeometryEnabled: boolean;
30
34
  reverseSearchCoordsFormatEnabled: boolean;
35
+ allowResetSearchSourcesOptions: boolean;
31
36
  /**
32
37
  * Event emitted when the enabled search source changes
33
38
  */
@@ -45,7 +50,7 @@ export declare class SearchSettingsComponent implements OnInit {
45
50
  */
46
51
  reverseSearchCoordsFormatStatus: EventEmitter<boolean>;
47
52
  handleKeyboardEvent(event: KeyboardEvent): void;
48
- constructor(searchSourceService: SearchSourceService, mediaService: MediaService, storageService: StorageService);
53
+ constructor(formDialogService: FormDialogService, messageService: MessageService, searchSourceService: SearchSourceService, mediaService: MediaService, storageService: StorageService);
49
54
  ngOnInit(): void;
50
55
  /**
51
56
  * Get all search sources
@@ -76,6 +81,7 @@ export declare class SearchSettingsComponent implements OnInit {
76
81
  * @internal
77
82
  */
78
83
  computeSourcesCheckAllBehavior(sources: SearchSource[]): void;
84
+ resetSourceOptions(event: any): void;
79
85
  /**
80
86
  * Triggered when the check all / uncheck all type is clicked,
81
87
  * @internal
@@ -99,5 +105,5 @@ export declare class SearchSettingsComponent implements OnInit {
99
105
  changeSearchResultsGeometry(event: any): void;
100
106
  reverseSearchCoordsFormat(event: any): void;
101
107
  static ɵfac: i0.ɵɵFactoryDeclaration<SearchSettingsComponent, never>;
102
- static ɵcmp: i0.ɵɵComponentDeclaration<SearchSettingsComponent, "igo-search-settings", never, { "pointerSummaryEnabled": { "alias": "pointerSummaryEnabled"; "required": false; }; "searchResultsGeometryEnabled": { "alias": "searchResultsGeometryEnabled"; "required": false; }; "reverseSearchCoordsFormatEnabled": { "alias": "reverseSearchCoordsFormatEnabled"; "required": false; }; }, { "searchSourceChange": "searchSourceChange"; "pointerSummaryStatus": "pointerSummaryStatus"; "searchResultsGeometryStatus": "searchResultsGeometryStatus"; "reverseSearchCoordsFormatStatus": "reverseSearchCoordsFormatStatus"; }, never, never, true, never>;
108
+ static ɵcmp: i0.ɵɵComponentDeclaration<SearchSettingsComponent, "igo-search-settings", never, { "pointerSummaryEnabled": { "alias": "pointerSummaryEnabled"; "required": false; }; "searchResultsGeometryEnabled": { "alias": "searchResultsGeometryEnabled"; "required": false; }; "reverseSearchCoordsFormatEnabled": { "alias": "reverseSearchCoordsFormatEnabled"; "required": false; }; "allowResetSearchSourcesOptions": { "alias": "allowResetSearchSourcesOptions"; "required": false; }; }, { "searchSourceChange": "searchSourceChange"; "pointerSummaryStatus": "pointerSummaryStatus"; "searchResultsGeometryStatus": "searchResultsGeometryStatus"; "reverseSearchCoordsFormatStatus": "reverseSearchCoordsFormatStatus"; }, never, never, true, never>;
103
109
  }
@@ -18,7 +18,7 @@ export declare class CadastreSearchSource extends SearchSource implements TextSe
18
18
  constructor(http: HttpClient, languageService: LanguageService, storageService: StorageService, options: SearchSourceOptions);
19
19
  getId(): string;
20
20
  getType(): string;
21
- protected getDefaultOptions(): SearchSourceOptions;
21
+ protected getEffectiveOptions(): SearchSourceOptions;
22
22
  /**
23
23
  * Search a place by name
24
24
  * @param term Place name
@@ -27,7 +27,7 @@ export declare class CoordinatesReverseSearchSource extends SearchSource impleme
27
27
  constructor(options: SearchSourceOptions, languageService: LanguageService, storageService: StorageService, projections: Projection[]);
28
28
  getId(): string;
29
29
  getType(): string;
30
- protected getDefaultOptions(): SearchSourceOptions;
30
+ protected getEffectiveOptions(): SearchSourceOptions;
31
31
  /**
32
32
  * Search a location by coordinates
33
33
  * @param lonLat Location coordinates
@@ -32,12 +32,13 @@ export declare class IChercheSearchSource extends SearchSource implements TextSe
32
32
  static type: string;
33
33
  static propertiesBlacklist: string[];
34
34
  title$: BehaviorSubject<string>;
35
+ static defaultIchercheTypes: string[];
35
36
  private hashtagsLieuxToKeep;
36
37
  get title(): string;
37
38
  constructor(http: HttpClient, languageService: LanguageService, storageService: StorageService, options: SearchSourceOptions, formatter: IChercheSearchResultFormatter, injector: Injector);
38
39
  getId(): string;
39
40
  getType(): string;
40
- protected getDefaultOptions(): SearchSourceOptions;
41
+ protected getEffectiveOptions(): SearchSourceOptions;
41
42
  /**
42
43
  * Search a location by name or keyword
43
44
  * @param term Location name or keyword
@@ -73,12 +74,13 @@ export declare class IChercheReverseSearchSource extends SearchSource implements
73
74
  static id: string;
74
75
  static type: string;
75
76
  static propertiesBlacklist: string[];
77
+ static defaultIchercheTypes: string[];
76
78
  title$: BehaviorSubject<string>;
77
79
  get title(): string;
78
80
  constructor(http: HttpClient, languageService: LanguageService, storageService: StorageService, options: SearchSourceOptions, injector: Injector);
79
81
  getId(): string;
80
82
  getType(): string;
81
- protected getDefaultOptions(): SearchSourceOptions;
83
+ protected getEffectiveOptions(): SearchSourceOptions;
82
84
  /**
83
85
  * Search a location by coordinates
84
86
  * @param lonLat Location coordinates
@@ -28,7 +28,7 @@ export declare class ILayerSearchSource extends SearchSource implements TextSear
28
28
  constructor(http: HttpClient, languageService: LanguageService, storageService: StorageService, options: ILayerSearchSourceOptions, formatter: ILayerSearchResultFormatter);
29
29
  getId(): string;
30
30
  getType(): string;
31
- protected getDefaultOptions(): ILayerSearchSourceOptions;
31
+ protected getEffectiveOptions(): ILayerSearchSourceOptions;
32
32
  /**
33
33
  * Search a layer by name or keyword
34
34
  * @param term Layer name or keyword
@@ -16,7 +16,7 @@ export declare class NominatimSearchSource extends SearchSource implements TextS
16
16
  constructor(http: HttpClient, options: SearchSourceOptions, storageService: StorageService);
17
17
  getId(): string;
18
18
  getType(): string;
19
- protected getDefaultOptions(): SearchSourceOptions;
19
+ protected getEffectiveOptions(): SearchSourceOptions;
20
20
  /**
21
21
  * Search a place by name
22
22
  * @param term Place name
@@ -22,6 +22,7 @@ export declare class SearchSource {
22
22
  * @internal
23
23
  */
24
24
  protected options: SearchSourceOptions;
25
+ protected defaultOptions: SearchSourceOptions;
25
26
  /**
26
27
  * Get search source's id
27
28
  * @returns Search source's id
@@ -36,7 +37,7 @@ export declare class SearchSource {
36
37
  * Get search source's default options
37
38
  * @returns Search source default options
38
39
  */
39
- protected getDefaultOptions(): SearchSourceOptions;
40
+ protected getEffectiveOptions(): SearchSourceOptions;
40
41
  /**
41
42
  * Search source's title
42
43
  */
@@ -67,6 +68,7 @@ export declare class SearchSource {
67
68
  set featureStoresWithIndex(storesWithIndex: FeatureStore[]);
68
69
  get featureStoresWithIndex(): FeatureStore[];
69
70
  private _featureStoresWithIndex;
71
+ resetSourceOptions(): void;
70
72
  setWorkspaces(workspaces: Workspace[]): void;
71
73
  /**
72
74
  * Set params from selected settings
@@ -23,7 +23,7 @@ export declare class StoredQueriesSearchSource extends SearchSource implements T
23
23
  constructor(http: HttpClient, languageService: LanguageService, storageService: StorageService, options: SearchSourceOptions);
24
24
  getId(): string;
25
25
  getType(): string;
26
- protected getDefaultOptions(): SearchSourceOptions;
26
+ protected getEffectiveOptions(): SearchSourceOptions;
27
27
  /**
28
28
  * Search a location by name or keyword
29
29
  * @param term Location name or keyword
@@ -56,7 +56,7 @@ export declare class StoredQueriesReverseSearchSource extends SearchSource imple
56
56
  constructor(http: HttpClient, languageService: LanguageService, storageService: StorageService, options: SearchSourceOptions);
57
57
  getId(): string;
58
58
  getType(): string;
59
- protected getDefaultOptions(): SearchSourceOptions;
59
+ protected getEffectiveOptions(): SearchSourceOptions;
60
60
  /**
61
61
  * Search a location by coordinates
62
62
  * @param lonLat Location coordinates
@@ -18,7 +18,7 @@ export declare class WorkspaceSearchSource extends SearchSource implements TextS
18
18
  constructor(languageService: LanguageService, storageService: StorageService, options: SearchSourceOptions);
19
19
  getId(): string;
20
20
  getType(): string;
21
- protected getDefaultOptions(): SearchSourceOptions;
21
+ protected getEffectiveOptions(): SearchSourceOptions;
22
22
  /**
23
23
  * Search a location by name or keyword
24
24
  * @param term Location name or keyword