CommentContent added to the admin side

This commit is contained in:
okbel
2018-03-01 18:38:14 -03:00
parent 0055c82166
commit 8192a3bfc4
3 changed files with 23 additions and 13 deletions
@@ -133,7 +133,6 @@
color: #063b9a;
cursor: pointer;
font-weight: normal;
margin-left: 10px;
white-space: nowrap;
&:hover {
@@ -184,3 +183,9 @@
}
}
}
.commentContent {
height: 100%;
flex: 1;
display: flex;
}
@@ -64,6 +64,12 @@ class Comment extends React.Component {
const selectionStateCSS = selected ? 'mdl-shadow--16dp' : 'mdl-shadow--2dp';
const queryData = { root, comment, asset: comment.asset };
const formatterSettings = {
suspectWords: settings.wordlist.suspect,
bannedWords: settings.wordlist.banned,
body: comment.body,
};
return (
<li
tabIndex={0}
@@ -126,11 +132,15 @@ class Comment extends React.Component {
<CommentAnimatedEdit body={comment.body}>
<div className={styles.itemBody}>
<div className={styles.body}>
<CommentFormatter
suspectWords={settings.wordlist.suspect}
bannedWords={settings.wordlist.banned}
className="talk-admin-comment"
body={comment.body}
<Slot
fill="adminCommentContent"
data={data}
className={cn(styles.commentContent, 'talk-admin-comment')}
clearHeightCache={clearHeightCache}
queryData={queryData}
slotSize={1}
defaultComponent={CommentFormatter}
{...formatterSettings}
/>
<a
className={styles.external}
@@ -140,13 +150,7 @@ class Comment extends React.Component {
<Icon name="open_in_new" /> {t('comment.view_context')}
</a>
</div>
<Slot
fill="adminCommentContent"
data={data}
clearHeightCache={clearHeightCache}
queryData={queryData}
slotSize={1}
/>
<div className={styles.sideActions}>
<IfHasLink text={comment.body}>
<span className={styles.hasLinks}>
@@ -8,4 +8,5 @@
border: 1px solid #9E9E9E;
width: 100%;
box-sizing: border-box;
height: 100%;
}