mirror of
https://github.com/bitsocialnet/5chan.git
synced 2026-08-03 07:41:04 +02:00
fix(post): remove "user was banned for this post" because it's only visible to mods at the moment
This commit is contained in:
@@ -217,8 +217,9 @@ const PostMedia = ({ post }: PostProps) => {
|
||||
};
|
||||
|
||||
const PostMessage = ({ post }: PostProps) => {
|
||||
const { cid, content, commentAuthor, deleted, edit, original, parentCid, postCid, reason, removed, spoiler, state, subplebbitAddress } = post || {};
|
||||
const banned = !!commentAuthor?.banExpiresAt;
|
||||
const { cid, content, deleted, edit, original, parentCid, postCid, reason, removed, spoiler, state, subplebbitAddress } = post || {};
|
||||
// TODO: commentAuthor is not available outside of editedComment, update when available
|
||||
// const banned = !!post?.commentAuthor?.banExpiresAt;
|
||||
const { t } = useTranslation();
|
||||
const params = useParams();
|
||||
const location = useLocation();
|
||||
@@ -275,7 +276,8 @@ const PostMessage = ({ post }: PostProps) => {
|
||||
)}
|
||||
</>
|
||||
)}
|
||||
{banned && (
|
||||
{/* TODO: commentAuthor is not available outside of editedComment, update when available */}
|
||||
{/* {banned && (
|
||||
<span className={styles.removedContent}>
|
||||
<br />
|
||||
<br />
|
||||
@@ -288,7 +290,7 @@ const PostMessage = ({ post }: PostProps) => {
|
||||
})}${reason ? `. ${_.capitalize(t('reason'))}: "${reason}"` : ''}`}
|
||||
/>
|
||||
</span>
|
||||
)}
|
||||
)} */}
|
||||
{!isReply && content.length > 1000 && !isInPostView && (
|
||||
<span className={styles.abbr}>
|
||||
<br />
|
||||
|
||||
@@ -153,7 +153,8 @@ const ReplyBacklinks = ({ post }: PostProps) => {
|
||||
const PostMessageMobile = ({ post }: PostProps) => {
|
||||
const { t } = useTranslation();
|
||||
const { cid, commentAuthor, content, deleted, edit, original, parentCid, postCid, reason, removed, spoiler, state, subplebbitAddress } = post || {};
|
||||
const banned = !!commentAuthor?.banExpiresAt;
|
||||
// TODO: commentAuthor is not available outside of editedComment, update when available
|
||||
// const banned = !!post?.commentAuthor?.banExpiresAt;
|
||||
const [showOriginal, setShowOriginal] = useState(false);
|
||||
|
||||
const params = useParams();
|
||||
@@ -211,7 +212,8 @@ const PostMessageMobile = ({ post }: PostProps) => {
|
||||
)}
|
||||
</>
|
||||
)}
|
||||
{banned && (
|
||||
{/* TODO: commentAuthor is not available outside of editedComment, update when available */}
|
||||
{/* {banned && (
|
||||
<span className={styles.removedContent}>
|
||||
<br />
|
||||
<br />
|
||||
@@ -224,7 +226,7 @@ const PostMessageMobile = ({ post }: PostProps) => {
|
||||
})}${reason ? `. ${_.capitalize(t('reason'))}: "${reason}"` : ''}`}
|
||||
/>
|
||||
</span>
|
||||
)}
|
||||
)} */}
|
||||
{!isReply && content.length > 1000 && !isInPostView && (
|
||||
<span className={styles.abbr}>
|
||||
<br />
|
||||
|
||||
Reference in New Issue
Block a user