feat: add portrait line art to flash screen

This commit is contained in:
2026-11-13 00:39:44 +01:00
parent c28428a2f3
commit fb5ce525bb
3 changed files with 57 additions and 1 deletions

View File

@@ -142,6 +142,35 @@ export component AppWindow inherits Window {
active: root.hand-detected;
}
}
if root.flash-opacity > 0: Rectangle {
// Keep the portrait below the central countdown and most of the
// monitor white so it continues to provide light for the photo.
width: min(360px * root.ui-scale, root.width * 0.65, root.height * 0.36);
height: self.width * 200 / 360 + 40px * root.ui-scale;
x: (root.width - self.width) / 2;
y: root.height - self.height - root.inset - root.safe-area-insets.bottom;
background: transparent;
pose-label := Text {
x: 0px;
y: 0px;
width: parent.width;
height: 32px * root.ui-scale;
text: "Pose!";
color: #20302b77;
font-size: 26px * root.ui-scale;
font-weight: 600;
horizontal-alignment: center;
vertical-alignment: center;
}
Image {
x: 0px;
y: pose-label.y + pose-label.height + 8px * root.ui-scale;
width: parent.width;
height: parent.height - self.y;
source: @image-url("assets/photo-pose.svg");
image-fit: contain;
}
}
if root.countdown > 0: Text {
width: root.width;
height: root.height;