mapicgc-gl-js 0.0.76 → 0.0.77
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 +27 -14
- package/dist/{index-7vA8gJhT.mjs → index-k0DrX4BJ.mjs} +1172 -1127
- package/dist/{index.es-BR8y8uSW-DmctbIix.mjs → index.es-BR8y8uSW-D6xEGnjs.mjs} +1 -1
- package/dist/mapicgc-gl.js +46 -46
- package/dist/mapicgc-gl.mjs +1 -1
- package/dist/mapicgc-gl.umd.js +46 -46
- package/nodeDeploy.js +2 -2
- package/package.json +1 -1
- package/src/map/Map.js +87 -20
- package/test/exemples/addFeatureQuery.html +1 -1
- package/test/exemples/addLogo.html +1 -1
- package/test/exemples/advancedExemple.html +1 -1
- package/test/exemples/fetchData.html +1 -2
package/README.md
CHANGED
|
@@ -47,14 +47,22 @@ Check out the features through <a href="https://codepen.io/collection/mrvVZd" ta
|
|
|
47
47
|
2. Import the library:
|
|
48
48
|
```html
|
|
49
49
|
<script>
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
50
|
+
import { Map, Config } from "mapicgc-gl-js";
|
|
51
|
+
//import * as mapicgcgl from "mapicgc-gl-js";
|
|
52
|
+
|
|
53
|
+
async function initMap() {
|
|
54
|
+
const data = await Config.getConfigICGC(); //load config
|
|
55
|
+
const map = new Map({
|
|
56
|
+
container: "map",
|
|
57
|
+
style: data.Styles.LIGHT,
|
|
58
|
+
center: [1.808, 41.618],
|
|
59
|
+
zoom: 10,
|
|
60
|
+
maxZoom: 19,
|
|
61
|
+
hash: true,
|
|
62
|
+
pitch: 0,
|
|
63
|
+
});
|
|
64
|
+
}
|
|
65
|
+
initMap();
|
|
58
66
|
</script>
|
|
59
67
|
```
|
|
60
68
|
### CDN
|
|
@@ -70,12 +78,17 @@ Check out the features through <a href="https://codepen.io/collection/mrvVZd" ta
|
|
|
70
78
|
```html
|
|
71
79
|
<div id="map"></div>
|
|
72
80
|
<script>
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
81
|
+
async function initMap() {
|
|
82
|
+
const data = await mapicgcgl.Config.getConfigICGC();
|
|
83
|
+
const map = new mapicgcgl.Map({
|
|
84
|
+
container: "map",
|
|
85
|
+
style: data.Styles.TOPO, // <-- add style basemap here
|
|
86
|
+
center: [2.1464, 41.306],
|
|
87
|
+
zoom: 7.4,
|
|
88
|
+
maxZoom: 19,
|
|
89
|
+
hash: true,
|
|
90
|
+
pitch: 0,
|
|
91
|
+
});
|
|
79
92
|
</script>
|
|
80
93
|
```
|
|
81
94
|
|