Skip to content

v2.4.0

Choose a tag to compare

@laurence-syree laurence-syree released this 07 May 22:52

What changed

Layout overhaul (#6)

  • Gauges now fill the tile they're given, at any card size or aspect ratio. The hard-coded 200 px cap is gone — wide cards no longer leave gauges stranded in empty space.
  • Header and footer heights are now measured from the rendered DOM instead of guessed, so layout stays correct when the title wraps, themes change typography, or rows toggle on/off.
  • New "encroach" mode: on wide cards where the header text only occupies the corners, gauges automatically extend up into the header's vertical band via CSS Grid.
  • ResizeObserver callbacks are batched via requestAnimationFrame, eliminating the "ResizeObserver loop" warning during editor drag-resize.

Modern HA integration

  • getCardSize and instance getGridOptions updated to current HA best practice. min_columns / min_rows are derived from the configured chrome so resize handles snap to a size the card can actually render; no upper cap so HA's layout decides the maximum.

Robustness

  • Config validation at setConfig time with user-readable error messages — out-of-range numbers, inverted SOC thresholds, malformed colour tuples and bad entity IDs are now caught and surfaced as red banners in the visual editor instead of silently breaking.
  • Defensive guards in connectedCallback and a ResizeObserver feature check, so older WebViews (e.g. some Amazon Fire HD builds) render at static defaults rather than failing with a generic "Configuration error". May help #7.

Thanks to @jojkopeter for reporting #6 and @bouyssic for the follow-up testing.

Full changelog: CHANGELOG.md