projects
/
lemmy-ui.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
14aef0e
)
Hide downvote on mobile when downvotes disabled
author
m52go
<mfiver@gmail.com>
Tue, 17 Nov 2020 19:15:55 +0000
(19:15 +0000)
committer
GitHub
<noreply@github.com>
Tue, 17 Nov 2020 19:15:55 +0000
(19:15 +0000)
To address #79.
src/shared/components/post-listing.tsx
patch
|
blob
|
history
diff --git
a/src/shared/components/post-listing.tsx
b/src/shared/components/post-listing.tsx
index 809b8d12589b14779d9250085f0c90fd0d39273e..6e5e867f3c9a425b74228f74578e28b49035630b 100644
(file)
--- a/
src/shared/components/post-listing.tsx
+++ b/
src/shared/components/post-listing.tsx
@@
-562,7
+562,7
@@
export class PostListing extends Component<PostListingProps, PostListingState> {
</svg>
{this.state.upvotes}
</button>
- <button
+
{this.props.enableDownvotes && (
<button
className={`ml-2 btn-animate btn py-0 pl-1 ${
this.state.my_vote == -1 ? 'text-danger' : 'text-muted'
}`}
@@
-576,6
+576,7
@@
export class PostListing extends Component<PostListingProps, PostListingState> {
<span>{this.state.downvotes}</span>
)}
</button>
+ )}
</div>
<button
class="btn btn-link btn-animate text-muted py-0 pl-1 pr-0"