@angular-helpers/openlayers 0.3.0 → 0.5.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/README.md +102 -6
- package/fesm2022/angular-helpers-openlayers-controls.mjs +289 -36
- package/fesm2022/angular-helpers-openlayers-core.mjs +215 -16
- package/fesm2022/angular-helpers-openlayers-interactions.mjs +426 -23
- package/fesm2022/angular-helpers-openlayers-layers.mjs +717 -38
- package/fesm2022/angular-helpers-openlayers-military.mjs +329 -12
- package/fesm2022/angular-helpers-openlayers-overlays.mjs +11 -10
- package/package.json +6 -2
- package/types/angular-helpers-openlayers-controls.d.ts +24 -4
- package/types/angular-helpers-openlayers-core.d.ts +143 -4
- package/types/angular-helpers-openlayers-interactions.d.ts +127 -23
- package/types/angular-helpers-openlayers-layers.d.ts +194 -35
- package/types/angular-helpers-openlayers-military.d.ts +160 -16
|
@@ -36,6 +36,22 @@ interface Style {
|
|
|
36
36
|
width?: number;
|
|
37
37
|
};
|
|
38
38
|
};
|
|
39
|
+
/**
|
|
40
|
+
* Icon style for Point features. When set, renderers should produce an
|
|
41
|
+
* `ol/style/Icon` with the given source. Used by the military symbology
|
|
42
|
+
* helpers to embed `milsymbol`-generated SVGs as data URLs.
|
|
43
|
+
*/
|
|
44
|
+
icon?: {
|
|
45
|
+
/** Image source — typically a `data:image/svg+xml;base64,...` URL */
|
|
46
|
+
src: string;
|
|
47
|
+
/** Pixel size `[width, height]` */
|
|
48
|
+
size?: [number, number];
|
|
49
|
+
/**
|
|
50
|
+
* Anchor in fractional coordinates `[x, y]` where `0..1` is the icon
|
|
51
|
+
* extent. `[0.5, 0.5]` centers the icon on the feature.
|
|
52
|
+
*/
|
|
53
|
+
anchor?: [number, number];
|
|
54
|
+
};
|
|
39
55
|
text?: {
|
|
40
56
|
text?: string;
|
|
41
57
|
font?: string;
|
|
@@ -83,6 +99,7 @@ declare class OlMapComponent {
|
|
|
83
99
|
mapDblClick: _angular_core.OutputEmitterRef<MapClickEvent>;
|
|
84
100
|
mapContainerRef: _angular_core.Signal<ElementRef<HTMLDivElement>>;
|
|
85
101
|
private map?;
|
|
102
|
+
private resizeObserver?;
|
|
86
103
|
constructor();
|
|
87
104
|
private initMap;
|
|
88
105
|
private destroyMap;
|
|
@@ -140,7 +157,11 @@ declare class OlMapService {
|
|
|
140
157
|
private zoneHelper;
|
|
141
158
|
private map;
|
|
142
159
|
private readyCallbacks;
|
|
143
|
-
|
|
160
|
+
private _resolution;
|
|
161
|
+
/** Signal that emits the current map resolution in meters per pixel */
|
|
162
|
+
readonly resolution: _angular_core.Signal<number>;
|
|
163
|
+
setMap(map: OLMap | null): void;
|
|
164
|
+
setResolution(resolution: number): void;
|
|
144
165
|
getMap(): OLMap | null;
|
|
145
166
|
onReady(callback: (map: OLMap) => void): void;
|
|
146
167
|
getView(): View | null;
|
|
@@ -198,12 +219,130 @@ declare class OlZoneHelper {
|
|
|
198
219
|
static ɵprov: _angular_core.ɵɵInjectableDeclaration<OlZoneHelper>;
|
|
199
220
|
}
|
|
200
221
|
|
|
201
|
-
|
|
222
|
+
/**
|
|
223
|
+
* Configuration for an ellipse polygon centered at `center`.
|
|
224
|
+
* Coordinates are emitted in EPSG:4326 (lon/lat) using a local tangent-plane
|
|
225
|
+
* approximation; accuracy degrades for radii > ~100 km or near the poles.
|
|
226
|
+
*/
|
|
227
|
+
interface EllipseConfig {
|
|
228
|
+
/** Ellipse center as `[lon, lat]` in EPSG:4326. */
|
|
229
|
+
center: Coordinate;
|
|
230
|
+
/** Semi-major axis in meters. Must be > 0. */
|
|
231
|
+
semiMajor: number;
|
|
232
|
+
/** Semi-minor axis in meters. Must be > 0. */
|
|
233
|
+
semiMinor: number;
|
|
234
|
+
/**
|
|
235
|
+
* Rotation in radians, counter-clockwise from East. Default: 0
|
|
236
|
+
* (semi-major axis points East).
|
|
237
|
+
*/
|
|
238
|
+
rotation?: number;
|
|
239
|
+
/**
|
|
240
|
+
* Number of vertices used to approximate the ellipse. Default: 64.
|
|
241
|
+
* Minimum: 8.
|
|
242
|
+
*/
|
|
243
|
+
segments?: number;
|
|
244
|
+
/** Custom feature properties to attach to the output feature. */
|
|
245
|
+
properties?: Record<string, unknown>;
|
|
246
|
+
}
|
|
247
|
+
/**
|
|
248
|
+
* Configuration for a circular sector (pie-slice) polygon.
|
|
249
|
+
* Same projection caveats as `EllipseConfig`.
|
|
250
|
+
*/
|
|
251
|
+
interface SectorConfig {
|
|
252
|
+
/** Sector apex / center as `[lon, lat]` in EPSG:4326. */
|
|
253
|
+
center: Coordinate;
|
|
254
|
+
/** Sector radius in meters. Must be > 0. */
|
|
255
|
+
radius: number;
|
|
256
|
+
/** Start angle in radians (0 = East, CCW positive). */
|
|
257
|
+
startAngle: number;
|
|
258
|
+
/**
|
|
259
|
+
* End angle in radians. Must satisfy `startAngle < endAngle <= startAngle + 2π`.
|
|
260
|
+
*/
|
|
261
|
+
endAngle: number;
|
|
262
|
+
/**
|
|
263
|
+
* Number of vertices along the arc. Default: 32. Minimum: 4. The output
|
|
264
|
+
* polygon has `segments + 3` vertices (apex + arc + apex closer).
|
|
265
|
+
*/
|
|
266
|
+
segments?: number;
|
|
267
|
+
/** Custom feature properties to attach to the output feature. */
|
|
268
|
+
properties?: Record<string, unknown>;
|
|
269
|
+
}
|
|
270
|
+
/**
|
|
271
|
+
* Configuration for a donut (annular ring) polygon — a disk with a
|
|
272
|
+
* concentric circular hole.
|
|
273
|
+
*
|
|
274
|
+
* The output `Feature<Polygon>` has TWO rings: an outer ring (CCW) and
|
|
275
|
+
* an inner ring (CW per the GeoJSON right-hand rule), so renderers that
|
|
276
|
+
* follow the spec fill only the band between the radii.
|
|
277
|
+
*/
|
|
278
|
+
interface DonutConfig {
|
|
279
|
+
/** Donut center as `[lon, lat]` in EPSG:4326. */
|
|
280
|
+
center: Coordinate;
|
|
281
|
+
/** Outer radius in meters. Must be > `innerRadius`. */
|
|
282
|
+
outerRadius: number;
|
|
283
|
+
/** Inner radius in meters. Must be > 0 and < `outerRadius`. */
|
|
284
|
+
innerRadius: number;
|
|
285
|
+
/**
|
|
286
|
+
* Number of vertices per ring. Default: 64. Minimum: 8. Both rings use
|
|
287
|
+
* the same segment count.
|
|
288
|
+
*/
|
|
289
|
+
segments?: number;
|
|
290
|
+
/** Custom feature properties to attach to the output feature. */
|
|
291
|
+
properties?: Record<string, unknown>;
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
/**
|
|
295
|
+
* Service exposing general purpose geometry helpers for creating
|
|
296
|
+
* approximated polygons (ellipses, sectors, donuts) from metric parameters.
|
|
297
|
+
*/
|
|
298
|
+
declare class OlGeometryService {
|
|
299
|
+
private idCounter;
|
|
300
|
+
/**
|
|
301
|
+
* Build a `Feature<Polygon>` approximating an ellipse centered at
|
|
302
|
+
* `config.center`. See {@link EllipseConfig} for parameter semantics.
|
|
303
|
+
*/
|
|
304
|
+
createEllipse(config: EllipseConfig): Feature;
|
|
305
|
+
/**
|
|
306
|
+
* Build a `Feature<Polygon>` for a circular sector (pie slice).
|
|
307
|
+
* See {@link SectorConfig} for parameter semantics.
|
|
308
|
+
*/
|
|
309
|
+
createSector(config: SectorConfig): Feature;
|
|
310
|
+
/**
|
|
311
|
+
* Build a `Feature<Polygon>` for a donut (annular ring). The output has
|
|
312
|
+
* two rings: an outer ring wound counter-clockwise and an inner ring
|
|
313
|
+
* wound clockwise so the GeoJSON right-hand rule renders the hole.
|
|
314
|
+
*/
|
|
315
|
+
createDonut(config: DonutConfig): Feature;
|
|
316
|
+
/**
|
|
317
|
+
* Project an `(dx, dy)` meter offset from `center` to lon/lat using true
|
|
318
|
+
* geodesic math (Vincenty's formulae) via ol/sphere.
|
|
319
|
+
*/
|
|
320
|
+
offsetMetersToLonLat(center: Coordinate, dx: number, dy: number): Coordinate;
|
|
321
|
+
private nextId;
|
|
322
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<OlGeometryService, never>;
|
|
323
|
+
static ɵprov: _angular_core.ɵɵInjectableDeclaration<OlGeometryService>;
|
|
324
|
+
}
|
|
325
|
+
|
|
326
|
+
type OlFeatureKind = 'layers' | 'controls' | 'interactions' | 'overlays' | 'military' | 'projections';
|
|
202
327
|
interface OlFeature<Kind extends OlFeatureKind> {
|
|
203
328
|
kind: Kind;
|
|
204
329
|
providers: Provider[];
|
|
205
330
|
}
|
|
206
331
|
declare function provideOpenLayers(...features: OlFeature<OlFeatureKind>[]): EnvironmentProviders;
|
|
207
332
|
|
|
208
|
-
|
|
209
|
-
|
|
333
|
+
interface Proj4Definition {
|
|
334
|
+
code: string;
|
|
335
|
+
def: string;
|
|
336
|
+
extent?: [number, number, number, number];
|
|
337
|
+
}
|
|
338
|
+
/**
|
|
339
|
+
* Registers custom projections using proj4.
|
|
340
|
+
*
|
|
341
|
+
* @param proj4 - The proj4 instance (must be passed to avoid strong dependency on proj4 package)
|
|
342
|
+
* @param definitions - Array of projection definitions
|
|
343
|
+
* @returns OlFeature for projections
|
|
344
|
+
*/
|
|
345
|
+
declare function withProjections(proj4: any, definitions: Proj4Definition[]): OlFeature<'projections'>;
|
|
346
|
+
|
|
347
|
+
export { OlGeometryService, OlMapComponent, OlMapService, OlZoneHelper, provideOpenLayers, withProjections };
|
|
348
|
+
export type { AnimationOptions, Coordinate, DonutConfig, EllipseConfig, Extent, Feature, FitOptions, Geometry, GeometryType, Layer, MapClickEvent, MapConfig, MapViewOptions, OlFeature, OlFeatureKind, Pixel, Proj4Definition, ProjectionCode, SectorConfig, Style, ViewState };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as rxjs from 'rxjs';
|
|
2
2
|
import * as _angular_helpers_openlayers_interactions from '@angular-helpers/openlayers/interactions';
|
|
3
|
-
import * as
|
|
3
|
+
import * as _angular_core from '@angular/core';
|
|
4
4
|
import { Provider } from '@angular/core';
|
|
5
5
|
import * as _angular_helpers_openlayers_core from '@angular-helpers/openlayers/core';
|
|
6
6
|
import { Feature, OlFeature } from '@angular-helpers/openlayers/core';
|
|
@@ -11,14 +11,21 @@ import { Feature as Feature$1 } from 'ol';
|
|
|
11
11
|
type InteractionType = 'select' | 'draw' | 'modify' | 'dragAndDrop';
|
|
12
12
|
interface InteractionConfig {
|
|
13
13
|
active?: boolean;
|
|
14
|
+
/**
|
|
15
|
+
* If true, enabling this interaction will automatically disable other active exclusive interactions.
|
|
16
|
+
* Useful for mutually exclusive tools like Draw and Modify.
|
|
17
|
+
* @default true
|
|
18
|
+
*/
|
|
19
|
+
exclusive?: boolean;
|
|
14
20
|
}
|
|
15
21
|
interface SelectConfig extends InteractionConfig {
|
|
16
22
|
layers?: string[];
|
|
17
23
|
multi?: boolean;
|
|
18
24
|
hitTolerance?: number;
|
|
25
|
+
condition?: 'click' | 'pointerMove';
|
|
19
26
|
}
|
|
20
27
|
interface DrawConfig extends InteractionConfig {
|
|
21
|
-
type: 'Point' | 'LineString' | 'Polygon' | 'Circle';
|
|
28
|
+
type: 'Point' | 'LineString' | 'Polygon' | 'Circle' | 'Ellipse' | 'Donut';
|
|
22
29
|
source?: string;
|
|
23
30
|
freehand?: boolean;
|
|
24
31
|
snapTolerance?: number;
|
|
@@ -32,17 +39,21 @@ interface DragAndDropConfig extends InteractionConfig {
|
|
|
32
39
|
projection?: string;
|
|
33
40
|
}
|
|
34
41
|
interface SelectEvent {
|
|
35
|
-
|
|
36
|
-
selected:
|
|
42
|
+
interactionId: string;
|
|
43
|
+
selected: Feature[];
|
|
44
|
+
deselected: Feature[];
|
|
37
45
|
}
|
|
38
46
|
interface DrawEndEvent {
|
|
47
|
+
interactionId: string;
|
|
39
48
|
feature: Feature;
|
|
40
49
|
type: string;
|
|
41
50
|
}
|
|
42
51
|
interface DrawStartEvent {
|
|
52
|
+
interactionId: string;
|
|
43
53
|
feature: Feature;
|
|
44
54
|
}
|
|
45
55
|
interface ModifyEvent {
|
|
56
|
+
interactionId: string;
|
|
46
57
|
features: Feature[];
|
|
47
58
|
type: 'modifystart' | 'modifyend';
|
|
48
59
|
}
|
|
@@ -77,13 +88,14 @@ declare class OlInteractionService {
|
|
|
77
88
|
private selectService;
|
|
78
89
|
private drawService;
|
|
79
90
|
private modifyService;
|
|
80
|
-
readonly selectedFeatures:
|
|
81
|
-
readonly selectionCount:
|
|
82
|
-
readonly hasSelection:
|
|
83
|
-
readonly activeInteractions:
|
|
91
|
+
readonly selectedFeatures: _angular_core.Signal<_angular_helpers_openlayers_core.Feature[]>;
|
|
92
|
+
readonly selectionCount: _angular_core.Signal<number>;
|
|
93
|
+
readonly hasSelection: _angular_core.Signal<boolean>;
|
|
94
|
+
readonly activeInteractions: _angular_core.Signal<_angular_helpers_openlayers_interactions.ManagedInteraction[]>;
|
|
84
95
|
readonly drawStart$: rxjs.Observable<_angular_helpers_openlayers_interactions.DrawStartEvent>;
|
|
85
96
|
readonly drawEnd$: rxjs.Observable<_angular_helpers_openlayers_interactions.DrawEndEvent>;
|
|
86
97
|
readonly modify$: rxjs.Observable<_angular_helpers_openlayers_interactions.ModifyEvent>;
|
|
98
|
+
readonly select$: rxjs.Observable<_angular_helpers_openlayers_interactions.SelectEvent>;
|
|
87
99
|
/**
|
|
88
100
|
* Enable a select interaction on the map.
|
|
89
101
|
* @param id - Unique identifier for this interaction
|
|
@@ -138,8 +150,8 @@ declare class OlInteractionService {
|
|
|
138
150
|
* @returns Array of interaction state summaries
|
|
139
151
|
*/
|
|
140
152
|
getInteractionState(): _angular_helpers_openlayers_interactions.InteractionState[];
|
|
141
|
-
static ɵfac:
|
|
142
|
-
static ɵprov:
|
|
153
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<OlInteractionService, never>;
|
|
154
|
+
static ɵprov: _angular_core.ɵɵInjectableDeclaration<OlInteractionService>;
|
|
143
155
|
}
|
|
144
156
|
|
|
145
157
|
/**
|
|
@@ -169,15 +181,18 @@ declare class InteractionStateService {
|
|
|
169
181
|
private drawStartSubject;
|
|
170
182
|
private drawEndSubject;
|
|
171
183
|
private modifySubject;
|
|
172
|
-
|
|
173
|
-
readonly
|
|
174
|
-
readonly
|
|
175
|
-
readonly
|
|
184
|
+
private selectSubject;
|
|
185
|
+
readonly selectedFeatures: _angular_core.Signal<Feature[]>;
|
|
186
|
+
readonly selectionCount: _angular_core.Signal<number>;
|
|
187
|
+
readonly hasSelection: _angular_core.Signal<boolean>;
|
|
188
|
+
readonly activeInteractions: _angular_core.Signal<ManagedInteraction[]>;
|
|
176
189
|
readonly drawStart$: rxjs.Observable<DrawStartEvent>;
|
|
177
190
|
readonly drawEnd$: rxjs.Observable<DrawEndEvent>;
|
|
178
191
|
readonly modify$: rxjs.Observable<ModifyEvent>;
|
|
192
|
+
readonly select$: rxjs.Observable<SelectEvent>;
|
|
179
193
|
/**
|
|
180
194
|
* Adds a managed interaction to the state.
|
|
195
|
+
* If the interaction is marked as exclusive, it disables other exclusive interactions.
|
|
181
196
|
* @param interaction - The interaction to add
|
|
182
197
|
*/
|
|
183
198
|
addInteraction(interaction: ManagedInteraction): void;
|
|
@@ -221,6 +236,11 @@ declare class InteractionStateService {
|
|
|
221
236
|
* @param event - The modify event data
|
|
222
237
|
*/
|
|
223
238
|
emitModify(event: ModifyEvent): void;
|
|
239
|
+
/**
|
|
240
|
+
* Emits a select event.
|
|
241
|
+
* @param event - The select event data
|
|
242
|
+
*/
|
|
243
|
+
emitSelect(event: SelectEvent): void;
|
|
224
244
|
/**
|
|
225
245
|
* Gets the current interaction state summary.
|
|
226
246
|
* @returns Array of interaction state objects
|
|
@@ -237,8 +257,8 @@ declare class InteractionStateService {
|
|
|
237
257
|
* Note: This only clears the state tracking, not the actual OL interactions.
|
|
238
258
|
*/
|
|
239
259
|
clearAll(): void;
|
|
240
|
-
static ɵfac:
|
|
241
|
-
static ɵprov:
|
|
260
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<InteractionStateService, never>;
|
|
261
|
+
static ɵprov: _angular_core.ɵɵInjectableDeclaration<InteractionStateService>;
|
|
242
262
|
}
|
|
243
263
|
|
|
244
264
|
/**
|
|
@@ -256,8 +276,8 @@ declare class SelectInteractionService {
|
|
|
256
276
|
* @returns Promise that resolves when the interaction is created
|
|
257
277
|
*/
|
|
258
278
|
createSelectInteraction(id: string, config: SelectConfig, map: OLMap): void;
|
|
259
|
-
static ɵfac:
|
|
260
|
-
static ɵprov:
|
|
279
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<SelectInteractionService, never>;
|
|
280
|
+
static ɵprov: _angular_core.ɵɵInjectableDeclaration<SelectInteractionService>;
|
|
261
281
|
}
|
|
262
282
|
|
|
263
283
|
/**
|
|
@@ -276,8 +296,8 @@ declare class DrawInteractionService {
|
|
|
276
296
|
* @returns True if the interaction was created successfully
|
|
277
297
|
*/
|
|
278
298
|
createDrawInteraction(id: string, config: DrawConfig, map: OLMap): boolean;
|
|
279
|
-
static ɵfac:
|
|
280
|
-
static ɵprov:
|
|
299
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<DrawInteractionService, never>;
|
|
300
|
+
static ɵprov: _angular_core.ɵɵInjectableDeclaration<DrawInteractionService>;
|
|
281
301
|
}
|
|
282
302
|
|
|
283
303
|
/**
|
|
@@ -294,8 +314,30 @@ declare class ModifyInteractionService {
|
|
|
294
314
|
* @param map - OpenLayers map instance
|
|
295
315
|
*/
|
|
296
316
|
createModifyInteraction(id: string, config: ModifyConfig, map: OLMap): void;
|
|
297
|
-
static ɵfac:
|
|
298
|
-
static ɵprov:
|
|
317
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<ModifyInteractionService, never>;
|
|
318
|
+
static ɵprov: _angular_core.ɵɵInjectableDeclaration<ModifyInteractionService>;
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
declare class MeasurementInteractionService {
|
|
322
|
+
private mapService;
|
|
323
|
+
private zoneHelper;
|
|
324
|
+
private draw?;
|
|
325
|
+
private source;
|
|
326
|
+
private vectorLayer?;
|
|
327
|
+
private map?;
|
|
328
|
+
private sketch;
|
|
329
|
+
private measureTooltipElement;
|
|
330
|
+
private measureTooltip;
|
|
331
|
+
private listener;
|
|
332
|
+
private isMeasuring;
|
|
333
|
+
startMeasuring(type: 'LineString' | 'Polygon'): void;
|
|
334
|
+
stopMeasuring(): void;
|
|
335
|
+
isActive(): boolean;
|
|
336
|
+
private createMeasureTooltip;
|
|
337
|
+
private formatLength;
|
|
338
|
+
private formatArea;
|
|
339
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<MeasurementInteractionService, never>;
|
|
340
|
+
static ɵprov: _angular_core.ɵɵInjectableDeclaration<MeasurementInteractionService>;
|
|
299
341
|
}
|
|
300
342
|
|
|
301
343
|
/**
|
|
@@ -307,6 +349,63 @@ declare class ModifyInteractionService {
|
|
|
307
349
|
*/
|
|
308
350
|
declare function olFeatureToFeature(olFeature: Feature$1): Feature;
|
|
309
351
|
|
|
352
|
+
/**
|
|
353
|
+
* Declarative component to configure an OpenLayers Draw Interaction.
|
|
354
|
+
*/
|
|
355
|
+
declare class OlDrawInteractionComponent {
|
|
356
|
+
private interactionService;
|
|
357
|
+
private destroyRef;
|
|
358
|
+
id: _angular_core.InputSignal<string>;
|
|
359
|
+
type: _angular_core.InputSignal<"Point" | "LineString" | "Polygon" | "Circle">;
|
|
360
|
+
source: _angular_core.InputSignal<string>;
|
|
361
|
+
freehand: _angular_core.InputSignal<boolean>;
|
|
362
|
+
snapTolerance: _angular_core.InputSignal<number>;
|
|
363
|
+
active: _angular_core.InputSignal<boolean>;
|
|
364
|
+
private drawStartFiltered$;
|
|
365
|
+
private drawEndFiltered$;
|
|
366
|
+
drawStart: _angular_core.OutputRef<_angular_helpers_openlayers_interactions.DrawStartEvent>;
|
|
367
|
+
drawEnd: _angular_core.OutputRef<_angular_helpers_openlayers_interactions.DrawEndEvent>;
|
|
368
|
+
constructor();
|
|
369
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<OlDrawInteractionComponent, never>;
|
|
370
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<OlDrawInteractionComponent, "ol-draw-interaction", never, { "id": { "alias": "id"; "required": true; "isSignal": true; }; "type": { "alias": "type"; "required": true; "isSignal": true; }; "source": { "alias": "source"; "required": false; "isSignal": true; }; "freehand": { "alias": "freehand"; "required": false; "isSignal": true; }; "snapTolerance": { "alias": "snapTolerance"; "required": false; "isSignal": true; }; "active": { "alias": "active"; "required": false; "isSignal": true; }; }, { "drawStart": "drawStart"; "drawEnd": "drawEnd"; }, never, never, true, never>;
|
|
371
|
+
}
|
|
372
|
+
|
|
373
|
+
/**
|
|
374
|
+
* Declarative component to configure an OpenLayers Modify Interaction.
|
|
375
|
+
*/
|
|
376
|
+
declare class OlModifyInteractionComponent {
|
|
377
|
+
private interactionService;
|
|
378
|
+
private destroyRef;
|
|
379
|
+
id: _angular_core.InputSignal<string>;
|
|
380
|
+
source: _angular_core.InputSignal<string>;
|
|
381
|
+
snapTolerance: _angular_core.InputSignal<number>;
|
|
382
|
+
active: _angular_core.InputSignal<boolean>;
|
|
383
|
+
private modifyFiltered$;
|
|
384
|
+
modifyEvent: _angular_core.OutputRef<_angular_helpers_openlayers_interactions.ModifyEvent>;
|
|
385
|
+
constructor();
|
|
386
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<OlModifyInteractionComponent, never>;
|
|
387
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<OlModifyInteractionComponent, "ol-modify-interaction", never, { "id": { "alias": "id"; "required": true; "isSignal": true; }; "source": { "alias": "source"; "required": false; "isSignal": true; }; "snapTolerance": { "alias": "snapTolerance"; "required": false; "isSignal": true; }; "active": { "alias": "active"; "required": false; "isSignal": true; }; }, { "modifyEvent": "modifyEvent"; }, never, never, true, never>;
|
|
388
|
+
}
|
|
389
|
+
|
|
390
|
+
/**
|
|
391
|
+
* Declarative component to configure an OpenLayers Select Interaction.
|
|
392
|
+
*/
|
|
393
|
+
declare class OlSelectInteractionComponent {
|
|
394
|
+
private interactionService;
|
|
395
|
+
private destroyRef;
|
|
396
|
+
id: _angular_core.InputSignal<string>;
|
|
397
|
+
layers: _angular_core.InputSignal<string[]>;
|
|
398
|
+
multi: _angular_core.InputSignal<boolean>;
|
|
399
|
+
hitTolerance: _angular_core.InputSignal<number>;
|
|
400
|
+
condition: _angular_core.InputSignal<"click" | "pointerMove">;
|
|
401
|
+
active: _angular_core.InputSignal<boolean>;
|
|
402
|
+
private selectFiltered$;
|
|
403
|
+
selectEvent: _angular_core.OutputRef<_angular_helpers_openlayers_interactions.SelectEvent>;
|
|
404
|
+
constructor();
|
|
405
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<OlSelectInteractionComponent, never>;
|
|
406
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<OlSelectInteractionComponent, "ol-select-interaction", never, { "id": { "alias": "id"; "required": true; "isSignal": true; }; "layers": { "alias": "layers"; "required": false; "isSignal": true; }; "multi": { "alias": "multi"; "required": false; "isSignal": true; }; "hitTolerance": { "alias": "hitTolerance"; "required": false; "isSignal": true; }; "condition": { "alias": "condition"; "required": false; "isSignal": true; }; "active": { "alias": "active"; "required": false; "isSignal": true; }; }, { "selectEvent": "selectEvent"; }, never, never, true, never>;
|
|
407
|
+
}
|
|
408
|
+
|
|
310
409
|
/**
|
|
311
410
|
* Provide the interactions feature with OlInteractionService and all specialized services.
|
|
312
411
|
* Note: ZoneHelper is inherited from core's provideOpenLayers.
|
|
@@ -339,6 +438,11 @@ declare function withDrawInteraction(id: string, config: DrawConfig): Provider;
|
|
|
339
438
|
* @returns Provider function that enables modify interaction
|
|
340
439
|
*/
|
|
341
440
|
declare function withModifyInteraction(id: string, config?: ModifyConfig): Provider;
|
|
441
|
+
/**
|
|
442
|
+
* Enable measurement interaction when providing the interactions feature.
|
|
443
|
+
* @returns Provider function that enables measurement interaction
|
|
444
|
+
*/
|
|
445
|
+
declare function withMeasurementInteraction(): Provider;
|
|
342
446
|
|
|
343
|
-
export { DrawInteractionService, InteractionStateService, ModifyInteractionService, OlInteractionService, SelectInteractionService, olFeatureToFeature, provideInteractions, withDrawInteraction, withInteractions, withModifyInteraction, withSelectInteraction };
|
|
447
|
+
export { DrawInteractionService, InteractionStateService, MeasurementInteractionService, ModifyInteractionService, OlDrawInteractionComponent, OlInteractionService, OlModifyInteractionComponent, OlSelectInteractionComponent, SelectInteractionService, olFeatureToFeature, provideInteractions, withDrawInteraction, withInteractions, withMeasurementInteraction, withModifyInteraction, withSelectInteraction };
|
|
344
448
|
export type { DragAndDropConfig, DrawConfig, DrawEndEvent, DrawStartEvent, InteractionConfig, InteractionState, InteractionType, ManagedInteraction, ModifyConfig, ModifyEvent, SelectConfig, SelectEvent };
|