fix: show translucent countdown without a panel
This commit is contained in:
@@ -140,40 +140,15 @@ export component AppWindow inherits Window {
|
||||
active: root.hand-detected;
|
||||
}
|
||||
}
|
||||
if root.countdown > 0: Rectangle {
|
||||
x: (root.width - self.width) / 2;
|
||||
y: (root.height - self.height) / 2;
|
||||
width: min(420px * root.ui-scale, root.width - root.inset * 2);
|
||||
height: 340px * root.ui-scale;
|
||||
border-radius: 32px * root.ui-scale;
|
||||
background: #fffffff0;
|
||||
VerticalLayout {
|
||||
padding: 24px * root.ui-scale;
|
||||
spacing: 8px * root.ui-scale;
|
||||
Text {
|
||||
text: root.countdown;
|
||||
color: #20302b;
|
||||
font-size: 180px * root.ui-scale;
|
||||
font-weight: 700;
|
||||
horizontal-alignment: center;
|
||||
vertical-alignment: center;
|
||||
}
|
||||
Text {
|
||||
text: "Bitte in die Kamera schauen.";
|
||||
color: #20302b;
|
||||
font-size: 18px * root.ui-scale;
|
||||
font-weight: 600;
|
||||
horizontal-alignment: center;
|
||||
wrap: word-wrap;
|
||||
}
|
||||
Text {
|
||||
text: "Please look at the camera.";
|
||||
color: #52635d;
|
||||
font-size: 14px * root.ui-scale;
|
||||
horizontal-alignment: center;
|
||||
wrap: word-wrap;
|
||||
}
|
||||
}
|
||||
if root.countdown > 0: Text {
|
||||
width: root.width;
|
||||
height: root.height;
|
||||
text: root.countdown;
|
||||
color: #20302b77;
|
||||
font-size: min(240px * root.ui-scale, min(root.width * 0.6, root.height * 0.45));
|
||||
font-weight: 700;
|
||||
horizontal-alignment: center;
|
||||
vertical-alignment: center;
|
||||
}
|
||||
|
||||
if root.awaiting-release: Rectangle {
|
||||
|
||||
Reference in New Issue
Block a user