Fixed marker-cluster position
This commit is contained in:
@@ -26,7 +26,6 @@ export const calculateAnchor = (
|
||||
mode: "popup" | "marker",
|
||||
options?: { ignoreMarker?: boolean; ignoreCluster?: boolean },
|
||||
) => {
|
||||
console.log("calculateAnchor", id, mode, options);
|
||||
const otherMarkers = document.querySelectorAll(".map-collision");
|
||||
// get markers and check if they are overlapping
|
||||
const ownMarker =
|
||||
@@ -52,8 +51,6 @@ export const calculateAnchor = (
|
||||
);
|
||||
});
|
||||
|
||||
if (id.includes("13")) console.log(ownMarker, marksersInCluster);
|
||||
|
||||
// get the center of all overlapping markers
|
||||
const markersPosition = marksersInCluster.map((marker) => {
|
||||
const rect = (marker as HTMLElement).getBoundingClientRect();
|
||||
|
||||
Reference in New Issue
Block a user