From 743e84560db7ba17c02505dbb63337365ecb4909 Mon Sep 17 00:00:00 2001 From: Wolfgang Hottgenroth Date: Thu, 27 Nov 2025 22:24:29 +0100 Subject: [PATCH] garaga page 2 --- apps/ui/templates/garage.html | 63 ++++++++++++++++------------------- 1 file changed, 28 insertions(+), 35 deletions(-) diff --git a/apps/ui/templates/garage.html b/apps/ui/templates/garage.html index d046197..49bdccf 100644 --- a/apps/ui/templates/garage.html +++ b/apps/ui/templates/garage.html @@ -195,28 +195,13 @@ .phase-grid { display: grid; grid-template-columns: repeat(3, 1fr); - gap: 16px; - margin-top: 16px; - } - - @media (max-width: 600px) { - .phase-grid { - grid-template-columns: 1fr; - } - } - - .phase-section { - background: white; - border-radius: 8px; - padding: 16px; - text-align: center; + gap: 20px; } .phase-section h4 { - font-size: 14px; - font-weight: 600; color: #333; - margin: 0 0 12px 0; + margin-bottom: 12px; + text-align: center; } .phase-values { @@ -227,20 +212,26 @@ .phase-value { display: flex; - align-items: baseline; - justify-content: center; - gap: 4px; + justify-content: space-between; + padding: 8px 12px; + background: rgba(102, 126, 234, 0.1); + border-radius: 8px; } .phase-value .value { - font-size: 18px; font-weight: 600; color: #667eea; } .phase-value .unit { - font-size: 14px; color: #666; + font-size: 14px; + } + + @media (max-width: 768px) { + .phase-grid { + grid-template-columns: 1fr; + } } .loading { @@ -453,11 +444,11 @@ function renderThreePhasePowerDisplay(container, device) { const state = deviceStates[device.device_id] || {}; - // Overview card - const overviewCard = document.createElement('div'); - overviewCard.className = 'card'; - overviewCard.innerHTML = '
Leistungsmessung
'; + const card = document.createElement('div'); + card.className = 'card'; + card.innerHTML = '
Leistungsmessung
'; + // Übersicht const overviewGrid = document.createElement('div'); overviewGrid.className = 'state-grid'; overviewGrid.innerHTML = ` @@ -470,13 +461,13 @@
Energie
`; - overviewCard.appendChild(overviewGrid); - container.appendChild(overviewCard); + card.appendChild(overviewGrid); - // Phases card - const phasesCard = document.createElement('div'); - phasesCard.className = 'card'; - phasesCard.innerHTML = '
Phasen
'; + // Phasen Details + const phaseCard = document.createElement('div'); + phaseCard.className = 'card'; + phaseCard.innerHTML = '
Phasen
'; + phaseCard.style.marginTop = '20px'; const phaseGrid = document.createElement('div'); phaseGrid.className = 'phase-grid'; @@ -533,8 +524,10 @@ `; - phasesCard.appendChild(phaseGrid); - container.appendChild(phasesCard); + phaseCard.appendChild(phaseGrid); + + container.appendChild(card); + container.appendChild(phaseCard); } async function toggleOutlet(deviceId, newState) {