mirror of
https://github.com/status-im/status-desktop.git
synced 2025-02-23 12:08:53 +00:00
fix: fix padding around stickers in compact mode
This commit is contained in:
parent
df76fb815b
commit
c37ba24f7b
@ -74,27 +74,36 @@ Item {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Rectangle {
|
Loader {
|
||||||
id: stickerContainer
|
id: stickerLoader
|
||||||
visible: contentType === Constants.stickerType
|
active: contentType === Constants.stickerType
|
||||||
color: Style.current.transparent
|
|
||||||
border.color: Style.current.grey
|
|
||||||
border.width: 1
|
|
||||||
radius: 16
|
|
||||||
width: stickerId.width
|
|
||||||
height: stickerId.height
|
|
||||||
anchors.left: chatText.left
|
anchors.left: chatText.left
|
||||||
anchors.top: chatName.visible ? chatName.bottom : parent.top
|
anchors.top: chatName.visible ? chatName.bottom : parent.top
|
||||||
anchors.topMargin: this.visible && chatName.visible ? chatTextItem.chatVerticalPadding : 0
|
anchors.topMargin: this.visible && chatName.visible ? chatTextItem.chatVerticalPadding : 0
|
||||||
|
|
||||||
Sticker {
|
sourceComponent: Component {
|
||||||
id: stickerId
|
Rectangle {
|
||||||
visible: stickerContainer.visible
|
id: stickerContainer
|
||||||
|
color: Style.current.transparent
|
||||||
|
border.color: Style.current.grey
|
||||||
|
border.width: 1
|
||||||
|
radius: 16
|
||||||
|
width: stickerId.width + 2 * chatTextItem.chatVerticalPadding
|
||||||
|
height: stickerId.height + 2 * chatTextItem.chatVerticalPadding
|
||||||
|
|
||||||
|
Sticker {
|
||||||
|
id: stickerId
|
||||||
|
anchors.top: parent.top
|
||||||
|
anchors.topMargin: chatTextItem.chatVerticalPadding
|
||||||
|
anchors.left: parent.left
|
||||||
|
anchors.leftMargin: chatTextItem.chatVerticalPadding
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
MessageMouseArea {
|
MessageMouseArea {
|
||||||
anchors.fill: stickerContainer.visible ? stickerContainer : chatText
|
anchors.fill: stickerLoader.active ? stickerLoader : chatText
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO show date for not the first messsage (on hover maybe)
|
// TODO show date for not the first messsage (on hover maybe)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user