Settings page was added

This commit is contained in:
2023-03-30 20:06:03 +02:00
parent 31cb989f67
commit 25e8a3ea79
16 changed files with 272 additions and 55 deletions

View File

@@ -5,6 +5,7 @@ Drawer {
property alias logo: logoImage.source
property alias appName: appNameLabel.text
property alias model: menuRepeater.model
property alias connected: connectionLabel.connected
signal actionSelected(var action)
@@ -26,12 +27,23 @@ Drawer {
anchors.margins: 10
}
Label {
id: appNameLabel
Column {
anchors.verticalCenter: parent.verticalCenter
font.pointSize: 20
text: qsTr("BeerLog v0.1")
Label {
id: appNameLabel
font.pointSize: 20
}
Label {
id: connectionLabel
property bool connected: false
text: connected ? qsTr("Online") : qsTr("Offline")
color: connected ? "green" : "red"
}
}
}

View File

@@ -0,0 +1,24 @@
import QtQuick 2.0
import QtQuick.Controls 2.2
ItemDelegate {
id: root
property string subtitle: ""
contentItem: Column {
Label {
id: titleLabel
width: parent.width
text: root.text
}
Label {
width: parent.width
font.pixelSize: titleLabel.font.pixelSize - 2
text: root.subtitle
opacity: 0.8
}
}
}

5
qml/Components/qmldir Normal file
View File

@@ -0,0 +1,5 @@
module Components
MainMenu 1.0 MainMenu.qml
MenuBackButton 1.0 MenuBackButton.qml
SubtitledItemDelegate 1.0 SubtitledItemDelegate.qml