From 345c34730f56f2450441c0cc9064268a5cf26c56 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=98=D0=BB=D1=8C=D1=8F=D1=81=20=D0=A1=D1=83=D0=BB=D1=82?= =?UTF-8?q?=D0=B0=D0=BD=D0=BE=D0=B2?= Date: Wed, 23 Sep 2026 13:07:13 +0300 Subject: [PATCH] =?UTF-8?q?fix(gps):=20iconShape=20=D1=83=20=D0=BA=D0=B0?= =?UTF-8?q?=D1=81=D1=82=D0=BE=D0=BC=D0=BD=D1=8B=D1=85=20=D0=BC=D0=B0=D1=80?= =?UTF-8?q?=D0=BA=D0=B5=D1=80=D0=BE=D0=B2=20=D0=AF=D0=BD=D0=B4=D0=B5=D0=BA?= =?UTF-8?q?=D1=81=D0=B0=20=E2=80=94=20=D0=B1=D0=B5=D0=B7=20=D0=BD=D0=B5?= =?UTF-8?q?=D0=B3=D0=BE=20hit-test=20=D0=BD=D0=B5=20=D0=BD=D0=B0=D1=85?= =?UTF-8?q?=D0=BE=D0=B4=D0=B8=D0=BB=20=D0=BC=D0=B5=D1=82=D0=BA=D1=83,=20?= =?UTF-8?q?=D0=BA=D0=BB=D0=B8=D0=BA=D0=B8=20=D1=83=D1=85=D0=BE=D0=B4=D0=B8?= =?UTF-8?q?=D0=BB=D0=B8=20=D0=B2=20events-pane?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- client/src/components/gps/Yandex21Map.tsx | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/client/src/components/gps/Yandex21Map.tsx b/client/src/components/gps/Yandex21Map.tsx index 536704a..540991a 100644 --- a/client/src/components/gps/Yandex21Map.tsx +++ b/client/src/components/gps/Yandex21Map.tsx @@ -268,6 +268,15 @@ export function Yandex21Map({ { iconLayout: ymaps.templateLayoutFactory.createClass(gpsMarkerHtml(m)), iconOffset: [-layout.anchorX, -layout.anchorY], + // Активная область клика: без iconShape у кастомного iconLayout + // hit-test Яндекса не находит метку — клики уходят в events-pane + iconShape: { + type: 'Rectangle', + coordinates: [ + [0, 0], + [layout.width, layout.height], + ], + } as unknown as ymaps.IGeometryJson, ...(m.zIndex !== undefined ? { zIndex: m.zIndex } : {}), } );