2020-07-15 21:04:14 +00:00
|
|
|
import QtQuick 2.3
|
2020-09-23 08:18:23 +00:00
|
|
|
import "../../../../../shared" as Shared
|
2020-07-15 21:04:14 +00:00
|
|
|
import "../../../../../imports"
|
|
|
|
|
2020-09-30 17:49:14 +00:00
|
|
|
Loader {
|
|
|
|
property color color
|
2020-12-07 23:38:53 +00:00
|
|
|
property var container
|
|
|
|
property int contentType: -1
|
2021-04-23 15:49:05 +00:00
|
|
|
property string stickerData: sticker
|
|
|
|
property int imageHeight: 140
|
|
|
|
property int imageWidth: 140
|
2020-09-30 17:49:14 +00:00
|
|
|
|
|
|
|
id: root
|
|
|
|
active: contentType === Constants.stickerType
|
|
|
|
|
|
|
|
sourceComponent: Component {
|
|
|
|
Shared.ImageLoader {
|
|
|
|
color: root.color
|
2020-12-16 20:50:54 +00:00
|
|
|
onLoaded: scrollToBottom(true, root.container)
|
2020-10-20 14:15:04 +00:00
|
|
|
|
2021-04-23 15:49:05 +00:00
|
|
|
width: imageWidth
|
|
|
|
height: this.visible ? imageHeight : 0
|
|
|
|
source: this.visible ? ("https://ipfs.infura.io/ipfs/" + stickerData) : ""
|
2020-09-30 17:49:14 +00:00
|
|
|
}
|
|
|
|
}
|
2020-07-15 21:04:14 +00:00
|
|
|
}
|