diff --git a/package.json b/package.json index c3167a0bd..797b97589 100644 --- a/package.json +++ b/package.json @@ -46,7 +46,8 @@ "electron-log": "^2.2.12", "electron-updater": "^4.0.6", "express": "^4.16.4", - "keytar": "^4.4.1" + "keytar": "^4.4.1", + "tiny-relative-date": "^1.3.0" }, "devDependencies": { "@babel/core": "^7.0.0", @@ -122,7 +123,7 @@ "jsmediatags": "^3.8.1", "json-loader": "^0.5.4", "lbry-format": "https://github.com/lbryio/lbry-format.git", - "lbry-redux": "lbryio/lbry-redux#3c862e72b36e620155b9c968be9b2bcbd9e0580c", + "lbry-redux": "lbryio/lbry-redux#141593500693a93db74c62ef5a9fe67b43896603", "lbryinc": "lbryio/lbryinc#43d382d9b74d396a581a74d87e4c53105e04f845", "lint-staged": "^7.0.2", "localforage": "^1.7.1", @@ -148,7 +149,7 @@ "react-dom": "^16.8.2", "react-feather": "^1.0.8", "react-ga": "^2.5.7", - "react-hot-loader": "^4.7.2", + "react-hot-loader": "^4.11.1", "react-modal": "^3.1.7", "react-paginate": "^5.2.1", "react-pose": "^4.0.5", diff --git a/src/ui/component/comment/index.js b/src/ui/component/comment/index.js new file mode 100644 index 000000000..ec92bc310 --- /dev/null +++ b/src/ui/component/comment/index.js @@ -0,0 +1,7 @@ +import { connect } from 'react-redux'; +import Comment from './view'; + +export default connect( + null, + null +)(Comment); diff --git a/src/ui/component/comment/view.jsx b/src/ui/component/comment/view.jsx new file mode 100644 index 000000000..096f35642 --- /dev/null +++ b/src/ui/component/comment/view.jsx @@ -0,0 +1,36 @@ +// @flow +import React from 'react'; +import relativeDate from 'tiny-relative-date'; + +type Props = { + author: string, + message: string, + timePosted: number, +}; + +function Comment(props: Props) { + const { author, timePosted, message } = props; + + return ( +
{message}
+ {/* The following is for adding threaded replies, upvoting and downvoting */} + {/*- {user - ? __('Your support has been added. You will be notified when comments are available.') - : __('Your support has been added. Comments are coming soon.')} -
- )} ); } diff --git a/src/ui/component/fileRender/view.jsx b/src/ui/component/fileRender/view.jsx index bff166e27..f8e688d40 100644 --- a/src/ui/component/fileRender/view.jsx +++ b/src/ui/component/fileRender/view.jsx @@ -1,43 +1,57 @@ // @flow import { remote } from 'electron'; -import React, { Suspense } from 'react'; +import React from 'react'; import LoadingScreen from 'component/common/loading-screen'; import VideoViewer from 'component/viewers/videoViewer'; const AudioViewer = React.lazy<*>(() => - import(/* webpackChunkName: "audioViewer" */ - 'component/viewers/audioViewer') + import( + /* webpackChunkName: "audioViewer" */ + 'component/viewers/audioViewer' + ) ); const DocumentViewer = React.lazy<*>(() => - import(/* webpackChunkName: "documentViewer" */ - 'component/viewers/documentViewer') + import( + /* webpackChunkName: "documentViewer" */ + 'component/viewers/documentViewer' + ) ); const DocxViewer = React.lazy<*>(() => - import(/* webpackChunkName: "docxViewer" */ - 'component/viewers/docxViewer') + import( + /* webpackChunkName: "docxViewer" */ + 'component/viewers/docxViewer' + ) ); const HtmlViewer = React.lazy<*>(() => - import(/* webpackChunkName: "htmlViewer" */ - 'component/viewers/htmlViewer') + import( + /* webpackChunkName: "htmlViewer" */ + 'component/viewers/htmlViewer' + ) ); const PdfViewer = React.lazy<*>(() => - import(/* webpackChunkName: "pdfViewer" */ - 'component/viewers/pdfViewer') + import( + /* webpackChunkName: "pdfViewer" */ + 'component/viewers/pdfViewer' + ) ); // @if TARGET='app' const ComicBookViewer = React.lazy<*>(() => - import(/* webpackChunkName: "comicBookViewer" */ - 'component/viewers/comicBookViewer') + import( + /* webpackChunkName: "comicBookViewer" */ + 'component/viewers/comicBookViewer' + ) ); const ThreeViewer = React.lazy<*>(() => - import(/* webpackChunkName: "threeViewer" */ - 'component/viewers/threeViewer') + import( + /* webpackChunkName: "threeViewer" */ + 'component/viewers/threeViewer' + ) ); // @endif @@ -174,7 +188,7 @@ class FileRender extends React.PureComponent