Header: hide message button again (for now)
This commit is contained in:
parent
d0ec2af4ee
commit
632726ef1c
1 changed files with 26 additions and 26 deletions
|
@ -654,33 +654,33 @@ const Header: React.FC<IHeader> = ({ account }) => {
|
||||||
return info;
|
return info;
|
||||||
};
|
};
|
||||||
|
|
||||||
const renderMessageButton = () => {
|
// const renderMessageButton = () => {
|
||||||
if (!ownAccount || !account || account.id === ownAccount?.id) {
|
// if (!ownAccount || !account || account.id === ownAccount?.id) {
|
||||||
return null;
|
// return null;
|
||||||
}
|
// }
|
||||||
|
|
||||||
const canChat = account.getIn(['pleroma', 'accepts_chat_messages']) === true;
|
// const canChat = account.getIn(['pleroma', 'accepts_chat_messages']) === true;
|
||||||
|
|
||||||
if (canChat) {
|
// if (canChat) {
|
||||||
return (
|
// return (
|
||||||
<IconButton
|
// <IconButton
|
||||||
src={require('@tabler/icons/messages.svg')}
|
// src={require('@tabler/icons/messages.svg')}
|
||||||
onClick={onChat}
|
// onClick={onChat}
|
||||||
title={intl.formatMessage(messages.chat, { name: account.username })}
|
// title={intl.formatMessage(messages.chat, { name: account.username })}
|
||||||
/>
|
// />
|
||||||
);
|
// );
|
||||||
} else {
|
// } else {
|
||||||
return (
|
// return (
|
||||||
<IconButton
|
// <IconButton
|
||||||
src={require('@tabler/icons/mail.svg')}
|
// src={require('@tabler/icons/mail.svg')}
|
||||||
onClick={onDirect}
|
// onClick={onDirect}
|
||||||
title={intl.formatMessage(messages.direct, { name: account.username })}
|
// title={intl.formatMessage(messages.direct, { name: account.username })}
|
||||||
className='px-2 border border-solid bg-transparent border-gray-400 dark:border-gray-800 hover:border-primary-300 dark:hover:border-primary-700 focus:border-primary-500 text-gray-900 dark:text-gray-100 focus:ring-primary-500'
|
// className='px-2 border border-solid bg-transparent border-gray-400 dark:border-gray-800 hover:border-primary-300 dark:hover:border-primary-700 focus:border-primary-500 text-gray-900 dark:text-gray-100 focus:ring-primary-500'
|
||||||
iconClassName='w-4 h-4'
|
// iconClassName='w-4 h-4'
|
||||||
/>
|
// />
|
||||||
);
|
// );
|
||||||
}
|
// }
|
||||||
};
|
// };
|
||||||
|
|
||||||
const renderShareButton = () => {
|
const renderShareButton = () => {
|
||||||
const canShare = 'share' in navigator;
|
const canShare = 'share' in navigator;
|
||||||
|
@ -796,7 +796,7 @@ const Header: React.FC<IHeader> = ({ account }) => {
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{renderShareButton()}
|
{renderShareButton()}
|
||||||
{renderMessageButton()}
|
{/* {renderMessageButton()} */}
|
||||||
|
|
||||||
<ActionButton account={account} />
|
<ActionButton account={account} />
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in a new issue