indicate commenter is part of forwarded group
This commit is contained in:
parent
2a7267a35a
commit
374cc26224
|
@ -131,6 +131,10 @@ export default function Comment ({
|
||||||
const bottomedOut = depth === COMMENT_DEPTH_LIMIT
|
const bottomedOut = depth === COMMENT_DEPTH_LIMIT
|
||||||
// Don't show OP badge when anon user comments on anon user posts
|
// Don't show OP badge when anon user comments on anon user posts
|
||||||
const op = root.user.name === item.user.name && Number(item.user.id) !== ANON_USER_ID
|
const op = root.user.name === item.user.name && Number(item.user.id) !== ANON_USER_ID
|
||||||
|
? 'OP'
|
||||||
|
: root.forwards.some(f => f.user.name === item.user.name) && Number(item.user.id) !== ANON_USER_ID
|
||||||
|
? 'OPG'
|
||||||
|
: null
|
||||||
const bountyPaid = root.bountyPaidTo?.includes(Number(item.id))
|
const bountyPaid = root.bountyPaidTo?.includes(Number(item.id))
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
@ -151,7 +155,7 @@ export default function Comment ({
|
||||||
commentsText='replies'
|
commentsText='replies'
|
||||||
commentTextSingular='reply'
|
commentTextSingular='reply'
|
||||||
className={`${itemStyles.other} ${styles.other}`}
|
className={`${itemStyles.other} ${styles.other}`}
|
||||||
embellishUser={op && <><span> </span><Badge bg='boost' className={`${styles.op} bg-opacity-75`}>OP</Badge></>}
|
embellishUser={op && <><span> </span><Badge bg='boost' className={`${styles.op} bg-opacity-75`}>{op}</Badge></>}
|
||||||
extraInfo={
|
extraInfo={
|
||||||
<>
|
<>
|
||||||
{includeParent && <Parent item={item} rootText={rootText} />}
|
{includeParent && <Parent item={item} rootText={rootText} />}
|
||||||
|
|
Loading…
Reference in New Issue