2022-03-07 22:59:38 +00:00
|
|
|
import QtQuick 2.13
|
2022-04-14 08:26:46 +00:00
|
|
|
|
2022-03-07 22:59:38 +00:00
|
|
|
import StatusQ.Core.Utils 0.1 as StatusQUtils
|
2022-05-23 11:35:51 +00:00
|
|
|
import StatusQ.Components 0.1
|
2022-04-14 08:26:46 +00:00
|
|
|
|
2022-03-07 22:59:38 +00:00
|
|
|
import utils 1.0
|
2022-04-14 08:26:46 +00:00
|
|
|
import shared.panels 1.0
|
2022-03-07 22:59:38 +00:00
|
|
|
|
2022-04-14 08:26:46 +00:00
|
|
|
Item {
|
2022-03-07 22:59:38 +00:00
|
|
|
id: root
|
2022-04-14 08:26:46 +00:00
|
|
|
|
2022-07-04 20:09:08 +00:00
|
|
|
property bool compact: false
|
2022-03-07 22:59:38 +00:00
|
|
|
property string publicKey
|
2022-04-14 08:26:46 +00:00
|
|
|
|
2022-07-04 20:09:08 +00:00
|
|
|
readonly property real size: compact ? 10 : 15
|
2022-04-14 08:26:46 +00:00
|
|
|
|
|
|
|
implicitHeight: positioner.implicitHeight
|
|
|
|
implicitWidth: positioner.implicitWidth
|
|
|
|
|
|
|
|
Grid {
|
|
|
|
id: positioner
|
|
|
|
|
|
|
|
rows: 2
|
|
|
|
columnSpacing: Math.ceil(root.size / 16)
|
|
|
|
rowSpacing: columnSpacing + 6
|
|
|
|
|
|
|
|
Repeater {
|
|
|
|
model: Utils.getEmojiHashAsJson(root.publicKey)
|
|
|
|
|
2022-05-23 11:35:51 +00:00
|
|
|
StatusEmoji {
|
2022-04-14 08:26:46 +00:00
|
|
|
width: root.size
|
|
|
|
height: root.size
|
2022-05-23 11:35:51 +00:00
|
|
|
emojiId: StatusQUtils.Emoji.iconId(modelData)
|
2022-04-14 08:26:46 +00:00
|
|
|
}
|
2022-03-07 22:59:38 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|