@opensystemslab/map 0.8.1 → 0.8.2
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/component-lib.es.js +1 -1
- package/dist/component-lib.umd.js +101 -101
- package/dist/{index-eQGV5hbg.mjs → index-1HbxZ3C1.mjs} +21748 -19249
- package/dist/{index.es-BHgSsn4a.mjs → index.es-BF5JbvAz.mjs} +1 -1
- package/dist/index.html +1 -1
- package/dist/style.css +1 -1
- package/package.json +5 -5
- package/types/components/my-map/drawing.d.ts +2 -2
- package/types/components/my-map/index.d.ts +1 -0
- package/types/components/my-map/os-features.d.ts +2 -2
- package/types/components/my-map/snapping.d.ts +2 -2
- package/types/components/my-map/utils.d.ts +2 -2
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@opensystemslab/map",
|
3
|
-
"version": "0.8.
|
3
|
+
"version": "0.8.2",
|
4
4
|
"license": "MPL-2.0",
|
5
5
|
"private": false,
|
6
6
|
"repository": {
|
@@ -32,9 +32,9 @@
|
|
32
32
|
"govuk-frontend": "^5.0.0",
|
33
33
|
"jspdf": "^2.5.1",
|
34
34
|
"lit": "^3.0.1",
|
35
|
-
"ol": "^
|
36
|
-
"ol-ext": "^4.0.
|
37
|
-
"ol-mapbox-style": "^12.
|
35
|
+
"ol": "^9.1.0",
|
36
|
+
"ol-ext": "^4.0.17",
|
37
|
+
"ol-mapbox-style": "^12.3.0",
|
38
38
|
"postcode": "^5.1.0",
|
39
39
|
"proj4": "^2.9.2",
|
40
40
|
"rambda": "^8.6.0"
|
@@ -45,7 +45,7 @@
|
|
45
45
|
"@testing-library/user-event": "^14.5.2",
|
46
46
|
"@types/file-saver": "^2.0.7",
|
47
47
|
"@types/node": "18.19.21",
|
48
|
-
"@types/ol-ext": "npm:@siedlerchr/types-ol-ext@^3.0
|
48
|
+
"@types/ol-ext": "npm:@siedlerchr/types-ol-ext@^3.3.0",
|
49
49
|
"@types/proj4": "^2.5.5",
|
50
50
|
"@vitest/ui": "^0.34.7",
|
51
51
|
"happy-dom": "^9.1.9",
|
@@ -3,8 +3,8 @@ import { Vector as VectorLayer } from "ol/layer";
|
|
3
3
|
import { Vector as VectorSource } from "ol/source";
|
4
4
|
export type DrawTypeEnum = "Polygon" | "Point";
|
5
5
|
export type DrawPointerEnum = "crosshair" | "dot";
|
6
|
-
export declare const drawingSource: VectorSource<import("ol/geom/Geometry").default
|
7
|
-
export declare function configureDrawingLayer(drawType: DrawTypeEnum, pointColor: string, drawColor: string, drawFillColor: string): VectorLayer<VectorSource<import("ol/geom/Geometry").default
|
6
|
+
export declare const drawingSource: VectorSource<import("ol/Feature").default<import("ol/geom/Geometry").default>>;
|
7
|
+
export declare function configureDrawingLayer(drawType: DrawTypeEnum, pointColor: string, drawColor: string, drawFillColor: string): VectorLayer<VectorSource<import("ol/Feature").default<import("ol/geom/Geometry").default>>>;
|
8
8
|
export declare function configureDraw(drawType: DrawTypeEnum, pointerStyle: DrawPointerEnum, pointColor: string, drawColor: string, drawFillColor: string): Draw;
|
9
9
|
export declare const snap: Snap;
|
10
10
|
export declare function configureModify(pointerStyle: DrawPointerEnum, drawColor: string): Modify;
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { Vector as VectorLayer } from "ol/layer";
|
2
2
|
import { Vector as VectorSource } from "ol/source";
|
3
|
-
export declare const outlineSource: VectorSource<import("ol/geom/Geometry").default
|
4
|
-
export declare function makeFeatureLayer(color: string, featureFill: boolean, borderNone: boolean): VectorLayer<VectorSource<import("ol/geom/Geometry").default
|
3
|
+
export declare const outlineSource: VectorSource<import("ol/Feature").default<import("ol/geom/Geometry").default>>;
|
4
|
+
export declare function makeFeatureLayer(color: string, featureFill: boolean, borderNone: boolean): VectorLayer<VectorSource<import("ol/Feature").default<import("ol/geom/Geometry").default>>>;
|
5
5
|
/**
|
6
6
|
* Create an OGC XML filter parameter value which will select the TopographicArea
|
7
7
|
* features containing the coordinates of the provided point
|
@@ -1,8 +1,8 @@
|
|
1
1
|
import { Vector as VectorLayer } from "ol/layer";
|
2
2
|
import VectorTileLayer from "ol/layer/VectorTile";
|
3
3
|
import VectorSource from "ol/source/Vector";
|
4
|
-
export declare const pointsSource: VectorSource<
|
5
|
-
export declare const pointsLayer: VectorLayer<VectorSource<
|
4
|
+
export declare const pointsSource: VectorSource<never>;
|
5
|
+
export declare const pointsLayer: VectorLayer<VectorSource<never>>;
|
6
6
|
/**
|
7
7
|
* Extract points that are available to snap to when a VectorTileLayer basemap is displayed
|
8
8
|
* @param basemap - a VectorTileLayer
|
@@ -20,7 +20,7 @@ export declare function formatArea(polygon: Geometry, unit: AreaUnitEnum): strin
|
|
20
20
|
* @param bufferValue - amount to buffer extent by, refer to https://openlayers.org/en/latest/apidoc/module-ol_extent.html#.buffer
|
21
21
|
* @returns - a map view
|
22
22
|
*/
|
23
|
-
export declare function fitToData(olMap: Map, olSource: Vector<Geometry
|
23
|
+
export declare function fitToData(olMap: Map, olSource: Vector<Feature<Geometry>>, bufferValue: number): void;
|
24
24
|
/**
|
25
25
|
* Translate a hex color to an rgba string with opacity
|
26
26
|
* @param hexColor - a hex color string
|
@@ -34,4 +34,4 @@ export declare function hexToRgba(hexColor: string, alpha: number): string;
|
|
34
34
|
* @param projection
|
35
35
|
* @returns
|
36
36
|
*/
|
37
|
-
export declare function makeGeoJSON(source: VectorSource<Geometry
|
37
|
+
export declare function makeGeoJSON(source: VectorSource<Feature<Geometry>> | Feature<Geometry>[], projection: ProjectionEnum): GeoJSONObject;
|