hd-price-bars
Electricity prices as bars in their colours, cheap to expensive on each day’s own range (cheap, normal, expensive; below zero its own colour, drawn under the zero line), the slot now marked and the past dimmed. A band can mark the cheapest hours (highlight-*), a bracket another stretch, like a car’s charging (mark-*); slots not published yet (tomorrow before ~13:00) wait as a dashed outline with pending on it. Hover or tap a bar to read its price. The colours follow the theme (--hd-price-*), as greys on e-ink. Bars grow in at full motion only. For today and tomorrow: values="{{ prices.bars.values }}" start="{{ prices.bars.start }}" step="{{ prices.bars.step }}" now="{{ prices.now.start }}".
| Attribute | What it is |
|---|---|
valuesrequired | The prices per slot, separated by commas, e.g. {{ prices.bars.values }} or {{ prices.today.values }}. |
levels | Each slot’s level (negative, cheap, normal, high), separated by commas, e.g. {{ prices.bars.levels }}, so the colours are the ones the rest of the widget says; worked out from the values (against each day’s average) when left out. |
start | When the first slot starts (ISO), e.g. {{ prices.bars.start }}. |
step | Minutes per slot: 60, or 15.Default 60. |
slots | How many slots to make room for; past the values they wait for their prices (tomorrow’s 24 before they are out). |
pending | Said over the slots still waiting, e.g. {{ prices.bars.pending }}. |
now | The moment now (ISO); its slot is marked, the ones before dimmed. Defaults to the clock. |
from | Show from this moment (ISO) on, e.g. {{ prices.now.start }}, instead of from start. |
span | Hours to show from from; all by default. |
highlight-from | Start of a band behind the bars (ISO), e.g. the cheapest hours. |
highlight-to | End of the band (ISO). |
highlight-label | Said on the band, e.g. “Cheapest 3 h”. |
mark-from | Start of a bracket under the bars (ISO), e.g. when the car charged. |
mark-to | End of the bracket (ISO). |
mark-label | Said by the bracket, e.g. “Charged”. |
currency | Symbol for the prices read out, e.g. €.Default €. |
time-zone | The clock the hours are told by, e.g. {{ prices.timeZone }}; the screen’s by default. |
compact | No hour labels or read-out: bars only, for small spaces.Default false. |
<hd-price-bars values="{{ prices.bars.values }}" levels="{{ prices.bars.levels }}" start="{{ prices.bars.start }}" step="{{ prices.bars.step }}" now="{{ prices.now.start }}" slots="{{ prices.bars.slots }}" pending="{{ prices.bars.pending }}"></hd-price-bars>