Add column-glossary legend below the leaderboard table

This commit is contained in:
Michiel Berger 2026-04-30 21:44:09 +02:00
parent a3b9b2a0e9
commit a65ad1ba34
2 changed files with 25 additions and 3 deletions

View file

@ -188,6 +188,18 @@ table#leaderboard thead th.sort-asc::after { content: " ↑"; color: var(--acce
table#leaderboard thead th.sort-desc::after { content: " ↓"; color: var(--accent); }
table#leaderboard td.pos { color: var(--accent); }
table#leaderboard td.neg { color: var(--warn); }
dl.legend {
margin: 1rem 0 0;
font-size: 0.78rem;
color: var(--muted);
display: grid;
grid-template-columns: max-content 1fr;
column-gap: 0.75rem;
row-gap: 0.2rem;
}
dl.legend dt { font-weight: 600; color: var(--text); }
dl.legend dd { margin: 0; }
table#leaderboard tbody tr:hover { background: var(--panel2); }
table#leaderboard tbody tr:first-child { background: rgba(74, 222, 128, 0.08); }

View file

@ -4,7 +4,7 @@
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Honest battery payback — vs thuisbatterijgids.nl</title>
<link rel="stylesheet" href="{{ url_for('static', filename='style.css') }}?v=10">
<link rel="stylesheet" href="{{ url_for('static', filename='style.css') }}?v=11">
</head>
<body>
@ -108,7 +108,7 @@
<th data-sort="pct_hours_charge_saturated" data-default-dir="desc" title="% of surplus hours where charging was pegged at max kW and couldn't keep up">% sat</th>
</tr>
</thead>
<tbody id="leaderboard-body">
<tbody id="leaderboard-body">{# rendered cells start below; legend follows the table. #}
{% for r in initial.batteries %}
<tr data-category="{{ r.category }}">
<td>{{ loop.index }}</td>
@ -127,6 +127,16 @@
{% endfor %}
</tbody>
</table>
<dl class="legend">
<dt>LP €/yr</dt> <dd>Honest year-1 savings from our linear-program oracle (perfect 24h foresight).</dd>
<dt>LP yr</dt> <dd>Years until cumulative savings (with the chosen inflation rate) recoup the battery cost.</dd>
<dt>10-yr net</dt> <dd>Total profit over 10 years: cumulative savings (compounded by inflation) minus the battery cost. Red = doesn't break even within 10 yr.</dd>
<dt>kWh capt</dt> <dd>kWh of available solar surplus the battery actually absorbed over the year.</dd>
<dt>% capt</dt> <dd>That, as a percentage of the scenario's total surplus (shown in the heading).</dd>
<dt>% full</dt> <dd>Of all surplus hours, the % when the battery was already full and couldn't store more — capacity-bottlenecked.</dd>
<dt>% sat</dt> <dd>Of all surplus hours, the % when charging was pegged at max kW and couldn't keep up — power-bottlenecked.</dd>
</dl>
</div>
</section>
</main>
@ -140,6 +150,6 @@
</p>
</footer>
<script src="{{ url_for('static', filename='app.js') }}?v=10"></script>
<script src="{{ url_for('static', filename='app.js') }}?v=11"></script>
</body>
</html>