diff --git a/docs/design/web-ui-refresh/README.md b/docs/design/web-ui-refresh/README.md new file mode 100644 index 0000000..b27f4bc --- /dev/null +++ b/docs/design/web-ui-refresh/README.md @@ -0,0 +1,158 @@ +# Web UI visual refresh - three concepts + +Three self-contained prototypes of what a visual refresh to the cgateweb web UI +(`public/index.html`) could look like. Each is a static HTML file with fake data: +nothing is wired to the API, so they are safe to open anywhere. + +``` +docs/design/web-ui-refresh/ + variation-a-refined.html Same layout, new design tokens + variation-b-ha-native.html Looks like part of Home Assistant + variation-c-console.html Dense operator console +``` + +Open a file directly in a browser. Both variations accept two query parameters: +`?theme=dark` or `?theme=light` to force a palette, and `?tab=status|labels|events|import` +to land on a specific view. There is also a Theme button in each prototype. + +## What the refresh is trying to fix + + + +The current UI works, and none of this is about features. The observations that +drove all three concepts: + +- **Connection state reads as plain text.** On the Status tab, "connected", + "1.22.3" and "0" are all rendered at the same size and weight, so the eye has + nothing to lock onto. Whether the bridge is healthy should be answerable in a + glance, and today it takes a read. +- **Health is only visible on one tab.** You have to leave the device table to + find out that MQTT dropped. +- **The palette is generic.** The blue is Mantine's default rather than Home + Assistant's, so inside an ingress iframe the panel looks like a different + product bolted into HA. +- **The device table is styled loosely for its job.** Zebra striping plus row + hairlines plus a header underline is three separators doing one job, while the + addresses - the thing people actually scan - get no visual distinction from + labels. +- **Density is neither compact nor comfortable.** Rows are 6px-padded but the + type is 0.9rem, which gives a cramped-yet-tall row. A 418-group install shows + very few rows per screen. +- **Mobile degrades by hiding columns.** It works, but the Entity ID and Type + columns silently disappear, and the remaining table still needs sideways + scrolling on a phone. + +## Variation A - "Refined" + + + +Same layout, same DOM, new design tokens. Tabs become a segmented control, +cards get a larger radius and a real elevation token, the status tiles gain +coloured state dots so connection state is pre-attentive, addresses become +monospace chips, zebra striping is dropped in favour of hairlines plus a hover +tint, and badges become pills. Buttons get a visible hierarchy (filled primary, +outlined secondary, ghost tertiary) instead of three near-identical greys. + +**Cost:** the ` + +
+| + | Address ▲ | Label | Type | Entity ID | +Area | Excl | + | |
|---|---|---|---|---|---|---|---|---|
| + | 254/56/1 | +Kitchen Downlights | ++ | light.kitchen_downlights | +Kitchen | ++ | unsaved | ++ |
| + | 254/56/2 | +Kitchen Pendants | ++ | auto | +Kitchen | ++ | + | + |
| + | 254/56/4 | +Living Room Lamps | ++ | auto | +Living Room | ++ | + | + |
| + | 254/56/12 | +Hallway Sconces | ++ | auto | +Hall? | ++ | + | + |
| + | 254/203/1 | +Living Room Blinds | ++ | cover.living_blinds | +Living Room | ++ | + | + |
| + | 254/56/33 | +Garage Door Relay | ++ | auto | +Garage | ++ | + | + |
| + | 254/56/40 | +Alfresco Flood | ++ | auto | +Alfresco | ++ | + | + |
| + | 254/202/5 | +Scene: Movie Night | +trigger | +auto | +Living Room | ++ | + | + |
| Time | Address | Label | Level | Bar |
|---|---|---|---|---|
| 09:24:16 | 254/56/1 | Kitchen Downlights | 100% | |
| 09:24:11 | 254/56/4 | Living Room Lamps | 64% | |
| 09:23:58 | 254/203/1 | Living Room Blinds | 40% | |
| 09:23:41 | 254/56/12 | Hallway Sconces | 0% | |
| 09:23:02 | 254/56/33 | Garage Door Relay | 100% | |
| 09:22:47 | 254/56/2 | Kitchen Pendants | 25% |
or click to browse. Labels, areas and device types are read from the Toolkit project.
+ +