Merge branch 'impl/card-layouts-and-imagery' — v0.2.0: layouts, fallback art, +16 keg images
@@ -8,8 +8,9 @@ Designed and optimised for the Sonoff NSPanel Pro 120 in landscape mode, but wor
|
||||
|
||||
## Features
|
||||
|
||||
- **Beer emoji pictogram** — see how many glasses remain in your keg at a glance
|
||||
- **Built-in beer catalog** — 45+ PerfectDraft beers with brand color palettes
|
||||
- **Five layouts** — landscape, portrait, compact, hero, or single-vessel gauge; choose what fits your dashboard (defaults to landscape, so existing cards are unchanged)
|
||||
- **Beer emoji pictogram** — see how many glasses remain in your keg at a glance, in a grid that shrinks to fit narrow cards
|
||||
- **Built-in beer catalog** — 75+ PerfectDraft beers, 68 with real keg photos; brand-tinted fallback art for the rest so every beer looks intentional
|
||||
- **Glass size selector** — tap the emoji zone to choose between 250 mL, 330 mL, 500 mL, UK pint, or US pint
|
||||
- **Beer selector** — tap the label zone to pick your current beer from the catalog
|
||||
- **Freshness warnings** — escalating CSS-animated alerts as your keg approaches its 30-day expiry
|
||||
@@ -53,6 +54,9 @@ type: custom:perfectdraft-card
|
||||
device_id: "perfectdraft_pro"
|
||||
beer_name: "Leffe Blonde"
|
||||
glass_size: 330
|
||||
layout: landscape # landscape | portrait | compact | hero | vessel
|
||||
# matrix_columns: auto # "auto" or a fixed number of emoji columns
|
||||
# max_matrix_width: "480px" # cap + centre the emoji grid on wide cards
|
||||
# beer_entity: sensor.perfectdraft_pro_keg_name # future: auto beer detection
|
||||
# custom_beers:
|
||||
# - name: "My Homebrew IPA"
|
||||
@@ -71,6 +75,20 @@ glass_size: 330
|
||||
|
||||
Selections persist in your browser across page refreshes.
|
||||
|
||||
## Layouts
|
||||
|
||||
Set `layout` (or pick it in the visual editor) to match where the card lives:
|
||||
|
||||
| Layout | Best for |
|
||||
|--------|----------|
|
||||
| `landscape` (default) | Wall panels (NSPanel Pro), wide cards — label left, emoji grid right |
|
||||
| `portrait` | Phones and tall/narrow columns — label on top, grid below |
|
||||
| `compact` | Dense dashboards — a single row with a remaining-beer bar |
|
||||
| `hero` | Showing off the beer — full-bleed keg photo with status overlaid |
|
||||
| `vessel` | A calm single glass that fills to show how much is left |
|
||||
|
||||
The emoji grid is width-tolerant: it shrinks to fit narrow cards instead of overflowing. Power users can force a column count with `matrix_columns` or cap/centre the grid with `max_matrix_width`.
|
||||
|
||||
## Supported glass sizes
|
||||
|
||||
| Size | Description |
|
||||
|
||||
|
Before Width: | Height: | Size: 271 KiB |
|
After Width: | Height: | Size: 46 KiB |
|
Before Width: | Height: | Size: 224 KiB |
|
After Width: | Height: | Size: 35 KiB |
|
Before Width: | Height: | Size: 226 KiB |
|
After Width: | Height: | Size: 35 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 27 KiB |
|
Before Width: | Height: | Size: 253 KiB |
|
After Width: | Height: | Size: 39 KiB |
|
Before Width: | Height: | Size: 66 KiB |
|
After Width: | Height: | Size: 20 KiB |
|
Before Width: | Height: | Size: 194 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
Before Width: | Height: | Size: 652 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
Before Width: | Height: | Size: 61 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 35 KiB |
|
Before Width: | Height: | Size: 235 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
Before Width: | Height: | Size: 128 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
Before Width: | Height: | Size: 515 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 29 KiB |
|
Before Width: | Height: | Size: 241 KiB |
|
After Width: | Height: | Size: 34 KiB |
|
Before Width: | Height: | Size: 303 KiB |
|
After Width: | Height: | Size: 33 KiB |
|
Before Width: | Height: | Size: 910 KiB |
|
After Width: | Height: | Size: 32 KiB |
|
Before Width: | Height: | Size: 205 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
Before Width: | Height: | Size: 174 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
Before Width: | Height: | Size: 262 KiB |
|
After Width: | Height: | Size: 32 KiB |
|
Before Width: | Height: | Size: 268 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
Before Width: | Height: | Size: 213 KiB |
|
After Width: | Height: | Size: 28 KiB |
|
After Width: | Height: | Size: 29 KiB |
|
Before Width: | Height: | Size: 236 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
Before Width: | Height: | Size: 224 KiB |
|
After Width: | Height: | Size: 33 KiB |
|
Before Width: | Height: | Size: 212 KiB |
|
After Width: | Height: | Size: 34 KiB |
|
Before Width: | Height: | Size: 196 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
Before Width: | Height: | Size: 178 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
Before Width: | Height: | Size: 198 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
After Width: | Height: | Size: 27 KiB |
|
Before Width: | Height: | Size: 209 KiB |
|
After Width: | Height: | Size: 28 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
Before Width: | Height: | Size: 189 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
Before Width: | Height: | Size: 231 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
Before Width: | Height: | Size: 214 KiB |
|
After Width: | Height: | Size: 28 KiB |
|
Before Width: | Height: | Size: 207 KiB |
|
After Width: | Height: | Size: 34 KiB |
|
Before Width: | Height: | Size: 156 KiB |
|
After Width: | Height: | Size: 33 KiB |
|
Before Width: | Height: | Size: 153 KiB |
|
After Width: | Height: | Size: 27 KiB |
|
Before Width: | Height: | Size: 164 KiB |
|
After Width: | Height: | Size: 27 KiB |
|
Before Width: | Height: | Size: 218 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
Before Width: | Height: | Size: 199 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
Before Width: | Height: | Size: 816 KiB |
|
After Width: | Height: | Size: 27 KiB |
|
Before Width: | Height: | Size: 70 KiB |
|
After Width: | Height: | Size: 29 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
Before Width: | Height: | Size: 204 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 28 KiB |
|
Before Width: | Height: | Size: 288 KiB |
|
After Width: | Height: | Size: 42 KiB |
|
Before Width: | Height: | Size: 56 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
Before Width: | Height: | Size: 199 KiB |
|
After Width: | Height: | Size: 32 KiB |
|
Before Width: | Height: | Size: 72 KiB |
|
After Width: | Height: | Size: 17 KiB |
|
Before Width: | Height: | Size: 285 KiB |
|
After Width: | Height: | Size: 46 KiB |
|
Before Width: | Height: | Size: 185 KiB |