Home is now Overview | My Home | Phone. Overview leads with quick-action tiles (focus, Do Not Disturb, health, snapshots, storage), keeps the findings card — updates fold in, the reclaim-space prompt is gone on purpose — and adds glance cards, the next calendar event, and weather. My Home groups every light by Home Assistant area: the helper gained an `areas` command (one REST template render, no websocket), and the rooms degrade to a flat list on setups without areas. The favorites editor and connection card moved intact. Phone gains a vitals strip — battery and cell signal read from KDE Connect's plugin D-Bus objects, where absence is data, not an error — beside ring, clipboard, send-a-file, and the BlueBubbles handoff. The retired home-phone id resolves to my-home forever via a new alias map in SettingsRoutes (with a hasOwnProperty guard so prototype names cannot leak into settingsPage). Storage no longer claims 0 B free — the old page read a field the disks helper never emitted. Contracts updated alongside; per the new workflow, the full suite runs once at the end of the redesign (see the test backlog note). Claude-Session: https://claude.ai/code/session_01Ms2FbjQy31TVf3CEvQhGM8
84 lines
2.1 KiB
QML
84 lines
2.1 KiB
QML
// A quick action on the Home overview: one glyph, one name, one line of state,
|
|
// one tap. The fixed set lives in HomePage; this only draws and reports.
|
|
|
|
import QtQuick
|
|
import qs.config
|
|
|
|
Rectangle {
|
|
id: root
|
|
|
|
property string glyph
|
|
property color glyphColor: Theme.accent
|
|
property string label
|
|
property string caption
|
|
property bool interactive: true
|
|
|
|
signal activated()
|
|
|
|
radius: 14
|
|
color: tileArea.containsMouse && root.interactive
|
|
? Theme.alpha(Theme.fg, 0.09)
|
|
: Theme.alpha(Theme.fg, 0.05)
|
|
border.width: 1
|
|
border.color: Theme.alpha(Theme.fg, 0.07)
|
|
implicitHeight: body.implicitHeight + 24
|
|
|
|
Column {
|
|
id: body
|
|
|
|
anchors.left: parent.left
|
|
anchors.right: parent.right
|
|
anchors.top: parent.top
|
|
anchors.margins: 12
|
|
spacing: 7
|
|
|
|
Rectangle {
|
|
width: 30
|
|
height: 30
|
|
radius: 10
|
|
color: Theme.alpha(root.glyphColor, 0.13)
|
|
|
|
Text {
|
|
anchors.centerIn: parent
|
|
text: root.glyph
|
|
color: root.glyphColor
|
|
font.family: Theme.fontMono
|
|
font.pixelSize: 14
|
|
}
|
|
}
|
|
|
|
Text {
|
|
width: parent.width
|
|
text: root.label
|
|
color: Theme.fg
|
|
font.family: Theme.fontFamily
|
|
font.pixelSize: Theme.fontSize
|
|
font.weight: Font.DemiBold
|
|
elide: Text.ElideRight
|
|
}
|
|
|
|
Text {
|
|
width: parent.width
|
|
text: root.caption
|
|
color: Theme.fgDim
|
|
font.family: Theme.fontFamily
|
|
font.pixelSize: Theme.fontSizeSmall
|
|
wrapMode: Text.WordWrap
|
|
maximumLineCount: 2
|
|
elide: Text.ElideRight
|
|
}
|
|
}
|
|
|
|
MouseArea {
|
|
id: tileArea
|
|
anchors.fill: parent
|
|
hoverEnabled: true
|
|
cursorShape: root.interactive ? Qt.PointingHandCursor : Qt.ArrowCursor
|
|
onClicked: if (root.interactive) root.activated()
|
|
}
|
|
|
|
Accessible.role: Accessible.Button
|
|
Accessible.name: root.label
|
|
Accessible.description: root.caption
|
|
}
|