feat: Anleitung-Popup und Version 1.5.0

- ANLEITUNG.html erstellt (Bedienungsanleitung als HTML-Seite)
- Anleitung-Button im Dashboard-Footer ergänzt
- Anleitung öffnet sich als Modal-Popup mit eigenem Header
- Version 1.4.1 → 1.5.0
This commit is contained in:
2026-05-02 21:36:12 +02:00
parent 6f7673358d
commit fc35e9b6e7
5 changed files with 1072 additions and 1 deletions
@@ -190,10 +190,27 @@
.version-line {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 0.5rem;
font-size: 0.85rem;
}
.anleitung-btn {
background: none;
border: 1px solid #0066cc;
border-radius: 6px;
color: #0066cc;
cursor: pointer;
font-size: 0.82rem;
padding: 0.2rem 0.75rem;
transition: background 0.15s, color 0.15s;
}
.anleitung-btn:hover {
background: #0066cc;
color: #fff;
}
.version-short {
display: none;
}
@@ -252,6 +269,52 @@
}
}
/* Anleitung Modal */
.anleitung-modal {
background: white;
border-radius: 12px;
width: 90vw;
max-width: 900px;
height: 85vh;
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
display: flex;
flex-direction: column;
overflow: hidden;
}
.anleitung-modal-header {
display: flex;
justify-content: space-between;
align-items: center;
padding: 0.55rem 0.9rem;
background: #1a3a5c;
color: #fff;
font-size: 0.95rem;
font-weight: 600;
border-radius: 12px 12px 0 0;
flex-shrink: 0;
}
.anleitung-modal-close {
background: none;
border: none;
font-size: 1.2rem;
cursor: pointer;
color: #fff;
line-height: 1;
padding: 0 0.2rem;
}
.anleitung-modal-close:hover {
color: #ddd;
}
.anleitung-frame {
width: 100%;
flex: 1;
border: none;
}
/* Modal Styles */
.modal-overlay {
position: fixed;
@@ -21,6 +21,9 @@ Highcharts.setOptions({
})
const WeatherDashboard = ({ data, currentData = [], rainData = [], timeRange = '24h', onTimeRangeChange, showTable = false, onToggleTable }) => {
// State für Anleitung
const [showAnleitung, setShowAnleitung] = useState(false)
// State für benutzerdefinierten Zeitbereich
const [showCustomRangeModal, setShowCustomRangeModal] = useState(false)
const [customStartDate, setCustomStartDate] = useState('')
@@ -1074,6 +1077,23 @@ const WeatherDashboard = ({ data, currentData = [], rainData = [], timeRange = '
</div>
)} {/* end showTable ternary */}
{/* Modal Anleitung */}
{showAnleitung && (
<div className="modal-overlay" onClick={() => setShowAnleitung(false)}>
<div className="anleitung-modal" onClick={(e) => e.stopPropagation()}>
<div className="anleitung-modal-header">
<span>Bedienungsanleitung</span>
<button className="anleitung-modal-close" onClick={() => setShowAnleitung(false)}></button>
</div>
<iframe
src="/ANLEITUNG.html"
title="Bedienungsanleitung"
className="anleitung-frame"
/>
</div>
</div>
)}
{/* Modal für benutzerdefinierten Zeitbereich */}
{showCustomRangeModal && (
<div className="modal-overlay" onClick={handleCancelCustomRange}>
@@ -1130,6 +1150,14 @@ const WeatherDashboard = ({ data, currentData = [], rainData = [], timeRange = '
mailto:rxf@gmx.de
</a>
</div>
<div>
<button
className="anleitung-btn"
onClick={() => setShowAnleitung(true)}
>
Anleitung
</button>
</div>
<div>
<span className="version-full">Version</span>
<span className="version-short">V</span>