2020-11-30 12:03:52 -05:00
|
|
|
import QtQuick 2.13
|
2021-10-26 16:21:08 +02:00
|
|
|
|
|
|
|
import StatusQ.Components 0.1
|
|
|
|
|
2021-10-28 23:23:30 +03:00
|
|
|
import utils 1.0
|
2021-10-28 00:27:49 +03:00
|
|
|
import shared.panels 1.0
|
|
|
|
import shared.status 1.0
|
|
|
|
import shared.controls 1.0
|
2021-10-28 23:23:30 +03:00
|
|
|
import shared.panels.chat 1.0
|
|
|
|
import shared.views.chat 1.0
|
|
|
|
import shared.controls.chat 1.0
|
2021-09-28 18:04:06 +03:00
|
|
|
|
2021-10-21 03:41:54 +03:00
|
|
|
Column {
|
2021-07-16 18:02:47 +03:00
|
|
|
id: root
|
2022-01-18 22:02:47 +01:00
|
|
|
|
2021-07-16 18:02:47 +03:00
|
|
|
width: parent.width
|
|
|
|
anchors.right: !isCurrentUser ? undefined : parent.right
|
|
|
|
z: (typeof chatLogView === "undefined") ? 1 : (chatLogView.count - index)
|
2021-10-01 18:58:36 +03:00
|
|
|
|
2022-02-11 16:41:34 -05:00
|
|
|
property var store
|
2021-10-22 01:39:53 +03:00
|
|
|
property var messageStore
|
2022-02-08 13:08:02 +01:00
|
|
|
property var usersStore
|
2022-01-04 13:06:05 +01:00
|
|
|
property var contactsStore
|
2021-12-14 15:19:55 +01:00
|
|
|
property var messageContextMenu
|
2021-12-09 13:53:40 +01:00
|
|
|
|
2022-02-24 13:15:02 +01:00
|
|
|
// Once we redo qml we will know all section/chat related details in each message form the parent components
|
|
|
|
// without an explicit need to fetch those details via message store/module.
|
|
|
|
property bool isChatBlocked: false
|
|
|
|
|
2021-12-09 13:53:40 +01:00
|
|
|
property string messageId: ""
|
2022-02-24 10:04:59 -05:00
|
|
|
property string communityId: ""
|
2021-12-09 13:53:40 +01:00
|
|
|
property string responseToMessageWithId: ""
|
|
|
|
property string senderId: ""
|
|
|
|
property string senderDisplayName: ""
|
|
|
|
property string senderLocalName: ""
|
|
|
|
property string senderIcon: ""
|
|
|
|
property bool isSenderIconIdenticon: true
|
|
|
|
property bool amISender: false
|
|
|
|
property string message: ""
|
|
|
|
property string messageImage: ""
|
|
|
|
property string messageTimestamp: ""
|
|
|
|
property string messageOutgoingStatus: ""
|
|
|
|
property int messageContentType: 1
|
|
|
|
property bool pinnedMessage: false
|
2022-01-05 16:50:03 +01:00
|
|
|
property string messagePinnedBy: ""
|
2021-12-29 11:32:43 +01:00
|
|
|
property var reactionsModel: []
|
2022-01-25 13:56:53 +01:00
|
|
|
property string linkUrls: ""
|
2022-02-01 13:45:28 -05:00
|
|
|
property bool isInPinnedPopup: false // The pinned popup limits the number of buttons shown
|
2022-02-09 01:04:49 +01:00
|
|
|
property var transactionParams
|
2021-12-09 13:53:40 +01:00
|
|
|
|
2022-02-25 11:42:32 +01:00
|
|
|
property int gapFrom: 0
|
|
|
|
property int gapTo: 0
|
|
|
|
|
2021-12-09 13:53:40 +01:00
|
|
|
property int prevMessageIndex: -1
|
|
|
|
property var prevMessageAsJsonObj
|
|
|
|
property int nextMessageIndex: -1
|
|
|
|
property var nextMessageAsJsonObj
|
|
|
|
|
|
|
|
property string hoveredMessage
|
|
|
|
property string activeMessage
|
|
|
|
property bool isHovered: typeof hoveredMessage !== "undefined" && hoveredMessage === messageId
|
|
|
|
property bool isMessageActive: typeof activeMessage !== "undefined" && activeMessage === messageId
|
|
|
|
|
2022-01-17 19:46:46 +01:00
|
|
|
property bool editModeOn: false
|
|
|
|
|
2021-12-09 13:53:40 +01:00
|
|
|
function setHovered(messageId, hovered) {
|
|
|
|
if (hovered) {
|
|
|
|
hoveredMessage = messageId;
|
|
|
|
} else if (hoveredMessage === messageId) {
|
|
|
|
hoveredMessage = "";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
function setMessageActive(messageId, active) {
|
|
|
|
if (active) {
|
|
|
|
activeMessage = messageId;
|
|
|
|
} else if (activeMessage === messageId) {
|
|
|
|
activeMessage = "";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// Legacy
|
|
|
|
property string responseTo: responseToMessageWithId
|
|
|
|
property bool isCurrentUser: amISender
|
|
|
|
property int contentType: messageContentType
|
|
|
|
property string timestamp: messageTimestamp
|
|
|
|
property string displayUserName: senderDisplayName
|
|
|
|
property string outgoingStatus: messageOutgoingStatus
|
|
|
|
property string authorCurrentMsg: senderId
|
|
|
|
property string authorPrevMsg: {
|
2022-02-23 15:40:52 -05:00
|
|
|
if(!prevMessageAsJsonObj ||
|
|
|
|
// The system message for private groups appear as created by the group host, but it shouldn't
|
|
|
|
prevMessageAsJsonObj.contentType === Constants.messageContentType.systemMessagePrivateGroupType) {
|
2021-12-09 13:53:40 +01:00
|
|
|
return ""
|
2022-02-23 15:40:52 -05:00
|
|
|
}
|
2021-12-09 13:53:40 +01:00
|
|
|
|
|
|
|
return prevMessageAsJsonObj.senderId
|
|
|
|
}
|
|
|
|
property string prevMsgTimestamp: {
|
|
|
|
if(!prevMessageAsJsonObj)
|
|
|
|
return ""
|
|
|
|
|
|
|
|
return prevMessageAsJsonObj.timestamp
|
|
|
|
}
|
|
|
|
property string nextMsgTimestamp: {
|
|
|
|
if(!nextMessageAsJsonObj)
|
|
|
|
return ""
|
|
|
|
|
|
|
|
return nextMessageAsJsonObj.timestamp
|
|
|
|
}
|
|
|
|
|
|
|
|
property bool shouldRepeatHeader: ((parseInt(timestamp, 10) - parseInt(prevMsgTimestamp, 10)) / 60 / 1000) > Constants.repeatHeaderInterval
|
2021-10-22 01:39:53 +03:00
|
|
|
|
2021-10-01 18:58:36 +03:00
|
|
|
//////////////////////////////////////
|
2021-12-10 17:11:18 +01:00
|
|
|
//TODO CHECCK - REMOVE
|
2020-07-10 11:24:52 -04:00
|
|
|
property string plainText: "That's right. We're friends... Of justice, that is."
|
2020-08-12 11:01:03 -04:00
|
|
|
property string emojiReactions: ""
|
2020-07-14 11:35:21 -04:00
|
|
|
property bool timeout: false
|
2021-02-01 13:40:55 -05:00
|
|
|
property bool hasMention: false
|
2020-11-30 12:03:52 -05:00
|
|
|
property bool placeholderMessage: false
|
2021-06-11 13:41:59 -04:00
|
|
|
property bool activityCenterMessage: false
|
2021-06-14 11:40:05 -04:00
|
|
|
property bool read: true
|
2021-05-25 15:34:46 -04:00
|
|
|
property bool forceHoverHandler: false // Used to force the HoverHandler to be active (useful for messages in popups)
|
2021-06-29 10:49:32 -04:00
|
|
|
property string replaces: ""
|
|
|
|
property bool isEdited: false
|
2022-01-05 16:50:03 +01:00
|
|
|
property bool stickersLoaded: false
|
2021-12-10 17:11:18 +01:00
|
|
|
//////////////////////////////////////
|
2021-12-09 13:53:40 +01:00
|
|
|
|
2022-01-13 14:25:38 -05:00
|
|
|
property string sticker: "Qme8vJtyrEHxABcSVGPF95PtozDgUyfr1xGjePmFdZgk9v"
|
|
|
|
property int stickerPack: -1
|
2021-12-09 13:53:40 +01:00
|
|
|
property bool isEmoji: contentType === Constants.messageContentType.emojiType
|
|
|
|
property bool isImage: contentType === Constants.messageContentType.imageType
|
|
|
|
property bool isAudio: contentType === Constants.messageContentType.audioType
|
|
|
|
property bool isStatusMessage: contentType === Constants.messageContentType.systemMessagePrivateGroupType
|
|
|
|
property bool isSticker: contentType === Constants.messageContentType.stickerType
|
|
|
|
property bool isText: contentType === Constants.messageContentType.messageType || contentType === Constants.messageContentType.editType
|
2021-02-01 13:40:55 -05:00
|
|
|
property bool isMessage: isEmoji || isImage || isSticker || isText || isAudio
|
2021-12-09 13:53:40 +01:00
|
|
|
|| contentType === Constants.messageContentType.communityInviteType || contentType === Constants.messageContentType.transactionType
|
2020-06-10 11:14:12 -04:00
|
|
|
|
2021-04-23 11:49:05 -04:00
|
|
|
property bool isExpired: (outgoingStatus === "sending" && (Math.floor(timestamp) + 180000) < Date.now())
|
2021-12-09 13:53:40 +01:00
|
|
|
property bool isStatusUpdate: false
|
2021-07-15 17:59:30 +03:00
|
|
|
property int statusAgeEpoch: 0
|
2020-07-16 13:27:09 -04:00
|
|
|
|
2022-01-18 22:02:47 +01:00
|
|
|
signal imageClicked(var image)
|
2020-07-10 11:37:23 -04:00
|
|
|
property var scrollToBottom: function () {}
|
2020-11-30 12:03:52 -05:00
|
|
|
|
2021-12-14 15:19:55 +01:00
|
|
|
property var clickMessage: function(isProfileClick,
|
|
|
|
isSticker = false,
|
|
|
|
isImage = false,
|
|
|
|
image = null,
|
|
|
|
emojiOnly = false,
|
|
|
|
hideEmojiPicker = false,
|
|
|
|
isReply = false,
|
|
|
|
isRightClickOnImage = false,
|
|
|
|
imageSource = "") {
|
|
|
|
|
|
|
|
if (placeholderMessage || activityCenterMessage) {
|
|
|
|
return
|
|
|
|
}
|
2021-12-09 13:53:40 +01:00
|
|
|
|
2021-12-14 15:19:55 +01:00
|
|
|
messageContextMenu.myPublicKey = userProfile.pubKey
|
2022-01-05 16:50:03 +01:00
|
|
|
messageContextMenu.amIChatAdmin = messageStore.amIChatAdmin()
|
2021-12-14 15:19:55 +01:00
|
|
|
messageContextMenu.chatType = messageStore.getChatType()
|
|
|
|
|
|
|
|
messageContextMenu.messageId = root.messageId
|
|
|
|
messageContextMenu.messageSenderId = root.senderId
|
|
|
|
messageContextMenu.messageContentType = root.messageContentType
|
|
|
|
messageContextMenu.pinnedMessage = root.pinnedMessage
|
2021-12-17 13:53:10 +01:00
|
|
|
messageContextMenu.canPin = messageStore.getNumberOfPinnedMessages() < Constants.maxNumberOfPins
|
2021-12-14 15:19:55 +01:00
|
|
|
|
|
|
|
messageContextMenu.selectedUserPublicKey = root.senderId
|
|
|
|
messageContextMenu.selectedUserDisplayName = root.senderDisplayName
|
|
|
|
messageContextMenu.selectedUserIcon = root.senderIcon
|
|
|
|
messageContextMenu.isSelectedUserIconIdenticon = root.isSenderIconIdenticon
|
|
|
|
|
|
|
|
messageContextMenu.imageSource = imageSource
|
|
|
|
|
|
|
|
messageContextMenu.isProfile = !!isProfileClick
|
|
|
|
messageContextMenu.isRightClickOnImage = isRightClickOnImage
|
|
|
|
messageContextMenu.emojiOnly = emojiOnly
|
|
|
|
messageContextMenu.hideEmojiPicker = hideEmojiPicker
|
|
|
|
|
|
|
|
if(isReply){
|
|
|
|
let obj = messageStore.getMessageByIdAsJson(responseTo)
|
|
|
|
if(!obj)
|
|
|
|
return
|
|
|
|
|
|
|
|
messageContextMenu.messageSenderId = obj.id
|
|
|
|
messageContextMenu.selectedUserPublicKey = obj.id
|
|
|
|
messageContextMenu.selectedUserDisplayName = obj.senderDisplayName
|
|
|
|
messageContextMenu.selectedUserIcon = obj.senderIcon
|
|
|
|
messageContextMenu.isSelectedUserIconIdenticon = obj.isSenderIconIdenticon
|
|
|
|
}
|
2021-12-09 13:53:40 +01:00
|
|
|
|
|
|
|
|
2021-12-14 15:19:55 +01:00
|
|
|
messageContextMenu.x = messageContextMenu.setXPosition()
|
|
|
|
messageContextMenu.y = messageContextMenu.setYPosition()
|
|
|
|
|
|
|
|
messageContextMenu.popup()
|
2020-06-17 08:53:51 -04:00
|
|
|
}
|
|
|
|
|
2022-01-12 15:55:26 +03:00
|
|
|
signal showReplyArea(string messageId, string author)
|
|
|
|
|
2021-10-01 18:58:36 +03:00
|
|
|
|
2021-12-09 13:53:40 +01:00
|
|
|
// function showReactionAuthors(fromAccounts, emojiId) {
|
|
|
|
// return root.rootStore.showReactionAuthors(fromAccounts, emojiId)
|
|
|
|
// }
|
2021-10-01 18:58:36 +03:00
|
|
|
|
2022-01-27 12:28:27 +01:00
|
|
|
function startMessageFoundAnimation() {
|
|
|
|
messageLoader.item.startMessageFoundAnimation();
|
|
|
|
}
|
2021-10-01 18:58:36 +03:00
|
|
|
/////////////////////////////////////////////
|
|
|
|
|
2021-12-08 23:20:43 +02:00
|
|
|
|
|
|
|
signal openStickerPackPopup(string stickerPackId)
|
2021-12-09 13:53:40 +01:00
|
|
|
// Not Refactored Yet
|
|
|
|
// Connections {
|
|
|
|
// enabled: (!placeholderMessage && !!root.rootStore)
|
|
|
|
// target: !!root.rootStore ? root.rootStore.allContacts : null
|
|
|
|
// onContactChanged: {
|
|
|
|
// if (pubkey === fromAuthor) {
|
|
|
|
// const img = appMain.getProfileImage(userPubKey, isCurrentUser, useLargeImage)
|
|
|
|
// if (img) {
|
|
|
|
// profileImageSource = img
|
|
|
|
// }
|
|
|
|
// } else if (replyMessageIndex > -1 && pubkey === repliedMessageAuthorPubkey) {
|
|
|
|
// const imgReply = appMain.getProfileImage(repliedMessageAuthorPubkey, repliedMessageAuthorIsCurrentUser, false)
|
|
|
|
// if (imgReply) {
|
|
|
|
// repliedMessageUserImage = imgReply
|
|
|
|
// }
|
|
|
|
// }
|
|
|
|
// }
|
|
|
|
// }
|
2021-10-01 18:58:36 +03:00
|
|
|
|
2020-07-15 17:04:14 -04:00
|
|
|
Loader {
|
2021-09-22 11:25:55 +03:00
|
|
|
id: messageLoader
|
2021-11-25 16:36:03 +01:00
|
|
|
active: root.visible
|
2020-07-15 17:04:14 -04:00
|
|
|
width: parent.width
|
|
|
|
sourceComponent: {
|
|
|
|
switch(contentType) {
|
2021-12-09 13:53:40 +01:00
|
|
|
case Constants.messageContentType.chatIdentifier:
|
2020-07-15 17:04:14 -04:00
|
|
|
return channelIdentifierComponent
|
2021-12-09 13:53:40 +01:00
|
|
|
case Constants.messageContentType.fetchMoreMessagesButton:
|
2020-09-04 13:55:24 +02:00
|
|
|
return fetchMoreMessagesButtonComponent
|
2021-12-09 13:53:40 +01:00
|
|
|
case Constants.messageContentType.systemMessagePrivateGroupType:
|
2020-07-22 08:23:15 -04:00
|
|
|
return privateGroupHeaderComponent
|
2021-12-09 13:53:40 +01:00
|
|
|
case Constants.messageContentType.gapType:
|
2021-05-10 15:12:26 -04:00
|
|
|
return gapComponent
|
2020-07-15 17:04:14 -04:00
|
|
|
default:
|
2021-12-10 12:29:33 +01:00
|
|
|
return isStatusUpdate ? statusUpdateComponent : compactMessageComponent
|
2021-01-25 15:13:43 -05:00
|
|
|
|
2020-06-04 12:30:49 +02:00
|
|
|
}
|
|
|
|
}
|
2020-05-27 18:59:17 -04:00
|
|
|
}
|
|
|
|
|
2021-05-10 15:12:26 -04:00
|
|
|
Component {
|
|
|
|
id: gapComponent
|
2021-10-21 03:41:54 +03:00
|
|
|
GapComponent {
|
2022-02-25 11:42:32 +01:00
|
|
|
gapFrom: root.gapFrom
|
|
|
|
gapTo: root.gapTo
|
2021-10-21 03:41:54 +03:00
|
|
|
onClicked: {
|
2022-01-28 19:18:30 -04:00
|
|
|
messageStore.fillGaps(messageId)
|
|
|
|
root.visible = false;
|
|
|
|
root.height = 0;
|
2021-05-10 15:12:26 -04:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-09-04 13:55:24 +02:00
|
|
|
Component {
|
|
|
|
id: fetchMoreMessagesButtonComponent
|
2021-10-21 03:41:54 +03:00
|
|
|
FetchMoreMessagesButton {
|
2021-12-10 17:11:18 +01:00
|
|
|
nextMessageIndex: root.nextMessageIndex
|
|
|
|
nextMsgTimestamp: root.nextMsgTimestamp
|
2021-10-21 03:41:54 +03:00
|
|
|
onTimerTriggered: {
|
2022-01-28 19:18:30 -04:00
|
|
|
messageStore.requestMoreMessages();
|
2020-09-04 13:55:24 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-07-15 17:04:14 -04:00
|
|
|
Component {
|
|
|
|
id: channelIdentifierComponent
|
2021-12-10 17:11:18 +01:00
|
|
|
ChannelIdentifierView {
|
|
|
|
chatName: root.senderDisplayName
|
2022-02-11 17:01:36 +01:00
|
|
|
chatType: root.messageStore.getChatType()
|
|
|
|
chatColor: root.messageStore.getChatColor()
|
|
|
|
amIChatAdmin: root.messageStore.amIChatAdmin()
|
2021-12-10 17:11:18 +01:00
|
|
|
chatIcon: root.senderIcon
|
|
|
|
chatIconIsIdenticon: root.isSenderIconIdenticon
|
2022-02-11 17:01:36 +01:00
|
|
|
didIJoinedChat: root.messageStore.didIJoinedChat()
|
|
|
|
|
|
|
|
onJoinChatClicked: root.messageStore.joinGroupChat()
|
|
|
|
onRejectJoiningChatClicked: root.messageStore.leaveChat()
|
2020-06-10 14:23:18 -04:00
|
|
|
}
|
2020-05-27 18:59:17 -04:00
|
|
|
}
|
|
|
|
|
2020-07-15 17:04:14 -04:00
|
|
|
// Private group Messages
|
|
|
|
Component {
|
|
|
|
id: privateGroupHeaderComponent
|
|
|
|
StyledText {
|
2020-06-25 16:17:42 -04:00
|
|
|
wrapMode: Text.Wrap
|
2020-11-30 12:03:52 -05:00
|
|
|
text: {
|
2020-09-21 11:47:15 -04:00
|
|
|
return `<html>`+
|
|
|
|
`<head>`+
|
|
|
|
`<style type="text/css">`+
|
|
|
|
`a {`+
|
|
|
|
`color: ${Style.current.textColor};`+
|
|
|
|
`text-decoration: none;`+
|
|
|
|
`}`+
|
|
|
|
`</style>`+
|
|
|
|
`</head>`+
|
|
|
|
`<body>`+
|
|
|
|
`${message}`+
|
|
|
|
`</body>`+
|
|
|
|
`</html>`;
|
|
|
|
}
|
2020-07-15 17:04:14 -04:00
|
|
|
visible: isStatusMessage
|
2020-09-21 11:47:15 -04:00
|
|
|
font.pixelSize: 14
|
|
|
|
color: Style.current.secondaryText
|
2020-07-15 17:04:14 -04:00
|
|
|
width: parent.width - 120
|
|
|
|
horizontalAlignment: Text.AlignHCenter
|
|
|
|
anchors.horizontalCenter: parent.horizontalCenter
|
|
|
|
textFormat: Text.RichText
|
2020-12-08 10:38:53 +11:00
|
|
|
topPadding: root.prevMessageIndex === 1 ? Style.current.bigPadding : 0
|
2020-07-09 13:47:36 -04:00
|
|
|
}
|
2020-07-09 11:50:38 -04:00
|
|
|
}
|
2020-05-28 15:32:14 -04:00
|
|
|
|
2021-12-09 13:53:40 +01:00
|
|
|
Component {
|
|
|
|
id: statusUpdateComponent
|
|
|
|
StatusUpdateView {
|
2022-02-22 21:48:57 +01:00
|
|
|
messageStore: root.messageStore
|
2021-12-09 13:53:40 +01:00
|
|
|
statusAgeEpoch: root.statusAgeEpoch
|
2020-12-16 15:50:54 -05:00
|
|
|
container: root
|
2021-12-10 17:11:18 +01:00
|
|
|
// Not Refactored Yet
|
|
|
|
// store: root.rootStore
|
2021-12-09 13:53:40 +01:00
|
|
|
messageContextMenu: root.messageContextMenu
|
|
|
|
onAddEmoji: {
|
|
|
|
root.clickMessage(isProfileClick, isSticker, isImage , image, emojiOnly, hideEmojiPicker);
|
|
|
|
}
|
2022-01-18 22:02:47 +01:00
|
|
|
onChatImageClicked: root.imageClicked(image)
|
|
|
|
|
2021-12-09 13:53:40 +01:00
|
|
|
onUserNameClicked: {
|
2021-12-10 17:11:18 +01:00
|
|
|
// Not Refactored Yet - Should do it via messageStore
|
|
|
|
// root.parent.clickMessage(isProfileClick);
|
2021-12-09 13:53:40 +01:00
|
|
|
}
|
|
|
|
onEmojiBtnClicked: {
|
2021-12-10 17:11:18 +01:00
|
|
|
// Not Refactored Yet - Should do it via messageStore
|
|
|
|
// root.parent.clickMessage(isProfileClick, isSticker, isImage, image, emojiOnly);
|
2021-12-09 13:53:40 +01:00
|
|
|
}
|
|
|
|
onClickMessage: {
|
2021-12-10 17:11:18 +01:00
|
|
|
// Not Refactored Yet - Should do it via messageStore
|
|
|
|
// root.parent.clickMessage(isProfileClick, isSticker, isImage, image, emojiOnly, hideEmojiPicker, isReply);
|
2021-12-09 13:53:40 +01:00
|
|
|
}
|
|
|
|
onSetMessageActive: {
|
2021-12-20 15:21:35 +01:00
|
|
|
root.setMessageActive(messageId, active);
|
2021-12-09 13:53:40 +01:00
|
|
|
}
|
2020-05-28 15:32:14 -04:00
|
|
|
}
|
2020-07-09 11:50:38 -04:00
|
|
|
}
|
2020-07-10 11:37:23 -04:00
|
|
|
|
2020-07-15 17:04:14 -04:00
|
|
|
Component {
|
|
|
|
id: compactMessageComponent
|
2022-01-18 22:02:47 +01:00
|
|
|
|
2021-10-01 18:58:36 +03:00
|
|
|
CompactMessageView {
|
2022-02-22 21:48:57 +01:00
|
|
|
container: root
|
2022-02-11 16:41:34 -05:00
|
|
|
store: root.store
|
2022-01-18 22:02:47 +01:00
|
|
|
messageStore: root.messageStore
|
2022-02-08 13:08:02 +01:00
|
|
|
usersStore: root.usersStore
|
2022-01-04 13:06:05 +01:00
|
|
|
contactsStore: root.contactsStore
|
2021-07-16 18:02:47 +03:00
|
|
|
messageContextMenu: root.messageContextMenu
|
2022-01-13 14:25:38 -05:00
|
|
|
contentType: root.messageContentType
|
2022-02-24 13:15:02 +01:00
|
|
|
isChatBlocked: root.isChatBlocked
|
2022-01-05 16:50:03 +01:00
|
|
|
|
2022-02-24 10:04:59 -05:00
|
|
|
communityId: root.communityId
|
2022-01-05 16:50:03 +01:00
|
|
|
stickersLoaded: root.stickersLoaded
|
2022-01-13 14:25:38 -05:00
|
|
|
sticker: root.sticker
|
|
|
|
stickerPack: root.stickerPack
|
2022-01-05 16:50:03 +01:00
|
|
|
isMessageActive: root.isMessageActive
|
2022-02-18 14:39:04 -05:00
|
|
|
amISender: root.amISender
|
2022-01-05 16:50:03 +01:00
|
|
|
isHovered: root.isHovered
|
2022-01-17 19:46:46 +01:00
|
|
|
editModeOn: root.editModeOn
|
2022-01-25 13:56:53 +01:00
|
|
|
linkUrls: root.linkUrls
|
2022-02-01 13:45:28 -05:00
|
|
|
isInPinnedPopup: root.isInPinnedPopup
|
2022-01-05 16:50:03 +01:00
|
|
|
|
2022-02-09 01:04:49 +01:00
|
|
|
transactionParams: root.transactionParams
|
|
|
|
|
2021-07-16 18:02:47 +03:00
|
|
|
onAddEmoji: {
|
2021-12-14 15:19:55 +01:00
|
|
|
root.clickMessage(isProfileClick, isSticker, isImage , image, emojiOnly, hideEmojiPicker)
|
|
|
|
}
|
|
|
|
|
|
|
|
onClickMessage: {
|
|
|
|
root.clickMessage(isProfileClick, isSticker, isImage, image, emojiOnly, hideEmojiPicker, isReply, isRightClickOnImage, imageSource)
|
2021-07-16 18:02:47 +03:00
|
|
|
}
|
2022-01-18 22:02:47 +01:00
|
|
|
|
2021-12-08 23:20:43 +02:00
|
|
|
onOpenStickerPackPopup: {
|
|
|
|
root.openStickerPackPopup(stickerPackId);
|
|
|
|
}
|
2022-01-12 15:55:26 +03:00
|
|
|
|
|
|
|
onReplyClicked: {
|
|
|
|
root.showReplyArea(messageId, author)
|
|
|
|
}
|
2022-01-18 22:02:47 +01:00
|
|
|
|
|
|
|
onImageClicked: root.imageClicked(image)
|
2020-07-10 11:37:23 -04:00
|
|
|
}
|
2020-05-27 18:59:17 -04:00
|
|
|
}
|
|
|
|
}
|