fix(Communities/Settings): Cropped bottom panel in Community Overview
Footer buttons anchored to `leftPanel` bottom. Improved list view alignment. Fixes #7322
This commit is contained in:
parent
d45230a6f7
commit
751d61df8b
|
@ -57,69 +57,82 @@ StatusSectionLayout {
|
||||||
signal backToCommunityClicked
|
signal backToCommunityClicked
|
||||||
signal openLegacyPopupClicked // TODO: remove me when migration to new settings is done
|
signal openLegacyPopupClicked // TODO: remove me when migration to new settings is done
|
||||||
|
|
||||||
leftPanel: ColumnLayout {
|
leftPanel: Item {
|
||||||
anchors {
|
anchors.fill: parent
|
||||||
fill: parent
|
|
||||||
margins: 8
|
|
||||||
topMargin: 16
|
|
||||||
bottomMargin: 16
|
|
||||||
}
|
|
||||||
|
|
||||||
spacing: 16
|
ColumnLayout {
|
||||||
|
anchors {
|
||||||
|
top: parent.top
|
||||||
|
bottom: footer.top
|
||||||
|
topMargin: 16
|
||||||
|
bottomMargin: 16
|
||||||
|
horizontalCenter: parent.horizontalCenter
|
||||||
|
}
|
||||||
|
width: parent.width - 16
|
||||||
|
spacing: 16
|
||||||
|
clip: true
|
||||||
|
|
||||||
StatusNavigationPanelHeadline {
|
StatusNavigationPanelHeadline {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
text: qsTr("Settings")
|
text: qsTr("Settings")
|
||||||
}
|
}
|
||||||
|
|
||||||
StatusListView {
|
StatusListView {
|
||||||
id: listView
|
id: listView
|
||||||
|
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
implicitHeight: contentItem.childrenRect.height
|
Layout.fillHeight: true
|
||||||
|
model: root.settingsMenuModel
|
||||||
model: root.settingsMenuModel
|
delegate: StatusNavigationListItem {
|
||||||
delegate: StatusNavigationListItem {
|
width: listView.width
|
||||||
width: listView.width
|
title: modelData.name
|
||||||
title: modelData.name
|
asset.name: modelData.icon
|
||||||
asset.name: modelData.icon
|
selected: d.currentIndex === index
|
||||||
selected: d.currentIndex === index
|
onClicked: d.currentIndex = index
|
||||||
onClicked: d.currentIndex = index
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Item {
|
// TODO: remove me when migration to new settings is done. Only keep back button and anchor to it.
|
||||||
Layout.fillHeight: true
|
ColumnLayout {
|
||||||
}
|
id: footer
|
||||||
|
|
||||||
// TODO: remove me when migration to new settings is done
|
anchors {
|
||||||
StatusBaseText {
|
bottom: parent.bottom
|
||||||
Layout.alignment: Qt.AlignHCenter
|
bottomMargin: 16
|
||||||
text: qsTr("Open legacy popup (to be removed)")
|
|
||||||
color: Theme.palette.baseColor1
|
|
||||||
font.pixelSize: 10
|
|
||||||
font.underline: true
|
|
||||||
|
|
||||||
MouseArea {
|
|
||||||
anchors.fill: parent
|
|
||||||
cursorShape: Qt.PointingHandCursor
|
|
||||||
onClicked: root.openLegacyPopupClicked()
|
|
||||||
}
|
}
|
||||||
}
|
width: parent.width
|
||||||
|
spacing: 16
|
||||||
|
|
||||||
StatusBaseText {
|
// TODO: remove me when migration to new settings is done
|
||||||
objectName: "communitySettingsBackToCommunityButton"
|
StatusBaseText {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
text: "<- " + qsTr("Back to community")
|
text: qsTr("Open legacy popup (to be removed)")
|
||||||
color: Theme.palette.baseColor1
|
color: Theme.palette.baseColor1
|
||||||
font.pixelSize: 15
|
font.pixelSize: 10
|
||||||
font.underline: true
|
font.underline: true
|
||||||
|
|
||||||
MouseArea {
|
MouseArea {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
cursorShape: Qt.PointingHandCursor
|
cursorShape: Qt.PointingHandCursor
|
||||||
onClicked: root.backToCommunityClicked()
|
onClicked: root.openLegacyPopupClicked()
|
||||||
hoverEnabled: true
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
StatusBaseText {
|
||||||
|
objectName: "communitySettingsBackToCommunityButton"
|
||||||
|
Layout.alignment: Qt.AlignHCenter
|
||||||
|
text: "<- " + qsTr("Back to community")
|
||||||
|
color: Theme.palette.baseColor1
|
||||||
|
font.pixelSize: 15
|
||||||
|
font.underline: true
|
||||||
|
|
||||||
|
MouseArea {
|
||||||
|
anchors.fill: parent
|
||||||
|
cursorShape: Qt.PointingHandCursor
|
||||||
|
onClicked: root.backToCommunityClicked()
|
||||||
|
hoverEnabled: true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue