From 2d0aaaa974bcc16239a163a88578c8805ed3a95d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Cie=C5=9Blak?= Date: Mon, 3 Jul 2023 16:56:25 +0200 Subject: [PATCH] fix(CommunityTokenView): Hide holdings list when token not deployed Closes: #11386 --- .../Communities/views/CommunityTokenView.qml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/ui/app/AppLayouts/Communities/views/CommunityTokenView.qml b/ui/app/AppLayouts/Communities/views/CommunityTokenView.qml index 420bfecfeb..9410642e9a 100644 --- a/ui/app/AppLayouts/Communities/views/CommunityTokenView.qml +++ b/ui/app/AppLayouts/Communities/views/CommunityTokenView.qml @@ -21,7 +21,7 @@ StatusScrollView { property bool preview: false // https://bugreports.qt.io/browse/QTBUG-84269 - /* readonly */ property TokenObject token + /* required */ property TokenObject token readonly property bool isAssetView: token.type === Constants.TokenType.ERC20 @@ -44,6 +44,9 @@ StatusScrollView { readonly property string chainIcon: token.chainIcon readonly property int decimals: token.decimals + readonly property bool deploymentCompleted: + deployState === Constants.ContractTransactionStatus.Completed + // Models: property var tokenOwnersModel @@ -83,8 +86,7 @@ StatusScrollView { spacing: Style.current.padding RowLayout { - visible: !root.preview && ((root.deployState === Constants.ContractTransactionStatus.InProgress) || - (root.deployState === Constants.ContractTransactionStatus.Failed)) + visible: !root.preview && !root.deploymentCompleted spacing: Style.current.halfPadding StatusDotsLoadingIndicator { visible: (root.deployState === Constants.ContractTransactionStatus.InProgress) } @@ -338,7 +340,7 @@ StatusScrollView { } SortableTokenHoldersPanel { - visible: !root.preview + visible: !root.preview && root.deploymentCompleted model: root.tokenOwnersModel tokenName: root.name