lista: ListItemLayout (titolo+paese+range senza sovrapposizioni); card porto vicino: binding con guardia, click centralizzato openPort, log
This commit is contained in:
+8
-26
@@ -83,32 +83,14 @@ Page {
|
||||
contentHeight: Theme.itemSizeMedium
|
||||
highlighted: model.isPreferred
|
||||
|
||||
Label {
|
||||
text: model.name
|
||||
color: model.isPreferred ? Theme.highlightColor : Theme.primaryColor
|
||||
font.pixelSize: Theme.fontSizeMedium
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: Theme.horizontalPageMargin
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
truncationMode: TruncationMode.Fade
|
||||
width: parent.width - 3 * Theme.horizontalPageMargin
|
||||
}
|
||||
Label {
|
||||
text: model.country
|
||||
color: Theme.secondaryColor
|
||||
font.pixelSize: Theme.fontSizeSmall
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: Theme.horizontalPageMargin
|
||||
anchors.top: parent.top
|
||||
anchors.topMargin: Theme.paddingSmall
|
||||
}
|
||||
Label {
|
||||
text: model.range
|
||||
color: Theme.secondaryColor
|
||||
font.pixelSize: Theme.fontSizeSmall
|
||||
anchors.right: parent.right
|
||||
anchors.rightMargin: Theme.horizontalPageMargin
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
ListItemLayout {
|
||||
title.text: model.name
|
||||
title.color: model.isPreferred ? Theme.highlightColor : Theme.primaryColor
|
||||
title.truncationMode: TruncationMode.Fade
|
||||
subtitle.text: model.country
|
||||
subtitle.color: Theme.secondaryColor
|
||||
summary.text: model.range
|
||||
summary.color: Theme.secondaryColor
|
||||
}
|
||||
onClicked: {
|
||||
console.log("[tide] open port:", model.name, "custom:", model.custom)
|
||||
|
||||
Reference in New Issue
Block a user