diff --git a/docker-compose.gitea.yml b/docker-compose.gitea.yml index 86524d7..bc8ccfa 100644 --- a/docker-compose.gitea.yml +++ b/docker-compose.gitea.yml @@ -24,7 +24,7 @@ services: - USER_UID=1000 - USER_GID=1000 - GITEA__database__DB_TYPE=sqlite3 - - GITEA__server__ROOT_URL=http://192.168.1.183:3100 + - GITEA__server__ROOT_URL=https://git.purepixel.ch - GITEA__server__HTTP_PORT=3000 - GITEA__server__LFS_START_SERVER=true volumes: @@ -43,3 +43,4 @@ volumes: networks: lageplan_lageplan-net: external: true + diff --git a/docker-compose.portainer.yml b/docker-compose.portainer.yml index 6a4cdc5..44e6946 100644 --- a/docker-compose.portainer.yml +++ b/docker-compose.portainer.yml @@ -77,7 +77,7 @@ services: # ─── Lageplan Web App ────────────────────── web: - image: lageplan-web:latest + image: 192.168.1.183:3100/adminpepe/lageplan:latest restart: unless-stopped environment: DATABASE_URL: postgresql://${POSTGRES_USER:-lageplan}:${POSTGRES_PASSWORD:-lageplan_secret}@db:5432/${POSTGRES_DB:-lageplan} diff --git a/next.config.js b/next.config.js index 58035f9..be8d2fd 100644 --- a/next.config.js +++ b/next.config.js @@ -35,7 +35,7 @@ const nextConfig = { key: 'Content-Security-Policy', value: [ "default-src 'self'", - "script-src 'self' 'unsafe-inline' 'unsafe-eval'", + "script-src 'self' 'unsafe-inline' 'unsafe-eval' blob:", "style-src 'self' 'unsafe-inline'", "img-src 'self' data: blob: https://*.tile.openstreetmap.org https://api.maptiler.com http://localhost:9000 http://minio:9000", "font-src 'self' data:", diff --git a/package.json b/package.json index b3f4855..26da5f0 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "lageplan", - "version": "1.0.0", + "version": "1.0.1", "description": "Feuerwehr Lageplan - Krokier-App für Einsatzdokumentation", "private": true, "scripts": { diff --git a/src/components/layout/topbar.tsx b/src/components/layout/topbar.tsx index 26fdaef..6c868b2 100644 --- a/src/components/layout/topbar.tsx +++ b/src/components/layout/topbar.tsx @@ -38,6 +38,7 @@ import { Key, Shield, Building2, + MapPin, } from 'lucide-react' import { HoseSettingsDialog } from '@/components/dialogs/hose-settings-dialog' import type { Project, DrawFeature } from '@/app/app/page' diff --git a/src/components/map/map-view.tsx b/src/components/map/map-view.tsx index 2b8e0d4..de54ce8 100644 --- a/src/components/map/map-view.tsx +++ b/src/components/map/map-view.tsx @@ -718,6 +718,9 @@ export function MapView({ if (!m) return setIsMapLoaded(true) + // Guard: skip if sources already exist (React strict mode double-mount) + if (m.getSource('draw-features')) return + // Drawing features source m.addSource('draw-features', { type: 'geojson', @@ -2028,14 +2031,14 @@ export function MapView({ const startW = selectedSymbolRef.current.resizeStartWidth || 1 const startScale = selectedSymbolRef.current.resizeStartScale || 1 const ratio = width / startW - selectedSymbolRef.current.scale = Math.max(0.5, Math.min(5, startScale * ratio)) + selectedSymbolRef.current.scale = Math.max(0.2, Math.min(10, startScale * ratio)) selectedSymbolRef.current.innerEl.style.fontSize = `${baseFontSize * selectedSymbolRef.current.scale}px` } else { // For symbols: resize wrapper selectedSymbolRef.current.wrapperEl.style.width = `${width}px` selectedSymbolRef.current.wrapperEl.style.height = `${height}px` const baseSize = 32 - selectedSymbolRef.current.scale = Math.max(0.3, Math.min(4, width / baseSize)) + selectedSymbolRef.current.scale = Math.max(0.1, Math.min(10, width / baseSize)) } } }}