diff --git a/client/coral-embed-stream/src/components/Comment.js b/client/coral-embed-stream/src/components/Comment.js index e5272f2db..9d3cb0218 100644 --- a/client/coral-embed-stream/src/components/Comment.js +++ b/client/coral-embed-stream/src/components/Comment.js @@ -2,7 +2,7 @@ import React from 'react'; import PropTypes from 'prop-types'; import TagLabel from 'talk-plugin-tag-label/TagLabel'; -import PubDate from 'coral-framework/components/PubDate'; +import CommentTimestamp from 'coral-framework/components/CommentTimestamp'; import {ReplyBox, ReplyButton} from 'talk-plugin-replies'; import {FlagComment} from 'talk-plugin-flags'; import {can} from 'coral-framework/services/perms'; @@ -467,7 +467,7 @@ export default class Comment extends React.Component { ( -
+const CommentTimestamp = ({className, created_at}) => ( +
{timeago(created_at)}
); -PubDate.propTypes = { +CommentTimestamp.propTypes = { className: PropTypes.string, created_at: PropTypes.string, }; -export default PubDate; +export default CommentTimestamp; diff --git a/client/talk-plugin-history/Comment.js b/client/talk-plugin-history/Comment.js index 1f7979018..7532548cf 100644 --- a/client/talk-plugin-history/Comment.js +++ b/client/talk-plugin-history/Comment.js @@ -3,7 +3,7 @@ import PropTypes from 'prop-types'; import {Icon} from '../coral-ui'; import styles from './Comment.css'; import Slot from 'coral-framework/components/Slot'; -import PubDate from 'coral-framework/components/PubDate'; +import CommentTimestamp from 'coral-framework/components/CommentTimestamp'; import CommentContent from '../coral-embed-stream/src/components/CommentContent'; import cn from 'classnames'; import {getTotalReactionsCount} from 'coral-framework/utils'; @@ -62,7 +62,7 @@ class Comment extends React.Component { (
{username} - +
{body}
diff --git a/plugins/talk-plugin-featured-comments/client/components/Comment.js b/plugins/talk-plugin-featured-comments/client/components/Comment.js index 8c355192f..a8c7cb6f1 100644 --- a/plugins/talk-plugin-featured-comments/client/components/Comment.js +++ b/plugins/talk-plugin-featured-comments/client/components/Comment.js @@ -2,7 +2,7 @@ import React from 'react'; import cn from 'classnames'; import styles from './Comment.css'; import {t} from 'plugin-api/beta/client/services'; -import {Slot, CommentAuthorName, PubDate} from 'plugin-api/beta/client/components'; +import {Slot, CommentAuthorName, CommentTimestamp} from 'plugin-api/beta/client/components'; import {Icon} from 'plugin-api/beta/client/components/ui'; import {pluginName} from '../../package.json'; import FeaturedButton from '../containers/FeaturedButton'; @@ -36,8 +36,8 @@ class Comment extends React.Component {