diff options
author | Dessalines <tyhou13@gmx.com> | 2020-02-09 11:44:24 -0500 |
---|---|---|
committer | Dessalines <tyhou13@gmx.com> | 2020-02-09 11:44:24 -0500 |
commit | fd8814677ec81eff5358c102b6b424ec1c23c2fb (patch) | |
tree | b715aedaf6b06ccf6bcbb10c099c2d794b2c819c /ui/src/components/community.tsx | |
parent | 56cd103209605471b27aa5a854cc3b051f2a65f5 (diff) |
Live post and comment resorting. Fixes #522
- Moving sorting to utils.
Diffstat (limited to 'ui/src/components/community.tsx')
-rw-r--r-- | ui/src/components/community.tsx | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/ui/src/components/community.tsx b/ui/src/components/community.tsx index 32392ca1..e28c99bc 100644 --- a/ui/src/components/community.tsx +++ b/ui/src/components/community.tsx @@ -178,9 +178,17 @@ export class Community extends Component<any, State> { listings() { return this.state.dataType == DataType.Post ? ( - <PostListings posts={this.state.posts} removeDuplicates /> + <PostListings + posts={this.state.posts} + removeDuplicates + sort={this.state.sort} + /> ) : ( - <CommentNodes nodes={commentsToFlatNodes(this.state.comments)} noIndent /> + <CommentNodes + nodes={commentsToFlatNodes(this.state.comments)} + noIndent + sortType={this.state.sort} + /> ); } |