mirror of
https://codeberg.org/streams/streams.git
synced 2024-09-19 21:55:15 +00:00
make undo repeat work. There are still a couple of quirks to deal with but it appears to work.
This commit is contained in:
parent
5004a80f3d
commit
3449823d92
2 changed files with 8 additions and 2 deletions
|
@ -230,6 +230,7 @@ class ThreadItem
|
|||
if ($v === 'repeat') {
|
||||
$undo_repeat = $conv_responses[$v][$item['mid'] . '-mitem'];
|
||||
}
|
||||
}
|
||||
|
||||
$like_count = ((x($conv_responses['like'], $item['mid'])) ? $conv_responses['like'][$item['mid']] : '');
|
||||
$like_list = ((x($conv_responses['like'], $item['mid'])) ? $conv_responses['like'][$item['mid'] . '-l'] : '');
|
||||
|
@ -343,8 +344,13 @@ class ThreadItem
|
|||
}
|
||||
|
||||
if ($shareable) {
|
||||
if ($my_responses['repeat']) {
|
||||
$share = t('Undo repeat');
|
||||
}
|
||||
else {
|
||||
$share = t('Repeat this');
|
||||
}
|
||||
}
|
||||
|
||||
$dreport = '';
|
||||
|
||||
|
|
|
@ -161,7 +161,7 @@
|
|||
<a class="dropdown-item" href="#" onclick="jotEmbed({{$item.id}},{{$item.item_type}}); return false"><i class="generic-icons-nav fa fa-fw fa-share" title="{{$item.embed}}"></i>{{$item.embed}}</a>
|
||||
{{/if}}
|
||||
{{if $item.share}}
|
||||
<a class="dropdown-item" href="#" onclick="jotShare({{$item.id}},{{$item.item_type}}); return false"><i class="generic-icons-nav fa fa-fw fa-bullhorn" title="{{$item.share}}"></i>{{$item.share}}</a>
|
||||
<a class="dropdown-item" href="#" {{if $item.undo_repeat}}onclick="dropItem('item/drop/{{$item.undo_repeat}}', '#thread-wrapper-{{$item.id}}'); return false;"{{else}}onclick="jotShare({{$item.id}},{{$item.item_type}}); return false"{{/if}}><i class="generic-icons-nav fa fa-fw fa-bullhorn" title="{{$item.share}}"></i>{{$item.share}}</a>
|
||||
{{/if}}
|
||||
{{if $item.plink}}
|
||||
<a class="dropdown-item" href="{{$item.plink.href}}" target="_blank" title="{{$item.plink.title}}" class="u-url"><i class="generic-icons-nav fa fa-fw fa-external-link"></i>{{$item.plink.title}}</a>
|
||||
|
|
Loading…
Reference in a new issue