mirror of
https://github.com/cheeaun/phanpy.git
synced 2025-01-23 09:06:23 +01:00
Hide "more" icon for posts in notifications
This commit is contained in:
parent
07f927d4ff
commit
4b9ff0ca5b
2 changed files with 22 additions and 5 deletions
|
@ -292,7 +292,12 @@ function Notification({
|
|||
instance ? `/${instance}/s/${status.id}` : `/s/${status.id}`
|
||||
}
|
||||
>
|
||||
<Status status={status} size="s" />
|
||||
<Status
|
||||
status={status}
|
||||
size="s"
|
||||
previewMode
|
||||
allowContextMenu
|
||||
/>
|
||||
</TruncatedLink>
|
||||
</li>
|
||||
))}
|
||||
|
@ -326,9 +331,19 @@ function Notification({
|
|||
}
|
||||
>
|
||||
{isStatic ? (
|
||||
<Status status={actualStatus} size="s" />
|
||||
<Status
|
||||
status={actualStatus}
|
||||
size="s"
|
||||
previewMode
|
||||
allowContextMenu
|
||||
/>
|
||||
) : (
|
||||
<Status statusID={actualStatusID} size="s" />
|
||||
<Status
|
||||
statusID={actualStatusID}
|
||||
size="s"
|
||||
previewMode
|
||||
allowContextMenu
|
||||
/>
|
||||
)}
|
||||
</TruncatedLink>
|
||||
)}
|
||||
|
|
|
@ -124,6 +124,7 @@ function Status({
|
|||
quoted,
|
||||
onStatusLinkClick = () => {},
|
||||
showFollowedTags,
|
||||
allowContextMenu,
|
||||
}) {
|
||||
if (skeleton) {
|
||||
return (
|
||||
|
@ -987,7 +988,8 @@ function Status({
|
|||
const [isContextMenuOpen, setIsContextMenuOpen] = useState(false);
|
||||
const [contextMenuProps, setContextMenuProps] = useState({});
|
||||
|
||||
const showContextMenu = !isSizeLarge && !previewMode && !_deleted && !quoted;
|
||||
const showContextMenu =
|
||||
allowContextMenu || (!isSizeLarge && !previewMode && !_deleted && !quoted);
|
||||
|
||||
// Only iOS/iPadOS browsers don't support contextmenu
|
||||
// Some comments report iPadOS might support contextmenu if a mouse is connected
|
||||
|
@ -1412,7 +1414,7 @@ function Status({
|
|||
/>
|
||||
)}{' '}
|
||||
<RelativeTime datetime={createdAtDate} format="micro" />
|
||||
{showContextMenu && <Icon icon="more2" class="more" />}
|
||||
{!previewMode && <Icon icon="more2" class="more" />}
|
||||
</Link>
|
||||
) : (
|
||||
// <Menu
|
||||
|
|
Loading…
Reference in a new issue