Skip to content

Build your personal knowledge base with Trilium Notes

feat(geomap): enable autopan for dragging markers

Elian Doranb2a5f0664619
diff --git a/src/public/app/widgets/type_widgets/geo_map.ts b/src/public/app/widgets/type_widgets/geo_map.ts
index 77ccfd0491..ed61f0a2c0 100644
--- a/src/public/app/widgets/type_widgets/geo_map.ts
+++ b/src/public/app/widgets/type_widgets/geo_map.ts
@@ -128,7 +128,9 @@ export default class GeoMapTypeWidget extends TypeWidget {
const [ lat, lng ] = latLng.split(",", 2).map((el) => parseFloat(el));
const marker = L.marker(L.latLng(lat, lng), {
- draggable: true
+ draggable: true,
+ autoPan: true,
+ autoPanSpeed: 5
})
.addTo(map)
.bindPopup(childNote.title)