Commit 1199fb89 authored by Dan Leinir Turthra Jensen's avatar Dan Leinir Turthra Jensen 🌈
Browse files

Make the "no accounts yet" indicator more pleasant and functional

parent f3ab5eee
......@@ -76,19 +76,26 @@ ScrollViewKCM {
]
onClicked: kcm.push("AvailableServices.qml", {model: model.services})
}
Controls.Label {
anchors {
fill: parent
margins: Kirigami.Units.largeSpacing
Kirigami.AbstractCard {
visible: view.count === 0
anchors.centerIn: parent
width: kaccountsRoot.width * 2/ 3
height: kaccountsRoot.height * 2 / 3
header: Kirigami.Heading {
Layout.fillWidth: true;
text: i18n("No accounts yet")
}
contentItem: Controls.Label {
clip: true
horizontalAlignment: Text.AlignHCenter
wrapMode: Text.Wrap
textFormat: Text.RichText
text: i18nc("A text shown when a user has not yet added any accounts", "You have not added any accounts yet.<br /><br />Click on <a href=\"add-new-account\">\"Add New Account\"</a> to do so.")
onLinkActivated: kcm.push("AvailableAccounts.qml")
}
verticalAlignment: Text.AlignVCenter
horizontalAlignment: Text.AlignHCenter
wrapMode: Text.Wrap
visible: parent.count === 0
opacity: 0.5
text: i18nc("A text shown when a user has not yet added any accounts", "You have not added any accounts yet.\nClick the \"Add new Account\" button below to do so.")
}
}
MessageBoxSheet {
id: accountRemovalDlg
parent: kaccountsRoot
......@@ -115,6 +122,7 @@ ScrollViewKCM {
}
]
}
Component {
id: accountRemovalJob
KAccounts.RemoveAccount { }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment