Skip to content

Commit 4f2b197

Browse files
committed
fix: center location pin
1 parent e4dfd37 commit 4f2b197

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

script.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -155,9 +155,7 @@ onload = function () {
155155

156156
if (URLwords != null) {
157157
setStart(words_to_coord(URLwords), map, marker);
158-
// notify("You recived a message!")
159158
} else {
160-
// notify("Write something and share the URL!")
161159
if (navigator.geolocation) {
162160
navigator.geolocation.getCurrentPosition(function (position) {
163161
setStart(
@@ -193,7 +191,7 @@ var map = new ol.Map({
193191

194192
var marker = new ol.Overlay({
195193
position: ol.proj.fromLonLat(coords),
196-
// positioning: "center-center",
194+
positioning: "center-center",
197195
element: document.getElementById("marker"),
198196
stopEvent: false,
199197
});
@@ -206,4 +204,4 @@ map.on("click", function (evt) {
206204
marker.setPosition(ol.proj.fromLonLat(coords));
207205

208206
updateWords(coords);
209-
});
207+
});

0 commit comments

Comments
 (0)