This commit is contained in:
2025-09-11 07:45:25 -07:00
parent ca8798848e
commit 955946e79d
2873 changed files with 299107 additions and 183282 deletions

18
node_modules/@react-leaflet/core/lib/attribution.js generated vendored Normal file
View File

@@ -0,0 +1,18 @@
import { useEffect, useRef } from 'react';
export function useAttribution(map, attribution) {
const attributionRef = useRef(attribution);
useEffect(function updateAttribution() {
if (attribution !== attributionRef.current && map.attributionControl != null) {
if (attributionRef.current != null) {
map.attributionControl.removeAttribution(attributionRef.current);
}
if (attribution != null) {
map.attributionControl.addAttribution(attribution);
}
}
attributionRef.current = attribution;
}, [
map,
attribution
]);
}