GODT-1851: Port field error label now wraps.

This commit is contained in:
Xavier Michelon
2022-09-26 15:26:59 +02:00
parent 653727fd12
commit 86443252b1
2 changed files with 6 additions and 3 deletions

View File

@ -56,6 +56,7 @@ SettingsView {
colorScheme: root.colorScheme
label: qsTr("IMAP port")
Layout.preferredWidth: 160
Layout.alignment: Qt.AlignTop | Qt.AlignLeft
validator: root.validate
}
TextField {
@ -63,6 +64,7 @@ SettingsView {
colorScheme: root.colorScheme
label: qsTr("SMTP port")
Layout.preferredWidth: 160
Layout.alignment: Qt.AlignTop | Qt.AlignLeft
validator: root.validate
}
}
@ -86,7 +88,7 @@ SettingsView {
imapField.error = false
smtpField.error = false
// checking errors seperatly because we want to display "same port" error only once
// checking errors separately because we want to display "same port" error only once
imapField.validate()
if (imapField.error) {
return

View File

@ -320,8 +320,8 @@ FocusScope {
visible: root.error && (assistiveText.text.length > 0)
source: "../icons/ic-exclamation-circle-filled.svg"
color: root.colorScheme.signal_danger
height: assistiveText.height
sourceSize.height: assistiveText.height
height: assistiveText.lineHeight
sourceSize.height: assistiveText.lineHeight
}
Proton.Label {
@ -330,6 +330,7 @@ FocusScope {
Layout.fillHeight: true
Layout.fillWidth: true
wrapMode: Text.WordWrap
text: root.error ? root.errorString : root.assistiveText