);
}
diff --git a/client/coral-admin/src/index.js b/client/coral-admin/src/index.js
index 306461dd0..00190847a 100644
--- a/client/coral-admin/src/index.js
+++ b/client/coral-admin/src/index.js
@@ -7,6 +7,9 @@ import store from './services/store';
import App from './components/App';
+import 'react-mdl/extra/material.css';
+import 'react-mdl/extra/material.js';
+
render(
diff --git a/client/coral-admin/src/translations.json b/client/coral-admin/src/translations.json
index 5b15564d7..7219a22ca 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": {
@@ -113,6 +114,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",
@@ -152,6 +154,7 @@
"flagged": "marcado",
"shortcuts": "Atajos de teclado",
"close": "Cerrar",
+ "emptyqueue": "No se encontro ningún usuario. Están escondidos.",
"showshortcuts": "Mostrar atajos"
},
"comment": {
@@ -220,6 +223,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 1d460d580..7262d10ed 100644
--- a/client/coral-embed-stream/src/Comment.js
+++ b/client/coral-embed-stream/src/Comment.js
@@ -180,7 +180,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 7010618ca..ac9c09eac 100644
--- a/client/coral-embed-stream/src/Embed.js
+++ b/client/coral-embed-stream/src/Embed.js
@@ -2,6 +2,9 @@ import React, {Component} from 'react';
import {compose} from 'react-apollo';
import {connect} from 'react-redux';
import isEqual from 'lodash/isEqual';
+import I18n from 'coral-framework/modules/i18n/i18n';
+import translations from 'coral-framework/translations';
+const lang = new I18n(translations);
import {TabBar, Tab, TabContent, Spinner} from 'coral-ui';
@@ -12,6 +15,7 @@ const {fetchAssetSuccess} = assetActions;
import {queryStream} from 'coral-framework/graphql/queries';
import {postComment, postFlag, postLike, postDontAgree, 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';
@@ -24,10 +28,11 @@ import UserBox from 'coral-sign-in/components/UserBox';
import SignInContainer from 'coral-sign-in/containers/SignInContainer';
import SuspendedAccount from 'coral-framework/components/SuspendedAccount';
import ChangeUsernameContainer from '../../coral-sign-in/containers/ChangeUsernameContainer';
-import SettingsContainer from 'coral-settings/containers/SettingsContainer';
+import ProfileContainer from 'coral-settings/containers/ProfileContainer';
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 +87,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,12 +103,17 @@ 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 (
-
- {
-
- // Hiding display of users ID unless there's a use case for it.
- //
{userData.profiles.map(profile => profile.id)}
- }
-
-);
diff --git a/client/coral-settings/containers/SettingsContainer.js b/client/coral-settings/containers/ProfileContainer.js
similarity index 92%
rename from client/coral-settings/containers/SettingsContainer.js
rename to client/coral-settings/containers/ProfileContainer.js
index 9e72cdadc..4a98ed8ff 100644
--- a/client/coral-settings/containers/SettingsContainer.js
+++ b/client/coral-settings/containers/ProfileContainer.js
@@ -8,13 +8,13 @@ import {myCommentHistory} from 'coral-framework/graphql/queries';
import {link} from 'coral-framework/services/PymConnection';
import NotLoggedIn from '../components/NotLoggedIn';
import {Spinner} from 'coral-ui';
-import SettingsHeader from '../components/SettingsHeader';
+import ProfileHeader from '../components/ProfileHeader';
import CommentHistory from 'coral-plugin-history/CommentHistory';
import translations from '../translations';
const lang = new I18n(translations);
-class SettingsContainer extends Component {
+class ProfileContainer extends Component {
constructor (props) {
super(props);
this.state = {
@@ -44,7 +44,7 @@ class SettingsContainer extends Component {
return (
-
+
{
// Hiding bio until moderation can get figured out
@@ -88,4 +88,4 @@ const mapDispatchToProps = () => ({
export default compose(
connect(mapStateToProps, mapDispatchToProps),
myCommentHistory
-)(SettingsContainer);
+)(ProfileContainer);
diff --git a/client/coral-settings/translations.json b/client/coral-settings/translations.json
index 2a827a4f0..945d71b87 100644
--- a/client/coral-settings/translations.json
+++ b/client/coral-settings/translations.json
@@ -1,14 +1,22 @@
{
"en":{
- "userNoComment": "This user has not yet left a comment.",
+ "profile": "Profile",
+ "userNoComment": "You've never left a comment. Join the conversation!",
"allComments": "All Comments",
"profileSettings": "Profile Settings",
- "myCommentHistory": "My comment History"
+ "myCommentHistory": "My comment History",
+ "signIn": "Sign in",
+ "toAccess": " to access Profile",
+ "fromSettingsPage": "From the Profile Page you can see your comment history."
},
"es":{
- "userNoComment": "Aún no ha escrito ningún comentario.",
+ "profile": "Perfil",
+ "userNoComment": "No has dejado áun ningún comentario. ¡Unete a la conversación!",
"allComments": "Todos los comentarios",
"profileSettings": "Configuración del perfil",
- "myCommentHistory": "Mi historial de comentarios"
+ "myCommentHistory": "Mi historial de comentarios",
+ "signIn": "Entrar",
+ "toAccess": "para acceder a al perfil",
+ "fromSettingsPage": "Desde la peagina de configuración puede ver su historia de comentarios."
}
}
diff --git a/client/coral-sign-in/components/CreateUsernameDialog.js b/client/coral-sign-in/components/CreateUsernameDialog.js
index d245b38ac..d0e348046 100644
--- a/client/coral-sign-in/components/CreateUsernameDialog.js
+++ b/client/coral-sign-in/components/CreateUsernameDialog.js
@@ -3,14 +3,18 @@ import TextField from 'coral-ui/components/TextField';
import Alert from './Alert';
import Button from 'coral-ui/components/Button';
import {Dialog} from 'coral-ui';
+import FakeComment from './FakeComment';
+
import styles from './styles.css';
+
import I18n from 'coral-framework/modules/i18n/i18n';
import translations from '../translations';
const lang = new I18n(translations);
-const CreateUsernameDialog = ({open, handleClose, offset, formData, handleSubmitUsername, handleChange, ...props}) => (
+const CreateUsernameDialog = ({open, handleClose, offset, formData, handleSubmitUsername, handleChange, ...props}) => {
+ return (
-
+
{lang.t('createdisplay.yourusername')}
+
+
{lang.t('createdisplay.ifyoudontchangeyourname')}
{ props.auth.error && {props.auth.error} }
-);
+ );
+};
export default CreateUsernameDialog;
diff --git a/client/coral-sign-in/components/FakeComment.js b/client/coral-sign-in/components/FakeComment.js
new file mode 100644
index 000000000..b5af6bf1c
--- /dev/null
+++ b/client/coral-sign-in/components/FakeComment.js
@@ -0,0 +1,66 @@
+import React from 'react';
+import styles from 'coral-embed-stream/src/Comment.css';
+
+import AuthorName from 'coral-plugin-author-name/AuthorName';
+import Content from 'coral-plugin-commentcontent/CommentContent';
+import PubDate from 'coral-plugin-pubdate/PubDate';
+import {ReplyButton} from 'coral-plugin-replies';
+
+import I18n from 'coral-framework/modules/i18n/i18n';
+import translations from '../translations';
+
+const lang = new I18n(translations);
+
+class FakeComment extends React.Component {
+ constructor (props) {
+ super(props);
+ }
+
+ render () {
+ const {username, created_at, body} = this.props;
+
+ return (
+