Displaying author names and bios.

This commit is contained in:
David Jay
2017-01-24 11:49:59 -05:00
parent 9fd184f638
commit 9fbd1d3a77
3 changed files with 7 additions and 6 deletions
+3 -5
View File
@@ -9,7 +9,7 @@
import React, {PropTypes} from 'react';
import PermalinkButton from 'coral-plugin-permalinks/PermalinkButton';
// import AuthorName from '../../coral-plugin-author-name/AuthorName';
import AuthorName from '../../coral-plugin-author-name/AuthorName';
import Content from '../../coral-plugin-commentcontent/CommentContent';
import PubDate from '../../coral-plugin-pubdate/PubDate';
import {ReplyBox, ReplyButton} from 'coral-plugin-replies';
@@ -81,7 +81,7 @@ class Comment extends React.Component {
id={`c_${comment.id}`}
style={{marginLeft: depth * 30}}>
<hr aria-hidden={true} />
{/* <AuthorName
<AuthorName
author={comment.user}
addNotification={this.props.addNotification}
id={comment.id}
@@ -89,9 +89,7 @@ class Comment extends React.Component {
postAction={this.props.postAction}
showSignInDialog={this.props.showSignInDialog}
deleteAction={this.props.deleteAction}
addItem={this.props.addItem}
updateItem={this.props.updateItem}
currentUser={currentUser}/>*/}
currentUser={currentUser}/>
<PubDate created_at={comment.created_at} />
<Content body={comment.body} />
@@ -5,6 +5,9 @@ fragment commentView on Comment {
user {
id
name: displayName
settings {
bio
}
}
actions {
type: action_type
@@ -36,7 +36,7 @@ export default class AuthorName extends Component {
onMouseOver={this.handleMouseOver}
onMouseLeave={this.handleMouseLeave}
>
{author && author.displayName}
{author && author.name}
{ showTooltip && <Tooltip>
<div className={`${packagename}-bio`}>
{author.settings.bio}