@superrouteca/smap 1.0.0 → 1.0.1
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/CHANGELOG.md +20 -1
- package/README.md +25 -8
- package/dist/SOURCE.json +11 -12
- package/dist/smap-client.cjs +1 -1
- package/dist/smap-client.d.cts +1 -1
- package/dist/smap-client.d.mts +1 -1
- package/dist/smap-client.d.ts +42 -0
- package/dist/smap-client.js +300 -0
- package/dist/smap-client.mjs +1 -1
- package/dist/smap.cjs +26924 -81
- package/dist/smap.css +24 -1
- package/dist/smap.js +27452 -0
- package/dist/smap.mjs +26924 -81
- package/package.json +18 -6
- package/types/smap.d.cts +5 -2
- package/types/smap.d.mts +5 -2
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@superrouteca/smap",
|
|
3
|
-
"version": "1.0.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "1.0.1",
|
|
4
|
+
"description": "sMap for the web: maps from Superroute's sMap service, the Web SDK (map view) and the JS client (tokens, nearest node, styles, tiles).",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Goodneo Solutions",
|
|
7
7
|
"homepage": "https://github.com/Goodneo-Solutions/smap-sdk/tree/main/js#readme",
|
|
@@ -10,8 +10,16 @@
|
|
|
10
10
|
"url": "git+https://github.com/Goodneo-Solutions/smap-sdk.git",
|
|
11
11
|
"directory": "js"
|
|
12
12
|
},
|
|
13
|
-
"keywords": [
|
|
14
|
-
|
|
13
|
+
"keywords": [
|
|
14
|
+
"map",
|
|
15
|
+
"maps",
|
|
16
|
+
"vector-tiles",
|
|
17
|
+
"smap",
|
|
18
|
+
"superroute"
|
|
19
|
+
],
|
|
20
|
+
"sideEffects": [
|
|
21
|
+
"*.css"
|
|
22
|
+
],
|
|
15
23
|
"main": "./dist/smap.cjs",
|
|
16
24
|
"module": "./dist/smap.mjs",
|
|
17
25
|
"types": "./types/smap.d.cts",
|
|
@@ -50,8 +58,12 @@
|
|
|
50
58
|
"node": ">=18"
|
|
51
59
|
},
|
|
52
60
|
"scripts": {
|
|
53
|
-
"
|
|
61
|
+
"build": "node build.mjs",
|
|
54
62
|
"prepack": "cp ../LICENSE LICENSE",
|
|
55
|
-
"test": "node --test test/*.test.mjs"
|
|
63
|
+
"test": "node --test test/*.test.mjs test/*.test.cjs"
|
|
64
|
+
},
|
|
65
|
+
"devDependencies": {
|
|
66
|
+
"esbuild": "0.28.2",
|
|
67
|
+
"maplibre-gl": "6.16.0"
|
|
56
68
|
}
|
|
57
69
|
}
|
package/types/smap.d.cts
CHANGED
|
@@ -49,8 +49,11 @@ interface CommonLayerOptions {
|
|
|
49
49
|
maxzoom?: number;
|
|
50
50
|
/** A feature property used as the feature id. */
|
|
51
51
|
idProperty?: string;
|
|
52
|
-
/**
|
|
53
|
-
|
|
52
|
+
/**
|
|
53
|
+
* A popup opened on click, from the clicked feature's properties: an HTML string, inserted as it is and never
|
|
54
|
+
* sanitized (so it must be trusted; escape any feature data you put in it), or a DOM node.
|
|
55
|
+
*/
|
|
56
|
+
popup?: (properties: Record<string, unknown>, feature: GeoJSONFeature) => string | Node | null | undefined | false;
|
|
54
57
|
onClick?: (feature: GeoJSONFeature, event: LayerClickEvent) => void;
|
|
55
58
|
}
|
|
56
59
|
|
package/types/smap.d.mts
CHANGED
|
@@ -49,8 +49,11 @@ interface CommonLayerOptions {
|
|
|
49
49
|
maxzoom?: number;
|
|
50
50
|
/** A feature property used as the feature id. */
|
|
51
51
|
idProperty?: string;
|
|
52
|
-
/**
|
|
53
|
-
|
|
52
|
+
/**
|
|
53
|
+
* A popup opened on click, from the clicked feature's properties: an HTML string, inserted as it is and never
|
|
54
|
+
* sanitized (so it must be trusted; escape any feature data you put in it), or a DOM node.
|
|
55
|
+
*/
|
|
56
|
+
popup?: (properties: Record<string, unknown>, feature: GeoJSONFeature) => string | Node | null | undefined | false;
|
|
54
57
|
onClick?: (feature: GeoJSONFeature, event: LayerClickEvent) => void;
|
|
55
58
|
}
|
|
56
59
|
|