Skip to content

Commit

Permalink
Do not allow to react if the reaction is from external server
Browse files Browse the repository at this point in the history
  • Loading branch information
h3poteto committed Feb 8, 2024
1 parent 39ba631 commit 959123b
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/components/timelines/status/Status.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -178,10 +178,17 @@ const Status: React.FC<Props> = props => {
)}
{status.emoji_reactions &&
status.emoji_reactions.map(e => (
<Button appearance="subtle" size="sm" key={e.name} onClick={() => emojiClicked(e)} active={e.me}>
<Button
appearance="subtle"
size="sm"
key={e.name}
onClick={() => emojiClicked(e)}
active={e.me}
disabled={e.name.includes('@')}
title={e.name}
>
{e.url ? (
<>
{/** TODO: Do not allow external server's reaction **/}
<img src={e.url} style={{ height: '20px' }} /> <span style={{ marginLeft: '0.2em' }}>{e.count}</span>
</>
) : (
Expand Down

0 comments on commit 959123b

Please sign in to comment.