From 89aea77213daa23acc40dc77a049f38871b1b7f2 Mon Sep 17 00:00:00 2001 From: Sander van Grieken Date: Tue, 3 Jan 2023 18:22:29 +0100 Subject: [PATCH] qml: add placeholder text for transaction history and channel list --- electrum/gui/qml/components/Channels.qml | 11 +++++++++++ electrum/gui/qml/components/History.qml | 10 ++++++++++ 2 files changed, 21 insertions(+) diff --git a/electrum/gui/qml/components/Channels.qml b/electrum/gui/qml/components/Channels.qml index 4e0bb056b..36f3c742e 100644 --- a/electrum/gui/qml/components/Channels.qml +++ b/electrum/gui/qml/components/Channels.qml @@ -121,6 +121,17 @@ Pane { } ScrollIndicator.vertical: ScrollIndicator { } + + Label { + visible: Daemon.currentWallet.channelModel.rowCount() == 0 + anchors.centerIn: parent + width: listview.width * 4/5 + font.pixelSize: constants.fontSizeXXLarge + color: constants.mutedForeground + text: qsTr('You have no Lightning channels yet in this wallet') + wrapMode: Text.Wrap + horizontalAlignment: Text.AlignHCenter + } } } } diff --git a/electrum/gui/qml/components/History.qml b/electrum/gui/qml/components/History.qml index d46353326..23b5a7fb2 100644 --- a/electrum/gui/qml/components/History.qml +++ b/electrum/gui/qml/components/History.qml @@ -82,6 +82,16 @@ Pane { ScrollIndicator.vertical: ScrollIndicator { } + Label { + visible: Daemon.currentWallet.historyModel.rowCount() == 0 + anchors.centerIn: parent + width: listview.width * 4/5 + font.pixelSize: constants.fontSizeXXLarge + color: constants.mutedForeground + text: qsTr('No transactions yet in this wallet') + wrapMode: Text.Wrap + horizontalAlignment: Text.AlignHCenter + } } MouseArea {