diff --git a/src/styles/map.less b/src/styles/map.less index a033225..0a53d55 100644 --- a/src/styles/map.less +++ b/src/styles/map.less @@ -126,8 +126,25 @@ font-size: 13px; transform: translate(-12px, -12px); transition: box-shadow 250ms; + position: relative; + outline: none; &:hover { box-shadow: fade(@cluster_small, 70%) 0 0 0 7px; } + + span { + outline: none; + position: absolute; + right: -7px; + bottom: 11px; + background: @cluster_small; + width: 16px; + height: 16px; + display: flex; + align-items: center; + justify-content: center; + border-radius: 8px; + font-size: 11px; + } } diff --git a/src/utils/clusterIcon.js b/src/utils/clusterIcon.js index 2224df4..7d45b89 100644 --- a/src/utils/clusterIcon.js +++ b/src/utils/clusterIcon.js @@ -1,8 +1,9 @@ import { divIcon } from 'leaflet'; -export const clusterIcon = () => divIcon({ +export const clusterIcon = cluster => divIcon({ html: ` -