@artstesh/maps 1.1.17 → 1.1.19
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/dist/bundles/maps-components-src-map.umd.js +12 -5
- package/dist/bundles/maps-components-src-map.umd.js.map +1 -1
- package/dist/bundles/maps-components.umd.js +12 -5
- package/dist/bundles/maps-components.umd.js.map +1 -1
- package/dist/esm2015/map/models/index.js +2 -1
- package/dist/esm2015/map/models/polygon.model.js +8 -1
- package/dist/esm2015/src/map/models/index.js +2 -1
- package/dist/esm2015/src/map/models/polygon.model.js +8 -1
- package/dist/fesm2015/maps-components-src-map.js +7 -2
- package/dist/fesm2015/maps-components-src-map.js.map +1 -1
- package/dist/fesm2015/maps-components.js +7 -2
- package/dist/fesm2015/maps-components.js.map +1 -1
- package/dist/map/models/index.d.ts +1 -0
- package/dist/map/models/polygon.model.d.ts +3 -0
- package/dist/src/map/models/index.d.ts +1 -0
- package/dist/src/map/models/polygon.model.d.ts +3 -0
- package/package.json +1 -1
|
@@ -6,6 +6,7 @@ import { Feature, Collection } from 'ol';
|
|
|
6
6
|
import { Point } from 'ol/geom';
|
|
7
7
|
import { GeoJSON, WKT } from 'ol/format';
|
|
8
8
|
import { getCenter, createEmpty, extend } from 'ol/extent';
|
|
9
|
+
import Polygon, { circular, fromExtent } from 'ol/geom/Polygon';
|
|
9
10
|
import { Control, Zoom } from 'ol/control';
|
|
10
11
|
import { get, useGeographic, transform } from 'ol/proj';
|
|
11
12
|
import { PostboyGenericMessage, PostboyCallbackMessage, PostboyExecutor, PostboyService, PostboyAbstractRegistrator } from '@artstesh/postboy';
|
|
@@ -19,7 +20,6 @@ import TileLayer from 'ol/layer/Tile';
|
|
|
19
20
|
import OSM from 'ol/source/OSM';
|
|
20
21
|
import { Vector as Vector$1 } from 'ol/layer';
|
|
21
22
|
import { bbox } from 'ol/loadingstrategy';
|
|
22
|
-
import Polygon, { fromExtent } from 'ol/geom/Polygon';
|
|
23
23
|
import Cluster from 'ol/source/Cluster';
|
|
24
24
|
import { combineLatest } from 'rxjs';
|
|
25
25
|
import Map from 'ol/Map';
|
|
@@ -239,6 +239,11 @@ class PolygonModel {
|
|
|
239
239
|
feature.setId(id);
|
|
240
240
|
return new PolygonModel(feature, id, info);
|
|
241
241
|
}
|
|
242
|
+
static circle(id, lat, lng, radius, vertices = 32, info) {
|
|
243
|
+
let feature = new Feature(circular([lng, lat], radius, vertices));
|
|
244
|
+
feature.setId(id);
|
|
245
|
+
return new PolygonModel(feature, id, info);
|
|
246
|
+
}
|
|
242
247
|
}
|
|
243
248
|
|
|
244
249
|
/**
|
|
@@ -2758,5 +2763,5 @@ class StringifyFeatureHelper {
|
|
|
2758
2763
|
* Generated bundle index. Do not edit.
|
|
2759
2764
|
*/
|
|
2760
2765
|
|
|
2761
|
-
export { AddControlCommand, CalculateAreaExecutor, CancelDrawingCommand, CancelFeatureModificationCommand, CloseTooltipCommand, ClusterLayerComponent, ClusterLayerSettings, DrawSelectionAreaCommand, DrawingType, FeatureLayerComponent, FeatureLayerSettings, FeatureOutputFormat, FilterFeaturesInAreaExecutor, FilterFeaturesInPointExecutor, FitToPolygonsCommand, GetFeaturesInAreaQuery, GetFeaturesInPointQuery, GetMapPositionExecutor, MapClickEvent, MapControl, MapControlZoomComponent, MapLyrs, MapLyrsLabel, MapModule, MapMoveEndEvent, MapPlateComponent, MapPostboyService, MapRenderedEvent, MapSettings, MarkerModel, MarkerStyleHelper, MarkersComponent, MessageRegistratorService, ModifyFeatureCommand, OsmTileLayerComponent, PolygonModel, PolygonStyleHelper, PolygonsComponent, RemoveControlCommand, SetMapCenterCommand, StartDrawingCommand, StringifyFeatureHelper, TextStyleHelper, TileLayerComponent, TileLayerSettings, TooltipComponent, TooltipSettings, ZoomControlSettings };
|
|
2766
|
+
export { AddControlCommand, CalculateAreaExecutor, CancelDrawingCommand, CancelFeatureModificationCommand, CloseTooltipCommand, ClusterLayerComponent, ClusterLayerSettings, DrawSelectionAreaCommand, DrawingType, FeatureLayerComponent, FeatureLayerSettings, FeatureOutputFormat, FilterFeaturesInAreaExecutor, FilterFeaturesInPointExecutor, FitToPolygonsCommand, GetFeaturesInAreaQuery, GetFeaturesInPointQuery, GetMapPositionExecutor, MapClickEvent, MapConstants, MapControl, MapControlZoomComponent, MapLyrs, MapLyrsLabel, MapModule, MapMoveEndEvent, MapPlateComponent, MapPostboyService, MapRenderedEvent, MapSettings, MarkerModel, MarkerStyleHelper, MarkersComponent, MessageRegistratorService, ModifyFeatureCommand, OsmTileLayerComponent, PolygonModel, PolygonStyleHelper, PolygonsComponent, RemoveControlCommand, SetMapCenterCommand, StartDrawingCommand, StringifyFeatureHelper, TextStyleHelper, TileLayerComponent, TileLayerSettings, TooltipComponent, TooltipSettings, ZoomControlSettings };
|
|
2762
2767
|
//# sourceMappingURL=maps-components.js.map
|