@inlog/inlog-maps 1.0.0 → 1.1.0-test
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/DOCUMENTATION.md +1813 -0
- package/README.md +46 -591
- package/_bundles/inlog-maps.js +3 -0
- package/_bundles/inlog-maps.js.LICENSE.txt +20 -0
- package/_bundles/inlog-maps.js.map +1 -0
- package/_bundles/inlog-maps.min.js +3 -0
- package/_bundles/inlog-maps.min.js.LICENSE.txt +20 -0
- package/_bundles/inlog-maps.min.js.map +1 -0
- package/bower.json +23 -0
- package/lib/index.d.ts +46 -0
- package/lib/index.js +47 -0
- package/lib/index.js.map +1 -0
- package/lib/map.d.ts +519 -0
- package/lib/map.js +1137 -0
- package/lib/map.js.map +1 -0
- package/lib/models/apis/google/google-circles.d.ts +18 -0
- package/lib/models/apis/google/google-circles.js +134 -0
- package/lib/models/apis/google/google-circles.js.map +1 -0
- package/lib/models/apis/google/google-geojson.d.ts +9 -0
- package/lib/models/apis/google/google-geojson.js +73 -0
- package/lib/models/apis/google/google-geojson.js.map +1 -0
- package/lib/models/apis/google/google-map.d.ts +16 -0
- package/lib/models/apis/google/google-map.js +174 -0
- package/lib/models/apis/google/google-map.js.map +1 -0
- package/lib/models/apis/google/google-markers.d.ts +29 -0
- package/lib/models/apis/google/google-markers.js +325 -0
- package/lib/models/apis/google/google-markers.js.map +1 -0
- package/lib/models/apis/google/google-overlay.d.ts +11 -0
- package/lib/models/apis/google/google-overlay.js +102 -0
- package/lib/models/apis/google/google-overlay.js.map +1 -0
- package/lib/models/apis/google/google-polygons.d.ts +29 -0
- package/lib/models/apis/google/google-polygons.js +301 -0
- package/lib/models/apis/google/google-polygons.js.map +1 -0
- package/lib/models/apis/google/google-polylines.d.ts +55 -0
- package/lib/models/apis/google/google-polylines.js +707 -0
- package/lib/models/apis/google/google-polylines.js.map +1 -0
- package/lib/models/apis/google/google-popup.d.ts +10 -0
- package/lib/models/apis/google/google-popup.js +59 -0
- package/lib/models/apis/google/google-popup.js.map +1 -0
- package/lib/models/apis/googleMaps.d.ts +97 -0
- package/lib/models/apis/googleMaps.js +449 -0
- package/lib/models/apis/googleMaps.js.map +1 -0
- package/lib/models/apis/leaflet/leaflet-circle.d.ts +18 -0
- package/lib/models/apis/leaflet/leaflet-circle.js +163 -0
- package/lib/models/apis/leaflet/leaflet-circle.js.map +1 -0
- package/lib/models/apis/leaflet/leaflet-geojson.d.ts +9 -0
- package/lib/models/apis/leaflet/leaflet-geojson.js +73 -0
- package/lib/models/apis/leaflet/leaflet-geojson.js.map +1 -0
- package/lib/models/apis/leaflet/leaflet-map.d.ts +16 -0
- package/lib/models/apis/leaflet/leaflet-map.js +140 -0
- package/lib/models/apis/leaflet/leaflet-map.js.map +1 -0
- package/lib/models/apis/leaflet/leaflet-markers.d.ts +29 -0
- package/lib/models/apis/leaflet/leaflet-markers.js +294 -0
- package/lib/models/apis/leaflet/leaflet-markers.js.map +1 -0
- package/lib/models/apis/leaflet/leaflet-overlay.d.ts +10 -0
- package/lib/models/apis/leaflet/leaflet-overlay.js +35 -0
- package/lib/models/apis/leaflet/leaflet-overlay.js.map +1 -0
- package/lib/models/apis/leaflet/leaflet-polygons.d.ts +23 -0
- package/lib/models/apis/leaflet/leaflet-polygons.js +211 -0
- package/lib/models/apis/leaflet/leaflet-polygons.js.map +1 -0
- package/lib/models/apis/leaflet/leaflet-polylines.d.ts +55 -0
- package/lib/models/apis/leaflet/leaflet-polylines.js +721 -0
- package/lib/models/apis/leaflet/leaflet-polylines.js.map +1 -0
- package/lib/models/apis/leaflet/leaflet-popup.d.ts +11 -0
- package/lib/models/apis/leaflet/leaflet-popup.js +74 -0
- package/lib/models/apis/leaflet/leaflet-popup.js.map +1 -0
- package/lib/models/apis/leaflet.d.ts +99 -0
- package/lib/models/apis/leaflet.js +464 -0
- package/lib/models/apis/leaflet.js.map +1 -0
- package/lib/models/apis/mapFunctions.d.ts +85 -0
- package/lib/models/apis/mapFunctions.js +2 -0
- package/lib/models/apis/mapFunctions.js.map +1 -0
- package/lib/models/dto/event-type.d.ts +33 -0
- package/lib/models/dto/event-type.js +39 -0
- package/lib/models/dto/event-type.js.map +1 -0
- package/lib/models/dto/map-type.d.ts +4 -0
- package/lib/models/dto/map-type.js +6 -0
- package/lib/models/dto/map-type.js.map +1 -0
- package/lib/models/dto/polyline-type.d.ts +5 -0
- package/lib/models/dto/polyline-type.js +7 -0
- package/lib/models/dto/polyline-type.js.map +1 -0
- package/lib/models/features/circle/circle-alter-options.d.ts +12 -0
- package/lib/models/features/circle/circle-alter-options.js +14 -0
- package/lib/models/features/circle/circle-alter-options.js.map +1 -0
- package/lib/models/features/circle/circle-options.d.ts +15 -0
- package/lib/models/features/circle/circle-options.js +19 -0
- package/lib/models/features/circle/circle-options.js.map +1 -0
- package/lib/models/features/events/event-return.d.ts +4 -0
- package/lib/models/features/events/event-return.js +8 -0
- package/lib/models/features/events/event-return.js.map +1 -0
- package/lib/models/features/geojson/geojson-options.d.ts +5 -0
- package/lib/models/features/geojson/geojson-options.js +9 -0
- package/lib/models/features/geojson/geojson-options.js.map +1 -0
- package/lib/models/features/marker/circle-marker-options.d.ts +9 -0
- package/lib/models/features/marker/circle-marker-options.js +12 -0
- package/lib/models/features/marker/circle-marker-options.js.map +1 -0
- package/lib/models/features/marker/circle-marker-style.d.ts +8 -0
- package/lib/models/features/marker/circle-marker-style.js +12 -0
- package/lib/models/features/marker/circle-marker-style.js.map +1 -0
- package/lib/models/features/marker/marker-alter-options.d.ts +8 -0
- package/lib/models/features/marker/marker-alter-options.js +10 -0
- package/lib/models/features/marker/marker-alter-options.js.map +1 -0
- package/lib/models/features/marker/marker-icon.d.ts +6 -0
- package/lib/models/features/marker/marker-icon.js +10 -0
- package/lib/models/features/marker/marker-icon.js.map +1 -0
- package/lib/models/features/marker/marker-options.d.ts +11 -0
- package/lib/models/features/marker/marker-options.js +18 -0
- package/lib/models/features/marker/marker-options.js.map +1 -0
- package/lib/models/features/marker-clusterer/marker-clusterer-config.d.ts +6 -0
- package/lib/models/features/marker-clusterer/marker-clusterer-config.js +10 -0
- package/lib/models/features/marker-clusterer/marker-clusterer-config.js.map +1 -0
- package/lib/models/features/overlay/overlay-options.d.ts +11 -0
- package/lib/models/features/overlay/overlay-options.js +15 -0
- package/lib/models/features/overlay/overlay-options.js.map +1 -0
- package/lib/models/features/polygons/polygon-alter-options.d.ts +13 -0
- package/lib/models/features/polygons/polygon-alter-options.js +14 -0
- package/lib/models/features/polygons/polygon-alter-options.js.map +1 -0
- package/lib/models/features/polygons/polygon-options.d.ts +15 -0
- package/lib/models/features/polygons/polygon-options.js +19 -0
- package/lib/models/features/polygons/polygon-options.js.map +1 -0
- package/lib/models/features/polyline/navigations-options.d.ts +11 -0
- package/lib/models/features/polyline/navigations-options.js +16 -0
- package/lib/models/features/polyline/navigations-options.js.map +1 -0
- package/lib/models/features/polyline/polyline-options.d.ts +18 -0
- package/lib/models/features/polyline/polyline-options.js +20 -0
- package/lib/models/features/polyline/polyline-options.js.map +1 -0
- package/lib/models/features/popup/popup-options.d.ts +9 -0
- package/lib/models/features/popup/popup-options.js +13 -0
- package/lib/models/features/popup/popup-options.js.map +1 -0
- package/lib/utils/maps-api-loader.service.d.ts +14 -0
- package/lib/utils/maps-api-loader.service.js +89 -0
- package/lib/utils/maps-api-loader.service.js.map +1 -0
- package/lib/utils/url-builder.d.ts +20 -0
- package/lib/utils/url-builder.js +44 -0
- package/lib/utils/url-builder.js.map +1 -0
- package/lib-esm/index.d.ts +46 -0
- package/lib-esm/index.js +47 -0
- package/lib-esm/index.js.map +1 -0
- package/lib-esm/map.d.ts +519 -0
- package/lib-esm/map.js +1137 -0
- package/lib-esm/map.js.map +1 -0
- package/lib-esm/models/apis/google/google-circles.d.ts +18 -0
- package/lib-esm/models/apis/google/google-circles.js +134 -0
- package/lib-esm/models/apis/google/google-circles.js.map +1 -0
- package/lib-esm/models/apis/google/google-geojson.d.ts +9 -0
- package/lib-esm/models/apis/google/google-geojson.js +73 -0
- package/lib-esm/models/apis/google/google-geojson.js.map +1 -0
- package/lib-esm/models/apis/google/google-map.d.ts +16 -0
- package/lib-esm/models/apis/google/google-map.js +174 -0
- package/lib-esm/models/apis/google/google-map.js.map +1 -0
- package/lib-esm/models/apis/google/google-markers.d.ts +29 -0
- package/lib-esm/models/apis/google/google-markers.js +325 -0
- package/lib-esm/models/apis/google/google-markers.js.map +1 -0
- package/lib-esm/models/apis/google/google-overlay.d.ts +11 -0
- package/lib-esm/models/apis/google/google-overlay.js +102 -0
- package/lib-esm/models/apis/google/google-overlay.js.map +1 -0
- package/lib-esm/models/apis/google/google-polygons.d.ts +29 -0
- package/lib-esm/models/apis/google/google-polygons.js +301 -0
- package/lib-esm/models/apis/google/google-polygons.js.map +1 -0
- package/lib-esm/models/apis/google/google-polylines.d.ts +55 -0
- package/lib-esm/models/apis/google/google-polylines.js +707 -0
- package/lib-esm/models/apis/google/google-polylines.js.map +1 -0
- package/lib-esm/models/apis/google/google-popup.d.ts +10 -0
- package/lib-esm/models/apis/google/google-popup.js +59 -0
- package/lib-esm/models/apis/google/google-popup.js.map +1 -0
- package/lib-esm/models/apis/googleMaps.d.ts +97 -0
- package/lib-esm/models/apis/googleMaps.js +449 -0
- package/lib-esm/models/apis/googleMaps.js.map +1 -0
- package/lib-esm/models/apis/leaflet/leaflet-circle.d.ts +18 -0
- package/lib-esm/models/apis/leaflet/leaflet-circle.js +163 -0
- package/lib-esm/models/apis/leaflet/leaflet-circle.js.map +1 -0
- package/lib-esm/models/apis/leaflet/leaflet-geojson.d.ts +9 -0
- package/lib-esm/models/apis/leaflet/leaflet-geojson.js +73 -0
- package/lib-esm/models/apis/leaflet/leaflet-geojson.js.map +1 -0
- package/lib-esm/models/apis/leaflet/leaflet-map.d.ts +16 -0
- package/lib-esm/models/apis/leaflet/leaflet-map.js +140 -0
- package/lib-esm/models/apis/leaflet/leaflet-map.js.map +1 -0
- package/lib-esm/models/apis/leaflet/leaflet-markers.d.ts +29 -0
- package/lib-esm/models/apis/leaflet/leaflet-markers.js +294 -0
- package/lib-esm/models/apis/leaflet/leaflet-markers.js.map +1 -0
- package/lib-esm/models/apis/leaflet/leaflet-overlay.d.ts +10 -0
- package/lib-esm/models/apis/leaflet/leaflet-overlay.js +35 -0
- package/lib-esm/models/apis/leaflet/leaflet-overlay.js.map +1 -0
- package/lib-esm/models/apis/leaflet/leaflet-polygons.d.ts +23 -0
- package/lib-esm/models/apis/leaflet/leaflet-polygons.js +211 -0
- package/lib-esm/models/apis/leaflet/leaflet-polygons.js.map +1 -0
- package/lib-esm/models/apis/leaflet/leaflet-polylines.d.ts +55 -0
- package/lib-esm/models/apis/leaflet/leaflet-polylines.js +721 -0
- package/lib-esm/models/apis/leaflet/leaflet-polylines.js.map +1 -0
- package/lib-esm/models/apis/leaflet/leaflet-popup.d.ts +11 -0
- package/lib-esm/models/apis/leaflet/leaflet-popup.js +74 -0
- package/lib-esm/models/apis/leaflet/leaflet-popup.js.map +1 -0
- package/lib-esm/models/apis/leaflet.d.ts +99 -0
- package/lib-esm/models/apis/leaflet.js +464 -0
- package/lib-esm/models/apis/leaflet.js.map +1 -0
- package/lib-esm/models/apis/mapFunctions.d.ts +85 -0
- package/lib-esm/models/apis/mapFunctions.js +2 -0
- package/lib-esm/models/apis/mapFunctions.js.map +1 -0
- package/lib-esm/models/dto/event-type.d.ts +33 -0
- package/lib-esm/models/dto/event-type.js +39 -0
- package/lib-esm/models/dto/event-type.js.map +1 -0
- package/lib-esm/models/dto/map-type.d.ts +4 -0
- package/lib-esm/models/dto/map-type.js +6 -0
- package/lib-esm/models/dto/map-type.js.map +1 -0
- package/lib-esm/models/dto/polyline-type.d.ts +5 -0
- package/lib-esm/models/dto/polyline-type.js +7 -0
- package/lib-esm/models/dto/polyline-type.js.map +1 -0
- package/lib-esm/models/features/circle/circle-alter-options.d.ts +12 -0
- package/lib-esm/models/features/circle/circle-alter-options.js +14 -0
- package/lib-esm/models/features/circle/circle-alter-options.js.map +1 -0
- package/lib-esm/models/features/circle/circle-options.d.ts +15 -0
- package/{src → lib-esm/models/features}/circle/circle-options.js +6 -4
- package/lib-esm/models/features/circle/circle-options.js.map +1 -0
- package/lib-esm/models/features/events/event-return.d.ts +4 -0
- package/lib-esm/models/features/events/event-return.js +8 -0
- package/lib-esm/models/features/events/event-return.js.map +1 -0
- package/lib-esm/models/features/geojson/geojson-options.d.ts +5 -0
- package/lib-esm/models/features/geojson/geojson-options.js +9 -0
- package/lib-esm/models/features/geojson/geojson-options.js.map +1 -0
- package/lib-esm/models/features/marker/circle-marker-options.d.ts +9 -0
- package/lib-esm/models/features/marker/circle-marker-options.js +12 -0
- package/lib-esm/models/features/marker/circle-marker-options.js.map +1 -0
- package/lib-esm/models/features/marker/circle-marker-style.d.ts +8 -0
- package/lib-esm/models/features/marker/circle-marker-style.js +12 -0
- package/lib-esm/models/features/marker/circle-marker-style.js.map +1 -0
- package/lib-esm/models/features/marker/marker-alter-options.d.ts +8 -0
- package/lib-esm/models/features/marker/marker-alter-options.js +10 -0
- package/lib-esm/models/features/marker/marker-alter-options.js.map +1 -0
- package/lib-esm/models/features/marker/marker-icon.d.ts +6 -0
- package/lib-esm/models/features/marker/marker-icon.js +10 -0
- package/lib-esm/models/features/marker/marker-icon.js.map +1 -0
- package/lib-esm/models/features/marker/marker-options.d.ts +11 -0
- package/lib-esm/models/features/marker/marker-options.js +18 -0
- package/lib-esm/models/features/marker/marker-options.js.map +1 -0
- package/lib-esm/models/features/marker-clusterer/marker-clusterer-config.d.ts +6 -0
- package/lib-esm/models/features/marker-clusterer/marker-clusterer-config.js +10 -0
- package/lib-esm/models/features/marker-clusterer/marker-clusterer-config.js.map +1 -0
- package/lib-esm/models/features/overlay/overlay-options.d.ts +11 -0
- package/lib-esm/models/features/overlay/overlay-options.js +15 -0
- package/lib-esm/models/features/overlay/overlay-options.js.map +1 -0
- package/lib-esm/models/features/polygons/polygon-alter-options.d.ts +13 -0
- package/lib-esm/models/features/polygons/polygon-alter-options.js +14 -0
- package/lib-esm/models/features/polygons/polygon-alter-options.js.map +1 -0
- package/lib-esm/models/features/polygons/polygon-options.d.ts +15 -0
- package/{src → lib-esm/models/features}/polygons/polygon-options.js +7 -5
- package/lib-esm/models/features/polygons/polygon-options.js.map +1 -0
- package/lib-esm/models/features/polyline/navigations-options.d.ts +11 -0
- package/lib-esm/models/features/polyline/navigations-options.js +16 -0
- package/lib-esm/models/features/polyline/navigations-options.js.map +1 -0
- package/lib-esm/models/features/polyline/polyline-options.d.ts +18 -0
- package/lib-esm/models/features/polyline/polyline-options.js +20 -0
- package/lib-esm/models/features/polyline/polyline-options.js.map +1 -0
- package/lib-esm/models/features/popup/popup-options.d.ts +9 -0
- package/lib-esm/models/features/popup/popup-options.js +13 -0
- package/lib-esm/models/features/popup/popup-options.js.map +1 -0
- package/lib-esm/utils/maps-api-loader.service.d.ts +14 -0
- package/lib-esm/utils/maps-api-loader.service.js +89 -0
- package/lib-esm/utils/maps-api-loader.service.js.map +1 -0
- package/lib-esm/utils/url-builder.d.ts +20 -0
- package/lib-esm/utils/url-builder.js +44 -0
- package/lib-esm/utils/url-builder.js.map +1 -0
- package/package.json +69 -53
- package/test/test.js +11 -0
- package/tslint.json +24 -0
- package/typings.json +5 -0
- package/.babelrc +0 -4
- package/.editorconfig +0 -12
- package/.eslintrc +0 -291
- package/.nvmrc +0 -1
- package/.travis.yml +0 -5
- package/demo/demo.js +0 -432
- package/demo/images/cursor_locate.png +0 -0
- package/demo/images/inicio_rota.png +0 -0
- package/demo/index.html +0 -58
- package/demo/style.css +0 -45
- package/lib/inlogMaps.js +0 -16326
- package/lib/inlogMaps.js.map +0 -1
- package/lib/inlogMaps.min.js +0 -5
- package/src/circle/circle-alter-options.js +0 -9
- package/src/events/event-return.js +0 -5
- package/src/google-maps.js +0 -722
- package/src/index.js +0 -36
- package/src/leaflet.js +0 -638
- package/src/map.js +0 -306
- package/src/marker/circle-marker-options.js +0 -9
- package/src/marker/circle-marker-style.js +0 -9
- package/src/marker/marker-alter-options.js +0 -7
- package/src/marker/marker-icon.js +0 -6
- package/src/marker/marker-options.js +0 -10
- package/src/polygons/polygon-alter-options.js +0 -9
- package/src/polyline/navigations-options.js +0 -6
- package/src/polyline/polyline-alter-options.js +0 -9
- package/src/polyline/polyline-navigation-options.js +0 -15
- package/src/polyline/polyline-options.js +0 -12
- package/src/popup/popup-options.js +0 -7
- package/test/index.spec.js +0 -32
- package/webpack.config.js +0 -50
- package/yarn.lock +0 -3403
package/demo/demo.js
DELETED
|
@@ -1,432 +0,0 @@
|
|
|
1
|
-
let mapToUse = 'Leaflet'; // Google ou Leaflet
|
|
2
|
-
const map = new inlogMaps.Map(mapToUse);
|
|
3
|
-
|
|
4
|
-
let simpleMarkerShow = null;
|
|
5
|
-
let customMarkerShow = null;
|
|
6
|
-
let circleMarkerShow = null;
|
|
7
|
-
let polygonShow = null;
|
|
8
|
-
let polylineShow = null;
|
|
9
|
-
let circleShow = null;
|
|
10
|
-
let drawing = false;
|
|
11
|
-
|
|
12
|
-
/* GEOJson */
|
|
13
|
-
function onClick(event) {
|
|
14
|
-
console.log(event);
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
function geojsonMarker() {
|
|
18
|
-
let marker = {
|
|
19
|
-
'type': 'Feature',
|
|
20
|
-
'properties': {
|
|
21
|
-
'marker-color': '#d12c44',
|
|
22
|
-
'marker-size': 'medium',
|
|
23
|
-
'marker-symbol': 'star'
|
|
24
|
-
},
|
|
25
|
-
'geometry': {
|
|
26
|
-
'type': 'Point',
|
|
27
|
-
'coordinates': [-49.2806026, -25.4327193]
|
|
28
|
-
}
|
|
29
|
-
};
|
|
30
|
-
|
|
31
|
-
map.loadGEOJson(marker, {
|
|
32
|
-
draggable: true,
|
|
33
|
-
editable: true
|
|
34
|
-
}, onClick);
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
function geojsonPolyline() {
|
|
38
|
-
let polylines = {
|
|
39
|
-
'type': 'FeatureCollection',
|
|
40
|
-
'features': [
|
|
41
|
-
{
|
|
42
|
-
'type': 'Feature',
|
|
43
|
-
'properties': {
|
|
44
|
-
'id': 1
|
|
45
|
-
},
|
|
46
|
-
'geometry': {
|
|
47
|
-
'type': 'LineString',
|
|
48
|
-
'coordinates': [
|
|
49
|
-
[-43.48283, -23.02487],
|
|
50
|
-
[-43.48391, -23.02475],
|
|
51
|
-
[-43.48233, -23.02486],
|
|
52
|
-
[-43.48212, -23.02443],
|
|
53
|
-
[-43.48243, -23.02429],
|
|
54
|
-
[-43.48245, -23.02477]
|
|
55
|
-
]
|
|
56
|
-
}
|
|
57
|
-
},
|
|
58
|
-
{
|
|
59
|
-
'type': 'Feature',
|
|
60
|
-
'properties': {
|
|
61
|
-
'id': 2
|
|
62
|
-
},
|
|
63
|
-
'geometry': {
|
|
64
|
-
'type': 'LineString',
|
|
65
|
-
'coordinates': [
|
|
66
|
-
[-46.65953, -23.55865],
|
|
67
|
-
[-46.65953, -23.5579],
|
|
68
|
-
[-46.65972, -23.55809],
|
|
69
|
-
[-46.65941, -23.55878],
|
|
70
|
-
[-46.65953, -23.55896],
|
|
71
|
-
[-46.65903, -23.55888]
|
|
72
|
-
]
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
]
|
|
76
|
-
};
|
|
77
|
-
|
|
78
|
-
map.loadGEOJson(polylines, {
|
|
79
|
-
draggable: true,
|
|
80
|
-
editable: true
|
|
81
|
-
}, onClick);
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
function geojsonPolygon() {
|
|
85
|
-
let polygon = {
|
|
86
|
-
'type': 'Feature',
|
|
87
|
-
'geometry': {
|
|
88
|
-
'type': 'Polygon',
|
|
89
|
-
'coordinates': [
|
|
90
|
-
[
|
|
91
|
-
[-67.13734351262877, 45.137451890638886],
|
|
92
|
-
[-66.96466, 44.8097],
|
|
93
|
-
[-68.03252, 44.3252],
|
|
94
|
-
[-69.06, 43.98],
|
|
95
|
-
[-70.11617, 43.68405],
|
|
96
|
-
[-70.64573401557249, 43.090083319667144],
|
|
97
|
-
[-70.75102474636725, 43.08003225358635],
|
|
98
|
-
[-70.79761105007827, 43.21973948828747],
|
|
99
|
-
[-70.98176001655037, 43.36789581966826],
|
|
100
|
-
[-70.94416541205806, 43.46633942318431],
|
|
101
|
-
[-71.08482, 45.3052400000002],
|
|
102
|
-
[-70.6600225491012, 45.46022288673396],
|
|
103
|
-
[-70.30495378282376, 45.914794623389355],
|
|
104
|
-
[-70.00014034695016, 46.69317088478567],
|
|
105
|
-
[-69.23708614772835, 47.44777598732787],
|
|
106
|
-
[-68.90478084987546, 47.184794623394396],
|
|
107
|
-
[-68.23430497910454, 47.35462921812177],
|
|
108
|
-
[-67.79035274928509, 47.066248887716995],
|
|
109
|
-
[-67.79141211614706, 45.702585354182816],
|
|
110
|
-
[-67.13734351262877, 45.137451890638886]
|
|
111
|
-
]
|
|
112
|
-
]
|
|
113
|
-
}
|
|
114
|
-
};
|
|
115
|
-
|
|
116
|
-
map.loadGEOJson(polygon, {
|
|
117
|
-
draggable: true,
|
|
118
|
-
editable: true
|
|
119
|
-
}, onClick);
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
/* Marker tests */
|
|
123
|
-
function onClickMarker(marker, event) {
|
|
124
|
-
let options = new inlogMaps.PopupOptions(event.latlng, '<p>Hello world!<br />This is a nice popup.</p>', marker);
|
|
125
|
-
|
|
126
|
-
map.drawPopup('marker', options);
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
function addMarker() {
|
|
130
|
-
if (simpleMarkerShow === null) {
|
|
131
|
-
let options = new inlogMaps.MarkerOptions([-25.4327193, -49.2806026], true, true, null, true);
|
|
132
|
-
|
|
133
|
-
map.drawMarker('simple', options, onClickMarker);
|
|
134
|
-
simpleMarkerShow = true;
|
|
135
|
-
} else {
|
|
136
|
-
simpleMarkerShow = !simpleMarkerShow;
|
|
137
|
-
map.showMarkers(simpleMarkerShow, 'simple');
|
|
138
|
-
}
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
function changeMarkerPosition() {
|
|
142
|
-
if (simpleMarkerShow === null) {
|
|
143
|
-
alert('The marker was not created yet');
|
|
144
|
-
} else {
|
|
145
|
-
let options = new inlogMaps.MarkerAlterOptions([-20, -40]);
|
|
146
|
-
|
|
147
|
-
map.alterMarkerOptions('simple', options);
|
|
148
|
-
}
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
function onClickMarkerCustom(marker, event, object) {
|
|
152
|
-
let content = `
|
|
153
|
-
<div class="infowindow-default">
|
|
154
|
-
<h3 class="title">
|
|
155
|
-
<span>Item</span>
|
|
156
|
-
</h3>
|
|
157
|
-
<div class="section">
|
|
158
|
-
<div class="infowindow-table">
|
|
159
|
-
<div><strong>Valor 1:</strong><span> ${object.valor1 || ''}</span> </div>
|
|
160
|
-
<div><strong>Valor 2:</strong><span> ${object.valor2 || ''}</span></div>
|
|
161
|
-
<div><strong>Valor 3:</strong><span> ${object.valor3 || ''}</span></div>
|
|
162
|
-
<div><strong>Valor 4:</strong><span> ${object.valor4}</span></div>
|
|
163
|
-
<div><strong>Valor 5:</strong><span> ${object.valor5}</span></div>
|
|
164
|
-
</div>
|
|
165
|
-
</div>
|
|
166
|
-
</div>`;
|
|
167
|
-
|
|
168
|
-
let options = new inlogMaps.PopupOptions(event.latlng, content, marker);
|
|
169
|
-
|
|
170
|
-
map.drawPopup('markerCustom', options);
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
function addMarkerCustom() {
|
|
174
|
-
if (customMarkerShow === null) {
|
|
175
|
-
let item = {
|
|
176
|
-
valor1: 'Um valor',
|
|
177
|
-
valor2: 'Dois valores',
|
|
178
|
-
valor3: 'Três valores',
|
|
179
|
-
valor4: 'Quatro valores',
|
|
180
|
-
valor5: 'Cinco valores'
|
|
181
|
-
};
|
|
182
|
-
|
|
183
|
-
let icon = new inlogMaps.MarkerIcon('images/cursor_locate.png');
|
|
184
|
-
let options = new inlogMaps.MarkerOptions([-26, -50], true, false, icon, true, item);
|
|
185
|
-
|
|
186
|
-
map.drawMarker('custom', options, onClickMarkerCustom);
|
|
187
|
-
customMarkerShow = true;
|
|
188
|
-
} else {
|
|
189
|
-
customMarkerShow = !customMarkerShow;
|
|
190
|
-
map.showMarkers(customMarkerShow, 'custom');
|
|
191
|
-
}
|
|
192
|
-
}
|
|
193
|
-
|
|
194
|
-
function changeCustomMarkerImage() {
|
|
195
|
-
if (customMarkerShow === null) {
|
|
196
|
-
alert('The custom marker was not created yet');
|
|
197
|
-
} else {
|
|
198
|
-
let icon = new inlogMaps.MarkerIcon('images/inicio_rota.png');
|
|
199
|
-
let options = new inlogMaps.MarkerAlterOptions(null, icon);
|
|
200
|
-
|
|
201
|
-
map.alterMarkerOptions('custom', options);
|
|
202
|
-
}
|
|
203
|
-
}
|
|
204
|
-
|
|
205
|
-
function addCircleMarker() {
|
|
206
|
-
if (circleMarkerShow === null) {
|
|
207
|
-
let style = new inlogMaps.CircleMarkerStyle(5, 1, '#000000', '#FF0000', 0.8);
|
|
208
|
-
let options = new inlogMaps.CircleMarkerOptions([-24, -48], true, style, true);
|
|
209
|
-
|
|
210
|
-
map.drawCircleMarker('circleMarker', options, onClickMarker);
|
|
211
|
-
|
|
212
|
-
circleMarkerShow = true;
|
|
213
|
-
} else {
|
|
214
|
-
circleMarkerShow = !circleMarkerShow;
|
|
215
|
-
map.showMarkers(circleMarkerShow, 'circleMarker');
|
|
216
|
-
}
|
|
217
|
-
}
|
|
218
|
-
|
|
219
|
-
function changeCircleMarkerColor() {
|
|
220
|
-
if (circleMarkerShow === null) {
|
|
221
|
-
alert('The circle marker was not created yet!');
|
|
222
|
-
} else {
|
|
223
|
-
let style = new inlogMaps.CircleMarkerStyle();
|
|
224
|
-
|
|
225
|
-
style.fillColor = '#FFFF00';
|
|
226
|
-
let options = new inlogMaps.MarkerAlterOptions();
|
|
227
|
-
|
|
228
|
-
options.style = style;
|
|
229
|
-
map.alterMarkerOptions('circleMarker', options);
|
|
230
|
-
}
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
/* Polyline tests */
|
|
234
|
-
function onClickPolyline(polyline, event, object) {
|
|
235
|
-
let options = new inlogMaps.PopupOptions(event.latlng, `<p>${object.item}.</p>`);
|
|
236
|
-
|
|
237
|
-
map.drawPopup('polyline', options);
|
|
238
|
-
}
|
|
239
|
-
|
|
240
|
-
function addPolyline() {
|
|
241
|
-
if (polylineShow === null) {
|
|
242
|
-
let options = new inlogMaps.PolylineOptions();
|
|
243
|
-
|
|
244
|
-
options.path = [
|
|
245
|
-
[-23.02487, -43.48283],
|
|
246
|
-
[-23.02475, -43.48391],
|
|
247
|
-
[-23.02486, -43.48233],
|
|
248
|
-
[-23.02443, -43.48212],
|
|
249
|
-
[-23.02429, -43.48243],
|
|
250
|
-
[-23.02477, -43.48245]
|
|
251
|
-
];
|
|
252
|
-
options.addToMap = true;
|
|
253
|
-
options.fitBounds = true;
|
|
254
|
-
options.object = {
|
|
255
|
-
item: 'New'
|
|
256
|
-
};
|
|
257
|
-
map.drawPolyline('polyline', options, onClickPolyline);
|
|
258
|
-
polylineShow = true;
|
|
259
|
-
} else {
|
|
260
|
-
polylineShow = !polylineShow;
|
|
261
|
-
map.showPolyline(polylineShow, 'polyline');
|
|
262
|
-
}
|
|
263
|
-
}
|
|
264
|
-
|
|
265
|
-
function addPolylineWithNavigation() {
|
|
266
|
-
let options = new inlogMaps.PolylineNavigationOptions();
|
|
267
|
-
|
|
268
|
-
options.path = [
|
|
269
|
-
[-23.024657518124023, -43.48285071469786],
|
|
270
|
-
[-23.02484265813435, -43.48359100438597],
|
|
271
|
-
[-23.025441015571875, -43.48343945957663],
|
|
272
|
-
[-23.02518922621311, -43.48251677967551],
|
|
273
|
-
[-23.02535214879308, -43.482527508511566],
|
|
274
|
-
[-23.025524945253615, -43.48268307663443],
|
|
275
|
-
[-23.025618748953754, -43.483053221478485],
|
|
276
|
-
[-23.025692804460373, -43.48372377373221],
|
|
277
|
-
[-23.025762332433345, -43.484101627160385],
|
|
278
|
-
[-23.025828982320164, -43.484316203881576],
|
|
279
|
-
[-23.025944178594504, -43.484607520870725],
|
|
280
|
-
[-23.025988611796098, -43.48474163132147],
|
|
281
|
-
[-23.026284415679036, -43.485281467437744],
|
|
282
|
-
[-23.026438676263012, -43.485623602168175],
|
|
283
|
-
[-23.025967191451137, -43.48567456413946],
|
|
284
|
-
[-23.025775881698536, -43.48496646095953],
|
|
285
|
-
[-23.025542347567463, -43.48405234610573],
|
|
286
|
-
[-23.02516960068853, -43.484262899513396],
|
|
287
|
-
[-23.024949270121056, -43.48403893506065]
|
|
288
|
-
];
|
|
289
|
-
options.infowindows = [
|
|
290
|
-
'<h1>1</h1>',
|
|
291
|
-
'<h1>2</h1>',
|
|
292
|
-
'<h1>3</h1>',
|
|
293
|
-
'<h1>4</h1>',
|
|
294
|
-
'<h1>5</h1>',
|
|
295
|
-
'<h1>6</h1>',
|
|
296
|
-
'<h1>7</h1>',
|
|
297
|
-
'<h1>8</h1>',
|
|
298
|
-
'<h1>9</h1>',
|
|
299
|
-
'<h1>10</h1>',
|
|
300
|
-
'<h1>11</h1>',
|
|
301
|
-
'<h1>12</h1>',
|
|
302
|
-
'<h1>13</h1>',
|
|
303
|
-
'<h1>14</h1>',
|
|
304
|
-
'<h1>15</h1>',
|
|
305
|
-
'<h1>16</h1>',
|
|
306
|
-
'<h1>17</h1>',
|
|
307
|
-
'<h1>18</h1>',
|
|
308
|
-
'<h1>19</h1>'
|
|
309
|
-
];
|
|
310
|
-
options.addToMap = true;
|
|
311
|
-
options.weight = 8;
|
|
312
|
-
options.fitBounds = true;
|
|
313
|
-
options.navigateOptions = new inlogMaps.NavigationOptions('#0000FF');
|
|
314
|
-
map.drawPolylineWithNavigation('polylineNavigation', options);
|
|
315
|
-
}
|
|
316
|
-
|
|
317
|
-
function removePolylineHighlight() {
|
|
318
|
-
map.removePolylineHighlight();
|
|
319
|
-
}
|
|
320
|
-
|
|
321
|
-
function updatePolyline(event) {
|
|
322
|
-
map.addPolylinePath('polyline', event.latlng);
|
|
323
|
-
}
|
|
324
|
-
|
|
325
|
-
function drawPolyline() {
|
|
326
|
-
if (!polylineShow) {
|
|
327
|
-
alert('The polyline is not on the map!');
|
|
328
|
-
} else {
|
|
329
|
-
if (drawing) {
|
|
330
|
-
map.removeClickMap();
|
|
331
|
-
drawing = false;
|
|
332
|
-
} else {
|
|
333
|
-
map.addClickMap(updatePolyline);
|
|
334
|
-
drawing = true;
|
|
335
|
-
}
|
|
336
|
-
}
|
|
337
|
-
}
|
|
338
|
-
|
|
339
|
-
function changePolyline() {
|
|
340
|
-
let options = new inlogMaps.PolylineAlterOptions(true, true, '#00FF00', 12, {
|
|
341
|
-
item: 'Edited'
|
|
342
|
-
});
|
|
343
|
-
|
|
344
|
-
map.alterPolylineOptions('polyline', options);
|
|
345
|
-
}
|
|
346
|
-
|
|
347
|
-
/* Polygon tests */
|
|
348
|
-
function onClickPolygon(polygon, event) {
|
|
349
|
-
let options = new inlogMaps.PopupOptions(event.latlng, '<p>Hello world!<br />This is a nice popup.</p>');
|
|
350
|
-
|
|
351
|
-
map.drawPopup('polygon', options);
|
|
352
|
-
}
|
|
353
|
-
|
|
354
|
-
function addPolygon() {
|
|
355
|
-
if (polygonShow === null) {
|
|
356
|
-
let path = [
|
|
357
|
-
[25.774, -80.190],
|
|
358
|
-
[18.466, -66.118],
|
|
359
|
-
[32.321, -64.757],
|
|
360
|
-
[25.774, -80.190]
|
|
361
|
-
];
|
|
362
|
-
let options = new inlogMaps.PolygonOptions(path, 1, true, '#000000', 1, '#FFFFFF', 0.8);
|
|
363
|
-
|
|
364
|
-
options.fitBounds = true;
|
|
365
|
-
map.drawPolygon('polygon', options, onClickPolygon);
|
|
366
|
-
polygonShow = true;
|
|
367
|
-
} else {
|
|
368
|
-
polygonShow = !polygonShow;
|
|
369
|
-
map.showPolygons(polygonShow, 'polygon');
|
|
370
|
-
}
|
|
371
|
-
}
|
|
372
|
-
|
|
373
|
-
function changePolygonColor() {
|
|
374
|
-
if (polygonShow === null) {
|
|
375
|
-
alert('The polygon was not created yet!');
|
|
376
|
-
} else {
|
|
377
|
-
let options = new inlogMaps.PolygonAlterOptions();
|
|
378
|
-
|
|
379
|
-
options.fillColor = '#FFFF00';
|
|
380
|
-
map.alterPolygonOptions('polygon', options);
|
|
381
|
-
}
|
|
382
|
-
}
|
|
383
|
-
|
|
384
|
-
function changePopupValue() {
|
|
385
|
-
if (polygonShow === null) {
|
|
386
|
-
alert('The polygon was not created yet!');
|
|
387
|
-
} else {
|
|
388
|
-
let options = new inlogMaps.PopupOptions([25.774, -80.190], '<p>This popup content has changed.</p>');
|
|
389
|
-
|
|
390
|
-
map.drawPopup('polygon', options);
|
|
391
|
-
}
|
|
392
|
-
}
|
|
393
|
-
|
|
394
|
-
/* Circle tests */
|
|
395
|
-
function onClickCircle(circle, event) {
|
|
396
|
-
let options = new inlogMaps.PopupOptions(event.latlng, '<p>Hello world!<br />This is a nice popup.</p>');
|
|
397
|
-
|
|
398
|
-
map.drawPopup('marker', options);
|
|
399
|
-
}
|
|
400
|
-
|
|
401
|
-
function addCircle() {
|
|
402
|
-
if (circleShow === null) {
|
|
403
|
-
let options = new inlogMaps.CircleOptions();
|
|
404
|
-
|
|
405
|
-
options.addToMap = true;
|
|
406
|
-
options.center = [-25.4327193, -49.2784139];
|
|
407
|
-
options.radius = 100;
|
|
408
|
-
options.weight = 1;
|
|
409
|
-
options.fillOpacity = 0.8;
|
|
410
|
-
options.fillColor = '#FF0000';
|
|
411
|
-
options.color = '#000000';
|
|
412
|
-
options.fitBounds = true;
|
|
413
|
-
options.draggable = false;
|
|
414
|
-
options.editable = false;
|
|
415
|
-
map.drawCircle('circle', options, onClickCircle);
|
|
416
|
-
circleShow = true;
|
|
417
|
-
} else {
|
|
418
|
-
circleShow = !circleShow;
|
|
419
|
-
map.showCircles(circleShow, 'circle');
|
|
420
|
-
}
|
|
421
|
-
}
|
|
422
|
-
|
|
423
|
-
function changeCircleColor() {
|
|
424
|
-
if (circleShow === null) {
|
|
425
|
-
alert('The circle was not created yet!');
|
|
426
|
-
} else {
|
|
427
|
-
let options = new inlogMaps.CircleAlterOptions();
|
|
428
|
-
|
|
429
|
-
options.fillColor = '#FFFF00';
|
|
430
|
-
map.alterCircleOptions('circle', options);
|
|
431
|
-
}
|
|
432
|
-
}
|
|
Binary file
|
|
Binary file
|
package/demo/index.html
DELETED
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
<html>
|
|
2
|
-
|
|
3
|
-
<head>
|
|
4
|
-
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.3.1/dist/leaflet.css" integrity="sha512-Rksm5RenBEKSKFjgI3a41vrjkw4EVPlJ3+OiI65vTjIdo9brlAacEuKOiQ5OFh7cOI1bkDwLqdLw3Zg0cRJAAQ=="
|
|
5
|
-
crossorigin="" />
|
|
6
|
-
<link type="text/css" href="style.css" rel="stylesheet" />
|
|
7
|
-
</head>
|
|
8
|
-
|
|
9
|
-
<body>
|
|
10
|
-
<div id="map"></div>
|
|
11
|
-
|
|
12
|
-
<fieldset class="markers">
|
|
13
|
-
Markers:
|
|
14
|
-
<input type="submit" value="Show/Hide Marker" onclick="addMarker()" />
|
|
15
|
-
<input type="submit" value="Change Marker Position" onclick="changeMarkerPosition()" />
|
|
16
|
-
<input type="submit" value="Show/Hide Marker Custom" onclick="addMarkerCustom()" />
|
|
17
|
-
<input type="submit" value="Change Marker Custom Image" onclick="changeCustomMarkerImage()" />
|
|
18
|
-
<input type="submit" value="Show/Hide Circle Marker" onclick="addCircleMarker()" />
|
|
19
|
-
<input type="submit" value="Change Circle Marker Color" onclick="changeCircleMarkerColor()" />
|
|
20
|
-
</fieldset>
|
|
21
|
-
<fieldset>
|
|
22
|
-
Polylines:
|
|
23
|
-
<input type="submit" value="Show/Hide Polyline" onclick="addPolyline()" />
|
|
24
|
-
<input type="submit" value="Draw Polyline" onclick="drawPolyline()" />
|
|
25
|
-
<input type="submit" value="Change Polyline" onclick="changePolyline()" />
|
|
26
|
-
<input type="submit" value="Show Polyline With Navigation" onclick="addPolylineWithNavigation()" />
|
|
27
|
-
<input type="submit" value="Remove Polyline Highlight" onclick="removePolylineHighlight()" />
|
|
28
|
-
</fieldset>
|
|
29
|
-
<fieldset>
|
|
30
|
-
Polygons:
|
|
31
|
-
<input type="submit" value="Show/Hide Polygon" onclick="addPolygon()" />
|
|
32
|
-
<input type="submit" value="Change Polygon Color" onclick="changePolygonColor()" />
|
|
33
|
-
<input type="submit" value="Change Popup Value" onclick="changePopupValue()" />
|
|
34
|
-
</fieldset>
|
|
35
|
-
<fieldset>
|
|
36
|
-
Circles:
|
|
37
|
-
<input type="submit" value="Show/Hide Circle" onclick="addCircle()" />
|
|
38
|
-
<input type="submit" value="Change Circle Color" onclick="changeCircleColor()" />
|
|
39
|
-
</fieldset>
|
|
40
|
-
<fieldset>
|
|
41
|
-
GEOJSON:
|
|
42
|
-
<input type="submit" value="Marker" onclick="geojsonMarker()" />
|
|
43
|
-
<input type="submit" value="Polyline" onclick="geojsonPolyline()" />
|
|
44
|
-
<input type="submit" value="Polygon" onclick="geojsonPolygon()" />
|
|
45
|
-
</fieldset>
|
|
46
|
-
|
|
47
|
-
<script type="text/javascript" src="https://maps.google.com/maps/api/js?key=AIzaSyDSzUM8dlV_QeNaIjTbaDEDKIKa7fFc_Ss"></script>
|
|
48
|
-
<script src="https://unpkg.com/leaflet@1.3.1/dist/leaflet.js" integrity="sha512-/Nsx9X4HebavoBvEBuyp3I7od5tA0UzAxs+j83KgC8PU0kgB4XiK4Lfe4y4cgBtaRJQEIFCW+oC506aPT2L1zw=="
|
|
49
|
-
crossorigin=""></script>
|
|
50
|
-
|
|
51
|
-
<!-- Below is unecessery when implemented -->
|
|
52
|
-
<script src="../lib/inlogMaps.js"></script>
|
|
53
|
-
<script src="../node_modules/leaflet.path.drag/src/Path.Drag.js"></script>
|
|
54
|
-
<script src="../node_modules/leaflet-editable/src/Leaflet.Editable.js"></script>
|
|
55
|
-
<script type="text/javascript" src="demo.js"></script>
|
|
56
|
-
</body>
|
|
57
|
-
|
|
58
|
-
</html>
|
package/demo/style.css
DELETED
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
html {
|
|
2
|
-
font-family: Arial, Helvetica, sans-serif;
|
|
3
|
-
font-size: 0.8rem;
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
fieldset {
|
|
7
|
-
border: 0.1rem #999 solid;
|
|
8
|
-
border-radius: 0.3rem;
|
|
9
|
-
margin: 0.5rem;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
input[type="submit"] {
|
|
13
|
-
border: 0.1rem #333 solid;
|
|
14
|
-
text-decoration: none;
|
|
15
|
-
font-family: helvetica;
|
|
16
|
-
color: black;
|
|
17
|
-
border-radius: 0.3rem;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
#map {
|
|
21
|
-
height: 80%;
|
|
22
|
-
width: 100%
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
.infowindow-default {
|
|
26
|
-
font-size: 1.1rem;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
.infowindow-default .title {
|
|
30
|
-
text-align: center;
|
|
31
|
-
background-color: #428bca;
|
|
32
|
-
color: #FFF;
|
|
33
|
-
text-transform: uppercase;
|
|
34
|
-
margin: 0;
|
|
35
|
-
border-radius: 0.3rem;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
.infowindow-default div.section {
|
|
39
|
-
width: 15rem;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
.infowindow-default div.section .infowindow-table{
|
|
43
|
-
margin: 1rem;
|
|
44
|
-
line-height: 1.5rem;
|
|
45
|
-
}
|