pl-fe: add some feedback on deleted post, remove unused feature
Signed-off-by: mkljczk <git@mkljczk.pl>
This commit is contained in:
@@ -85,7 +85,6 @@ interface IAccount {
|
||||
/** Override other actions for specificity like mute/unmute. */
|
||||
actionType?: 'muting' | 'blocking' | 'follow_request' | 'biting';
|
||||
avatarSize?: number;
|
||||
hidden?: boolean;
|
||||
hideActions?: boolean;
|
||||
id?: string;
|
||||
onActionClick?: (account: AccountSchema) => void;
|
||||
@@ -115,7 +114,6 @@ const Account = ({
|
||||
actionTitle,
|
||||
actionAlignment = 'center',
|
||||
avatarSize = 42,
|
||||
hidden = false,
|
||||
hideActions = false,
|
||||
onActionClick,
|
||||
showAccountHoverCard = true,
|
||||
@@ -181,15 +179,6 @@ const Account = ({
|
||||
return null;
|
||||
}
|
||||
|
||||
if (hidden) {
|
||||
return (
|
||||
<>
|
||||
{account.display_name}
|
||||
{account.username}
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
if (withDate) timestamp = account.created_at;
|
||||
|
||||
const LinkEl: any = withLinkToProfile ? Link : 'div';
|
||||
|
||||
@@ -29,6 +29,7 @@ import StatusLanguagePicker from './status-language-picker';
|
||||
import StatusReactionsBar from './status-reactions-bar';
|
||||
import StatusReplyMentions from './status-reply-mentions';
|
||||
import StatusInfo from './statuses/status-info';
|
||||
import Tombstone from './tombstone';
|
||||
|
||||
const messages = defineMessages({
|
||||
reblogged_by: { id: 'status.reblogged_by', defaultMessage: '{name} reposted' },
|
||||
@@ -40,7 +41,6 @@ interface IStatus {
|
||||
status: SelectedStatus;
|
||||
onClick?: () => void;
|
||||
muted?: boolean;
|
||||
hidden?: boolean;
|
||||
unread?: boolean;
|
||||
onMoveUp?: (statusId: string, featured?: boolean) => void;
|
||||
onMoveDown?: (statusId: string, featured?: boolean) => void;
|
||||
@@ -65,7 +65,6 @@ const Status: React.FC<IStatus> = (props) => {
|
||||
onMoveUp,
|
||||
onMoveDown,
|
||||
muted,
|
||||
hidden,
|
||||
featured,
|
||||
unread,
|
||||
hideActionBar,
|
||||
@@ -95,7 +94,7 @@ const Status: React.FC<IStatus> = (props) => {
|
||||
|
||||
// Track height changes we know about to compensate scrolling.
|
||||
useEffect(() => {
|
||||
didShowCard.current = Boolean(!muted && !hidden && status?.card);
|
||||
didShowCard.current = Boolean(!muted && status?.card);
|
||||
}, []);
|
||||
|
||||
const handleClick = (e?: React.MouseEvent) => {
|
||||
@@ -299,16 +298,13 @@ const Status: React.FC<IStatus> = (props) => {
|
||||
|
||||
if (!status) return null;
|
||||
|
||||
if (hidden) {
|
||||
return (
|
||||
<div ref={node}>
|
||||
<>
|
||||
{actualStatus.account.display_name || actualStatus.account.username}
|
||||
{actualStatus.content}
|
||||
</>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
if (status.deleted) return (
|
||||
<Tombstone
|
||||
id={status.id}
|
||||
onMoveUp={onMoveUp}
|
||||
onMoveDown={onMoveDown}
|
||||
/>
|
||||
);
|
||||
|
||||
if (filtered && status.showFiltered !== false) {
|
||||
const minHandlers = muted ? undefined : {
|
||||
|
||||
Reference in New Issue
Block a user