diff --git a/ts/components/MapLocator.vue b/ts/components/MapLocator.vue index 718f4247..fb7c679d 100644 --- a/ts/components/MapLocator.vue +++ b/ts/components/MapLocator.vue @@ -164,14 +164,14 @@ import { watch, } from "vue"; import { boundsMarkers, boundsDefault } from "@/map-utils"; -import type { Marker } from "@/types"; +import type { MapClickEvent, Marker } from "@/types"; import type { Location } from "@/type/api"; import type { Camera, MoveEndEventInternal } from "@/type/map"; // Emits interface interface Emits { (e: "update:modelValue", value: Camera): void; - (e: "click", location: Location): void; + (e: "click", event: MapClickEvent): void; (e: "marker-drag-end", location: Location): void; } @@ -290,11 +290,14 @@ function initializeMap() { } clickTimeout.value = window.setTimeout(() => { - const location: Location = { - latitude: e.lngLat.lat, - longitude: e.lngLat.lng, - }; - emit("click", location); + emit("click", { + location: { + latitude: e.lngLat.lat, + longitude: e.lngLat.lng, + }, + map: _map, + point: e.point, + }); }, 100); }); diff --git a/ts/components/MapProxiedArcgisTile.vue b/ts/components/MapProxiedArcgisTile.vue index 954c2ef3..002721a7 100644 --- a/ts/components/MapProxiedArcgisTile.vue +++ b/ts/components/MapProxiedArcgisTile.vue @@ -140,12 +140,12 @@ import { import LayersControl from "@/components/LayersControl"; import { boundsMarkers, boundsDefault } from "@/map-utils"; -import { MapClickEvent, Marker, Point } from "@/types"; +import { type MapClickEvent, type Marker, Point } from "@/types"; import type { Location } from "@/type/api"; import type { Camera, MoveEndEventInternal } from "@/type/map"; interface Emits { - (e: "map-click", event: MapClickEvent): void; + (e: "click", event: MapClickEvent): void; (e: "update:modelValue", value: Camera): void; } interface Props { @@ -288,8 +288,9 @@ const initializeMap = () => { type: "raster", }); - _map.on("click", (e) => { - emit("map-click", { + _map.on("click", (e: maplibregl.MapLayerMouseEvent) => { + e.preventDefault(); + emit("click", { location: { latitude: e.lngLat.lat, longitude: e.lngLat.lng, diff --git a/ts/components/ReviewPoolColumnDetail.vue b/ts/components/ReviewPoolColumnDetail.vue index 4d4a76a5..a25d7099 100644 --- a/ts/components/ReviewPoolColumnDetail.vue +++ b/ts/components/ReviewPoolColumnDetail.vue @@ -133,7 +133,12 @@
- +

loading...

@@ -145,7 +150,7 @@ v-show="selectedTask?.pool" >