react-spatial 1.5.3 → 1.5.5
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/components/BaseLayerSwitcher/BaseLayerSwitcher.js +262 -0
- package/components/BaseLayerSwitcher/BaseLayerSwitcher.js.map +7 -0
- package/components/BaseLayerSwitcher/index.js +1 -0
- package/components/BaseLayerSwitcher/index.js.map +7 -0
- package/{src/components → components}/BasicMap/BasicMap.js +80 -170
- package/components/BasicMap/BasicMap.js.map +7 -0
- package/components/BasicMap/index.js +1 -0
- package/components/BasicMap/index.js.map +7 -0
- package/{src/components → components}/CanvasSaveButton/CanvasSaveButton.js +133 -278
- package/components/CanvasSaveButton/CanvasSaveButton.js.map +7 -0
- package/components/CanvasSaveButton/index.js +1 -0
- package/components/CanvasSaveButton/index.js.map +7 -0
- package/{src/components → components}/Copyright/Copyright.js +21 -41
- package/components/Copyright/Copyright.js.map +7 -0
- package/components/Copyright/index.js +1 -0
- package/components/Copyright/index.js.map +7 -0
- package/components/FeatureExportButton/FeatureExportButton.js +80 -0
- package/components/FeatureExportButton/FeatureExportButton.js.map +7 -0
- package/components/FeatureExportButton/index.js +1 -0
- package/components/FeatureExportButton/index.js.map +7 -0
- package/{src/components → components}/FitExtent/FitExtent.js +16 -30
- package/components/FitExtent/FitExtent.js.map +7 -0
- package/components/FitExtent/index.js +1 -0
- package/components/FitExtent/index.js.map +7 -0
- package/{src/components → components}/Geolocation/Geolocation.js +60 -110
- package/components/Geolocation/Geolocation.js.map +7 -0
- package/components/Geolocation/index.js +1 -0
- package/components/Geolocation/index.js.map +7 -0
- package/{src/components → components}/LayerTree/LayerTree.js +113 -213
- package/components/LayerTree/LayerTree.js.map +7 -0
- package/components/LayerTree/index.js +1 -0
- package/components/LayerTree/index.js.map +7 -0
- package/{src/components → components}/MousePosition/MousePosition.js +37 -70
- package/components/MousePosition/MousePosition.js.map +7 -0
- package/components/MousePosition/index.js +1 -0
- package/components/MousePosition/index.js.map +7 -0
- package/{src/components → components}/NorthArrow/NorthArrow.js +18 -34
- package/components/NorthArrow/NorthArrow.js.map +7 -0
- package/components/NorthArrow/index.js +1 -0
- package/components/NorthArrow/index.js.map +7 -0
- package/{src/components → components}/Overlay/Overlay.js +59 -85
- package/components/Overlay/Overlay.js.map +7 -0
- package/components/Overlay/index.js +1 -0
- package/components/Overlay/index.js.map +7 -0
- package/{src/components → components}/Permalink/Permalink.js +64 -147
- package/components/Permalink/Permalink.js.map +7 -0
- package/components/Permalink/index.js +1 -0
- package/components/Permalink/index.js.map +7 -0
- package/{src/components → components}/Popup/Popup.js +57 -116
- package/components/Popup/Popup.js.map +7 -0
- package/components/Popup/index.js +1 -0
- package/components/Popup/index.js.map +7 -0
- package/{src/components → components}/ResizeHandler/ResizeHandler.js +15 -49
- package/components/ResizeHandler/ResizeHandler.js.map +7 -0
- package/components/ResizeHandler/index.js +1 -0
- package/components/ResizeHandler/index.js.map +7 -0
- package/components/RouteSchedule/RouteSchedule.js +268 -0
- package/components/RouteSchedule/RouteSchedule.js.map +7 -0
- package/components/RouteSchedule/index.js +1 -0
- package/components/RouteSchedule/index.js.map +7 -0
- package/{src/components → components}/ScaleLine/ScaleLine.js +8 -23
- package/components/ScaleLine/ScaleLine.js.map +7 -0
- package/components/ScaleLine/index.js +1 -0
- package/components/ScaleLine/index.js.map +7 -0
- package/{src/components → components}/StopsFinder/StopsFinder.js +74 -103
- package/components/StopsFinder/StopsFinder.js.map +7 -0
- package/components/StopsFinder/StopsFinderOption.js +44 -0
- package/components/StopsFinder/StopsFinderOption.js.map +7 -0
- package/components/StopsFinder/index.js +1 -0
- package/components/StopsFinder/index.js.map +7 -0
- package/{src/components → components}/Zoom/Zoom.js +46 -77
- package/components/Zoom/Zoom.js.map +7 -0
- package/components/Zoom/index.js +1 -0
- package/components/Zoom/index.js.map +7 -0
- package/package.json +32 -31
- package/{src/propTypes.js → propTypes.js} +30 -16
- package/propTypes.js.map +7 -0
- package/{src/setupTests.js → setupTests.js} +1 -1
- package/setupTests.js.map +7 -0
- package/utils/GlobalsForOle.js +94 -0
- package/utils/GlobalsForOle.js.map +7 -0
- package/utils/KML.js +420 -0
- package/utils/KML.js.map +7 -0
- package/{src/utils → utils}/KMLFormat.js +29 -32
- package/utils/KMLFormat.js.map +7 -0
- package/{src/utils → utils}/Styles.js +14 -20
- package/utils/Styles.js.map +7 -0
- package/{src/utils → utils}/getPolygonPattern.js +6 -34
- package/utils/getPolygonPattern.js.map +7 -0
- package/{src/utils → utils}/timeUtils.js +5 -22
- package/utils/timeUtils.js.map +7 -0
- package/.github/workflows/conventional-pr-title.yml +0 -21
- package/.github/workflows/main.yml +0 -28
- package/.husky/commit-msg +0 -4
- package/.husky/post-checkout +0 -4
- package/.husky/post-merge +0 -4
- package/.husky/post-rebase +0 -4
- package/.husky/pre-commit +0 -4
- package/.nvmrc +0 -1
- package/.whitesource +0 -8
- package/CHANGELOG.md +0 -65
- package/DEVELOP.md +0 -113
- package/__mocks__/mapbox-gl.js +0 -11
- package/__mocks__/resize-observer-polyfill.js +0 -9
- package/babel.config.js +0 -3
- package/commitlint.config.js +0 -1
- package/data/topic1.js +0 -119
- package/data/topic2.js +0 -28
- package/doc/README.md +0 -21
- package/doc/doc-config.json +0 -4
- package/pull_request_template.md +0 -16
- package/renovate.json +0 -4
- package/scripts/read-pkg-json.js +0 -17
- package/src/components/BaseLayerSwitcher/BaseLayerSwitcher.js +0 -322
- package/src/components/BaseLayerSwitcher/BaseLayerSwitcher.test.js +0 -69
- package/src/components/BaseLayerSwitcher/README.md +0 -61
- package/src/components/BaseLayerSwitcher/__snapshots__/BaseLayerSwitcher.test.js.snap +0 -88
- package/src/components/BaseLayerSwitcher/index.js +0 -1
- package/src/components/BasicMap/BasicMap.test.js +0 -281
- package/src/components/BasicMap/README.md +0 -18
- package/src/components/BasicMap/index.js +0 -1
- package/src/components/CanvasSaveButton/CanvasSaveButton.test.js +0 -148
- package/src/components/CanvasSaveButton/README.md +0 -76
- package/src/components/CanvasSaveButton/__snapshots__/CanvasSaveButton.test.js.snap +0 -76
- package/src/components/CanvasSaveButton/index.js +0 -1
- package/src/components/Copyright/Copyright.test.js +0 -134
- package/src/components/Copyright/README.md +0 -36
- package/src/components/Copyright/index.js +0 -1
- package/src/components/FeatureExportButton/FeatureExportButton.js +0 -118
- package/src/components/FeatureExportButton/FeatureExportButton.test.js +0 -417
- package/src/components/FeatureExportButton/README.md +0 -76
- package/src/components/FeatureExportButton/__snapshots__/FeatureExportButton.test.js.snap +0 -67
- package/src/components/FeatureExportButton/index.js +0 -1
- package/src/components/FitExtent/FitExtent.test.js +0 -48
- package/src/components/FitExtent/README.md +0 -34
- package/src/components/FitExtent/__snapshots__/FitExtent.test.js.snap +0 -13
- package/src/components/FitExtent/index.js +0 -1
- package/src/components/Geolocation/Geolocation.test.js +0 -267
- package/src/components/Geolocation/README.md +0 -25
- package/src/components/Geolocation/__snapshots__/Geolocation.test.js.snap +0 -92
- package/src/components/Geolocation/index.js +0 -1
- package/src/components/LayerTree/LayerTree.test.js +0 -337
- package/src/components/LayerTree/README.md +0 -92
- package/src/components/LayerTree/__snapshots__/LayerTree.test.js.snap +0 -1746
- package/src/components/LayerTree/index.js +0 -1
- package/src/components/MousePosition/MousePosition.test.js +0 -132
- package/src/components/MousePosition/README.md +0 -50
- package/src/components/MousePosition/__snapshots__/MousePosition.test.js.snap +0 -76
- package/src/components/MousePosition/index.js +0 -1
- package/src/components/NorthArrow/NorthArrow.test.js +0 -104
- package/src/components/NorthArrow/README.md +0 -59
- package/src/components/NorthArrow/__snapshots__/NorthArrow.test.js.snap +0 -117
- package/src/components/NorthArrow/index.js +0 -1
- package/src/components/Overlay/Overlay.test.js +0 -149
- package/src/components/Overlay/README.md +0 -59
- package/src/components/Overlay/__snapshots__/Overlay.test.js.snap +0 -9
- package/src/components/Overlay/index.js +0 -1
- package/src/components/Permalink/Permalink.test.js +0 -285
- package/src/components/Permalink/README.md +0 -105
- package/src/components/Permalink/index.js +0 -1
- package/src/components/Popup/Popup.test.js +0 -307
- package/src/components/Popup/README.md +0 -93
- package/src/components/Popup/__snapshots__/Popup.test.js.snap +0 -180
- package/src/components/Popup/index.js +0 -1
- package/src/components/README.md +0 -41
- package/src/components/ResizeHandler/ResizeHandler.test.js +0 -344
- package/src/components/ResizeHandler/index.js +0 -1
- package/src/components/RouteSchedule/README.md +0 -118
- package/src/components/RouteSchedule/RouteSchedule.js +0 -370
- package/src/components/RouteSchedule/RouteSchedule.test.js +0 -113
- package/src/components/RouteSchedule/__snapshots__/RouteSchedule.test.js.snap +0 -248
- package/src/components/RouteSchedule/index.js +0 -1
- package/src/components/ScaleLine/README.md +0 -29
- package/src/components/ScaleLine/ScaleLine.test.js +0 -30
- package/src/components/ScaleLine/__snapshots__/ScaleLine.test.js.snap +0 -7
- package/src/components/ScaleLine/index.js +0 -1
- package/src/components/StopsFinder/README.md +0 -50
- package/src/components/StopsFinder/StopsFinder.test.js +0 -17
- package/src/components/StopsFinder/StopsFinderOption.js +0 -61
- package/src/components/StopsFinder/__snapshots__/StopsFinder.test.js.snap +0 -133
- package/src/components/StopsFinder/index.js +0 -1
- package/src/components/Zoom/README.md +0 -25
- package/src/components/Zoom/Zoom.test.js +0 -141
- package/src/components/Zoom/__snapshots__/Zoom.test.js.snap +0 -201
- package/src/components/Zoom/index.js +0 -1
- package/src/styleguidist/ComponentsList.js +0 -52
- package/src/styleguidist/StyleGuide.js +0 -277
- package/src/styleguidist/styleguidist.css +0 -38
- package/src/utils/GlobalsForOle.js +0 -99
- package/src/utils/KML.js +0 -594
- package/src/utils/KML.test.js +0 -337
- package/src/utils/KMLFormat.test.js +0 -50
- package/src/utils/__snapshots__/KML.test.js.snap.KML-readFeatures()-and-writeFeatures()-should-read-and-write-lineDash-and-fillPattern-style-for-polygon.canvas-image.png +0 -0
- package/src/utils/__snapshots__/getPolygonPattern.test.js.snap.getPolygonPattern()-render-pattern-2-(cross)-color-and-(light-blue)-opacity.canvas-image.png +0 -0
- package/src/utils/__snapshots__/getPolygonPattern.test.js.snap.getPolygonPattern()-render-pattern-3-(diagonal-line-from-bottom-left-tot-top-right)-with-color-(light-blue)-and-opacity.canvas-image.png +0 -0
- package/src/utils/__snapshots__/getPolygonPattern.test.js.snap.getPolygonPattern()-render-pattern-4-(diagonal-line-from-top-left-to-bottom-right)-with-color-(light-blue)-and-opacity.canvas-image.png +0 -0
- package/src/utils/getPolygonPattern.test.js +0 -61
- package/src/utils/timeUtils.test.js +0 -30
- package/styleguide.config.js +0 -251
- /package/{src/components → components}/BaseLayerSwitcher/BaseLayerSwitcher.md.scss +0 -0
- /package/{src/components → components}/BaseLayerSwitcher/BaseLayerSwitcher.scss +0 -0
- /package/{src/components → components}/BasicMap/BasicMap.md.scss +0 -0
- /package/{src/components → components}/CanvasSaveButton/CanvasSaveButton.md.scss +0 -0
- /package/{src/components → components}/Copyright/Copyright.md.scss +0 -0
- /package/{src/components → components}/FeatureExportButton/FeatureExportButton.md.scss +0 -0
- /package/{src/components → components}/FitExtent/FitExtent.md.scss +0 -0
- /package/{src/components → components}/Geolocation/Geolocation.md.scss +0 -0
- /package/{src/components → components}/Geolocation/Geolocation.scss +0 -0
- /package/{src/components → components}/LayerTree/LayerTree.md.scss +0 -0
- /package/{src/components → components}/LayerTree/LayerTree.scss +0 -0
- /package/{src/components → components}/MousePosition/MousePosition.md.scss +0 -0
- /package/{src/components → components}/NorthArrow/NorthArrow.scss +0 -0
- /package/{src/components → components}/Overlay/Overlay.md.scss +0 -0
- /package/{src/components → components}/Overlay/Overlay.scss +0 -0
- /package/{src/components → components}/Permalink/Permalink.md.scss +0 -0
- /package/{src/components → components}/Popup/Popup.md.scss +0 -0
- /package/{src/components → components}/Popup/Popup.scss +0 -0
- /package/{src/components → components}/RouteSchedule/RouteSchedule.md.scss +0 -0
- /package/{src/components → components}/RouteSchedule/RouteSchedule.scss +0 -0
- /package/{src/components → components}/ScaleLine/ScaleLine.scss +0 -0
- /package/{src/components → components}/Zoom/Zoom.md.scss +0 -0
- /package/{src/components → components}/Zoom/Zoom.scss +0 -0
- /package/{src/images → images}/RouteSchedule/firstStation.png +0 -0
- /package/{src/images → images}/RouteSchedule/lastStation.png +0 -0
- /package/{src/images → images}/RouteSchedule/line.png +0 -0
- /package/{src/images → images}/RouteSchedule/station.png +0 -0
- /package/{src/images → images}/baselayer/baselayer.basebright.png +0 -0
- /package/{src/images → images}/baselayer/baselayer.osm.png +0 -0
- /package/{src/images → images}/baselayer/baselayer.travic.png +0 -0
- /package/{src/images → images}/baselayer/open.topo.map.png +0 -0
- /package/{src/images → images}/baselayer/osm.baselayer.hot.png +0 -0
- /package/{src/images → images}/baselayer/osm.baselayer.png +0 -0
- /package/{src/images → images}/favicon.png +0 -0
- /package/{src/images → images}/geops_logo.png +0 -0
- /package/{src/images → images}/geops_logo.svg +0 -0
- /package/{src/images → images}/geops_qr.png +0 -0
- /package/{src/images → images}/mots/bus_poi-blue-01.svg +0 -0
- /package/{src/images → images}/mots/bus_poi-grey-01.svg +0 -0
- /package/{src/images → images}/mots/bus_round-blue-01.svg +0 -0
- /package/{src/images → images}/mots/bus_round-grey-01.svg +0 -0
- /package/{src/images → images}/mots/bus_square-blue-01.svg +0 -0
- /package/{src/images → images}/mots/bus_square-grey-01.svg +0 -0
- /package/{src/images → images}/mots/cable_car_poi-blue-01.svg +0 -0
- /package/{src/images → images}/mots/cable_car_poi-grey-01.svg +0 -0
- /package/{src/images → images}/mots/cable_car_round-blue-01.svg +0 -0
- /package/{src/images → images}/mots/cable_car_round-grey-01.svg +0 -0
- /package/{src/images → images}/mots/cable_car_square-blue-01.svg +0 -0
- /package/{src/images → images}/mots/cable_car_square-grey-01.svg +0 -0
- /package/{src/images → images}/mots/ferry_poi-blue-01.svg +0 -0
- /package/{src/images → images}/mots/ferry_poi-grey-01.svg +0 -0
- /package/{src/images → images}/mots/ferry_round-blue-01.svg +0 -0
- /package/{src/images → images}/mots/ferry_round-grey-01.svg +0 -0
- /package/{src/images → images}/mots/ferry_square-blue-01.svg +0 -0
- /package/{src/images → images}/mots/ferry_square-grey-01.svg +0 -0
- /package/{src/images → images}/mots/funicular_round-blue-01.svg +0 -0
- /package/{src/images → images}/mots/funicular_round-grey-01.svg +0 -0
- /package/{src/images → images}/mots/funicular_square-blue-01.svg +0 -0
- /package/{src/images → images}/mots/gondola_round-blue-01.svg +0 -0
- /package/{src/images → images}/mots/rail_poi-blue-01.svg +0 -0
- /package/{src/images → images}/mots/rail_poi-grey-01.svg +0 -0
- /package/{src/images → images}/mots/rail_round-blue-01.svg +0 -0
- /package/{src/images → images}/mots/rail_round-grey-01.svg +0 -0
- /package/{src/images → images}/mots/rail_square-blue-01.svg +0 -0
- /package/{src/images → images}/mots/rail_square-grey-01.svg +0 -0
- /package/{src/images → images}/mots/subway_round blue-01.svg +0 -0
- /package/{src/images → images}/mots/subway_round-blue-01.svg +0 -0
- /package/{src/images → images}/mots/tram_poi-blue-01.svg +0 -0
- /package/{src/images → images}/mots/tram_poi-grey-01.svg +0 -0
- /package/{src/images → images}/mots/tram_round-blue-01.svg +0 -0
- /package/{src/images → images}/mots/tram_round-grey-01.svg +0 -0
- /package/{src/images → images}/mots/tram_square-blue-01.svg +0 -0
- /package/{src/images → images}/mots/tram_square-grey-01.svg +0 -0
- /package/{src/images → images}/northArrow.svg +0 -0
- /package/{src/images → images}/northArrow.url.svg +0 -0
- /package/{src/images → images}/northArrowCircle.svg +0 -0
- /package/{src/images → images}/northArrowCircle.url.svg +0 -0
- /package/{src/themes → themes}/README.md +0 -0
- /package/{src/themes → themes}/default/components.scss +0 -0
- /package/{src/themes → themes}/default/examples.scss +0 -0
- /package/{src/themes → themes}/default/index.scss +0 -0
- /package/{src/themes → themes}/default/mixins.scss +0 -0
- /package/{src/themes → themes}/default/variables.scss +0 -0
|
@@ -1,119 +1,97 @@
|
|
|
1
|
-
import React, { PureComponent } from
|
|
2
|
-
import PropTypes from
|
|
3
|
-
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
|
|
15
|
-
import VectorLayer from 'ol/layer/Vector';
|
|
16
|
-
import VectorSource from 'ol/source/Vector';
|
|
17
|
-
|
|
18
|
-
import { FaRegDotCircle } from 'react-icons/fa';
|
|
19
|
-
|
|
1
|
+
import React, { PureComponent } from "react";
|
|
2
|
+
import PropTypes from "prop-types";
|
|
3
|
+
import OLMap from "ol/Map";
|
|
4
|
+
import { transform } from "ol/proj";
|
|
5
|
+
import Point from "ol/geom/Point";
|
|
6
|
+
import Feature from "ol/Feature";
|
|
7
|
+
import { unByKey } from "ol/Observable";
|
|
8
|
+
import Style from "ol/style/Style";
|
|
9
|
+
import Circle from "ol/style/Circle";
|
|
10
|
+
import Fill from "ol/style/Fill";
|
|
11
|
+
import Stroke from "ol/style/Stroke";
|
|
12
|
+
import VectorLayer from "ol/layer/Vector";
|
|
13
|
+
import VectorSource from "ol/source/Vector";
|
|
14
|
+
import { FaRegDotCircle } from "react-icons/fa";
|
|
20
15
|
const propTypes = {
|
|
21
16
|
/**
|
|
22
17
|
* CSS class of the button.
|
|
23
18
|
*/
|
|
24
19
|
className: PropTypes.string,
|
|
25
|
-
|
|
26
20
|
/**
|
|
27
21
|
* Children content of the Geolocation button.
|
|
28
22
|
*/
|
|
29
23
|
children: PropTypes.node,
|
|
30
|
-
|
|
31
24
|
/**
|
|
32
25
|
* An [ol/map](https://openlayers.org/en/latest/apidoc/module-ol_Map-Map.html).
|
|
33
26
|
*/
|
|
34
27
|
map: PropTypes.instanceOf(OLMap).isRequired,
|
|
35
|
-
|
|
36
28
|
/**
|
|
37
29
|
* Function triggered when geolocating is not successful.
|
|
38
30
|
*/
|
|
39
31
|
onError: PropTypes.func,
|
|
40
|
-
|
|
41
32
|
/**
|
|
42
33
|
* Function triggered after successful geoLocation calls. Takes the ol/map, the current lat/lon coordinate and the component instance as arguments.
|
|
43
34
|
*/
|
|
44
35
|
onSuccess: PropTypes.func,
|
|
45
|
-
|
|
46
36
|
/**
|
|
47
37
|
* Function triggered after the geolocation is activated. Takes the ol/map and the component instance as arguments.
|
|
48
38
|
*/
|
|
49
39
|
onActivate: PropTypes.func,
|
|
50
|
-
|
|
51
40
|
/**
|
|
52
41
|
* Function triggered after the geolocation is deactivated. Takes the ol/map and the component instance as arguments..
|
|
53
42
|
*/
|
|
54
43
|
onDeactivate: PropTypes.func,
|
|
55
|
-
|
|
56
44
|
/**
|
|
57
45
|
* If true, the map is not centered after it has been dragged once.
|
|
58
46
|
*/
|
|
59
47
|
noCenterAfterDrag: PropTypes.bool,
|
|
60
|
-
|
|
61
48
|
/**
|
|
62
49
|
* If true, the map will constantly recenter to the current Position
|
|
63
50
|
*/
|
|
64
51
|
alwaysRecenterToPosition: PropTypes.bool,
|
|
65
|
-
|
|
66
52
|
/**
|
|
67
53
|
* Color (Number array with rgb values) or style function.
|
|
68
54
|
* If a color is given, the style is animated.
|
|
69
55
|
*/
|
|
70
56
|
colorOrStyleFunc: PropTypes.oneOfType([
|
|
71
57
|
PropTypes.arrayOf(PropTypes.number),
|
|
72
|
-
PropTypes.func
|
|
73
|
-
])
|
|
58
|
+
PropTypes.func
|
|
59
|
+
])
|
|
74
60
|
};
|
|
75
|
-
|
|
76
61
|
const defaultProps = {
|
|
77
|
-
className:
|
|
78
|
-
children:
|
|
79
|
-
onError: () => {
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
62
|
+
className: "rs-geolocation",
|
|
63
|
+
children: /* @__PURE__ */ React.createElement(FaRegDotCircle, { focusable: false }),
|
|
64
|
+
onError: () => {
|
|
65
|
+
},
|
|
66
|
+
onSuccess: () => {
|
|
67
|
+
},
|
|
68
|
+
onActivate: () => {
|
|
69
|
+
},
|
|
70
|
+
onDeactivate: () => {
|
|
71
|
+
},
|
|
83
72
|
noCenterAfterDrag: false,
|
|
84
73
|
alwaysRecenterToPosition: true,
|
|
85
|
-
colorOrStyleFunc: [235, 0, 0]
|
|
74
|
+
colorOrStyleFunc: [235, 0, 0]
|
|
86
75
|
};
|
|
87
|
-
|
|
88
|
-
/**
|
|
89
|
-
* The GeoLocation component creates a button to display the current device's location on an
|
|
90
|
-
* [ol/map](https://openlayers.org/en/latest/apidoc/module-ol_Map-Map.html).
|
|
91
|
-
*/
|
|
92
76
|
class Geolocation extends PureComponent {
|
|
93
77
|
constructor(props) {
|
|
94
78
|
super(props);
|
|
95
|
-
|
|
96
79
|
this.layer = new VectorLayer({
|
|
97
|
-
source: new VectorSource()
|
|
80
|
+
source: new VectorSource()
|
|
98
81
|
});
|
|
99
|
-
|
|
100
82
|
this.isRecenteringToPosition = true;
|
|
101
|
-
|
|
102
83
|
this.state = {
|
|
103
|
-
active: false
|
|
84
|
+
active: false
|
|
104
85
|
};
|
|
105
|
-
this.point =
|
|
86
|
+
this.point = void 0;
|
|
106
87
|
}
|
|
107
|
-
|
|
108
88
|
componentWillUnmount() {
|
|
109
89
|
this.deactivate();
|
|
110
90
|
}
|
|
111
|
-
|
|
112
91
|
toggle() {
|
|
113
92
|
const { active } = this.state;
|
|
114
93
|
const { onError } = this.props;
|
|
115
|
-
const geolocation =
|
|
116
|
-
|
|
94
|
+
const geolocation = "geolocation" in navigator;
|
|
117
95
|
if (!geolocation) {
|
|
118
96
|
onError();
|
|
119
97
|
} else if (!active) {
|
|
@@ -122,89 +100,71 @@ class Geolocation extends PureComponent {
|
|
|
122
100
|
this.deactivate();
|
|
123
101
|
}
|
|
124
102
|
}
|
|
125
|
-
|
|
126
103
|
error() {
|
|
127
104
|
const { onError } = this.props;
|
|
128
|
-
|
|
129
105
|
this.deactivate();
|
|
130
106
|
onError();
|
|
131
107
|
}
|
|
132
|
-
|
|
133
108
|
deactivate() {
|
|
134
109
|
const { map, onDeactivate } = this.props;
|
|
135
110
|
window.clearInterval(this.interval);
|
|
136
111
|
this.layer.setMap(null);
|
|
137
112
|
navigator.geolocation.clearWatch(this.watch);
|
|
138
|
-
|
|
139
113
|
this.setState({
|
|
140
|
-
active: false
|
|
114
|
+
active: false
|
|
141
115
|
});
|
|
142
|
-
|
|
143
116
|
this.isRecenteringToPosition = true;
|
|
144
|
-
this.point =
|
|
117
|
+
this.point = void 0;
|
|
145
118
|
onDeactivate(map, this);
|
|
146
119
|
unByKey(this.dragListener);
|
|
147
120
|
}
|
|
148
|
-
|
|
149
121
|
activate() {
|
|
150
122
|
const { map, noCenterAfterDrag, onActivate } = this.props;
|
|
151
|
-
|
|
152
123
|
this.projection = map.getView().getProjection().getCode();
|
|
153
124
|
this.point = new Point([0, 0]);
|
|
154
125
|
this.highlight();
|
|
155
126
|
this.layer.setMap(map);
|
|
156
127
|
this.setState({ active: true });
|
|
157
|
-
|
|
158
128
|
this.watch = navigator.geolocation.watchPosition(
|
|
159
129
|
this.update.bind(this),
|
|
160
130
|
this.error.bind(this),
|
|
161
131
|
{
|
|
162
|
-
enableHighAccuracy: true
|
|
163
|
-
}
|
|
132
|
+
enableHighAccuracy: true
|
|
133
|
+
}
|
|
164
134
|
);
|
|
165
|
-
|
|
166
135
|
if (noCenterAfterDrag) {
|
|
167
|
-
this.dragListener = map.on(
|
|
136
|
+
this.dragListener = map.on("pointerdrag", () => {
|
|
168
137
|
this.isRecenteringToPosition = false;
|
|
169
138
|
});
|
|
170
139
|
}
|
|
171
|
-
|
|
172
140
|
onActivate(map, this);
|
|
173
141
|
}
|
|
174
|
-
|
|
175
142
|
update({ coords: { latitude, longitude } }) {
|
|
176
143
|
const { map, alwaysRecenterToPosition, onSuccess } = this.props;
|
|
177
|
-
|
|
178
144
|
const position = transform(
|
|
179
145
|
[longitude, latitude],
|
|
180
|
-
|
|
181
|
-
this.projection
|
|
146
|
+
"EPSG:4326",
|
|
147
|
+
this.projection
|
|
182
148
|
);
|
|
183
149
|
this.point.setCoordinates(position);
|
|
184
|
-
|
|
185
150
|
if (this.isRecenteringToPosition) {
|
|
186
151
|
map.getView().setCenter(position);
|
|
187
152
|
if (!alwaysRecenterToPosition) {
|
|
188
153
|
this.isRecenteringToPosition = false;
|
|
189
154
|
}
|
|
190
155
|
}
|
|
191
|
-
|
|
192
156
|
onSuccess(map, [latitude, longitude], this);
|
|
193
157
|
}
|
|
194
|
-
|
|
195
158
|
highlight() {
|
|
196
159
|
const { colorOrStyleFunc } = this.props;
|
|
197
160
|
const feature = new Feature({
|
|
198
|
-
geometry: this.point
|
|
161
|
+
geometry: this.point
|
|
199
162
|
});
|
|
200
|
-
|
|
201
163
|
if (Array.isArray(colorOrStyleFunc)) {
|
|
202
164
|
const color = colorOrStyleFunc;
|
|
203
|
-
|
|
204
165
|
let decrease = true;
|
|
205
166
|
let opacity = 0.5;
|
|
206
167
|
let rotation = 0;
|
|
207
|
-
|
|
208
168
|
window.clearInterval(this.interval);
|
|
209
169
|
this.interval = window.setInterval(() => {
|
|
210
170
|
rotation += 0.03;
|
|
@@ -215,74 +175,64 @@ class Geolocation extends PureComponent {
|
|
|
215
175
|
feature.changed();
|
|
216
176
|
}
|
|
217
177
|
}, 50);
|
|
218
|
-
|
|
219
178
|
feature.setStyle(() => {
|
|
220
179
|
const circleStyle = new Style({
|
|
221
180
|
image: new Circle({
|
|
222
181
|
radius: 20,
|
|
223
182
|
rotation,
|
|
224
183
|
fill: new Fill({
|
|
225
|
-
color:
|
|
184
|
+
color: "rgba(255, 255, 255, 0.01)"
|
|
226
185
|
}),
|
|
227
186
|
stroke: new Stroke({
|
|
228
187
|
lineDash: [30, 10],
|
|
229
188
|
width: 6,
|
|
230
|
-
color: `rgba(${color[0]}, ${color[1]}, ${color[2]}, ${opacity})
|
|
231
|
-
})
|
|
232
|
-
})
|
|
189
|
+
color: `rgba(${color[0]}, ${color[1]}, ${color[2]}, ${opacity})`
|
|
190
|
+
})
|
|
191
|
+
})
|
|
233
192
|
});
|
|
234
|
-
|
|
235
193
|
circleStyle.getImage().setRotation(rotation);
|
|
236
|
-
|
|
237
194
|
return [
|
|
238
195
|
new Style({
|
|
239
196
|
image: new Circle({
|
|
240
197
|
radius: 10,
|
|
241
198
|
fill: new Fill({
|
|
242
|
-
color: `rgba(${color[0]}, ${color[1]}, ${color[2]}, 0.5)
|
|
243
|
-
})
|
|
244
|
-
})
|
|
199
|
+
color: `rgba(${color[0]}, ${color[1]}, ${color[2]}, 0.5)`
|
|
200
|
+
})
|
|
201
|
+
})
|
|
245
202
|
}),
|
|
246
|
-
circleStyle
|
|
203
|
+
circleStyle
|
|
247
204
|
];
|
|
248
205
|
});
|
|
249
206
|
} else {
|
|
250
207
|
feature.setStyle(colorOrStyleFunc);
|
|
251
208
|
}
|
|
252
|
-
|
|
253
209
|
this.layer.getSource().clear();
|
|
254
210
|
this.layer.getSource().addFeature(feature);
|
|
255
211
|
}
|
|
256
|
-
|
|
257
212
|
render() {
|
|
258
213
|
const { children, className } = this.props;
|
|
259
|
-
// Remove component props from other HTML props.
|
|
260
214
|
const other = Object.entries(this.props).reduce((props, [key, value]) => {
|
|
261
215
|
return propTypes[key] ? props : { ...props, [key]: value };
|
|
262
216
|
}, {});
|
|
263
217
|
const { active } = this.state;
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
role
|
|
268
|
-
tabIndex
|
|
269
|
-
className
|
|
270
|
-
onClick
|
|
218
|
+
return /* @__PURE__ */ React.createElement(
|
|
219
|
+
"div",
|
|
220
|
+
{
|
|
221
|
+
role: "button",
|
|
222
|
+
tabIndex: "0",
|
|
223
|
+
className: `${className} ${active ? "rs-active" : ""}`,
|
|
224
|
+
onClick: () => {
|
|
271
225
|
return this.toggle();
|
|
272
|
-
}
|
|
273
|
-
onKeyPress
|
|
226
|
+
},
|
|
227
|
+
onKeyPress: (e) => {
|
|
274
228
|
return e.which === 13 && this.toggle();
|
|
275
|
-
}
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
{children}
|
|
280
|
-
</div>
|
|
229
|
+
},
|
|
230
|
+
...other
|
|
231
|
+
},
|
|
232
|
+
children
|
|
281
233
|
);
|
|
282
234
|
}
|
|
283
235
|
}
|
|
284
|
-
|
|
285
236
|
Geolocation.propTypes = propTypes;
|
|
286
237
|
Geolocation.defaultProps = defaultProps;
|
|
287
|
-
|
|
288
238
|
export default Geolocation;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/components/Geolocation/Geolocation.js"],
|
|
4
|
+
"sourcesContent": ["import React, { PureComponent } from 'react';\nimport PropTypes from 'prop-types';\n\nimport OLMap from 'ol/Map';\nimport { transform } from 'ol/proj';\nimport Point from 'ol/geom/Point';\nimport Feature from 'ol/Feature';\nimport { unByKey } from 'ol/Observable';\n\nimport Style from 'ol/style/Style';\nimport Circle from 'ol/style/Circle';\nimport Fill from 'ol/style/Fill';\nimport Stroke from 'ol/style/Stroke';\n\nimport VectorLayer from 'ol/layer/Vector';\nimport VectorSource from 'ol/source/Vector';\n\nimport { FaRegDotCircle } from 'react-icons/fa';\n\nconst propTypes = {\n /**\n * CSS class of the button.\n */\n className: PropTypes.string,\n\n /**\n * Children content of the Geolocation button.\n */\n children: PropTypes.node,\n\n /**\n * An [ol/map](https://openlayers.org/en/latest/apidoc/module-ol_Map-Map.html).\n */\n map: PropTypes.instanceOf(OLMap).isRequired,\n\n /**\n * Function triggered when geolocating is not successful.\n */\n onError: PropTypes.func,\n\n /**\n * Function triggered after successful geoLocation calls. Takes the ol/map, the current lat/lon coordinate and the component instance as arguments.\n */\n onSuccess: PropTypes.func,\n\n /**\n * Function triggered after the geolocation is activated. Takes the ol/map and the component instance as arguments.\n */\n onActivate: PropTypes.func,\n\n /**\n * Function triggered after the geolocation is deactivated. Takes the ol/map and the component instance as arguments..\n */\n onDeactivate: PropTypes.func,\n\n /**\n * If true, the map is not centered after it has been dragged once.\n */\n noCenterAfterDrag: PropTypes.bool,\n\n /**\n * If true, the map will constantly recenter to the current Position\n */\n alwaysRecenterToPosition: PropTypes.bool,\n\n /**\n * Color (Number array with rgb values) or style function.\n * If a color is given, the style is animated.\n */\n colorOrStyleFunc: PropTypes.oneOfType([\n PropTypes.arrayOf(PropTypes.number),\n PropTypes.func,\n ]),\n};\n\nconst defaultProps = {\n className: 'rs-geolocation',\n children: <FaRegDotCircle focusable={false} />,\n onError: () => {},\n onSuccess: () => {},\n onActivate: () => {},\n onDeactivate: () => {},\n noCenterAfterDrag: false,\n alwaysRecenterToPosition: true,\n colorOrStyleFunc: [235, 0, 0],\n};\n\n/**\n * The GeoLocation component creates a button to display the current device's location on an\n * [ol/map](https://openlayers.org/en/latest/apidoc/module-ol_Map-Map.html).\n */\nclass Geolocation extends PureComponent {\n constructor(props) {\n super(props);\n\n this.layer = new VectorLayer({\n source: new VectorSource(),\n });\n\n this.isRecenteringToPosition = true;\n\n this.state = {\n active: false,\n };\n this.point = undefined;\n }\n\n componentWillUnmount() {\n this.deactivate();\n }\n\n toggle() {\n const { active } = this.state;\n const { onError } = this.props;\n const geolocation = 'geolocation' in navigator;\n\n if (!geolocation) {\n onError();\n } else if (!active) {\n this.activate();\n } else {\n this.deactivate();\n }\n }\n\n error() {\n const { onError } = this.props;\n\n this.deactivate();\n onError();\n }\n\n deactivate() {\n const { map, onDeactivate } = this.props;\n window.clearInterval(this.interval);\n this.layer.setMap(null);\n navigator.geolocation.clearWatch(this.watch);\n\n this.setState({\n active: false,\n });\n\n this.isRecenteringToPosition = true;\n this.point = undefined;\n onDeactivate(map, this);\n unByKey(this.dragListener);\n }\n\n activate() {\n const { map, noCenterAfterDrag, onActivate } = this.props;\n\n this.projection = map.getView().getProjection().getCode();\n this.point = new Point([0, 0]);\n this.highlight();\n this.layer.setMap(map);\n this.setState({ active: true });\n\n this.watch = navigator.geolocation.watchPosition(\n this.update.bind(this),\n this.error.bind(this),\n {\n enableHighAccuracy: true,\n },\n );\n\n if (noCenterAfterDrag) {\n this.dragListener = map.on('pointerdrag', () => {\n this.isRecenteringToPosition = false;\n });\n }\n\n onActivate(map, this);\n }\n\n update({ coords: { latitude, longitude } }) {\n const { map, alwaysRecenterToPosition, onSuccess } = this.props;\n\n const position = transform(\n [longitude, latitude],\n 'EPSG:4326',\n this.projection,\n );\n this.point.setCoordinates(position);\n\n if (this.isRecenteringToPosition) {\n map.getView().setCenter(position);\n if (!alwaysRecenterToPosition) {\n this.isRecenteringToPosition = false;\n }\n }\n\n onSuccess(map, [latitude, longitude], this);\n }\n\n highlight() {\n const { colorOrStyleFunc } = this.props;\n const feature = new Feature({\n geometry: this.point,\n });\n\n if (Array.isArray(colorOrStyleFunc)) {\n const color = colorOrStyleFunc;\n\n let decrease = true;\n let opacity = 0.5;\n let rotation = 0;\n\n window.clearInterval(this.interval);\n this.interval = window.setInterval(() => {\n rotation += 0.03;\n decrease = opacity < 0.1 ? false : decrease;\n decrease = opacity > 0.5 ? true : decrease;\n opacity += decrease ? -0.03 : 0.03;\n if (feature) {\n feature.changed();\n }\n }, 50);\n\n feature.setStyle(() => {\n const circleStyle = new Style({\n image: new Circle({\n radius: 20,\n rotation,\n fill: new Fill({\n color: 'rgba(255, 255, 255, 0.01)',\n }),\n stroke: new Stroke({\n lineDash: [30, 10],\n width: 6,\n color: `rgba(${color[0]}, ${color[1]}, ${color[2]}, ${opacity})`,\n }),\n }),\n });\n\n circleStyle.getImage().setRotation(rotation);\n\n return [\n new Style({\n image: new Circle({\n radius: 10,\n fill: new Fill({\n color: `rgba(${color[0]}, ${color[1]}, ${color[2]}, 0.5)`,\n }),\n }),\n }),\n circleStyle,\n ];\n });\n } else {\n feature.setStyle(colorOrStyleFunc);\n }\n\n this.layer.getSource().clear();\n this.layer.getSource().addFeature(feature);\n }\n\n render() {\n const { children, className } = this.props;\n // Remove component props from other HTML props.\n const other = Object.entries(this.props).reduce((props, [key, value]) => {\n return propTypes[key] ? props : { ...props, [key]: value };\n }, {});\n const { active } = this.state;\n\n return (\n <div\n role=\"button\"\n tabIndex=\"0\"\n className={`${className} ${active ? 'rs-active' : ''}`}\n onClick={() => {\n return this.toggle();\n }}\n onKeyPress={(e) => {\n return e.which === 13 && this.toggle();\n }}\n // eslint-disable-next-line react/jsx-props-no-spreading\n {...other}\n >\n {children}\n </div>\n );\n }\n}\n\nGeolocation.propTypes = propTypes;\nGeolocation.defaultProps = defaultProps;\n\nexport default Geolocation;\n"],
|
|
5
|
+
"mappings": "AAAA,OAAO,SAAS,qBAAqB;AACrC,OAAO,eAAe;AAEtB,OAAO,WAAW;AAClB,SAAS,iBAAiB;AAC1B,OAAO,WAAW;AAClB,OAAO,aAAa;AACpB,SAAS,eAAe;AAExB,OAAO,WAAW;AAClB,OAAO,YAAY;AACnB,OAAO,UAAU;AACjB,OAAO,YAAY;AAEnB,OAAO,iBAAiB;AACxB,OAAO,kBAAkB;AAEzB,SAAS,sBAAsB;AAE/B,MAAM,YAAY;AAAA;AAAA;AAAA;AAAA,EAIhB,WAAW,UAAU;AAAA;AAAA;AAAA;AAAA,EAKrB,UAAU,UAAU;AAAA;AAAA;AAAA;AAAA,EAKpB,KAAK,UAAU,WAAW,KAAK,EAAE;AAAA;AAAA;AAAA;AAAA,EAKjC,SAAS,UAAU;AAAA;AAAA;AAAA;AAAA,EAKnB,WAAW,UAAU;AAAA;AAAA;AAAA;AAAA,EAKrB,YAAY,UAAU;AAAA;AAAA;AAAA;AAAA,EAKtB,cAAc,UAAU;AAAA;AAAA;AAAA;AAAA,EAKxB,mBAAmB,UAAU;AAAA;AAAA;AAAA;AAAA,EAK7B,0BAA0B,UAAU;AAAA;AAAA;AAAA;AAAA;AAAA,EAMpC,kBAAkB,UAAU,UAAU;AAAA,IACpC,UAAU,QAAQ,UAAU,MAAM;AAAA,IAClC,UAAU;AAAA,EACZ,CAAC;AACH;AAEA,MAAM,eAAe;AAAA,EACnB,WAAW;AAAA,EACX,UAAU,oCAAC,kBAAe,WAAW,OAAO;AAAA,EAC5C,SAAS,MAAM;AAAA,EAAC;AAAA,EAChB,WAAW,MAAM;AAAA,EAAC;AAAA,EAClB,YAAY,MAAM;AAAA,EAAC;AAAA,EACnB,cA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