@opensystemslab/map 0.5.7 → 0.5.8
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 +28 -133
- package/dist/component-lib.es.js +24472 -19124
- package/dist/component-lib.umd.js +64 -44
- package/dist/style.css +1 -1
- package/package.json +26 -7
- package/types/components/address-autocomplete/main.test.d.ts +6 -0
- package/types/components/my-map/index.d.ts +2 -0
- package/types/components/my-map/main.test.d.ts +6 -0
- package/types/components/my-map/projections.d.ts +3 -0
- package/types/components/postcode-search/main.test.d.ts +6 -0
- package/types/test-utils.d.ts +2 -0
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@opensystemslab/map",
|
3
|
-
"version": "0.5.
|
3
|
+
"version": "0.5.8",
|
4
4
|
"license": "OGL-UK-3.0",
|
5
5
|
"private": false,
|
6
6
|
"repository": {
|
@@ -19,29 +19,48 @@
|
|
19
19
|
"dev": "vite",
|
20
20
|
"build": "rm -rf dist types && tsc && vite build && sed 's/src=\".*\"/src=\"component-lib.es.js\"/' index.html > dist/index.html",
|
21
21
|
"prepublishOnly": "npm run build",
|
22
|
-
"prepare": "husky install"
|
22
|
+
"prepare": "husky install",
|
23
|
+
"test": "vitest",
|
24
|
+
"test:ui": "vitest --ui",
|
25
|
+
"docs": "NODE_ENV=development pitsby build --watch --port=7007",
|
26
|
+
"docsPublish": "pitsby build"
|
23
27
|
},
|
24
28
|
"dependencies": {
|
25
29
|
"@turf/union": "^6.5.0",
|
26
30
|
"accessible-autocomplete": "^2.0.4",
|
27
31
|
"govuk-frontend": "^4.0.1",
|
28
|
-
"lit": "^2.
|
29
|
-
"ol": "^
|
30
|
-
"ol-mapbox-style": "^
|
32
|
+
"lit": "^2.3.1",
|
33
|
+
"ol": "^7.0.0",
|
34
|
+
"ol-mapbox-style": "^9.0.0",
|
31
35
|
"postcode": "^5.1.0",
|
36
|
+
"proj4": "^2.8.0",
|
32
37
|
"rambda": "^7.0.1"
|
33
38
|
},
|
34
39
|
"devDependencies": {
|
35
|
-
"@
|
40
|
+
"@glorious/pitsby": "^1.30.16",
|
41
|
+
"@testing-library/dom": "^8.17.1",
|
42
|
+
"@testing-library/user-event": "^14.4.3",
|
43
|
+
"@types/node": "^18.6.3",
|
44
|
+
"@types/proj4": "^2.5.2",
|
45
|
+
"@vitest/ui": "^0.22.1",
|
46
|
+
"happy-dom": "^6.0.4",
|
36
47
|
"husky": "^8.0.1",
|
37
48
|
"lint-staged": "^13.0.3",
|
38
49
|
"prettier": "^2.3.2",
|
39
50
|
"rollup-plugin-postcss-lit": "^2.0.0",
|
40
51
|
"sass": "^1.44.0",
|
41
52
|
"typescript": "^4.3.5",
|
42
|
-
"vite": "^3.0.
|
53
|
+
"vite": "^3.0.4",
|
54
|
+
"vitest": "0.20.3"
|
55
|
+
},
|
56
|
+
"engines": {
|
57
|
+
"node": "^16",
|
58
|
+
"pnpm": "^7.8.0"
|
43
59
|
},
|
44
60
|
"lint-staged": {
|
45
61
|
"src/**/*.{js,jsx,ts,tsx,json,css,scss,md,html}": "prettier --write"
|
62
|
+
},
|
63
|
+
"stackblitz": {
|
64
|
+
"startCommand": "npm run test:ui"
|
46
65
|
}
|
47
66
|
}
|
@@ -1,6 +1,7 @@
|
|
1
1
|
import { LitElement } from "lit";
|
2
2
|
import Map from "ol/Map";
|
3
3
|
import { DrawPointerEnum } from "./drawing";
|
4
|
+
import { ProjectionEnum } from "./projections";
|
4
5
|
import { AreaUnitEnum } from "./utils";
|
5
6
|
declare type MarkerImageEnum = "circle" | "pin";
|
6
7
|
export declare class MyMap extends LitElement {
|
@@ -8,6 +9,7 @@ export declare class MyMap extends LitElement {
|
|
8
9
|
id: string;
|
9
10
|
latitude: number;
|
10
11
|
longitude: number;
|
12
|
+
projection: ProjectionEnum;
|
11
13
|
zoom: number;
|
12
14
|
minZoom: number;
|
13
15
|
maxZoom: number;
|