Skip to content

Build your personal knowledge base with Trilium Notes

Merge branch 'feature/geomap_collection' of https://github.com/TriliumNext/trilium into feature/geomap_collection

Elian Doran9df7d6227e6e
diff --cc apps/client/src/widgets/view_widgets/geo_view/markers.ts
index 1d335cfcb2,71737df49b..448da11d9f
--- a/apps/client/src/widgets/view_widgets/geo_view/markers.ts
+++ b/apps/client/src/widgets/view_widgets/geo_view/markers.ts
@@@ -8,9 -11,9 +10,9 @@@ import L from "leaflet"
let gpxLoaded = false;
- export default function processNoteWithMarker(map: Map, note: FNote, location: string) {
+ export default function processNoteWithMarker(map: Map, note: FNote, location: string, isEditable: boolean) {
const [lat, lng] = location.split(",", 2).map((el) => parseFloat(el));
- const icon = buildIcon(note.getIcon(), note.getColorClass(), note.title);
+ const icon = buildIcon(note.getIcon(), note.getColorClass(), note.title, note.noteId);
const newMarker = marker(latLng(lat, lng), {
icon,
@@@ -32,9 -38,16 +37,9 @@@
}
});
newMarker.on("contextmenu", (e) => {
- openContextMenu(note.noteId, e.originalEvent);
+ openContextMenu(note.noteId, e, isEditable);
});
- const el = newMarker.getElement();
- if (el) {
- const $el = $(el);
- $el.attr("data-href", `#${note.noteId}`);
- note_tooltip.setupElementTooltip($($el));
- }
-
return newMarker;
}