41 lines
876 B
QML
41 lines
876 B
QML
import QtQuick
|
|
import QtQuick.Controls
|
|
import QtQuick.Layouts
|
|
|
|
RowLayout {
|
|
id: root
|
|
|
|
property var theme
|
|
property string label: ""
|
|
property string description: ""
|
|
default property alias controlData: controls.data
|
|
|
|
Layout.fillWidth: true
|
|
spacing: 10
|
|
|
|
ColumnLayout {
|
|
Layout.fillWidth: true
|
|
spacing: 1
|
|
|
|
Label {
|
|
text: root.label
|
|
color: root.theme ? root.theme.text : "#cdd6f4"
|
|
Layout.fillWidth: true
|
|
elide: Text.ElideRight
|
|
}
|
|
Label {
|
|
visible: root.description.length > 0
|
|
text: root.description
|
|
color: root.theme ? root.theme.mutedText : "#9399b2"
|
|
font.pixelSize: 10
|
|
Layout.fillWidth: true
|
|
wrapMode: Text.Wrap
|
|
}
|
|
}
|
|
|
|
RowLayout {
|
|
id: controls
|
|
spacing: 6
|
|
}
|
|
}
|