This commit is contained in:
Ry0 2025-05-20 10:34:57 +00:00 committed by GitHub
commit 7f2290b7f1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 22 additions and 1 deletions

View file

@ -113,6 +113,7 @@ final class WallPresenter extends OpenVKPresenter
"amount" => sizeof($this->template->posts), "amount" => sizeof($this->template->posts),
"perPage" => OPENVK_DEFAULT_PER_PAGE, "perPage" => OPENVK_DEFAULT_PER_PAGE,
]; ];
$this->template->ignore_status = $owner->isIgnoredBy($this->user->identity);
$this->logPostsViewed($this->template->posts, $user); $this->logPostsViewed($this->template->posts, $user);

View file

@ -58,6 +58,7 @@
<span n:if="$post->isPinned()" class="nobold">{_pinned}</span> <span n:if="$post->isPinned()" class="nobold">{_pinned}</span>
<a n:if="$canBeDeleted && !($forceNoDeleteLink ?? false) && $compact == false" class="delete" href="/wall{$post->getPrettyId()}/delete"></a> <a n:if="$canBeDeleted && !($forceNoDeleteLink ?? false) && $compact == false" class="delete" href="/wall{$post->getPrettyId()}/delete"></a>
<a n:if="!$canBeDeleted" class="ignore" id="__ignoreSomeone" title="{if !$ignore_status}{_ignore_user}{else}{_unignore_user}{/if}" data-val='{!$ignore_status ? 1 : 0}' data-id="{$wallOwner->getId()}"></a>
{if $canBePinned && !($forceNoPinLink ?? false) && $compact == false} {if $canBePinned && !($forceNoPinLink ?? false) && $compact == false}
{if $post->isPinned()} {if $post->isPinned()}

View file

@ -135,6 +135,10 @@
<a href="/wall{$post->getPrettyId()}/delete">{_delete}</a> &nbsp;|&nbsp; <a href="/wall{$post->getPrettyId()}/delete">{_delete}</a> &nbsp;|&nbsp;
{/if} {/if}
{if !$canBeDeleted}
<a class="delete" id="__ignoreSomeone" data-val='{!$ignore_status ? 1 : 0}' data-id="{$wallOwner->getId()}">{if !$ignore_status}{_ignore_user}{else}{_unignore_user}{/if}</a> &nbsp;|&nbsp;
{/if}
{if !($forceNoPinLink ?? false) && $canBePinned} {if !($forceNoPinLink ?? false) && $canBePinned}
{if $post->isPinned()} {if $post->isPinned()}
<a href="/wall{$post->getPrettyId()}/pin?act=unpin&hash={rawurlencode($csrfToken)}">{_unpin}</a> <a href="/wall{$post->getPrettyId()}/pin?act=unpin&hash={rawurlencode($csrfToken)}">{_unpin}</a>

View file

@ -86,6 +86,21 @@
background-color: rgb(240, 240, 240); background-color: rgb(240, 240, 240);
} }
.ignore {
float: right;
height: 16px;
width: 16px;
overflow: auto;
background: url("/assets/packages/static/openvk/img/audios_controls.png") no-repeat 0 0;
background-position: -51px -67px;
opacity: 0.1;
transition-duration: 0.3s;
}
.ignore:hover {
opacity: 0.4;
}
.post-author .delete { .post-author .delete {
float: right; float: right;
height: 16px; height: 16px;