nicolium: indicate unavailable parent posts on akkoma
Signed-off-by: nicole mikołajczyk <git@mkljczk.pl>
This commit is contained in:
@ -9,7 +9,7 @@ import { useModalsActions } from '@/stores/modals';
|
||||
import type { NormalizedStatus as Status } from '@/queries/statuses/normalize';
|
||||
|
||||
interface IStatusReplyMentions {
|
||||
status: Pick<Status, 'in_reply_to_id' | 'id' | 'mentions'>;
|
||||
status: Pick<Status, 'in_reply_to_id' | 'in_reply_to_account_id' | 'id' | 'mentions'>;
|
||||
hoverable?: boolean;
|
||||
}
|
||||
|
||||
@ -23,6 +23,15 @@ const StatusReplyMentions: React.FC<IStatusReplyMentions> = ({ status, hoverable
|
||||
};
|
||||
|
||||
if (!status.in_reply_to_id) {
|
||||
// Used as placeholder by Akkoma
|
||||
// https://akkoma.dev/AkkomaGang/akkoma/src/branch/develop/lib/pleroma/web/mastodon_api/views/status_view.ex#L31
|
||||
if (status.in_reply_to_account_id === '_') {
|
||||
return (
|
||||
<div className='⁂-status-reply-mentions ⁂-status-reply-mentions--unavailable'>
|
||||
<FormattedMessage id='reply_mentions.reply_empty' defaultMessage='Replying to post' />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
@ -57,6 +57,10 @@
|
||||
.dark & {
|
||||
color: rgb(var(--color-gray-600));
|
||||
}
|
||||
|
||||
&--unavailable {
|
||||
text-decoration: line-through;
|
||||
}
|
||||
}
|
||||
|
||||
.⁂-status,
|
||||
|
||||
Reference in New Issue
Block a user