+ : {lang.t('streams.empty_result')}
+ }
);
}
diff --git a/client/coral-admin/src/translations.json b/client/coral-admin/src/translations.json
index 13d482d6c..f3deb6792 100644
--- a/client/coral-admin/src/translations.json
+++ b/client/coral-admin/src/translations.json
@@ -7,7 +7,7 @@
"admin": "Administrator",
"moderator": "Moderator",
"role": "Select role...",
- "no-results": "No users found with that user name or email address.",
+ "no-results": "No users found with that user name or email address. They're hiding!",
"status": "Status",
"select-status": "Select status...",
"active": "Active",
@@ -32,6 +32,7 @@
"prevcomment": "Go to the previous comment",
"singleview": "Toggle single comment edit view",
"thismenu": "Open this menu",
+ "emptyqueue": "No more comments to moderate! You're all caught up. Go have some ☕️",
"showshortcuts": "Show Shortcuts"
},
"comment": {
@@ -114,6 +115,7 @@
"comment_count": "Comments"
},
"streams": {
+ "empty_result": "No assets match this search. Maybe try widening your search?",
"search": "Search",
"filter-streams": "Filter Streams",
"stream-status": "Stream Status",
@@ -153,6 +155,7 @@
"flagged": "marcado",
"shortcuts": "Atajos de teclado",
"close": "Cerrar",
+ "emptyqueue": "No se encontro ningún usuario. Están escondidos.",
"showshortcuts": "Mostrar atajos"
},
"comment": {
@@ -222,6 +225,7 @@
"comment_count": "Comentarios"
},
"streams": {
+ "empty_result": "No se encuentro articulo con esta busqueda. Tal vez extender la busqueda?",
"search": "",
"filter-streams": "",
"stream-status": "",
diff --git a/client/coral-embed-stream/src/Comment.js b/client/coral-embed-stream/src/Comment.js
index 9d679473e..8371cec45 100644
--- a/client/coral-embed-stream/src/Comment.js
+++ b/client/coral-embed-stream/src/Comment.js
@@ -177,7 +177,7 @@ class Comment extends React.Component {
comment.replies &&
comment.replies.length}
diff --git a/client/coral-embed-stream/src/Embed.js b/client/coral-embed-stream/src/Embed.js
index a7c4dcb38..5e979d243 100644
--- a/client/coral-embed-stream/src/Embed.js
+++ b/client/coral-embed-stream/src/Embed.js
@@ -12,6 +12,7 @@ const {fetchAssetSuccess} = assetActions;
import {queryStream} from 'coral-framework/graphql/queries';
import {postComment, postFlag, postLike, deleteAction} from 'coral-framework/graphql/mutations';
import {editName} from 'coral-framework/actions/user';
+import {updateCountCache} from 'coral-framework/actions/asset';
import {Notification, notificationActions, authActions, assetActions, pym} from 'coral-framework';
import Stream from './Stream';
@@ -28,6 +29,7 @@ import SettingsContainer from 'coral-settings/containers/SettingsContainer';
import RestrictedContent from 'coral-framework/components/RestrictedContent';
import ConfigureStreamContainer from 'coral-configure/containers/ConfigureStreamContainer';
import LoadMore from './LoadMore';
+import NewCount from './NewCount';
class Embed extends Component {
@@ -82,7 +84,7 @@ class Embed extends Component {
render () {
const {activeTab} = this.state;
- const {closedAt} = this.props.asset;
+ const {closedAt, countCache = {}} = this.props.asset;
const {loading, asset, refetch} = this.props.data;
const {loggedIn, isAdmin, user, showSignInDialog, signInOffset} = this.props.auth;
@@ -98,6 +100,11 @@ class Embed extends Component {
return ;
}
+ // Find the created_at date of the first comment. If no comments exist, set the date to a week ago.
+ const firstCommentDate = asset.comments[0]
+ ? asset.comments[0].created_at
+ : new Date(Date.now() - 1000 * 60 * 60 * 24 * 7).toISOString();
+
return (