Files
nodeMap/docs/components/pois/AddPOIModal.md
2025-05-28 09:45:35 +02:00

27 lines
964 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!-- /docs/components/pois/AddPOIModal.md -->
# AddPOIModal.js
Zeigt ein modales Formular an, um einen neuen POI auf der Karte zu erstellen.
Die Koordinaten (`latlng`) werden automatisch übernommen.
## Funktionen
- POI-Name, Typ und zugehöriges Gerät auswählbar
- Koordinatenanzeige (`lat`, `lng`)
- Dynamisches Laden der Gerätedaten und POI-Typen
- Fehleranzeige bei fehlgeschlagenem Speichern
- Löst `addPoiThunk` + Refresh-Trigger (`incrementTrigger`) aus
## Props
| Prop | Typ | Beschreibung |
|----------|-----------|--------------------------------------------------|
| `onClose` | `function` | Schließt das Modal |
| `map` | `Leaflet` | (optional) zum Schließen evtl. offener Popups |
| `latlng` | `object` | Koordinaten für den neuen POI |
## Redux
- `fetchPoiTypThunk`, `fetchPoiIconsDataThunk`
- `addPoiThunk`, `resetAddPoiStatus`