diff --git a/internal/frontend/bridge-gui/bridge-gui/qml/Banner.qml b/internal/frontend/bridge-gui/bridge-gui/qml/Banner.qml index 47a80893..aea135f8 100644 --- a/internal/frontend/bridge-gui/bridge-gui/qml/Banner.qml +++ b/internal/frontend/bridge-gui/bridge-gui/qml/Banner.qml @@ -84,6 +84,7 @@ Popup { anchors.topMargin: 14 spacing: 8 + ColorImage { Layout.preferredHeight: 24 Layout.preferredWidth: 24 @@ -108,14 +109,35 @@ Popup { sourceSize.width: 24 width: 24 } - Label { - Layout.alignment: Qt.AlignVCenter + ColumnLayout { + Layout.alignment: Qt.AlignTop Layout.fillWidth: true Layout.leftMargin: 16 - color: root.colorScheme.text_invert - colorScheme: root.colorScheme - text: root.notification ? root.notification.description : "" - wrapMode: Text.WordWrap + Label { + id: messageLabel + Layout.alignment: Qt.AlignTop + Layout.fillWidth: true + color: root.colorScheme.text_invert + colorScheme: root.colorScheme + text: root.notification ? root.notification.description : "" + wrapMode: Text.WordWrap + } + LinkLabel { + Layout.alignment: Qt.AlignTop | Qt.AlignLeft + Layout.fillWidth: true + colorScheme: root.colorScheme + color: messageLabel.color + external: true + link: root.notification ? root.notification.linkUrl : "" + text: root.notification ? root.notification.linkText : "" + visible: root.notification && root.notification.linkUrl.length > 0 + } + // Label { + // color: root.colorScheme.text_invert + // colorScheme: root.colorScheme + // text: "Youpi!" + // wrapMode: Text.WordWrap + // } } } } diff --git a/internal/frontend/bridge-gui/bridge-gui/qml/Notifications/Notifications.qml b/internal/frontend/bridge-gui/bridge-gui/qml/Notifications/Notifications.qml index 785b4120..a6361450 100644 --- a/internal/frontend/bridge-gui/bridge-gui/qml/Notifications/Notifications.qml +++ b/internal/frontend/bridge-gui/bridge-gui/qml/Notifications/Notifications.qml @@ -716,7 +716,8 @@ QtObject { group: Notifications.Group.Connection icon: "./icons/ic-no-connection.svg" type: Notification.NotificationType.Danger - + linkUrl: "https://proton.me/support/bridge" + linkText: qsTr("What happens with my messages when internet is down?") Connections { function onInternetOff() { root.noInternet.active = true; diff --git a/internal/frontend/bridge-gui/bridge-gui/qml/Proton/LinkLabel.qml b/internal/frontend/bridge-gui/bridge-gui/qml/Proton/LinkLabel.qml index 49db82ed..a1a6f8ee 100644 --- a/internal/frontend/bridge-gui/bridge-gui/qml/Proton/LinkLabel.qml +++ b/internal/frontend/bridge-gui/bridge-gui/qml/Proton/LinkLabel.qml @@ -22,6 +22,7 @@ RowLayout { property bool external: false property string link: "#" property string text: "" + property color color: colorScheme.interaction_norm function clear() { root.callback = null; @@ -49,9 +50,9 @@ RowLayout { id: label Layout.alignment: Qt.AlignVCenter colorScheme: root.colorScheme + linkColor: root.color text: label.link(root.link, root.text) type: Label.LabelType.Body - onLinkActivated: function (link) { if ((link !== "#") && (link.length > 0)) { Qt.openUrlExternally(link);