mirror of
https://github.com/Matysh/houseplan-card
synced 2026-10-07 15:09:30 +00:00
feat: make Glow follow door opening state (#20)
Issue: #20 User-Visible: yes
This commit is contained in:
+5
-3
@@ -508,9 +508,11 @@ export function renderSpaceStatic(o: StaticRenderOpts): TemplateResult | null {
|
||||
const wallStroke = disp.color || '#607d8b';
|
||||
const hostedOpeningSymbols = disp.hideOpenings ? [] : resolvedHosted.map((resolved) => {
|
||||
const opening = resolved.opening;
|
||||
const state = opening.type === 'passage' || !opening.contact
|
||||
? null : planHass.states?.[opening.contact]?.state;
|
||||
const amount = openingAmount(opening.type, state, !!opening.invert);
|
||||
const entity = opening.type === 'passage' || !opening.contact
|
||||
? null : planHass.states?.[opening.contact];
|
||||
const amount = openingAmount(
|
||||
opening.type, entity?.state, !!opening.invert, entity?.attributes?.current_position,
|
||||
);
|
||||
const active = amount > 0 && !!opening.contact;
|
||||
const faceFlipV = opening.type === 'gate' ? !opening.flip_v : !!opening.flip_v;
|
||||
const spec: OpeningVisibleSpec = {
|
||||
|
||||
Reference in New Issue
Block a user