41 lines
1.0 KiB
QML
41 lines
1.0 KiB
QML
import QtQuick
|
|
import "."
|
|
|
|
// Row of "[KEY] label" keyboard hints shown under launcher-style overlays,
|
|
// e.g. [ [↑↓, "Navigate"], ["↵", "Launch"], ["Esc", "Close"] ].
|
|
Row {
|
|
id: hintBar
|
|
|
|
property var hints: []
|
|
|
|
spacing: Theme.geometry.spacing * 2
|
|
|
|
Repeater {
|
|
model: hintBar.hints
|
|
|
|
delegate: Row {
|
|
spacing: Theme.geometry.spacing / 2
|
|
|
|
Pill {
|
|
tint: Theme.colors.outlineVariant
|
|
|
|
Text {
|
|
text: "[" + modelData.key + "]"
|
|
color: Theme.colors.text
|
|
font.family: Theme.font.family
|
|
font.bold: true
|
|
font.pixelSize: Theme.type.caption
|
|
}
|
|
}
|
|
|
|
Text {
|
|
text: modelData.label
|
|
color: Theme.colors.textMuted
|
|
font.family: Theme.font.family
|
|
font.pixelSize: Theme.type.caption
|
|
anchors.verticalCenter: parent.verticalCenter
|
|
}
|
|
}
|
|
}
|
|
}
|