diff --git a/src/main.py b/src/main.py index 351a55c..ead984c 100644 --- a/src/main.py +++ b/src/main.py @@ -235,7 +235,7 @@ class SecurityHeadersMiddleware(BaseHTTPMiddleware): "script-src 'self' 'unsafe-inline' https://cdn.jsdelivr.net; " "style-src 'self' 'unsafe-inline' https://fonts.googleapis.com https://cdn.jsdelivr.net; " "font-src 'self' https://fonts.gstatic.com; " - "img-src 'self' data: https://*.basemaps.cartocdn.com https://*.tile.openstreetmap.org; " + "img-src 'self' data: https://tile.openstreetmap.de; " "connect-src 'self' wss: ws:; " "frame-ancestors 'none'" ) diff --git a/src/static/js/components.js b/src/static/js/components.js index 494d197..fb982b9 100644 --- a/src/static/js/components.js +++ b/src/static/js/components.js @@ -744,15 +744,11 @@ const UI = { if (layer instanceof L.TileLayer) this._map.removeLayer(layer); }); - const theme = document.documentElement.getAttribute('data-theme') || 'dark'; - const tileUrl = theme === 'dark' - ? 'https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}.png' - : 'https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png'; - const attribution = theme === 'dark' - ? '© OSM © CARTO' - : '© OpenStreetMap'; + // Deutsche OSM-Kacheln: deutsche Ortsnamen, einheitlich fuer beide Themes + const tileUrl = 'https://tile.openstreetmap.de/{z}/{x}/{y}.png'; + const attribution = '© OpenStreetMap'; - L.tileLayer(tileUrl, { attribution, maxZoom: 18, subdomains: 'abcd' }).addTo(this._map); + L.tileLayer(tileUrl, { attribution, maxZoom: 18 }).addTo(this._map); }, updateMapTheme() {