diff --git a/apps/comments-ui/src/components/CommentsBox.js b/apps/comments-ui/src/components/CommentsBox.js index 3ca7511a6d..73d2cc4556 100644 --- a/apps/comments-ui/src/components/CommentsBox.js +++ b/apps/comments-ui/src/components/CommentsBox.js @@ -1,6 +1,7 @@ import React, {useContext} from 'react'; import AppContext from '../AppContext'; import NotSignedInBox from './NotSignedInBox'; +import Loading from './Loading'; import Form from './Form'; import Comment from './Comment'; import Pagination from './Pagination'; @@ -41,7 +42,7 @@ const CommentsBox = (props) => { const {accentColor, pagination, member, comments} = useContext(AppContext); - const commentsElements = !comments ? 'Loading...' : comments.slice().reverse().map(comment => ); + const commentsElements = comments.slice().reverse().map(comment => ); const containerClass = darkMode() ? 'dark' : ''; const commentsCount = comments.length; @@ -52,12 +53,16 @@ const CommentsBox = (props) => { return (
-
- {commentsElements} -
-
- { member ?
: } -
+ {comments ? + <> +
+ {commentsElements} +
+
+ { member ? : } +
+ + : }
); }; diff --git a/apps/comments-ui/src/components/Loading.js b/apps/comments-ui/src/components/Loading.js new file mode 100644 index 0000000000..c715252de8 --- /dev/null +++ b/apps/comments-ui/src/components/Loading.js @@ -0,0 +1,12 @@ +import React from 'react'; +import {ReactComponent as SpinnerIcon} from '../images/icons/spinner.svg'; + +function Loading() { + return ( +
+ +
+ ); +} + +export default Loading; diff --git a/apps/comments-ui/src/components/modals/ReportDialog.js b/apps/comments-ui/src/components/modals/ReportDialog.js index 0181fcf6d1..59a1d28251 100644 --- a/apps/comments-ui/src/components/modals/ReportDialog.js +++ b/apps/comments-ui/src/components/modals/ReportDialog.js @@ -18,14 +18,14 @@ const ReportDialog = (props) => { let buttonIcon = null; if (props.progress === 'sending') { - buttonIcon = ; + buttonIcon = ; } else if (props.progress === 'sent') { buttonIcon = ; } return ( -

You sure you want to report?

+

You sure you want to report?

You request will be sent to the owner of this site.