All of the above? 
I know Iām asking something very much for my specific situation, but for my specific use case it would be a dashboard strategy that that encompasses sub-views. For me, I would define one or two variables and an entity or auto-entity glob and everything can be fully calculated from that.
The foundry that Iāve created and am using on 9 (yes 9!) different HA systems is publicly available here: homeassistant-blueprints/uix-forge at main Ā· tykeal/homeassistant-blueprints Ā· GitHub
There are effectively two uses of it:
- A main dashboard auto-entities card (see
Figure 1) that is a general overall collapsed view and that has a click action to go to a sub-view where I then have
- All of the below defined in the view (see
Figure 2)
- A series of badges
- Two uses of the
current_guest forge.
- An Atomic Calendar Revive card that consumes a calendar that can be calculated off of the same entity that would be driving all of this view
All of those forges and other cards in the sub-view could be calculated based on a single entity coming into the sub-view. I already do a lot of that sort of calculation in the current_guest forge card that I built. Itās a vertical stack composite of heading, mushroom-template-cards, and entities cards. so you can perhaps have an idea of what Iām shooting for here.
Hereās what the main dashboard (auto-guest_card forge) card looks like rendered in an HA with multiple rental listings
It was defined like this:
type: custom:uix-forge
foundry: auto-guest_card
entity: sensor.r*_check_in
Hereās what a rendered sub-view looks like. Everything on that page could easily have been calculated from the sub-view path which came from the auto-guest_card on the main dashboard
. The Current and upcoming sections are the
current_guest forge that I only had to stick on variable into.
They were both defined as:
type: custom:uix-forge
foundry: current_guest
entity: sensor.rental_control_r22_event_0
forge:
billets:
doors:
- frontdoor
- r22
and
type: custom:uix-forge
foundry: current_guest
entity: sensor.rental_control_r22_event_1
forge:
billets:
doors:
- frontdoor
- r22
Some of the other HA systems I manage the doors billets are a lot larger with some exception cases (like a particular unit having an extra door that the others donāt have) or some where there is just a single front door and no other doors.
But in general if I could just do the following on a dashboard definition Iām pretty certain I could come up with a way to calculate everything else (hopefully)
strategy: custom:uix-forge
entity: sensor.suite*check_in
forge:
billets:
common_doors:
- main_door
- rear_door
private_door_pattern:
- s[[:digit:]]_*
Assuming I can use macros in billets I should be able to permute what I already have to work with a union of the common_doors billet and then something that takes the private_door_pattern and generates the finalized billet that would be consumed by the current_guest forge, or I rework that to be smarter in some way
Admittedly the pattern thing is very aspirational, as I just added more regex to what Iām doing
