Fix: Do not Show "Reply" button in the toolbox for replies since we only support one level of replies. (#5748)

This commit is contained in:
Sachin Chaurasiya 2022-06-29 21:00:40 +05:30 committed by GitHub
parent 67c4493892
commit e9b6de9fa4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 12 additions and 10 deletions

View File

@ -75,7 +75,7 @@ const PopoverContent: FC<Props> = ({
* if on reply method is undefined then get the panel element
* and scroll to the bottom
*/
if (isUndefined(onReply)) {
if (isUndefined(onReply) && isThread) {
const feedPanel = document.getElementById('feed-panel') as HTMLElement;
const threadPanel = document.getElementById(
'thread-panel'
@ -152,14 +152,16 @@ const PopoverContent: FC<Props> = ({
</button>
</Popover>
<button onClick={handleReply}>
<SVGIcons
alt="add-reply"
icon={Icons.ADD_REPLY}
title="Reply"
width="20px"
/>
</button>
{(onReply || isThread) && (
<button onClick={handleReply}>
<SVGIcons
alt="add-reply"
icon={Icons.ADD_REPLY}
title="Reply"
width="20px"
/>
</button>
)}
{deleteButtonCheck ? (
<button onClick={handleDelete}>

View File

@ -90,7 +90,7 @@ const ProfilePicture = ({
return profilePic ? (
<div
className={classNames('profile-image', type)}
className={classNames('profile-image', type, className)}
style={{ height: `${height || width}px`, width: `${width}px` }}>
<img
alt="user"