feat(CommunityBackup): remove backup banner after clicking on it
This commit is contained in:
parent
f353a29c3f
commit
1b491df9b4
|
@ -135,7 +135,7 @@ Rectangle {
|
|||
|
||||
Loader {
|
||||
id: emptyViewAndSuggestionsLoader
|
||||
active: !appSettings.hiddenCommunityWelcomeBanners.includes(chatsModel.communities.activeCommunity.id) && chatsModel.communities.activeCommunity.admin
|
||||
active: chatsModel.communities.activeCommunity.admin && !appSettings.hiddenCommunityWelcomeBanners.includes(chatsModel.communities.activeCommunity.id)
|
||||
width: parent.width
|
||||
height: active ? item.height : 0
|
||||
anchors.top: channelList.bottom
|
||||
|
@ -146,7 +146,7 @@ Rectangle {
|
|||
}
|
||||
Loader {
|
||||
id: backUpBannerLoader
|
||||
active: chatsModel.communities.activeCommunity.admin
|
||||
active: chatsModel.communities.activeCommunity.admin && !appSettings.hiddenCommunityBackUpBanners.includes(chatsModel.communities.activeCommunity.id)
|
||||
width: parent.width
|
||||
height: active ? item.height : 0
|
||||
anchors.top: emptyViewAndSuggestionsLoader.bottom
|
||||
|
|
|
@ -53,7 +53,12 @@ Rectangle {
|
|||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
anchors.top: backUpText.bottom
|
||||
anchors.topMargin: Style.current.padding
|
||||
onClicked: openPopup(transferOwnershipPopup, {privateKey: chatsModel.communities.exportComumnity()})
|
||||
onClicked: {
|
||||
let hiddenBannerIds = appSettings.hiddenCommunityBackUpBanners
|
||||
hiddenBannerIds.push(chatsModel.communities.activeCommunity.id)
|
||||
appSettings.hiddenCommunityBackUpBanners = hiddenBannerIds
|
||||
openPopup(transferOwnershipPopup, {privateKey: chatsModel.communities.exportComumnity()})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -117,6 +117,7 @@ RowLayout {
|
|||
property bool timelineEnabled: true
|
||||
property var recentEmojis: []
|
||||
property var hiddenCommunityWelcomeBanners: []
|
||||
property var hiddenCommunityBackUpBanners: []
|
||||
property real volume: 0.2
|
||||
property int notificationSetting: Constants.notifyAllMessages
|
||||
property bool notificationSoundsEnabled: true
|
||||
|
|
Loading…
Reference in New Issue