From 726b601682f5e8b0c19d5679d349a1b3a47aa710 Mon Sep 17 00:00:00 2001 From: Patrick Browne Date: Mon, 9 Sep 2024 09:51:12 +0200 Subject: [PATCH] feat: Add tooltip showing municipality name --- website/src/components/Mutations/Map.tsx | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/website/src/components/Mutations/Map.tsx b/website/src/components/Mutations/Map.tsx index 994bb53..0a82efe 100644 --- a/website/src/components/Mutations/Map.tsx +++ b/website/src/components/Mutations/Map.tsx @@ -18,12 +18,25 @@ const MutationsMap = ({ geoData: ReturnType["data"]; } & ComponentProps) => { return ( - + { + if (!object) { + return; + } + return "Municipality: " + object.properties.name; + }} + {...props} + > {geoData.municipalities && (