From 6ac3f86951f2d43f536266e7a606a7a511196214 Mon Sep 17 00:00:00 2001 From: Iuri Matias Date: Wed, 23 Sep 2020 13:42:15 -0400 Subject: [PATCH] fixes for empty view --- .../Chat/ContactsColumn/EmptyView.qml | 27 +++++++++++-------- 1 file changed, 16 insertions(+), 11 deletions(-) diff --git a/ui/app/AppLayouts/Chat/ContactsColumn/EmptyView.qml b/ui/app/AppLayouts/Chat/ContactsColumn/EmptyView.qml index 4c39f5fb82..fecea977ee 100644 --- a/ui/app/AppLayouts/Chat/ContactsColumn/EmptyView.qml +++ b/ui/app/AppLayouts/Chat/ContactsColumn/EmptyView.qml @@ -178,6 +178,11 @@ import "../../../../imports" // return totalHeight + Style.current.padding // } + Item { + anchors.top: suggestionsText.bottom + anchors.topMargin: Style.current.smallPadding + width: parent.width + Repeater { id: sectionRepeater anchors.top: suggestionsText.bottom @@ -185,21 +190,21 @@ import "../../../../imports" // id: sview model: ChannelJSON.categories Item { - anchors.top: index === 0 ? suggestionsText.bottom : parent.children[index - 1].bottom + anchors.top: index === 0 ? parent.top : parent.children[index - 1].bottom anchors.topMargin: index === 0 ? 0 : Style.current.padding width: parent.width - Style.current.padding -// height: { -// return childrenRect.height -// } - height: { - var totalHeight = 0 - for (let i = 0; i < channelRepeater.count; i++) { - totalHeight += channelRepeater.itemAt(i).height + Style.current.padding - } - return totalHeight + return childrenRect.height } +// height: { +// var totalHeight = 0 +// for (let i = 0; i < channelRepeater.count; i++) { +// totalHeight += channelRepeater.itemAt(i).height + Style.current.padding +// } +// return totalHeight +// } + Text { id: sectionTitle text: modelData.name @@ -224,7 +229,7 @@ import "../../../../imports" } // } - +} // Flow { // id: channelFlow // Layout.fillHeight: false