Don't show dislike if unwanted / views use the correct icon now / colours adjusted

This commit is contained in:
Michael 2023-11-09 18:22:25 +00:00
parent c261bf8759
commit 00395118f9
4 changed files with 11 additions and 6 deletions

View file

@ -458,7 +458,8 @@ class Post
$title = '';
}
if (DI::pConfig()->get(DI::userSession()->getLocalUserId(), 'system', 'hide_dislike')) {
$hide_dislike = DI::pConfig()->get(DI::userSession()->getLocalUserId(), 'system', 'hide_dislike');
if ($hide_dislike) {
$buttons['dislike'] = false;
}
@ -593,6 +594,7 @@ class Post
'vote' => $buttons,
'like_html' => $responses['like']['output'],
'dislike_html' => $responses['dislike']['output'],
'hide_dislike' => $hide_dislike,
'emojis' => $emojis,
'quoteshares' => $this->getQuoteShares($item['quoteshares']),
'reactions' => $reactions,

View file

@ -19,5 +19,5 @@ $background_color = '#000000';
$contentbg_transp = '0';
$font_color = '#cccccc';
$font_color_darker = '#acacac';
$font_color_lighter = '#cdcdcd';
$font_color_lighter = '#444444';
$background_image = '';

View file

@ -33,5 +33,5 @@ switch ($scheme_accent) {
$contentbg_transp = 4;
$font_color = '#e4e4e4';
$font_color_darker = '#dcdcdc';
$font_color_lighter = '#ababab';
$font_color_lighter = '#555555';
$background_image = '';

View file

@ -352,13 +352,17 @@ as the value of $top_child_total (this is done at the end of this file)
{{if $item.vote.dislike}}
<button type="button" class="btn-link button-likes{{if $item.responses.dislike.self}} active" aria-pressed="true{{/if}}" id="dislike-{{$item.id}}" title="{{$item.vote.dislike.0}}" onclick="doActivityItemAction({{$item.id}}, 'dislike'{{if $item.responses.dislike.self}}, true{{/if}});" ><i class="fa fa-thumbs-down" aria-hidden="true"></i></button>
<span title="{{$item.responses.dislike.title}}">{{$item.responses.dislike.total}}</span>
{{else}}
{{elseif !$item.hide_dislike}}
<button type="button" class="btn-link button-likes" id="dislike-{{$item.id}}" title="{{$item.vote.dislike.0}}" disabled><i class="fa fa-thumbs-o-down" aria-hidden="true"></i></button>
{{/if}}
</span>
{{foreach $item.reactions as $emoji}}
<span class="wall-item-emoji" title="{{$emoji.title}}">{{$emoji.emoji}} {{$emoji.total}}</span>
{{if $emoji.icon.fa}}
<span class="wall-item-emoji" title="{{$emoji.title}}"><i class="fa {{$emoji.icon.fa}}" aria-hidden="true"></i> {{$emoji.total}}</span>
{{else}}
<span class="wall-item-emoji" title="{{$emoji.title}}">{{$emoji.emoji}} {{$emoji.total}}</span>
{{/if}}
{{/foreach}}
{{/if}}
@ -495,7 +499,6 @@ as the value of $top_child_total (this is done at the end of this file)
</span>
{{/if}}
</span>
<div class="wall-item-actions-items btn-toolbar btn-group visible-xs" role="group">
<div class="wall-item-actions-row">
{{* Button to open the comment text field *}}