2022-04-24 08:06:45 +03:00
|
|
|
{var $author = $post->getOwner()}
|
2022-08-05 23:00:52 +03:00
|
|
|
{if $post->isDeactivationMessage() && $post->getText()}
|
|
|
|
{var $deac = "post_deact"}
|
|
|
|
{else}
|
|
|
|
{var $deac = "post_deact_silent"}
|
|
|
|
{/if}
|
2021-01-27 20:40:37 +03:00
|
|
|
|
|
|
|
<table border="0" style="font-size: 11px;" n:class="post, $post->isExplicit() ? post-nsfw">
|
|
|
|
<tbody>
|
|
|
|
<tr>
|
|
|
|
<td width="54" valign="top">
|
2022-02-05 20:24:46 +03:00
|
|
|
<a href="{$author->getURL()}">
|
2022-04-05 14:39:13 +03:00
|
|
|
<img src="{$author->getAvatarURL('miniscule')}" width="50" />
|
2022-03-24 15:29:00 +03:00
|
|
|
<span n:if="!$post->isPostedOnBehalfOfGroup() && !($compact ?? false) && $author->isOnline()" class="post-online">{_online}</span>
|
2022-02-05 20:24:46 +03:00
|
|
|
</a>
|
2021-01-27 20:40:37 +03:00
|
|
|
</td>
|
|
|
|
<td width="100%" valign="top">
|
|
|
|
<div class="post-author">
|
2022-03-24 15:29:00 +03:00
|
|
|
<a href="{$author->getURL()}"><b>{$author->getCanonicalName()}</b></a>
|
|
|
|
<img n:if="$author->isVerified()" class="name-checkmark" src="/assets/packages/static/openvk/img/checkmark.png">
|
2022-11-17 00:45:06 +03:00
|
|
|
{if $post->isDeactivationMessage()}
|
|
|
|
{$author->isFemale() ? tr($deac . "_f") : tr($deac . "_m")}
|
|
|
|
{elseif $post->isPostedOnBehalfOfGroup()}
|
|
|
|
{_post_writes_g}
|
|
|
|
{else}
|
|
|
|
{if $author->isFemale()}
|
|
|
|
{_post_writes_f}
|
|
|
|
{else}
|
|
|
|
{_post_writes_m}
|
|
|
|
{/if}
|
|
|
|
{/if}
|
2021-01-27 20:40:37 +03:00
|
|
|
{if ($onWallOf ?? false) &&!$post->isPostedOnBehalfOfGroup() && $post->getOwnerPost() !== $post->getTargetWall()}
|
2022-10-08 23:47:21 +03:00
|
|
|
{var $wallOwner = $post->getWallOwner()}
|
2022-10-09 11:34:57 +03:00
|
|
|
<a href="{$wallOwner->getURL()}" class="mention" data-mention-ref="{$post->getTargetWall()}">
|
2021-01-27 20:40:37 +03:00
|
|
|
<b>
|
2022-10-08 23:47:21 +03:00
|
|
|
{if isset($thisUser) && $thisUser->getId() === $post->getTargetWall()}
|
|
|
|
{_post_on_your_wall}
|
|
|
|
{elseif $wallOwner instanceof \openvk\Web\Models\Entities\Club}
|
|
|
|
{tr("post_on_group_wall", ovk_proc_strtr($wallOwner->getName(), 52))}
|
|
|
|
{else}
|
|
|
|
{tr("post_on_user_wall", $wallOwner->getMorphedName("genitive", false))}
|
2021-01-27 20:40:37 +03:00
|
|
|
{/if}
|
|
|
|
</b>
|
|
|
|
</a>
|
|
|
|
{/if}
|
|
|
|
<br/>
|
2021-09-20 15:19:15 +03:00
|
|
|
<a href="/wall{$post->getPrettyId()}" class="date">
|
2022-03-24 15:29:00 +03:00
|
|
|
{$post->getPublicationTime()}{if $post->isPinned()}, {_pinned}{/if}
|
2021-09-20 15:19:15 +03:00
|
|
|
</a>
|
2021-01-27 20:40:37 +03:00
|
|
|
</div>
|
|
|
|
<div class="post-content" id="{$post->getPrettyId()}">
|
|
|
|
<div class="text" id="text{$post->getPrettyId()}">
|
|
|
|
{$post->getText()|noescape}
|
|
|
|
|
2022-12-11 20:30:01 +03:00
|
|
|
{var $width = ($GLOBALS["_bigWall"] ?? false) ? 550 : 320}
|
|
|
|
{if isset($GLOBALS["_nesAttGloCou"])}
|
|
|
|
{var $width = $width - 70 * $GLOBALS["_nesAttGloCou"]}
|
|
|
|
{/if}
|
|
|
|
{var $attachmentsLayout = $post->getChildrenWithLayout($width)}
|
|
|
|
<div n:ifcontent class="attachments_b" style="height: {$attachmentsLayout->height|noescape}; width: {$attachmentsLayout->width|noescape};">
|
|
|
|
<div class="attachment" n:foreach="$attachmentsLayout->tiles as $attachment" style="float: {$attachment[3]|noescape}; width: {$attachment[0]|noescape}; height: {$attachment[1]|noescape};" data-localized-nsfw-text="{_nsfw_warning}">
|
2022-12-15 03:40:25 +03:00
|
|
|
{include "../attachment.xml", attachment => $attachment[2], post => $post}
|
2021-01-27 20:40:37 +03:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div n:if="$post->isAd()" style="color:grey;">
|
|
|
|
<br/>
|
|
|
|
! Этот пост был размещён за взятку.
|
|
|
|
</div>
|
|
|
|
<div n:if="$post->isSigned()" class="post-signature">
|
2022-04-24 08:06:45 +03:00
|
|
|
{var $actualAuthor = $post->getOwner(false)}
|
2021-01-27 20:40:37 +03:00
|
|
|
<span>
|
2022-03-24 15:29:00 +03:00
|
|
|
{_author}:
|
2022-10-09 11:34:57 +03:00
|
|
|
<a href="{$actualAuthor->getURL()}" class="mention" data-mention-ref="{$actualAuthor->getId()}">
|
2022-03-24 15:29:00 +03:00
|
|
|
{$actualAuthor->getCanonicalName()}
|
2021-01-27 20:40:37 +03:00
|
|
|
</a>
|
|
|
|
</span>
|
|
|
|
</div>
|
|
|
|
</div>
|
2022-07-22 11:40:56 +03:00
|
|
|
<div n:if="!($compact ?? false)" class="post-menu">
|
|
|
|
{if is_null($thisUser)}
|
|
|
|
{var $forceNoDeleteLink = true}
|
|
|
|
{var $forceNoPinLink = true}
|
|
|
|
{/if}
|
|
|
|
|
|
|
|
{if !($forceNoDeleteLink ?? false) && $post->canBeDeletedBy($thisUser)}
|
2022-03-24 15:29:00 +03:00
|
|
|
<a href="/wall{$post->getPrettyId()}/delete">{_delete}</a> |
|
2021-09-20 16:46:55 +03:00
|
|
|
{/if}
|
|
|
|
|
2022-07-22 11:40:56 +03:00
|
|
|
{if !($forceNoPinLink ?? false) && $post->canBePinnedBy($thisUser)}
|
2021-09-20 15:19:15 +03:00
|
|
|
{if $post->isPinned()}
|
2022-03-24 15:29:00 +03:00
|
|
|
<a href="/wall{$post->getPrettyId()}/pin?act=unpin&hash={rawurlencode($csrfToken)}">{_unpin}</a>
|
2021-09-20 15:19:15 +03:00
|
|
|
{else}
|
2022-03-24 15:29:00 +03:00
|
|
|
<a href="/wall{$post->getPrettyId()}/pin?act=pin&hash={rawurlencode($csrfToken)}">{_pin}</a>
|
2021-09-20 15:19:15 +03:00
|
|
|
{/if}
|
2022-03-24 15:29:00 +03:00
|
|
|
|
|
2021-01-27 20:40:37 +03:00
|
|
|
{/if}
|
|
|
|
|
2022-03-24 15:29:00 +03:00
|
|
|
<a n:if="!($forceNoCommentsLink ?? false)" href="/wall{$post->getPrettyId()}#comments">
|
|
|
|
{_comments}
|
|
|
|
{if $post->getCommentsCount() > 0}
|
|
|
|
(<b>{$post->getCommentsCount()}</b>)
|
|
|
|
{/if}
|
|
|
|
</a>
|
2021-12-26 14:05:22 +03:00
|
|
|
|
|
|
|
{if !($forceNoCommentsLink ?? false) && !($forceNoShareLink ?? false)}
|
2021-01-27 20:40:37 +03:00
|
|
|
|
|
|
|
|
{/if}
|
|
|
|
|
2022-07-22 11:40:56 +03:00
|
|
|
<a n:if="!($forceNoShareLink ?? false)" class="post-share-button" {ifset $thisUser} href="javascript:repostPost('{$post->getPrettyId()}', '{rawurlencode($csrfToken)}')"{/ifset}>
|
2022-03-24 15:29:00 +03:00
|
|
|
{_share}
|
|
|
|
{if $post->getRepostCount() > 0}
|
|
|
|
(<b>{$post->getRepostCount()}</b>)
|
|
|
|
{/if}
|
|
|
|
</a>
|
2021-12-26 14:05:22 +03:00
|
|
|
|
2022-03-24 15:29:00 +03:00
|
|
|
<div n:if="!($forceNoLike ?? false)" class="like_wrap">
|
2022-07-22 11:40:56 +03:00
|
|
|
{ifset $thisUser}
|
|
|
|
{var $liked = $post->hasLikeFrom($thisUser)}
|
|
|
|
<a href="/wall{$post->getPrettyId()}/like?hash={rawurlencode($csrfToken)}" class="post-like-button" data-liked="{(int) $liked}" data-likes="{$post->getLikesCount()}">
|
|
|
|
<div class="heart" id="{if $liked}liked{/if}"></div>
|
|
|
|
<span class="likeCnt">{if $post->getLikesCount() > 0}{$post->getLikesCount()}{/if}</span>
|
|
|
|
</a>
|
|
|
|
{else}
|
|
|
|
<a n:if="$post->getLikesCount() > 0" class="post-like-button">
|
|
|
|
<div class="heart"></div>
|
|
|
|
<span class="likeCnt">{$post->getLikesCount()}</span>
|
|
|
|
</a>
|
|
|
|
{/ifset}
|
2022-03-24 15:29:00 +03:00
|
|
|
</div>
|
2021-01-27 20:40:37 +03:00
|
|
|
</div>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
</tbody>
|
|
|
|
</table>
|