react-spatial 1.5.3 → 1.5.4
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 +231 -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/components/BasicMap/BasicMap.js +278 -0
- 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 +93 -320
- package/components/CanvasSaveButton/CanvasSaveButton.js.map +7 -0
- package/components/CanvasSaveButton/index.js +1 -0
- package/components/CanvasSaveButton/index.js.map +7 -0
- package/components/Copyright/Copyright.js +55 -0
- 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 +62 -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/components/FitExtent/FitExtent.js +32 -0
- 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 +61 -144
- package/components/Geolocation/Geolocation.js.map +7 -0
- package/components/Geolocation/index.js +1 -0
- package/components/Geolocation/index.js.map +7 -0
- package/components/LayerTree/LayerTree.js +278 -0
- package/components/LayerTree/LayerTree.js.map +7 -0
- package/components/LayerTree/index.js +1 -0
- package/components/LayerTree/index.js.map +7 -0
- package/components/MousePosition/MousePosition.js +110 -0
- package/components/MousePosition/MousePosition.js.map +7 -0
- package/components/MousePosition/index.js +1 -0
- package/components/MousePosition/index.js.map +7 -0
- package/components/NorthArrow/NorthArrow.js +43 -0
- package/components/NorthArrow/NorthArrow.js.map +7 -0
- package/components/NorthArrow/index.js +1 -0
- package/components/NorthArrow/index.js.map +7 -0
- package/components/Overlay/Overlay.js +122 -0
- package/components/Overlay/Overlay.js.map +7 -0
- package/components/Overlay/index.js +1 -0
- package/components/Overlay/index.js.map +7 -0
- package/components/Permalink/Permalink.js +206 -0
- 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 +55 -165
- 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 -50
- 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 +223 -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/components/ScaleLine/ScaleLine.js +32 -0
- package/components/ScaleLine/ScaleLine.js.map +7 -0
- package/components/ScaleLine/index.js +1 -0
- package/components/ScaleLine/index.js.map +7 -0
- package/components/StopsFinder/StopsFinder.js +210 -0
- package/components/StopsFinder/StopsFinder.js.map +7 -0
- package/components/StopsFinder/StopsFinderOption.js +51 -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/components/Zoom/Zoom.js +130 -0
- 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 +1 -1
- package/{src/propTypes.js → propTypes.js} +12 -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 +412 -0
- package/utils/KML.js.map +7 -0
- package/utils/KMLFormat.js +69 -0
- 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.js +0 -413
- 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.js +0 -89
- 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.js +0 -62
- 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.js +0 -487
- 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.js +0 -175
- 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.js +0 -75
- 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.js +0 -176
- 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.js +0 -326
- 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.js +0 -50
- 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.js +0 -284
- 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.js +0 -180
- 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.js +0 -100
- 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,201 +0,0 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
-
|
|
3
|
-
exports[`Zoom should match snapshot with custom attributes 1`] = `
|
|
4
|
-
<div
|
|
5
|
-
className="foo"
|
|
6
|
-
tabIndex={-1}
|
|
7
|
-
title="bar"
|
|
8
|
-
>
|
|
9
|
-
<button
|
|
10
|
-
className="rs-zoom-in"
|
|
11
|
-
disabled={false}
|
|
12
|
-
onClick={[Function]}
|
|
13
|
-
onKeyPress={[Function]}
|
|
14
|
-
tabIndex={0}
|
|
15
|
-
title="Zoom in"
|
|
16
|
-
type="button"
|
|
17
|
-
>
|
|
18
|
-
<svg
|
|
19
|
-
fill="currentColor"
|
|
20
|
-
focusable={false}
|
|
21
|
-
height="1em"
|
|
22
|
-
stroke="currentColor"
|
|
23
|
-
strokeWidth="0"
|
|
24
|
-
style={
|
|
25
|
-
{
|
|
26
|
-
"color": undefined,
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
viewBox="0 0 448 512"
|
|
30
|
-
width="1em"
|
|
31
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
32
|
-
>
|
|
33
|
-
<path
|
|
34
|
-
d="M416 208H272V64c0-17.67-14.33-32-32-32h-32c-17.67 0-32 14.33-32 32v144H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h144v144c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32V304h144c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z"
|
|
35
|
-
/>
|
|
36
|
-
</svg>
|
|
37
|
-
</button>
|
|
38
|
-
<button
|
|
39
|
-
className="rs-zoom-out"
|
|
40
|
-
disabled={false}
|
|
41
|
-
onClick={[Function]}
|
|
42
|
-
onKeyPress={[Function]}
|
|
43
|
-
tabIndex={0}
|
|
44
|
-
title="Zoom out"
|
|
45
|
-
type="button"
|
|
46
|
-
>
|
|
47
|
-
<svg
|
|
48
|
-
fill="currentColor"
|
|
49
|
-
focusable={false}
|
|
50
|
-
height="1em"
|
|
51
|
-
stroke="currentColor"
|
|
52
|
-
strokeWidth="0"
|
|
53
|
-
style={
|
|
54
|
-
{
|
|
55
|
-
"color": undefined,
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
viewBox="0 0 448 512"
|
|
59
|
-
width="1em"
|
|
60
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
61
|
-
>
|
|
62
|
-
<path
|
|
63
|
-
d="M416 208H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h384c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z"
|
|
64
|
-
/>
|
|
65
|
-
</svg>
|
|
66
|
-
</button>
|
|
67
|
-
</div>
|
|
68
|
-
`;
|
|
69
|
-
|
|
70
|
-
exports[`Zoom should match snapshot with zoom slider 1`] = `
|
|
71
|
-
<div
|
|
72
|
-
className="rs-zooms-bar"
|
|
73
|
-
>
|
|
74
|
-
<button
|
|
75
|
-
className="rs-zoom-in"
|
|
76
|
-
disabled={false}
|
|
77
|
-
onClick={[Function]}
|
|
78
|
-
onKeyPress={[Function]}
|
|
79
|
-
tabIndex={0}
|
|
80
|
-
title="Zoom in"
|
|
81
|
-
type="button"
|
|
82
|
-
>
|
|
83
|
-
<svg
|
|
84
|
-
fill="currentColor"
|
|
85
|
-
focusable={false}
|
|
86
|
-
height="1em"
|
|
87
|
-
stroke="currentColor"
|
|
88
|
-
strokeWidth="0"
|
|
89
|
-
style={
|
|
90
|
-
{
|
|
91
|
-
"color": undefined,
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
|
-
viewBox="0 0 448 512"
|
|
95
|
-
width="1em"
|
|
96
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
97
|
-
>
|
|
98
|
-
<path
|
|
99
|
-
d="M416 208H272V64c0-17.67-14.33-32-32-32h-32c-17.67 0-32 14.33-32 32v144H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h144v144c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32V304h144c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z"
|
|
100
|
-
/>
|
|
101
|
-
</svg>
|
|
102
|
-
</button>
|
|
103
|
-
<div
|
|
104
|
-
className="rs-zoomslider-wrapper"
|
|
105
|
-
/>
|
|
106
|
-
<button
|
|
107
|
-
className="rs-zoom-out"
|
|
108
|
-
disabled={false}
|
|
109
|
-
onClick={[Function]}
|
|
110
|
-
onKeyPress={[Function]}
|
|
111
|
-
tabIndex={0}
|
|
112
|
-
title="Zoom out"
|
|
113
|
-
type="button"
|
|
114
|
-
>
|
|
115
|
-
<svg
|
|
116
|
-
fill="currentColor"
|
|
117
|
-
focusable={false}
|
|
118
|
-
height="1em"
|
|
119
|
-
stroke="currentColor"
|
|
120
|
-
strokeWidth="0"
|
|
121
|
-
style={
|
|
122
|
-
{
|
|
123
|
-
"color": undefined,
|
|
124
|
-
}
|
|
125
|
-
}
|
|
126
|
-
viewBox="0 0 448 512"
|
|
127
|
-
width="1em"
|
|
128
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
129
|
-
>
|
|
130
|
-
<path
|
|
131
|
-
d="M416 208H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h384c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z"
|
|
132
|
-
/>
|
|
133
|
-
</svg>
|
|
134
|
-
</button>
|
|
135
|
-
</div>
|
|
136
|
-
`;
|
|
137
|
-
|
|
138
|
-
exports[`Zoom should match snapshot. 1`] = `
|
|
139
|
-
<div
|
|
140
|
-
className="rs-zooms-bar"
|
|
141
|
-
>
|
|
142
|
-
<button
|
|
143
|
-
className="rs-zoom-in"
|
|
144
|
-
disabled={false}
|
|
145
|
-
onClick={[Function]}
|
|
146
|
-
onKeyPress={[Function]}
|
|
147
|
-
tabIndex={0}
|
|
148
|
-
title="Zoom in"
|
|
149
|
-
type="button"
|
|
150
|
-
>
|
|
151
|
-
<svg
|
|
152
|
-
fill="currentColor"
|
|
153
|
-
focusable={false}
|
|
154
|
-
height="1em"
|
|
155
|
-
stroke="currentColor"
|
|
156
|
-
strokeWidth="0"
|
|
157
|
-
style={
|
|
158
|
-
{
|
|
159
|
-
"color": undefined,
|
|
160
|
-
}
|
|
161
|
-
}
|
|
162
|
-
viewBox="0 0 448 512"
|
|
163
|
-
width="1em"
|
|
164
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
165
|
-
>
|
|
166
|
-
<path
|
|
167
|
-
d="M416 208H272V64c0-17.67-14.33-32-32-32h-32c-17.67 0-32 14.33-32 32v144H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h144v144c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32V304h144c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z"
|
|
168
|
-
/>
|
|
169
|
-
</svg>
|
|
170
|
-
</button>
|
|
171
|
-
<button
|
|
172
|
-
className="rs-zoom-out"
|
|
173
|
-
disabled={false}
|
|
174
|
-
onClick={[Function]}
|
|
175
|
-
onKeyPress={[Function]}
|
|
176
|
-
tabIndex={0}
|
|
177
|
-
title="Zoom out"
|
|
178
|
-
type="button"
|
|
179
|
-
>
|
|
180
|
-
<svg
|
|
181
|
-
fill="currentColor"
|
|
182
|
-
focusable={false}
|
|
183
|
-
height="1em"
|
|
184
|
-
stroke="currentColor"
|
|
185
|
-
strokeWidth="0"
|
|
186
|
-
style={
|
|
187
|
-
{
|
|
188
|
-
"color": undefined,
|
|
189
|
-
}
|
|
190
|
-
}
|
|
191
|
-
viewBox="0 0 448 512"
|
|
192
|
-
width="1em"
|
|
193
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
194
|
-
>
|
|
195
|
-
<path
|
|
196
|
-
d="M416 208H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h384c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z"
|
|
197
|
-
/>
|
|
198
|
-
</svg>
|
|
199
|
-
</button>
|
|
200
|
-
</div>
|
|
201
|
-
`;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default } from './Zoom';
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import PropTypes from 'prop-types';
|
|
3
|
-
// Import default implementation from react-styleguidist using the full path
|
|
4
|
-
import ComponentsListRenderer from 'react-styleguidist/lib/client/rsg-components/ComponentsList/ComponentsListRenderer';
|
|
5
|
-
import getUrl from 'react-styleguidist/lib/client/utils/getUrl';
|
|
6
|
-
|
|
7
|
-
const propTypes = {
|
|
8
|
-
items: PropTypes.array.isRequired,
|
|
9
|
-
classes: PropTypes.object,
|
|
10
|
-
hashPath: PropTypes.array,
|
|
11
|
-
useRouterLinks: PropTypes.bool,
|
|
12
|
-
useHashId: PropTypes.bool,
|
|
13
|
-
};
|
|
14
|
-
|
|
15
|
-
const defaultProps = {
|
|
16
|
-
classes: null,
|
|
17
|
-
hashPath: [],
|
|
18
|
-
useRouterLinks: false,
|
|
19
|
-
useHashId: true,
|
|
20
|
-
};
|
|
21
|
-
|
|
22
|
-
function ComponentsList({
|
|
23
|
-
classes,
|
|
24
|
-
items,
|
|
25
|
-
useRouterLinks = false,
|
|
26
|
-
useHashId,
|
|
27
|
-
hashPath,
|
|
28
|
-
}) {
|
|
29
|
-
const mappedItems = items.map((item) => {
|
|
30
|
-
return {
|
|
31
|
-
...item,
|
|
32
|
-
href: item.href
|
|
33
|
-
? item.href
|
|
34
|
-
: // Conflict with Permalink Component: Remove the first '/' to avoid page reload on click
|
|
35
|
-
getUrl({
|
|
36
|
-
name: item.name,
|
|
37
|
-
slug: item.slug,
|
|
38
|
-
anchor: !useRouterLinks,
|
|
39
|
-
hashPath: useRouterLinks ? hashPath : false,
|
|
40
|
-
id: useRouterLinks ? useHashId : false,
|
|
41
|
-
})
|
|
42
|
-
.replace(/^\/index.html+/g, '')
|
|
43
|
-
.replace(/^\/+/g, ''),
|
|
44
|
-
};
|
|
45
|
-
});
|
|
46
|
-
return <ComponentsListRenderer classes={classes} items={mappedItems} />;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
ComponentsList.propTypes = propTypes;
|
|
50
|
-
ComponentsList.defaultProps = defaultProps;
|
|
51
|
-
|
|
52
|
-
export default ComponentsList;
|
|
@@ -1,277 +0,0 @@
|
|
|
1
|
-
/* eslint-disable import/no-unresolved */
|
|
2
|
-
import React, { useEffect, useState, useRef } from 'react';
|
|
3
|
-
import PropTypes from 'prop-types';
|
|
4
|
-
import { geopsTheme, Header, Footer } from '@geops/geops-ui';
|
|
5
|
-
import {
|
|
6
|
-
Hidden,
|
|
7
|
-
ClickAwayListener,
|
|
8
|
-
Collapse,
|
|
9
|
-
List,
|
|
10
|
-
ListItem,
|
|
11
|
-
Link,
|
|
12
|
-
} from '@material-ui/core';
|
|
13
|
-
import Open from '@material-ui/icons/ArrowDropDownTwoTone';
|
|
14
|
-
import Close from '@material-ui/icons/ArrowDropUpTwoTone';
|
|
15
|
-
import { ThemeProvider } from '@material-ui/core/styles';
|
|
16
|
-
import Version from 'react-styleguidist/lib/client/rsg-components/Version';
|
|
17
|
-
import Styled from 'react-styleguidist/lib/client/rsg-components/Styled';
|
|
18
|
-
import docConfig from '../../doc/doc-config.json';
|
|
19
|
-
|
|
20
|
-
const styles = ({ mq }) => {
|
|
21
|
-
return {
|
|
22
|
-
root: {
|
|
23
|
-
backgroundColor: 'white',
|
|
24
|
-
|
|
25
|
-
'& .MuiAutocomplete-root': {
|
|
26
|
-
margin: '20px 0',
|
|
27
|
-
width: 300,
|
|
28
|
-
},
|
|
29
|
-
},
|
|
30
|
-
version: {
|
|
31
|
-
padding: '10px 0 0 10px',
|
|
32
|
-
},
|
|
33
|
-
content: {
|
|
34
|
-
top: 68,
|
|
35
|
-
bottom: 0,
|
|
36
|
-
height: 'calc(100vh - 60px)',
|
|
37
|
-
position: 'fixed',
|
|
38
|
-
width: '100%',
|
|
39
|
-
zIndex: 0,
|
|
40
|
-
},
|
|
41
|
-
scrollable: {
|
|
42
|
-
overflowY: 'scroll',
|
|
43
|
-
height: 'calc(100vh - 68px)',
|
|
44
|
-
[mq.small]: {
|
|
45
|
-
top: 40,
|
|
46
|
-
position: 'absolute',
|
|
47
|
-
width: '100%',
|
|
48
|
-
height: 'calc(100vh - 108px)',
|
|
49
|
-
},
|
|
50
|
-
},
|
|
51
|
-
main: {
|
|
52
|
-
margin: 'auto',
|
|
53
|
-
width: 'calc(100vw - 30px)',
|
|
54
|
-
maxWidth: 1000,
|
|
55
|
-
padding: [[15, 30]],
|
|
56
|
-
paddingLeft: 230,
|
|
57
|
-
paddingTop: 55,
|
|
58
|
-
[mq.small]: {
|
|
59
|
-
padding: 5,
|
|
60
|
-
},
|
|
61
|
-
display: 'block',
|
|
62
|
-
},
|
|
63
|
-
sidebar: {
|
|
64
|
-
backgroundColor: '#EFEFEF',
|
|
65
|
-
border: '#e8e8e8 solid',
|
|
66
|
-
borderWidth: '0 1px 0 0',
|
|
67
|
-
position: 'fixed',
|
|
68
|
-
top: 68,
|
|
69
|
-
left: 0,
|
|
70
|
-
bottom: 0,
|
|
71
|
-
width: '200px',
|
|
72
|
-
overflow: 'auto',
|
|
73
|
-
},
|
|
74
|
-
dropdown: {
|
|
75
|
-
display: 'flex',
|
|
76
|
-
alignItems: 'center',
|
|
77
|
-
justifyContent: 'space-between',
|
|
78
|
-
padding: '0 10px 0',
|
|
79
|
-
position: 'fixed',
|
|
80
|
-
backgroundColor: '#efefef',
|
|
81
|
-
height: 40,
|
|
82
|
-
width: '100%',
|
|
83
|
-
zIndex: 99999,
|
|
84
|
-
color: '#6987a1',
|
|
85
|
-
borderBottom: '1px solid #6987a1',
|
|
86
|
-
},
|
|
87
|
-
footerWrapper: {
|
|
88
|
-
marginLeft: 200,
|
|
89
|
-
[mq.small]: {
|
|
90
|
-
marginLeft: 0,
|
|
91
|
-
},
|
|
92
|
-
},
|
|
93
|
-
};
|
|
94
|
-
};
|
|
95
|
-
|
|
96
|
-
export function StyleGuideRenderer({
|
|
97
|
-
classes,
|
|
98
|
-
children,
|
|
99
|
-
version,
|
|
100
|
-
toc,
|
|
101
|
-
hasSidebar,
|
|
102
|
-
}) {
|
|
103
|
-
const [apiKey, setApiKey] = useState();
|
|
104
|
-
const [dropdownOpen, toggleDropdown] = useState(false);
|
|
105
|
-
const [expanded, expandSection] = useState();
|
|
106
|
-
const [selected, setSelected] = useState('Components');
|
|
107
|
-
const ref = useRef();
|
|
108
|
-
useEffect(() => {
|
|
109
|
-
fetch('https://backend.developer.geops.io/publickey')
|
|
110
|
-
.then((response) => {
|
|
111
|
-
return response.json();
|
|
112
|
-
})
|
|
113
|
-
.then((data) => {
|
|
114
|
-
setApiKey(data.key);
|
|
115
|
-
})
|
|
116
|
-
.catch(() => {
|
|
117
|
-
setApiKey('error');
|
|
118
|
-
// eslint-disable-next-line no-console
|
|
119
|
-
console.error('Request to get the apiKey failed');
|
|
120
|
-
});
|
|
121
|
-
}, []);
|
|
122
|
-
|
|
123
|
-
if (!apiKey) {
|
|
124
|
-
return null;
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
// Makes apiKey accessible for all components.
|
|
128
|
-
window.apiKey = apiKey;
|
|
129
|
-
|
|
130
|
-
return (
|
|
131
|
-
<ThemeProvider theme={geopsTheme}>
|
|
132
|
-
<div className={classes.root}>
|
|
133
|
-
<Header
|
|
134
|
-
title={docConfig.appName}
|
|
135
|
-
tabs={[{ label: 'Code', href: `${docConfig.githubRepo}` }]}
|
|
136
|
-
/>
|
|
137
|
-
<div className={classes.content}>
|
|
138
|
-
<Hidden smUp>
|
|
139
|
-
<div
|
|
140
|
-
role="button"
|
|
141
|
-
type="button"
|
|
142
|
-
className={classes.dropdown}
|
|
143
|
-
onClick={() => {
|
|
144
|
-
return toggleDropdown(!dropdownOpen);
|
|
145
|
-
}}
|
|
146
|
-
onKeyDown={(e) => {
|
|
147
|
-
if (e.keyCode === 13) {
|
|
148
|
-
toggleDropdown(!dropdownOpen);
|
|
149
|
-
}
|
|
150
|
-
}}
|
|
151
|
-
tabIndex={0}
|
|
152
|
-
>
|
|
153
|
-
{selected}
|
|
154
|
-
{dropdownOpen ? <Close /> : <Open />}
|
|
155
|
-
</div>
|
|
156
|
-
<Collapse in={dropdownOpen} timeout="auto" unmountOnExit>
|
|
157
|
-
<ClickAwayListener
|
|
158
|
-
onClickAway={() => {
|
|
159
|
-
return toggleDropdown(false);
|
|
160
|
-
}}
|
|
161
|
-
>
|
|
162
|
-
<List
|
|
163
|
-
component="div"
|
|
164
|
-
disablePadding
|
|
165
|
-
style={{
|
|
166
|
-
width: '100%',
|
|
167
|
-
overflow: 'auto',
|
|
168
|
-
maxHeight: 'calc(100vh - 150px)',
|
|
169
|
-
top: 40,
|
|
170
|
-
backgroundColor: 'white',
|
|
171
|
-
boxShadow: '0 10px 15px #35353520',
|
|
172
|
-
zIndex: 99999,
|
|
173
|
-
}}
|
|
174
|
-
>
|
|
175
|
-
{toc.props.sections.slice(1).map((section) => {
|
|
176
|
-
return [
|
|
177
|
-
<ListItem
|
|
178
|
-
key={section.name}
|
|
179
|
-
button
|
|
180
|
-
onClick={() => {
|
|
181
|
-
return expanded === section.name
|
|
182
|
-
? expandSection()
|
|
183
|
-
: expandSection(section.name);
|
|
184
|
-
}}
|
|
185
|
-
style={{
|
|
186
|
-
fontWeight: 'bold',
|
|
187
|
-
color: '#6987a1',
|
|
188
|
-
borderTop: '1px solid #e8e8e8',
|
|
189
|
-
}}
|
|
190
|
-
>
|
|
191
|
-
{section.name}
|
|
192
|
-
</ListItem>,
|
|
193
|
-
<Collapse
|
|
194
|
-
key={`${section.name}-components`}
|
|
195
|
-
in={expanded === section.name}
|
|
196
|
-
timeout="auto"
|
|
197
|
-
unmountOnExit
|
|
198
|
-
>
|
|
199
|
-
{section.components.map((component) => {
|
|
200
|
-
return (
|
|
201
|
-
<ListItem
|
|
202
|
-
key={component.name}
|
|
203
|
-
button
|
|
204
|
-
style={{ paddingLeft: 32 }}
|
|
205
|
-
onClick={() => {
|
|
206
|
-
setSelected(component.name);
|
|
207
|
-
toggleDropdown(false);
|
|
208
|
-
}}
|
|
209
|
-
tabIndex={-1}
|
|
210
|
-
selected={selected === component.name}
|
|
211
|
-
>
|
|
212
|
-
<Link
|
|
213
|
-
style={{ display: 'block', width: '100%' }}
|
|
214
|
-
href={`#${component.name.toLowerCase()}`}
|
|
215
|
-
>
|
|
216
|
-
{component.name}
|
|
217
|
-
</Link>
|
|
218
|
-
</ListItem>
|
|
219
|
-
);
|
|
220
|
-
})}
|
|
221
|
-
</Collapse>,
|
|
222
|
-
];
|
|
223
|
-
})}
|
|
224
|
-
</List>
|
|
225
|
-
</ClickAwayListener>
|
|
226
|
-
</Collapse>
|
|
227
|
-
</Hidden>
|
|
228
|
-
<div className={classes.scrollable} ref={ref}>
|
|
229
|
-
<Hidden xsDown>
|
|
230
|
-
<div className={classes.sidebar}>
|
|
231
|
-
<header className={classes.version}>
|
|
232
|
-
{version && <Version>{version}</Version>}
|
|
233
|
-
</header>
|
|
234
|
-
{hasSidebar ? toc : null}
|
|
235
|
-
</div>
|
|
236
|
-
</Hidden>
|
|
237
|
-
<main className={classes.main}>{children}</main>
|
|
238
|
-
<div className={classes.footerWrapper}>
|
|
239
|
-
<Footer
|
|
240
|
-
onScrollToTop={() => {
|
|
241
|
-
ref.current.scrollTo({
|
|
242
|
-
top: 0,
|
|
243
|
-
left: 0,
|
|
244
|
-
behavior: 'smooth',
|
|
245
|
-
});
|
|
246
|
-
}}
|
|
247
|
-
/>
|
|
248
|
-
</div>
|
|
249
|
-
</div>
|
|
250
|
-
</div>
|
|
251
|
-
<div id="promo">
|
|
252
|
-
<a
|
|
253
|
-
href={docConfig.githubRepo}
|
|
254
|
-
target="_blank"
|
|
255
|
-
rel="noopener noreferrer"
|
|
256
|
-
>
|
|
257
|
-
<div id="promo-text">Fork me on GitHub</div>
|
|
258
|
-
</a>
|
|
259
|
-
</div>
|
|
260
|
-
</div>
|
|
261
|
-
</ThemeProvider>
|
|
262
|
-
);
|
|
263
|
-
}
|
|
264
|
-
|
|
265
|
-
StyleGuideRenderer.defaultProps = {
|
|
266
|
-
version: null,
|
|
267
|
-
};
|
|
268
|
-
|
|
269
|
-
StyleGuideRenderer.propTypes = {
|
|
270
|
-
classes: PropTypes.object.isRequired,
|
|
271
|
-
children: PropTypes.node.isRequired,
|
|
272
|
-
version: PropTypes.string,
|
|
273
|
-
toc: PropTypes.node.isRequired,
|
|
274
|
-
hasSidebar: PropTypes.bool.isRequired,
|
|
275
|
-
};
|
|
276
|
-
|
|
277
|
-
export default Styled(styles)(StyleGuideRenderer);
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
/* Overwrtie styleguidist styles */
|
|
2
|
-
|
|
3
|
-
.link-active {
|
|
4
|
-
font-weight: bold !important;
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
header a:hover {
|
|
8
|
-
text-decoration: none;
|
|
9
|
-
color: inherit;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
#promo {
|
|
13
|
-
position: fixed;
|
|
14
|
-
bottom: 55px;
|
|
15
|
-
background-color: #e90;
|
|
16
|
-
right: -65px;
|
|
17
|
-
transform: rotate(-45deg);
|
|
18
|
-
z-index: 1;
|
|
19
|
-
line-height: 1.2;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
#promo-text {
|
|
23
|
-
color: white;
|
|
24
|
-
font-size: 14px;
|
|
25
|
-
font-family: sans-serif;
|
|
26
|
-
font-weight: bold;
|
|
27
|
-
margin: 0;
|
|
28
|
-
padding: 3px 70px;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
#promo a,
|
|
32
|
-
#promo a:hover {
|
|
33
|
-
text-decoration: none;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
footer {
|
|
37
|
-
position: relative !important;
|
|
38
|
-
}
|
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
import OLVectorLayer from 'ol/layer/Vector';
|
|
2
|
-
import VectorSource from 'ol/source/Vector';
|
|
3
|
-
import Control from 'ol/control/Control';
|
|
4
|
-
import Draw from 'ol/interaction/Draw';
|
|
5
|
-
import Snap from 'ol/interaction/Snap';
|
|
6
|
-
import Pointer from 'ol/interaction/Pointer';
|
|
7
|
-
import Select from 'ol/interaction/Select';
|
|
8
|
-
import Modify from 'ol/interaction/Modify';
|
|
9
|
-
import Style from 'ol/style/Style';
|
|
10
|
-
import Fill from 'ol/style/Fill';
|
|
11
|
-
import Stroke from 'ol/style/Stroke';
|
|
12
|
-
import Circle from 'ol/style/Circle';
|
|
13
|
-
import Icon from 'ol/style/Icon';
|
|
14
|
-
import RegularShape from 'ol/style/RegularShape';
|
|
15
|
-
import Collection from 'ol/Collection';
|
|
16
|
-
import Feature from 'ol/Feature';
|
|
17
|
-
import Observable, { unByKey } from 'ol/Observable';
|
|
18
|
-
import { getCenter } from 'ol/extent';
|
|
19
|
-
import {
|
|
20
|
-
Point,
|
|
21
|
-
LineString,
|
|
22
|
-
Polygon,
|
|
23
|
-
MultiPoint,
|
|
24
|
-
MultiLineString,
|
|
25
|
-
MultiPolygon,
|
|
26
|
-
} from 'ol/geom';
|
|
27
|
-
import LinearRing from 'ol/geom/LinearRing';
|
|
28
|
-
import { fromExtent } from 'ol/geom/Polygon';
|
|
29
|
-
import * as events from 'ol/events';
|
|
30
|
-
import * as condition from 'ol/events/condition';
|
|
31
|
-
import { OL3Parser } from 'jsts/org/locationtech/jts/io';
|
|
32
|
-
import { BufferOp } from 'jsts/org/locationtech/jts/operation/buffer';
|
|
33
|
-
import { OverlayOp } from 'jsts/org/locationtech/jts/operation/overlay';
|
|
34
|
-
|
|
35
|
-
/**
|
|
36
|
-
* This module create window.ol and window.jsts variables for ole editor.
|
|
37
|
-
*/
|
|
38
|
-
if (!window.ol) {
|
|
39
|
-
window.ol = {
|
|
40
|
-
Feature,
|
|
41
|
-
Collection,
|
|
42
|
-
layer: {
|
|
43
|
-
Vector: OLVectorLayer,
|
|
44
|
-
},
|
|
45
|
-
source: {
|
|
46
|
-
Vector: VectorSource,
|
|
47
|
-
},
|
|
48
|
-
interaction: {
|
|
49
|
-
Draw,
|
|
50
|
-
Snap,
|
|
51
|
-
Pointer,
|
|
52
|
-
Select,
|
|
53
|
-
Modify,
|
|
54
|
-
},
|
|
55
|
-
control: {
|
|
56
|
-
Control,
|
|
57
|
-
},
|
|
58
|
-
style: {
|
|
59
|
-
Style,
|
|
60
|
-
Fill,
|
|
61
|
-
Stroke,
|
|
62
|
-
Circle,
|
|
63
|
-
RegularShape,
|
|
64
|
-
Icon,
|
|
65
|
-
},
|
|
66
|
-
geom: {
|
|
67
|
-
Point,
|
|
68
|
-
LineString,
|
|
69
|
-
Polygon,
|
|
70
|
-
MultiPoint,
|
|
71
|
-
MultiLineString,
|
|
72
|
-
MultiPolygon,
|
|
73
|
-
LinearRing,
|
|
74
|
-
},
|
|
75
|
-
extent: {
|
|
76
|
-
getCenter,
|
|
77
|
-
},
|
|
78
|
-
Observable: {
|
|
79
|
-
...Observable,
|
|
80
|
-
unByKey,
|
|
81
|
-
},
|
|
82
|
-
events: {
|
|
83
|
-
...events,
|
|
84
|
-
condition: {
|
|
85
|
-
...condition,
|
|
86
|
-
},
|
|
87
|
-
},
|
|
88
|
-
};
|
|
89
|
-
window.ol.geom.Polygon.fromExtent = fromExtent;
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
if (!window.jsts) {
|
|
93
|
-
window.jsts = {
|
|
94
|
-
io: {
|
|
95
|
-
OL3Parser,
|
|
96
|
-
},
|
|
97
|
-
operation: { buffer: { BufferOp }, overlay: { OverlayOp } },
|
|
98
|
-
};
|
|
99
|
-
}
|