fix[Onboarding] Password screen is not correct

- hide the "Current password" label when creating a new password
- fix margins inside the keycard popup
- some minor UI fixups according to Figma

Fixes: #14214
Fixes: #14177
This commit is contained in:
Lukáš Tinkl 2024-03-29 14:21:21 +01:00 committed by Lukáš Tinkl
parent 839f2c6b21
commit 5af2f28aa2
3 changed files with 7 additions and 7 deletions

View File

@ -165,7 +165,6 @@ StatusDialog {
StatusFlatButton {
text: qsTr("Cancel")
visible: !d.dbEncryptionInProgress && !d.passwordChanged
textColor: Style.current.darkGrey
onClicked: { root.close(); }
}
}
@ -173,7 +172,7 @@ StatusDialog {
StatusButton {
id: submitBtn
objectName: "changePasswordModalSubmitButton"
text: !d.dbEncryptionInProgress && !d.passwordChanged ? qsTr("Re-encrypt data using new password") : qsTr("Restart status")
text: !d.dbEncryptionInProgress && !d.passwordChanged ? qsTr("Re-encrypt data using new password") : qsTr("Restart Status")
enabled: !d.dbEncryptionInProgress
onClicked: {
if (d.passwordChanged) {

View File

@ -17,12 +17,13 @@ Item {
anchors.fill: parent
anchors.topMargin: Style.current.xlPadding
anchors.bottomMargin: Style.current.halfPadding
anchors.leftMargin: 2*(Style.current.xlPadding + Style.current.bigPadding)
anchors.rightMargin: 2*(Style.current.xlPadding + Style.current.bigPadding)
anchors.leftMargin: Style.current.xlPadding
anchors.rightMargin: Style.current.xlPadding
spacing: Style.current.padding
PasswordView {
Layout.minimumWidth: 460
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
Layout.fillHeight: true
passwordStrengthScoreFunction: RootStore.getPasswordStrengthScore

View File

@ -193,6 +193,8 @@ ColumnLayout {
}
ColumnLayout {
visible: !root.createNewPsw
StatusBaseText {
text: qsTr("Current password")
}
@ -204,7 +206,6 @@ ColumnLayout {
property bool showPassword
z: root.zFront
visible: !root.createNewPsw
Layout.fillWidth: true
Layout.alignment: root.contentAlignment
placeholderText: qsTr("Enter current password")
@ -229,12 +230,12 @@ ColumnLayout {
}
StatusModalDivider {
visible: !root.createNewPsw
Layout.fillWidth: true
Layout.alignment: root.contentAlignment
}
ColumnLayout {
spacing: 4
z: root.zFront
Layout.fillWidth: true
Layout.alignment: root.contentAlignment
@ -370,7 +371,6 @@ ColumnLayout {
ColumnLayout {
StatusBaseText {
text: qsTr("Confirm new password")
color: Theme.palette.baseColor1
}
StatusPasswordInput {