Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes Icon preview of latest WebXDC displayed when summary is reaction event #4062

Merged
merged 7 commits into from
Aug 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@
- fix composite emoji in text avatar #4038
- fix "Password and Account" dialog not indicating invalid credentials, making it seem that you can change password like this #4032
- fix empty context menu and unneccessary separators in HTML mail view #4053
- fix Icon preview of latest WebXDC displayed when summary is reaction event #4062

<a id="1_46_1"></a>

Expand Down
7 changes: 2 additions & 5 deletions src/renderer/components/chat/ChatListItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@ function Message({
isArchived,
isContactRequest,
summaryPreviewImage,
lastMessageType,
lastMessageId,
}: Pick<
ChatListItemType,
Expand All @@ -77,7 +76,6 @@ function Message({
| 'isArchived'
| 'isContactRequest'
| 'summaryPreviewImage'
| 'lastMessageType'
| `lastMessageId`
>) {
const wasReceived =
Expand All @@ -87,7 +85,7 @@ function Message({

const status = wasReceived ? '' : mapCoreMsgStatus2String(summaryStatus)

const iswebxdc = lastMessageType === 'Webxdc'
const iswebxdc = summaryPreviewImage === 'webxdc-icon://last-msg-id'

return (
<div className='chat-list-item-message'>
Expand All @@ -101,7 +99,7 @@ function Message({
{summaryText1 + ': '}
</div>
)}
{summaryPreviewImage && (
{summaryPreviewImage && !iswebxdc && (
<img className='summary_thumbnail' src={summaryPreviewImage} />
)}
{iswebxdc && lastMessageId && (
Expand Down Expand Up @@ -281,7 +279,6 @@ function ChatListItemNormal({
freshMessageCounter={chatListItem.freshMessageCounter}
isArchived={chatListItem.isArchived}
isContactRequest={chatListItem.isContactRequest}
lastMessageType={chatListItem.lastMessageType}
lastMessageId={chatListItem.lastMessageId}
/>
</div>
Expand Down
Loading