mirror of
https://github.com/openvk/openvk
synced 2024-11-15 03:31:18 +03:00
Compare commits
2 commits
c561b6317e
...
1e2ecb5f74
Author | SHA1 | Date | |
---|---|---|---|
|
1e2ecb5f74 | ||
|
a3d535040d |
25 changed files with 332 additions and 149 deletions
|
@ -74,7 +74,7 @@ final class Video extends VKAPIRequestHandler
|
||||||
$return_items = [];
|
$return_items = [];
|
||||||
$profiles = [];
|
$profiles = [];
|
||||||
$groups = [];
|
$groups = [];
|
||||||
foreach($items as $item)
|
foreach($items as $item) {
|
||||||
$return_item = $item->getApiStructure($this->getUser());
|
$return_item = $item->getApiStructure($this->getUser());
|
||||||
$return_item = $return_item->video;
|
$return_item = $return_item->video;
|
||||||
$return_items[] = $return_item;
|
$return_items[] = $return_item;
|
||||||
|
@ -85,6 +85,7 @@ final class Video extends VKAPIRequestHandler
|
||||||
else
|
else
|
||||||
$groups[] = abs($return_item['owner_id']);
|
$groups[] = abs($return_item['owner_id']);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if($extended) {
|
if($extended) {
|
||||||
$profiles = array_unique($profiles);
|
$profiles = array_unique($profiles);
|
||||||
|
|
|
@ -102,7 +102,14 @@ final class Wall extends VKAPIRequestHandler
|
||||||
} else if ($attachment instanceof \openvk\Web\Models\Entities\Video) {
|
} else if ($attachment instanceof \openvk\Web\Models\Entities\Video) {
|
||||||
$attachments[] = $attachment->getApiStructure($this->getUser());
|
$attachments[] = $attachment->getApiStructure($this->getUser());
|
||||||
} else if ($attachment instanceof \openvk\Web\Models\Entities\Note) {
|
} else if ($attachment instanceof \openvk\Web\Models\Entities\Note) {
|
||||||
$attachments[] = $attachment->toVkApiStruct();
|
if(VKAPI_DECL_VER === '4.100') {
|
||||||
|
$attachments[] = $attachment->toVkApiStruct();
|
||||||
|
} else {
|
||||||
|
$attachments[] = [
|
||||||
|
'type' => 'note',
|
||||||
|
'note' => $attachment->toVkApiStruct()
|
||||||
|
];
|
||||||
|
}
|
||||||
} else if ($attachment instanceof \openvk\Web\Models\Entities\Audio) {
|
} else if ($attachment instanceof \openvk\Web\Models\Entities\Audio) {
|
||||||
$attachments[] = [
|
$attachments[] = [
|
||||||
"type" => "audio",
|
"type" => "audio",
|
||||||
|
@ -176,12 +183,6 @@ final class Wall extends VKAPIRequestHandler
|
||||||
"count" => $post->getCommentsCount(),
|
"count" => $post->getCommentsCount(),
|
||||||
"can_post" => 1
|
"can_post" => 1
|
||||||
],
|
],
|
||||||
"copyright" => !is_null($post->getSource(false)) ? (object)[
|
|
||||||
"id" => 0,
|
|
||||||
"link" => $post->getSource(false),
|
|
||||||
"name" => "none",
|
|
||||||
"type" => "link"
|
|
||||||
] : NULL,
|
|
||||||
"likes" => (object)[
|
"likes" => (object)[
|
||||||
"count" => $post->getLikesCount(),
|
"count" => $post->getLikesCount(),
|
||||||
"user_likes" => (int) $post->hasLikeFrom($this->getUser()),
|
"user_likes" => (int) $post->hasLikeFrom($this->getUser()),
|
||||||
|
@ -194,6 +195,9 @@ final class Wall extends VKAPIRequestHandler
|
||||||
]
|
]
|
||||||
];
|
];
|
||||||
|
|
||||||
|
if($post->hasSource())
|
||||||
|
$post_temp_obj->copyright = $post->getVkApiCopyright();
|
||||||
|
|
||||||
if($signerId)
|
if($signerId)
|
||||||
$post_temp_obj->signer_id = $signerId;
|
$post_temp_obj->signer_id = $signerId;
|
||||||
|
|
||||||
|
@ -297,7 +301,14 @@ final class Wall extends VKAPIRequestHandler
|
||||||
} else if ($attachment instanceof \openvk\Web\Models\Entities\Video) {
|
} else if ($attachment instanceof \openvk\Web\Models\Entities\Video) {
|
||||||
$attachments[] = $attachment->getApiStructure($this->getUser());
|
$attachments[] = $attachment->getApiStructure($this->getUser());
|
||||||
} else if ($attachment instanceof \openvk\Web\Models\Entities\Note) {
|
} else if ($attachment instanceof \openvk\Web\Models\Entities\Note) {
|
||||||
$attachments[] = $attachment->toVkApiStruct();
|
if(VKAPI_DECL_VER === '4.100') {
|
||||||
|
$attachments[] = $attachment->toVkApiStruct();
|
||||||
|
} else {
|
||||||
|
$attachments[] = [
|
||||||
|
'type' => 'note',
|
||||||
|
'note' => $attachment->toVkApiStruct()
|
||||||
|
];
|
||||||
|
}
|
||||||
} else if ($attachment instanceof \openvk\Web\Models\Entities\Audio) {
|
} else if ($attachment instanceof \openvk\Web\Models\Entities\Audio) {
|
||||||
$attachments[] = [
|
$attachments[] = [
|
||||||
"type" => "audio",
|
"type" => "audio",
|
||||||
|
@ -367,12 +378,6 @@ final class Wall extends VKAPIRequestHandler
|
||||||
"count" => $post->getCommentsCount(),
|
"count" => $post->getCommentsCount(),
|
||||||
"can_post" => 1
|
"can_post" => 1
|
||||||
],
|
],
|
||||||
"copyright" => !is_null($post->getSource(false)) ? (object)[
|
|
||||||
"id" => 0,
|
|
||||||
"link" => $post->getSource(false),
|
|
||||||
"name" => "none",
|
|
||||||
"type" => "link"
|
|
||||||
] : NULL,
|
|
||||||
"likes" => (object)[
|
"likes" => (object)[
|
||||||
"count" => $post->getLikesCount(),
|
"count" => $post->getLikesCount(),
|
||||||
"user_likes" => (int) $post->hasLikeFrom($user),
|
"user_likes" => (int) $post->hasLikeFrom($user),
|
||||||
|
@ -385,6 +390,9 @@ final class Wall extends VKAPIRequestHandler
|
||||||
]
|
]
|
||||||
];
|
];
|
||||||
|
|
||||||
|
if($post->hasSource())
|
||||||
|
$post_temp_obj->copyright = $post->getVkApiCopyright();
|
||||||
|
|
||||||
if($signerId)
|
if($signerId)
|
||||||
$post_temp_obj->signer_id = $signerId;
|
$post_temp_obj->signer_id = $signerId;
|
||||||
|
|
||||||
|
@ -465,7 +473,7 @@ final class Wall extends VKAPIRequestHandler
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
function post(string $owner_id, string $message = "", int $from_group = 0, int $signed = 0, string $attachments = "", int $post_id = 0, string $copyright = NULL): object
|
function post(string $owner_id, string $message = "", int $from_group = 0, int $signed = 0, string $attachments = "", int $post_id = 0): object
|
||||||
{
|
{
|
||||||
$this->requireUser();
|
$this->requireUser();
|
||||||
$this->willExecuteWriteAction();
|
$this->willExecuteWriteAction();
|
||||||
|
@ -555,8 +563,10 @@ final class Wall extends VKAPIRequestHandler
|
||||||
$post->setFlags($flags);
|
$post->setFlags($flags);
|
||||||
$post->setApi_Source_Name($this->getPlatform());
|
$post->setApi_Source_Name($this->getPlatform());
|
||||||
|
|
||||||
if(!is_null($copyright) && !empty($copyright) && $copyright != "" && preg_match("/^(http:\/\/|https:\/\/)*[а-яА-ЯёЁa-z0-9\-_]+(\.[а-яА-ЯёЁa-z0-9\-_]+)+(\/\S*)*$/iu", $copyright) && iconv_strlen($copyright) < 50) {
|
if(!is_null($copyright) && !empty($copyright)) {
|
||||||
$post->setSource($copyright);
|
try {
|
||||||
|
$post->setSource($copyright);
|
||||||
|
} catch(\Throwable) {}
|
||||||
}
|
}
|
||||||
|
|
||||||
if($owner_id < 0 && !$wallOwner->canBeModifiedBy($this->getUser()) && $wallOwner->getWallType() == 2)
|
if($owner_id < 0 && !$wallOwner->canBeModifiedBy($this->getUser()) && $wallOwner->getWallType() == 2)
|
||||||
|
@ -574,11 +584,11 @@ final class Wall extends VKAPIRequestHandler
|
||||||
# Пример: photo1_1
|
# Пример: photo1_1
|
||||||
|
|
||||||
if(sizeof($attachmentsArr) > 10)
|
if(sizeof($attachmentsArr) > 10)
|
||||||
$this->fail(50, "Error: too many attachments");
|
$this->fail(50, "Too many attachments");
|
||||||
|
|
||||||
preg_match_all("/poll/m", $attachments, $matches, PREG_SET_ORDER, 0);
|
preg_match_all("/poll/m", $attachments, $matches, PREG_SET_ORDER, 0);
|
||||||
if(sizeof($matches) > 1)
|
if(sizeof($matches) > 1)
|
||||||
$this->fail(85, "Error: too many polls");
|
$this->fail(85, "Too many polls");
|
||||||
|
|
||||||
foreach($attachmentsArr as $attac) {
|
foreach($attachmentsArr as $attac) {
|
||||||
$attachmentType = NULL;
|
$attachmentType = NULL;
|
||||||
|
@ -1009,7 +1019,7 @@ final class Wall extends VKAPIRequestHandler
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function edit(int $owner_id, int $post_id, string $message = "", string $attachments = "") {
|
function edit(int $owner_id, int $post_id, string $message = "", string $attachments = "", string $copyright = NULL) {
|
||||||
$this->requireUser();
|
$this->requireUser();
|
||||||
$this->willExecuteWriteAction();
|
$this->willExecuteWriteAction();
|
||||||
|
|
||||||
|
@ -1018,9 +1028,6 @@ final class Wall extends VKAPIRequestHandler
|
||||||
if(!$post || $post->isDeleted())
|
if(!$post || $post->isDeleted())
|
||||||
$this->fail(102, "Invalid post");
|
$this->fail(102, "Invalid post");
|
||||||
|
|
||||||
if(empty($message) && empty($attachments))
|
|
||||||
$this->fail(100, "Required parameter 'message' missing.");
|
|
||||||
|
|
||||||
if(!$post->canBeEditedBy($this->getUser()))
|
if(!$post->canBeEditedBy($this->getUser()))
|
||||||
$this->fail(7, "Access to editing denied");
|
$this->fail(7, "Access to editing denied");
|
||||||
|
|
||||||
|
@ -1028,6 +1035,12 @@ final class Wall extends VKAPIRequestHandler
|
||||||
$post->setContent($message);
|
$post->setContent($message);
|
||||||
|
|
||||||
$post->setEdited(time());
|
$post->setEdited(time());
|
||||||
|
if(!is_null($copyright) && !empty($copyright)) {
|
||||||
|
try {
|
||||||
|
$post->setSource($copyright);
|
||||||
|
} catch(\Throwable) {}
|
||||||
|
}
|
||||||
|
|
||||||
$post->save(true);
|
$post->save(true);
|
||||||
|
|
||||||
# todo добавить такое в веб версию
|
# todo добавить такое в веб версию
|
||||||
|
@ -1098,52 +1111,61 @@ final class Wall extends VKAPIRequestHandler
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
function checkCopyrightLink(string $link) {
|
function checkCopyrightLink(string $link): int
|
||||||
$res = (int)(!is_null($link) && !empty($link) && preg_match("/^(http:\/\/|https:\/\/)*[а-яА-ЯёЁa-z0-9\-_]+(\.[а-яА-ЯёЁa-z0-9\-_]+)+(\/\S*)*$/iu", $link) && iconv_strlen($link) < 50);
|
{
|
||||||
|
$this->requireUser();
|
||||||
|
|
||||||
if($res == 0) {
|
try {
|
||||||
|
$result = check_copyright_link($link);
|
||||||
|
} catch(\InvalidArgumentException $e) {
|
||||||
|
$this->fail(3102, "Specified link is incorrect (can't find source)");
|
||||||
|
} catch(\LengthException $e) {
|
||||||
|
$this->fail(3103, "Specified link is incorrect (too long)");
|
||||||
|
} catch(\LogicException $e) {
|
||||||
|
$this->fail(3104, "Link is suspicious");
|
||||||
|
} catch(\Throwable $e) {
|
||||||
$this->fail(3102, "Specified link is incorrect");
|
$this->fail(3102, "Specified link is incorrect");
|
||||||
}
|
}
|
||||||
|
|
||||||
return $res;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
function pin(int $owner_id, int $post_id) {
|
function pin(int $owner_id, int $post_id)
|
||||||
|
{
|
||||||
$this->requireUser();
|
$this->requireUser();
|
||||||
$this->willExecuteWriteAction();
|
$this->willExecuteWriteAction();
|
||||||
|
|
||||||
$post = (new PostsRepo)->getPostById($owner_id, $post_id);
|
$post = (new PostsRepo)->getPostById($owner_id, $post_id);
|
||||||
if(!$post || $post->isDeleted())
|
if(!$post || $post->isDeleted())
|
||||||
$this->fail(361, "Invalid post");
|
$this->fail(100, "One of the parameters specified was missing or invalid: post_id is undefined");
|
||||||
|
|
||||||
if(!$post->canBePinnedBy($this->getUser()))
|
if(!$post->canBePinnedBy($this->getUser()))
|
||||||
$this->fail(14, "Access to pinning post denied");
|
return 0;
|
||||||
|
|
||||||
if(!$post->isPinned()) {
|
if($post->isPinned())
|
||||||
$post->pin();
|
|
||||||
return 1;
|
return 1;
|
||||||
} else {
|
|
||||||
$this->fail(50, "Post is already pinned");
|
$post->pin();
|
||||||
}
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
function unpin(int $owner_id, int $post_id) {
|
function unpin(int $owner_id, int $post_id)
|
||||||
|
{
|
||||||
$this->requireUser();
|
$this->requireUser();
|
||||||
$this->willExecuteWriteAction();
|
$this->willExecuteWriteAction();
|
||||||
|
|
||||||
$post = (new PostsRepo)->getPostById($owner_id, $post_id);
|
$post = (new PostsRepo)->getPostById($owner_id, $post_id);
|
||||||
if(!$post || $post->isDeleted())
|
if(!$post || $post->isDeleted())
|
||||||
$this->fail(361, "Invalid post");
|
$this->fail(100, "One of the parameters specified was missing or invalid: post_id is undefined");
|
||||||
|
|
||||||
if(!$post->canBePinnedBy($this->getUser()))
|
if(!$post->canBePinnedBy($this->getUser()))
|
||||||
$this->fail(14, "Access to unpinning post denied");
|
return 0;
|
||||||
|
|
||||||
if($post->isPinned()) {
|
if(!$post->isPinned())
|
||||||
$post->unpin();
|
|
||||||
return 1;
|
return 1;
|
||||||
} else {
|
|
||||||
$this->fail(50, "Post is not pinned");
|
$post->unpin();
|
||||||
}
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
private function getApiPhoto($attachment) {
|
private function getApiPhoto($attachment) {
|
||||||
|
|
|
@ -79,29 +79,38 @@ class Post extends Postable
|
||||||
return (bool) $this->getRecord()->pinned;
|
return (bool) $this->getRecord()->pinned;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function hasSource(): bool
|
||||||
|
{
|
||||||
|
return $this->getRecord()->source != NULL;
|
||||||
|
}
|
||||||
|
|
||||||
function getSource(bool $format = false)
|
function getSource(bool $format = false)
|
||||||
{
|
{
|
||||||
if(!$format) {
|
$orig_source = $this->getRecord()->source;
|
||||||
return $this->getRecord()->source;
|
if(!str_contains($orig_source, "https://") && !str_contains($orig_source, "http://"))
|
||||||
}
|
$orig_source = "https://" . $orig_source;
|
||||||
|
|
||||||
return $this->formatLinks($this->getRecord()->source);
|
if(!$format)
|
||||||
|
return $orig_source;
|
||||||
|
|
||||||
|
return $this->formatLinks($orig_source);
|
||||||
}
|
}
|
||||||
|
|
||||||
function setSource(string $source)
|
function setSource(string $source)
|
||||||
{
|
{
|
||||||
$src = $source;
|
$result = check_copyright_link($source);
|
||||||
|
|
||||||
if(iconv_strlen($source) > 50)
|
$this->stateChanges("source", $source);
|
||||||
throw new \LengthException("Link is too long.");
|
}
|
||||||
|
|
||||||
if(!preg_match("/^(http:\/\/|https:\/\/)*[а-яА-ЯёЁa-z0-9\-_]+(\.[а-яА-ЯёЁa-z0-9\-_]+)+(\/\S*)*$/iu", $source))
|
function getVkApiCopyright(): object
|
||||||
throw new \LogicException("Invalid link");
|
{
|
||||||
|
return (object)[
|
||||||
if(!str_contains($source, "https://") && !str_contains($source, "http://"))
|
'id' => 0,
|
||||||
$src = "https://" . $source;
|
'link' => $this->getSource(false),
|
||||||
|
'name' => $this->getSource(false),
|
||||||
$this->stateChanges("source", $src);
|
'type' => 'link',
|
||||||
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
function isAd(): bool
|
function isAd(): bool
|
||||||
|
|
|
@ -38,9 +38,20 @@ trait TRichText
|
||||||
$href = str_replace("#", "#", $matches[1]);
|
$href = str_replace("#", "#", $matches[1]);
|
||||||
$href = rawurlencode(str_replace(";", ";", $href));
|
$href = rawurlencode(str_replace(";", ";", $href));
|
||||||
$link = str_replace("#", "#", $matches[3]);
|
$link = str_replace("#", "#", $matches[3]);
|
||||||
|
# this string breaks ampersands
|
||||||
$link = str_replace(";", ";", $link);
|
$link = str_replace(";", ";", $link);
|
||||||
$rel = $this->isAd() ? "sponsored" : "ugc";
|
$rel = $this->isAd() ? "sponsored" : "ugc";
|
||||||
|
|
||||||
|
$server_domain = str_replace(':' . $_SERVER['SERVER_PORT'], '', $_SERVER['HTTP_HOST']);
|
||||||
|
if(str_contains($link, $server_domain)) {
|
||||||
|
$replaced_link = str_replace(':' . $_SERVER['SERVER_PORT'], '', $link);
|
||||||
|
$replaced_link = str_replace($server_domain, '', $replaced_link);
|
||||||
|
|
||||||
|
return "<a href='$replaced_link' rel='$rel'>$link</a>" . htmlentities($matches[4]);
|
||||||
|
}
|
||||||
|
|
||||||
|
$link = htmlentities(urldecode($link));
|
||||||
|
|
||||||
return "<a href='/away.php?to=$href' rel='$rel' target='_blank'>$link</a>" . htmlentities($matches[4]);
|
return "<a href='/away.php?to=$href' rel='$rel' target='_blank'>$link</a>" . htmlentities($matches[4]);
|
||||||
}),
|
}),
|
||||||
$text
|
$text
|
||||||
|
|
|
@ -124,6 +124,6 @@ final class SearchPresenter extends OpenVKPresenter
|
||||||
'pageCount' => ceil($count / $this->template->perPage),
|
'pageCount' => ceil($count / $this->template->perPage),
|
||||||
];
|
];
|
||||||
$this->template->extendedPaginatorConf = clone $this->template->paginatorConf;
|
$this->template->extendedPaginatorConf = clone $this->template->paginatorConf;
|
||||||
$this->template->extendedPaginatorConf->space = 12;
|
$this->template->extendedPaginatorConf->space = 11;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -367,8 +367,10 @@ final class WallPresenter extends OpenVKPresenter
|
||||||
$post->setFlags($flags);
|
$post->setFlags($flags);
|
||||||
$post->setNsfw($this->postParam("nsfw") === "on");
|
$post->setNsfw($this->postParam("nsfw") === "on");
|
||||||
|
|
||||||
if($this->postParam("set_source") === "on" && !is_null($this->postParam("source")) && !empty($this->postParam("source")) && preg_match("/^(http:\/\/|https:\/\/)*[а-яА-ЯёЁa-z0-9\-_]+(\.[а-яА-ЯёЁa-z0-9\-_]+)+(\/\S*)*$/iu", $this->postParam("source")) && iconv_strlen($this->postParam("set_source")) < 50) {
|
if(!empty($this->postParam("source")) && $this->postParam("source") != 'none') {
|
||||||
$post->setSource($this->postParam("source"));
|
try {
|
||||||
|
$post->setSource($this->postParam("source"));
|
||||||
|
} catch(\Throwable) {}
|
||||||
}
|
}
|
||||||
|
|
||||||
if($wall < 0 && !$wallOwner->canBeModifiedBy($this->user->identity) && $wallOwner->getWallType() == 2)
|
if($wall < 0 && !$wallOwner->canBeModifiedBy($this->user->identity) && $wallOwner->getWallType() == 2)
|
||||||
|
|
|
@ -17,7 +17,7 @@
|
||||||
|
|
||||||
<a n:if="!$isMy" n:attr="id => $mode === 'list' ? 'used' : 'ki'" href="/audios{$ownerId}">{if $ownerId > 0}{_music_user}{else}{_music_club}{/if}</a>
|
<a n:if="!$isMy" n:attr="id => $mode === 'list' ? 'used' : 'ki'" href="/audios{$ownerId}">{if $ownerId > 0}{_music_user}{else}{_music_club}{/if}</a>
|
||||||
<a href="/player/upload?gid={abs($ownerId)}" n:if="isset($thisUser) && isset($club) && $club->canUploadAudio($thisUser)">{_upload_audio}</a>
|
<a href="/player/upload?gid={abs($ownerId)}" n:if="isset($thisUser) && isset($club) && $club->canUploadAudio($thisUser)">{_upload_audio}</a>
|
||||||
<a n:attr="id => $mode === 'playlists' && $ownerId != $thisUser->getId() ? 'used' : 'ki'" href="/playlists{$ownerId}" n:if="isset($thisUser) && isset($ownerId) && !$isMy">{if $ownerId > 0}{_playlists_user}{else}{_playlists_club}{/if}</a>
|
<a n:attr="id => $mode === 'playlists' && $ownerId != $thisUser->getId() ? 'used' : 'ki'" class='noOverflow' href="/playlists{$ownerId}" n:if="isset($thisUser) && isset($ownerId) && !$isMy">{if $ownerId > 0}{_playlists_user}{else}{_playlists_club}{/if}</a>
|
||||||
<a href="/audios/newPlaylist{if $isMyClub}?gid={abs($ownerId)}{/if}" n:if="isset($thisUser) && $isMyClub">{_new_playlist}</a>
|
<a href="/audios/newPlaylist{if $isMyClub}?gid={abs($ownerId)}{/if}" n:if="isset($thisUser) && $isMyClub">{_new_playlist}</a>
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -32,13 +32,13 @@
|
||||||
<div n:class='page_wrap_content_main, $section == "audios" && $count > 0 ? audios_padding'>
|
<div n:class='page_wrap_content_main, $section == "audios" && $count > 0 ? audios_padding'>
|
||||||
{if $count > 0}
|
{if $count > 0}
|
||||||
{if $section === 'users'}
|
{if $section === 'users'}
|
||||||
<div class='search_content def_row_content' n:foreach="$data as $dat">
|
<div class='search_content content def_row_content' n:foreach="$data as $dat">
|
||||||
<table>
|
<table>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<td valign="top">
|
<td valign="top">
|
||||||
<a href="{$dat->getURL()}">
|
<a href="{$dat->getURL()}">
|
||||||
<img src="{$dat->getAvatarUrl('miniscule')}" width="75" alt="{_photo}" loading='lazy' />
|
<img src="{$dat->getAvatarUrl('tiny')}" width="75" alt="{_photo}" loading='lazy' />
|
||||||
</a>
|
</a>
|
||||||
</td>
|
</td>
|
||||||
<td valign="top" style="width: 100%">
|
<td valign="top" style="width: 100%">
|
||||||
|
@ -128,13 +128,13 @@
|
||||||
highlightText({$query}, '.page_wrap_content_main', ['text'])
|
highlightText({$query}, '.page_wrap_content_main', ['text'])
|
||||||
</script>
|
</script>
|
||||||
{elseif $section === 'groups'}
|
{elseif $section === 'groups'}
|
||||||
<div class='search_content def_row_content' n:foreach="$data as $dat">
|
<div class='search_content content def_row_content' n:foreach="$data as $dat">
|
||||||
<table>
|
<table>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<td valign="top">
|
<td valign="top">
|
||||||
<a href="{$dat->getURL()}">
|
<a href="{$dat->getURL()}">
|
||||||
<img src="{$dat->getAvatarUrl('miniscule')}" width="75" alt="{_photo}" loading='lazy' />
|
<img src="{$dat->getAvatarUrl('tiny')}" width="75" alt="{_photo}" loading='lazy' />
|
||||||
</a>
|
</a>
|
||||||
</td>
|
</td>
|
||||||
<td valign="top" style="width: 100%">
|
<td valign="top" style="width: 100%">
|
||||||
|
@ -183,7 +183,7 @@
|
||||||
highlightText({$query}, '.page_wrap_content_main', ['text', "td[data-highlight='_clubDesc']"])
|
highlightText({$query}, '.page_wrap_content_main', ['text', "td[data-highlight='_clubDesc']"])
|
||||||
</script>
|
</script>
|
||||||
{elseif $section === 'apps'}
|
{elseif $section === 'apps'}
|
||||||
<div class='search_content def_row_content' n:foreach="$data as $dat">
|
<div class='search_content content def_row_content' n:foreach="$data as $dat">
|
||||||
<table>
|
<table>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div n:if="$canPost && $type == 'all'" class="content_subtitle">
|
<div n:if="$canPost && $type == 'all'" class="content_subtitle">
|
||||||
{include "../components/textArea.xml", route => "/wall$owner/makePost"}
|
{include "../components/textArea.xml", route => "/wall$owner/makePost", hasSource => true}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="content">
|
<div class="content">
|
||||||
|
|
|
@ -1,9 +1,11 @@
|
||||||
{var $author = $comment->getOwner()}
|
{var $author = $comment->getOwner()}
|
||||||
{var $Club = openvk\Web\Models\Entities\Club::class}
|
{var $Club = openvk\Web\Models\Entities\Club::class}
|
||||||
{var $postId = $comment->getTarget() instanceof \openvk\Web\Models\Entities\Post ? $comment->getTarget()->getId() : NULL}
|
{var $likesCount = $comment->getLikesCount()}
|
||||||
|
{var $target = $comment->getTarget()}
|
||||||
|
{var $postId = $target instanceof \openvk\Web\Models\Entities\Post ? $target->getId() : NULL}
|
||||||
|
|
||||||
<a name="cid={$comment->getId()}"></a>
|
<a name="cid={$comment->getId()}"></a>
|
||||||
<table border="0" style="font-size: 11px;" class="post comment" id="_comment{$comment->getId()}" data-comment-id="{$comment->getId()}" data-owner-id="{$author->getId()}" data-from-group="{$comment->getOwner() instanceof $Club}" n:attr="data-post-id => $postId">
|
<table border="0" style="font-size: 11px;" class="post comment" id="_comment{$comment->getId()}" data-comment-id="{$comment->getId()}" data-owner-id="{$author->getId()}" data-from-group="{$author instanceof $Club}" n:attr="data-post-id => $postId">
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<td width="30" valign="top">
|
<td width="30" valign="top">
|
||||||
|
@ -40,8 +42,8 @@
|
||||||
<span n:if="$comment->getEditTime()" class="edited editedMark">({_edited_short})</span>
|
<span n:if="$comment->getEditTime()" class="edited editedMark">({_edited_short})</span>
|
||||||
</a>
|
</a>
|
||||||
{if !$timeOnly}
|
{if !$timeOnly}
|
||||||
|
|
|
||||||
{if $comment->canBeDeletedBy($thisUser)}
|
{if $comment->canBeDeletedBy($thisUser)}
|
||||||
|
|
|
||||||
<a href="/comment{$comment->getId()}/delete">{_delete}</a>
|
<a href="/comment{$comment->getId()}/delete">{_delete}</a>
|
||||||
{/if}
|
{/if}
|
||||||
{if $comment->canBeEditedBy($thisUser)}
|
{if $comment->canBeEditedBy($thisUser)}
|
||||||
|
@ -60,7 +62,7 @@
|
||||||
<div style="float: right; font-size: .7rem;">
|
<div style="float: right; font-size: .7rem;">
|
||||||
<a class="post-like-button" href="/comment{$comment->getId()}/like?hash={rawurlencode($csrfToken)}">
|
<a class="post-like-button" href="/comment{$comment->getId()}/like?hash={rawurlencode($csrfToken)}">
|
||||||
<div class="heart" style="{if $comment->hasLikeFrom($thisUser)}opacity: 1;{else}opacity: 0.4;{/if}"></div>
|
<div class="heart" style="{if $comment->hasLikeFrom($thisUser)}opacity: 1;{else}opacity: 0.4;{/if}"></div>
|
||||||
<span class="likeCnt">{if $comment->getLikesCount() > 0}{$comment->getLikesCount()}{/if}</span>
|
<span class="likeCnt">{if $likesCount > 0}{$likesCount}{/if}</span>
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
|
@ -3,6 +3,11 @@
|
||||||
{var $commentsCount = $post->getCommentsCount()}
|
{var $commentsCount = $post->getCommentsCount()}
|
||||||
{var $platform = $post->getPlatform()}
|
{var $platform = $post->getPlatform()}
|
||||||
{var $platformDetails = $post->getPlatformDetails()}
|
{var $platformDetails = $post->getPlatformDetails()}
|
||||||
|
{var $likesCount = $post->getLikesCount()}
|
||||||
|
{var $repostsCount = $post->getRepostCount()}
|
||||||
|
{var $canBePinned = $post->canBePinnedBy($thisUser ?? NULL)}
|
||||||
|
{var $canBeDeleted = $post->canBeDeletedBy($thisUser)}
|
||||||
|
{var $wallOwner = $post->getWallOwner()}
|
||||||
{if $post->isDeactivationMessage() && $post->getText()}
|
{if $post->isDeactivationMessage() && $post->getText()}
|
||||||
{var $deac = "post_deact"}
|
{var $deac = "post_deact"}
|
||||||
{else}
|
{else}
|
||||||
|
@ -30,7 +35,6 @@
|
||||||
{$post->isUpdateAvatarMessage() && !$post->isPostedOnBehalfOfGroup() ? ($author->isFemale() ? tr("upd_f") : ($author->isNeutral() ? tr("upd_n") : tr("upd_m")))}
|
{$post->isUpdateAvatarMessage() && !$post->isPostedOnBehalfOfGroup() ? ($author->isFemale() ? tr("upd_f") : ($author->isNeutral() ? tr("upd_n") : tr("upd_m")))}
|
||||||
{$post->isUpdateAvatarMessage() && $post->isPostedOnBehalfOfGroup() ? tr("upd_g") : ""}
|
{$post->isUpdateAvatarMessage() && $post->isPostedOnBehalfOfGroup() ? tr("upd_g") : ""}
|
||||||
{if ($onWallOf ?? false) &&!$post->isPostedOnBehalfOfGroup() && $post->getOwnerPost() !== $post->getTargetWall()}
|
{if ($onWallOf ?? false) &&!$post->isPostedOnBehalfOfGroup() && $post->getOwnerPost() !== $post->getTargetWall()}
|
||||||
{var $wallOwner = $post->getWallOwner()}
|
|
||||||
<a href="{$wallOwner->getURL()}" class="mention" data-mention-ref="{$post->getTargetWall()}">
|
<a href="{$wallOwner->getURL()}" class="mention" data-mention-ref="{$post->getTargetWall()}">
|
||||||
<b>
|
<b>
|
||||||
{if isset($thisUser) && $thisUser->getId() === $post->getTargetWall()}
|
{if isset($thisUser) && $thisUser->getId() === $post->getTargetWall()}
|
||||||
|
@ -53,9 +57,9 @@
|
||||||
|
|
||||||
<span n:if="$post->isPinned()" class="nobold">{_pinned}</span>
|
<span n:if="$post->isPinned()" class="nobold">{_pinned}</span>
|
||||||
|
|
||||||
<a n:if="$post->canBeDeletedBy($thisUser) && !($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>
|
||||||
|
|
||||||
{if $post->canBePinnedBy($thisUser) && !($forceNoPinLink ?? false) && $compact == false}
|
{if $canBePinned && !($forceNoPinLink ?? false) && $compact == false}
|
||||||
{if $post->isPinned()}
|
{if $post->isPinned()}
|
||||||
<a class="pin" href="/wall{$post->getPrettyId()}/pin?act=unpin&hash={rawurlencode($csrfToken)}"></a>
|
<a class="pin" href="/wall{$post->getPrettyId()}/pin?act=unpin&hash={rawurlencode($csrfToken)}"></a>
|
||||||
{else}
|
{else}
|
||||||
|
@ -67,7 +71,7 @@
|
||||||
<a class="edit" id="editPost"
|
<a class="edit" id="editPost"
|
||||||
data-id="{$post->getId()}"
|
data-id="{$post->getId()}"
|
||||||
data-nsfw="{(int)$post->isExplicit()}"
|
data-nsfw="{(int)$post->isExplicit()}"
|
||||||
{if $post->getTargetWall() < 0 && $post->getWallOwner()->canBeModifiedBy($thisUser)}data-fromgroup="{(int)$post->isPostedOnBehalfOfGroup()}"{/if}></a>
|
{if $post->getTargetWall() < 0 && $wallOwner->canBeModifiedBy($thisUser)}data-fromgroup="{(int)$post->isPostedOnBehalfOfGroup()}"{/if}></a>
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
<div class="post-content" id="{$post->getPrettyId()}">
|
<div class="post-content" id="{$post->getPrettyId()}">
|
||||||
|
@ -95,7 +99,7 @@
|
||||||
<br/>
|
<br/>
|
||||||
! {_post_is_ad}
|
! {_post_is_ad}
|
||||||
</div>
|
</div>
|
||||||
<div n:if="!is_null($post->getSource())" class="sourceDiv">
|
<div n:if="$post->hasSource()" class="sourceDiv">
|
||||||
<span>{_source}: {$post->getSource(true)|noescape}</span>
|
<span>{_source}: {$post->getSource(true)|noescape}</span>
|
||||||
</div>
|
</div>
|
||||||
<div n:if="$post->isSigned()" class="post-signature">
|
<div n:if="$post->isSigned()" class="post-signature">
|
||||||
|
@ -124,14 +128,14 @@
|
||||||
<div class="like_wrap">
|
<div class="like_wrap">
|
||||||
<a n:if="!($forceNoShareLink ?? false)" id="reposts{$post->getPrettyId()}" class="post-share-button" href="javascript:repostPost('{$post->getPrettyId()}', '{rawurlencode($csrfToken)}')">
|
<a n:if="!($forceNoShareLink ?? false)" id="reposts{$post->getPrettyId()}" class="post-share-button" href="javascript:repostPost('{$post->getPrettyId()}', '{rawurlencode($csrfToken)}')">
|
||||||
<div class="repost-icon" style="opacity: 0.4;"></div>
|
<div class="repost-icon" style="opacity: 0.4;"></div>
|
||||||
<span class="likeCnt" id="repostsCount{$post->getPrettyId()}">{if $post->getRepostCount() > 0}{$post->getRepostCount()}{/if}</span>
|
<span class="likeCnt" id="repostsCount{$post->getPrettyId()}">{if $repostsCount > 0}{$repostsCount}{/if}</span>
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
{if !($forceNoLike ?? false)}
|
{if !($forceNoLike ?? false)}
|
||||||
{var $liked = $post->hasLikeFrom($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()}">
|
<a href="/wall{$post->getPrettyId()}/like?hash={rawurlencode($csrfToken)}" class="post-like-button" data-liked="{(int) $liked}" data-likes="{$likesCount}">
|
||||||
<div class="heart" id="{if $liked}liked{/if}"></div>
|
<div class="heart" id="{if $liked}liked{/if}"></div>
|
||||||
<span class="likeCnt">{if $post->getLikesCount() > 0}{$post->getLikesCount()}{/if}</span>
|
<span class="likeCnt">{if $likesCount > 0}{$likesCount}{/if}</span>
|
||||||
</a>
|
</a>
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
|
@ -148,7 +152,7 @@
|
||||||
{include "../textArea.xml", route => $commentsURL, postOpts => false, graffiti => (bool) ovkGetQuirk("comments.allow-graffiti"), post => $post, club => $club}
|
{include "../textArea.xml", route => $commentsURL, postOpts => false, graffiti => (bool) ovkGetQuirk("comments.allow-graffiti"), post => $post, club => $club}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div n:if="$suggestion && $post->canBePinnedBy($thisUser ?? NULL)" class="suggestionControls">
|
<div n:if="$suggestion && $canBePinned" class="suggestionControls">
|
||||||
<input type="button" class="button" id="publish_post" data-id="{$post->getId()}" value="{_publish_suggested}">
|
<input type="button" class="button" id="publish_post" data-id="{$post->getId()}" value="{_publish_suggested}">
|
||||||
<input type="button" class="button" id="decline_post" data-id="{$post->getId()}" value="{_decline_suggested}">
|
<input type="button" class="button" id="decline_post" data-id="{$post->getId()}" value="{_decline_suggested}">
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,6 +1,12 @@
|
||||||
{var $author = $post->getOwner()}
|
{var $author = $post->getOwner()}
|
||||||
{var $platform = $post->getPlatform()}
|
{var $platform = $post->getPlatform()}
|
||||||
{var $platformDetails = $post->getPlatformDetails()}
|
{var $platformDetails = $post->getPlatformDetails()}
|
||||||
|
{var $wallOwner = $post->getWallOwner()}
|
||||||
|
{var $likesCount = $post->getLikesCount()}
|
||||||
|
{var $repostsCount = $post->getRepostCount()}
|
||||||
|
{var $commentsCount = $post->getCommentsCount()}
|
||||||
|
{var $canBePinned = $post->canBePinnedBy($thisUser ?? NULL)}
|
||||||
|
{var $canBeDeleted = $post->canBeDeletedBy($thisUser)}
|
||||||
{if $post->isDeactivationMessage() && $post->getText()}
|
{if $post->isDeactivationMessage() && $post->getText()}
|
||||||
{var $deac = "post_deact"}
|
{var $deac = "post_deact"}
|
||||||
{else}
|
{else}
|
||||||
|
@ -40,7 +46,6 @@
|
||||||
{/if}
|
{/if}
|
||||||
{/if}
|
{/if}
|
||||||
{if ($onWallOf ?? false) &&!$post->isPostedOnBehalfOfGroup() && $post->getOwnerPost() !== $post->getTargetWall()}
|
{if ($onWallOf ?? false) &&!$post->isPostedOnBehalfOfGroup() && $post->getOwnerPost() !== $post->getTargetWall()}
|
||||||
{var $wallOwner = $post->getWallOwner()}
|
|
||||||
<a href="{$wallOwner->getURL()}" class="mention" data-mention-ref="{$post->getTargetWall()}">
|
<a href="{$wallOwner->getURL()}" class="mention" data-mention-ref="{$post->getTargetWall()}">
|
||||||
<b>
|
<b>
|
||||||
{if isset($thisUser) && $thisUser->getId() === $post->getTargetWall()}
|
{if isset($thisUser) && $thisUser->getId() === $post->getTargetWall()}
|
||||||
|
@ -85,7 +90,7 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div n:if="$suggestion && $post->canBePinnedBy($thisUser ?? NULL)" class="suggestionControls" style="margin-bottom: 7px;">
|
<div n:if="$suggestion && $canBePinned" class="suggestionControls" style="margin-bottom: 7px;">
|
||||||
<input type="button" class="button" id="publish_post" data-id="{$post->getId()}" value="{_publish_suggested}">
|
<input type="button" class="button" id="publish_post" data-id="{$post->getId()}" value="{_publish_suggested}">
|
||||||
<input type="button" class="button" id="decline_post" data-id="{$post->getId()}" value="{_decline_suggested}">
|
<input type="button" class="button" id="decline_post" data-id="{$post->getId()}" value="{_decline_suggested}">
|
||||||
</div>
|
</div>
|
||||||
|
@ -93,7 +98,7 @@
|
||||||
<br/>
|
<br/>
|
||||||
! {_post_is_ad}
|
! {_post_is_ad}
|
||||||
</div>
|
</div>
|
||||||
<div n:if="!is_null($post->getSource())" class="sourceDiv" style="margin-top:0px;">
|
<div n:if="$post->hasSource()" class="sourceDiv">
|
||||||
<span>{_source}: {$post->getSource(true)|noescape}</span>
|
<span>{_source}: {$post->getSource(true)|noescape}</span>
|
||||||
</div>
|
</div>
|
||||||
<div n:if="$post->isSigned()" class="post-signature">
|
<div n:if="$post->isSigned()" class="post-signature">
|
||||||
|
@ -116,14 +121,14 @@
|
||||||
<a id="editPost"
|
<a id="editPost"
|
||||||
data-id="{$post->getId()}"
|
data-id="{$post->getId()}"
|
||||||
data-nsfw="{(int)$post->isExplicit()}"
|
data-nsfw="{(int)$post->isExplicit()}"
|
||||||
{if $post->getTargetWall() < 0 && $post->getWallOwner()->canBeModifiedBy($thisUser)}data-fromgroup="{(int)$post->isPostedOnBehalfOfGroup()}"{/if}>{_edit}</a> |
|
{if $post->getTargetWall() < 0 && $wallOwner->canBeModifiedBy($thisUser)}data-fromgroup="{(int)$post->isPostedOnBehalfOfGroup()}"{/if}>{_edit}</a> |
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
{if !($forceNoDeleteLink ?? false) && $post->canBeDeletedBy($thisUser)}
|
{if !($forceNoDeleteLink ?? false) && $canBeDeleted}
|
||||||
<a href="/wall{$post->getPrettyId()}/delete">{_delete}</a> |
|
<a href="/wall{$post->getPrettyId()}/delete">{_delete}</a> |
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
{if !($forceNoPinLink ?? false) && $post->canBePinnedBy($thisUser)}
|
{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>
|
||||||
{else}
|
{else}
|
||||||
|
@ -134,8 +139,8 @@
|
||||||
|
|
||||||
<a n:if="!($forceNoCommentsLink ?? false)" href="/wall{$post->getPrettyId()}#comments">
|
<a n:if="!($forceNoCommentsLink ?? false)" href="/wall{$post->getPrettyId()}#comments">
|
||||||
{_comments}
|
{_comments}
|
||||||
{if $post->getCommentsCount() > 0}
|
{if $commentsCount > 0}
|
||||||
(<b>{$post->getCommentsCount()}</b>)
|
(<b>{$commentsCount}</b>)
|
||||||
{/if}
|
{/if}
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
|
@ -145,22 +150,22 @@
|
||||||
|
|
||||||
<a n:if="!($forceNoShareLink ?? false)" id="reposts{$post->getPrettyId()}" class="post-share-button" {ifset $thisUser} href="javascript:repostPost('{$post->getPrettyId()}', '{rawurlencode($csrfToken)}')"{/ifset}>
|
<a n:if="!($forceNoShareLink ?? false)" id="reposts{$post->getPrettyId()}" class="post-share-button" {ifset $thisUser} href="javascript:repostPost('{$post->getPrettyId()}', '{rawurlencode($csrfToken)}')"{/ifset}>
|
||||||
{_share}
|
{_share}
|
||||||
{if $post->getRepostCount() > 0}
|
{if $repostsCount > 0}
|
||||||
(<b id="repostsCount{$post->getPrettyId()}">{$post->getRepostCount()}</b>)
|
(<b id="repostsCount{$post->getPrettyId()}">{$repostsCount}</b>)
|
||||||
{/if}
|
{/if}
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
<div n:if="!($forceNoLike ?? false)" class="like_wrap">
|
<div n:if="!($forceNoLike ?? false)" class="like_wrap">
|
||||||
{ifset $thisUser}
|
{ifset $thisUser}
|
||||||
{var $liked = $post->hasLikeFrom($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()}">
|
<a href="/wall{$post->getPrettyId()}/like?hash={rawurlencode($csrfToken)}" class="post-like-button" data-liked="{(int) $liked}" data-likes="{$likesCount}">
|
||||||
<div class="heart" id="{if $liked}liked{/if}"></div>
|
<div class="heart" id="{if $liked}liked{/if}"></div>
|
||||||
<span class="likeCnt">{if $post->getLikesCount() > 0}{$post->getLikesCount()}{/if}</span>
|
<span class="likeCnt">{if $likesCount > 0}{$likesCount}{/if}</span>
|
||||||
</a>
|
</a>
|
||||||
{else}
|
{else}
|
||||||
<a n:if="$post->getLikesCount() > 0" class="post-like-button">
|
<a n:if="$likesCount > 0" class="post-like-button">
|
||||||
<div class="heart"></div>
|
<div class="heart"></div>
|
||||||
<span class="likeCnt">{$post->getLikesCount()}</span>
|
<span class="likeCnt">{$likesCount}</span>
|
||||||
</a>
|
</a>
|
||||||
{/ifset}
|
{/ifset}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -18,23 +18,14 @@
|
||||||
<div class="post-has-poll">
|
<div class="post-has-poll">
|
||||||
{_poll}
|
{_poll}
|
||||||
</div>
|
</div>
|
||||||
<div class="post-has-note">
|
<div class="post-has-note"></div>
|
||||||
|
|
||||||
</div>
|
|
||||||
<div class="post-has-videos"></div>
|
<div class="post-has-videos"></div>
|
||||||
<div class="post-has-audios"></div>
|
<div class="post-has-audios"></div>
|
||||||
|
<div class="post-source"></div>
|
||||||
|
|
||||||
<div n:if="$postOpts ?? true" class="post-opts">
|
<div n:if="$postOpts ?? true" class="post-opts">
|
||||||
{var $anonEnabled = OPENVK_ROOT_CONF['openvk']['preferences']['wall']['anonymousPosting']['enable']}
|
{var $anonEnabled = OPENVK_ROOT_CONF['openvk']['preferences']['wall']['anonymousPosting']['enable']}
|
||||||
{if $hasSource}
|
|
||||||
<label style="user-select:none;">
|
|
||||||
<input type="checkbox" name="set_source"/> <span style="color: #777777;">{_set_source}</span>
|
|
||||||
</label>
|
|
||||||
|
|
||||||
<div id="sourceSet" style="display:none;">
|
|
||||||
<input type="text" name="source" placeholder="https://youtu.be/dQw4w9WgXcQ/"/>
|
|
||||||
</div>
|
|
||||||
{/if}
|
|
||||||
|
|
||||||
{if !is_null($thisUser) && !is_null($club ?? NULL) && $owner < 0}
|
{if !is_null($thisUser) && !is_null($club ?? NULL) && $owner < 0}
|
||||||
{if $club->canBeModifiedBy($thisUser)}
|
{if $club->canBeModifiedBy($thisUser)}
|
||||||
|
@ -76,6 +67,7 @@
|
||||||
<input type="hidden" name="audios" value="" />
|
<input type="hidden" name="audios" value="" />
|
||||||
<input type="hidden" name="poll" value="none" />
|
<input type="hidden" name="poll" value="none" />
|
||||||
<input type="hidden" id="note" name="note" value="none" />
|
<input type="hidden" id="note" name="note" value="none" />
|
||||||
|
<input type="hidden" id="source" name="source" value="none" />
|
||||||
<input type="hidden" name="type" value="1" />
|
<input type="hidden" name="type" value="1" />
|
||||||
<input type="hidden" name="hash" value="{$csrfToken}" />
|
<input type="hidden" name="hash" value="{$csrfToken}" />
|
||||||
<br/>
|
<br/>
|
||||||
|
@ -101,10 +93,6 @@
|
||||||
<img src="/assets/packages/static/openvk/img/oxygen-icons/16x16/mimetypes/audio-ac3.png" />
|
<img src="/assets/packages/static/openvk/img/oxygen-icons/16x16/mimetypes/audio-ac3.png" />
|
||||||
{_audio}
|
{_audio}
|
||||||
</a>
|
</a>
|
||||||
<a n:if="$notes ?? false" href="javascript:attachNote({$textAreaId})">
|
|
||||||
<img src="/assets/packages/static/openvk/img/oxygen-icons/16x16/mimetypes/application-x-srt.png" />
|
|
||||||
{_note}
|
|
||||||
</a>
|
|
||||||
<a n:if="$graffiti ?? false" href="javascript:initGraffiti({$textAreaId});">
|
<a n:if="$graffiti ?? false" href="javascript:initGraffiti({$textAreaId});">
|
||||||
<img src="/assets/packages/static/openvk/img/oxygen-icons/16x16/actions/draw-brush.png" />
|
<img src="/assets/packages/static/openvk/img/oxygen-icons/16x16/actions/draw-brush.png" />
|
||||||
{_graffiti}
|
{_graffiti}
|
||||||
|
@ -113,6 +101,10 @@
|
||||||
<img src="/assets/packages/static/openvk/img/oxygen-icons/16x16/actions/office-chart-bar-stacked.png" />
|
<img src="/assets/packages/static/openvk/img/oxygen-icons/16x16/actions/office-chart-bar-stacked.png" />
|
||||||
{_poll}
|
{_poll}
|
||||||
</a>
|
</a>
|
||||||
|
<a n:if="$hasSource ?? false" id='__sourceAttacher'>
|
||||||
|
<img src="/assets/packages/static/openvk/img/oxygen-icons/16x16/actions/insert-link.png" />
|
||||||
|
{_source}
|
||||||
|
</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -3,12 +3,12 @@
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<td valign="top">
|
<td valign="top">
|
||||||
<div class="video-preview">
|
<a href="/video{$video->getPrettyId()}" data-id="{$video->getId()}">
|
||||||
<a href="/video{$video->getPrettyId()}" {$videoModal ? "id='videoOpen'" : ''} data-id="{$video->getId()}">
|
<div class="video-preview">
|
||||||
<img src="{$video->getThumbnailURL()}"
|
<img src="{$video->getThumbnailURL()}"
|
||||||
style="max-width: 170px; max-height: 127px; margin: auto;" >
|
style="max-width: 170px; max-height: 127px; margin: auto;" >
|
||||||
</a>
|
</div>
|
||||||
</div>
|
</a>
|
||||||
</td>
|
</td>
|
||||||
<td valign="top" style="width: 100%">
|
<td valign="top" style="width: 100%">
|
||||||
{ifset infotable}
|
{ifset infotable}
|
||||||
|
|
|
@ -70,7 +70,7 @@ class Makima
|
||||||
$result->colSizes = [1];
|
$result->colSizes = [1];
|
||||||
$result->rowSizes = [1, 1];
|
$result->rowSizes = [1, 1];
|
||||||
$result->width = ceil($maxWidth);
|
$result->width = ceil($maxWidth);
|
||||||
$result->height = $computedHeight;
|
$result->height = $computedHeight * 2;
|
||||||
$result->tiles = [new ThumbTile(1, 1, $maxWidth, $computedHeight), new ThumbTile(1, 1, $maxWidth, $computedHeight)];
|
$result->tiles = [new ThumbTile(1, 1, $maxWidth, $computedHeight), new ThumbTile(1, 1, $maxWidth, $computedHeight)];
|
||||||
} else if(
|
} else if(
|
||||||
$orients == [Makima::ORIENT_WIDE, Makima::ORIENT_WIDE]
|
$orients == [Makima::ORIENT_WIDE, Makima::ORIENT_WIDE]
|
||||||
|
|
|
@ -9,7 +9,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.musicIcon {
|
.musicIcon {
|
||||||
background-image: url('/assets/packages/static/openvk/img/audios_controls.png');
|
background-image: url('/assets/packages/static/openvk/img/audios_controls.png?v=2');
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
@ -185,6 +185,7 @@
|
||||||
width: 81%;
|
width: 81%;
|
||||||
height: 13px;
|
height: 13px;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
|
line-height: 14px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.bigPlayer .paddingLayer .trackInfo .timer span {
|
.bigPlayer .paddingLayer .trackInfo .timer span {
|
||||||
|
@ -345,6 +346,7 @@
|
||||||
.audioEntry .status .mediaInfo {
|
.audioEntry .status .mediaInfo {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
line-height: 14px;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -549,6 +551,7 @@
|
||||||
|
|
||||||
.playlistListView .playlistInfo .playlistName {
|
.playlistListView .playlistInfo .playlistName {
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
|
line-height: 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.playlistListView .playlistInfo .playlistMeta, .playlistListView .playlistInfo .playlistMeta span {
|
.playlistListView .playlistInfo .playlistMeta, .playlistListView .playlistInfo .playlistMeta span {
|
||||||
|
|
|
@ -44,7 +44,7 @@
|
||||||
._add_image::before {
|
._add_image::before {
|
||||||
margin-top: 2px;
|
margin-top: 2px;
|
||||||
content: ' ';
|
content: ' ';
|
||||||
background: url('/assets/packages/static/openvk/img/upload.png');
|
background: url('/assets/packages/static/openvk/img/upload.png?v=2');
|
||||||
width: 10px;
|
width: 10px;
|
||||||
height: 10px;
|
height: 10px;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
|
@ -65,7 +65,7 @@
|
||||||
|
|
||||||
.avatarDelete::before {
|
.avatarDelete::before {
|
||||||
content: ' ';
|
content: ' ';
|
||||||
background: url('/assets/packages/static/openvk/img/upload.png');
|
background: url('/assets/packages/static/openvk/img/upload.png?v=2');
|
||||||
background-position: -10px 2px;
|
background-position: -10px 2px;
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
width: 12px;
|
width: 12px;
|
||||||
|
|
|
@ -1454,6 +1454,24 @@ body.scrolled .toTop:hover {
|
||||||
color: #3c3c3c;
|
color: #3c3c3c;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.post-source #remove_source_button {
|
||||||
|
display: inline-block;
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
background: url('/assets/packages/static/openvk/img/arrows.png?v=2');
|
||||||
|
|
||||||
|
margin-bottom: -2px;
|
||||||
|
background-position: -18px 0px;
|
||||||
|
height: 11px;
|
||||||
|
width: 11px;
|
||||||
|
opacity: 0.6;
|
||||||
|
transition-duration: 0.3s;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-source #remove_source_button:hover {
|
||||||
|
opacity: 0.8;
|
||||||
|
}
|
||||||
|
|
||||||
.post-upload::before, .post-has-poll::before, .post-has-note::before {
|
.post-upload::before, .post-has-poll::before, .post-has-note::before {
|
||||||
content: " ";
|
content: " ";
|
||||||
width: 8px;
|
width: 8px;
|
||||||
|
@ -3019,14 +3037,24 @@ body.article .floating_sidebar, body.article .page_content {
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.sourceDiv {
|
.post .sourceDiv {
|
||||||
margin-top: 3px;
|
margin-top: 3px;
|
||||||
margin-left: 4px;
|
margin-left: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.sourceDiv span {
|
.post .sourceDiv span {
|
||||||
color:grey;
|
color: grey;
|
||||||
font-size: 11px;
|
font-size: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.post .sourceDiv a:hover {
|
||||||
|
text-decoration: underline;
|
||||||
|
}
|
||||||
|
|
||||||
|
#source_flex_kunteynir {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
gap: 22px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.sugglist {
|
.sugglist {
|
||||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 219 B After Width: | Height: | Size: 316 B |
|
@ -66,16 +66,16 @@ u(`#search_box input[type='search']`).on('input', async (e) => {
|
||||||
|
|
||||||
switch(section) {
|
switch(section) {
|
||||||
case 'users':
|
case 'users':
|
||||||
results = await fetch(`/method/users.search?auth_mechanism=roaming&q=${query}&count=10&sort=4&fields=photo_50,status,nickname`)
|
results = await fetch(`/method/users.search?auth_mechanism=roaming&q=${encodeURIComponent(query)}&count=10&sort=4&fields=photo_50,status,nickname`)
|
||||||
break
|
break
|
||||||
case 'groups':
|
case 'groups':
|
||||||
results = await fetch(`/method/groups.search?auth_mechanism=roaming&q=${query}&count=10&sort=4&fields=photo_50,description`)
|
results = await fetch(`/method/groups.search?auth_mechanism=roaming&q=${encodeURIComponent(query)}&count=10&sort=4&fields=photo_50,description`)
|
||||||
break
|
break
|
||||||
case 'videos':
|
case 'videos':
|
||||||
results = await fetch(`/method/video.search?auth_mechanism=roaming&q=${query}&count=10&sort=4&extended=1`)
|
results = await fetch(`/method/video.search?auth_mechanism=roaming&q=${encodeURIComponent(query)}&count=10&sort=4&extended=1`)
|
||||||
break
|
break
|
||||||
case 'audios_playlists':
|
case 'audios_playlists':
|
||||||
results = await fetch(`/method/audio.searchAlbums?auth_mechanism=roaming&query=${query}&limit=10`)
|
results = await fetch(`/method/audio.searchAlbums?auth_mechanism=roaming&query=${encodeURIComponent(query)}&limit=10`)
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -525,21 +525,6 @@ async function showArticle(note_id) {
|
||||||
u("body").addClass("article");
|
u("body").addClass("article");
|
||||||
}
|
}
|
||||||
|
|
||||||
if(document.querySelector("input[name='set_source']") != null) {
|
|
||||||
document.querySelector("input[name='set_source']").checked = false
|
|
||||||
}
|
|
||||||
|
|
||||||
$(document).on("change", "input[name='set_source']", (e) => {
|
|
||||||
if(e.currentTarget.checked) {
|
|
||||||
document.getElementById("sourceSet").style.display = "block"
|
|
||||||
e.currentTarget.parentNode.querySelector("span").innerHTML = tr("source") + ":"
|
|
||||||
} else {
|
|
||||||
document.getElementById("sourceSet").style.display = "none"
|
|
||||||
e.currentTarget.parentNode.querySelector("span").innerHTML = tr("set_source")
|
|
||||||
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
// Оконный плеер
|
// Оконный плеер
|
||||||
|
|
||||||
$(document).on("click", "#videoOpen", async (e) => {
|
$(document).on("click", "#videoOpen", async (e) => {
|
||||||
|
@ -1160,7 +1145,7 @@ $(document).on("click", "#editPost", (e) => {
|
||||||
}
|
}
|
||||||
|
|
||||||
post.querySelector(".post-avatar").setAttribute("src", result.author.avatar)
|
post.querySelector(".post-avatar").setAttribute("src", result.author.avatar)
|
||||||
post.querySelector(".post-author-name").innerHTML = result.author.name
|
post.querySelector(".post-author-name").innerHTML = result.author.name.escapeHtml()
|
||||||
post.querySelector(".really_text").setAttribute("data-text", result.new_text)
|
post.querySelector(".really_text").setAttribute("data-text", result.new_text)
|
||||||
} else {
|
} else {
|
||||||
MessageBox(tr("error"), result.error, [tr("ok")], [Function.noop])
|
MessageBox(tr("error"), result.error, [tr("ok")], [Function.noop])
|
||||||
|
@ -1641,7 +1626,7 @@ $(document).on("click", ".avatarDelete", (e) => {
|
||||||
|
|
||||||
u("body").removeClass("dimmed");
|
u("body").removeClass("dimmed");
|
||||||
document.querySelector("html").style.overflowY = "scroll"
|
document.querySelector("html").style.overflowY = "scroll"
|
||||||
u(".ovk-diag-cont").remove();
|
u(".ovk-diag-cont").remove()
|
||||||
|
|
||||||
document.querySelector("#bigAvatar").src = response.url
|
document.querySelector("#bigAvatar").src = response.url
|
||||||
document.querySelector("#bigAvatar").parentNode.href = response.new_photo ? ("/photo" + response.new_photo) : "javascript:void(0)"
|
document.querySelector("#bigAvatar").parentNode.href = response.new_photo ? ("/photo" + response.new_photo) : "javascript:void(0)"
|
||||||
|
@ -1658,3 +1643,77 @@ $(document).on("click", ".avatarDelete", (e) => {
|
||||||
}),
|
}),
|
||||||
]);
|
]);
|
||||||
})
|
})
|
||||||
|
|
||||||
|
u(document).on('click', '#__sourceAttacher', (e) => {
|
||||||
|
MessageBox(tr('add_source'), `
|
||||||
|
<div id='source_flex_kunteynir'>
|
||||||
|
<span>${tr('set_source_tip')}</span>
|
||||||
|
<!-- давай, копируй ссылку и переходи по ней -->
|
||||||
|
<input type='text' maxlength='400' placeholder='https://www.youtube.com/watch?v=lkWuk_nzzVA'>
|
||||||
|
</div>
|
||||||
|
`, [tr('cancel')], [
|
||||||
|
() => {Function.noop}
|
||||||
|
])
|
||||||
|
|
||||||
|
__removeDialog = () => {
|
||||||
|
u("body").removeClass("dimmed");
|
||||||
|
document.querySelector("html").style.overflowY = "scroll"
|
||||||
|
u(".ovk-diag-cont").remove()
|
||||||
|
}
|
||||||
|
|
||||||
|
u('.ovk-diag-action').append(`
|
||||||
|
<button class='button' id='__setsrcbutton'>${tr('set_source')}</button>
|
||||||
|
`)
|
||||||
|
|
||||||
|
u('.ovk-diag-action #__setsrcbutton').on('click', async (ev) => {
|
||||||
|
// Consts
|
||||||
|
const _u_target = u(e.target)
|
||||||
|
const nearest_textarea = _u_target.closest('#write')
|
||||||
|
const source_output = nearest_textarea.find(`input[name='source']`)
|
||||||
|
const source_input = u(`#source_flex_kunteynir input[type='text']`)
|
||||||
|
const source_value = source_input.nodes[0].value ?? ''
|
||||||
|
if(source_value.length < 1) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
ev.target.classList.add('lagged')
|
||||||
|
|
||||||
|
// Checking link
|
||||||
|
const __checkCopyrightLinkRes = await fetch(`/method/wall.checkCopyrightLink?auth_mechanism=roaming&link=${encodeURIComponent(source_value)}`)
|
||||||
|
const checkCopyrightLink = await __checkCopyrightLinkRes.json()
|
||||||
|
|
||||||
|
// todo переписать блять мессенджбоксы чтоб они классами были
|
||||||
|
if(checkCopyrightLink.error_code) {
|
||||||
|
__removeDialog()
|
||||||
|
switch(checkCopyrightLink.error_code) {
|
||||||
|
default:
|
||||||
|
case 3102:
|
||||||
|
fastError(tr('error_adding_source_regex'))
|
||||||
|
return
|
||||||
|
case 3103:
|
||||||
|
fastError(tr('error_adding_source_long'))
|
||||||
|
return
|
||||||
|
case 3104:
|
||||||
|
fastError(tr('error_adding_source_sus'))
|
||||||
|
return
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Making indicator
|
||||||
|
__removeDialog()
|
||||||
|
source_output.attr('value', source_value)
|
||||||
|
nearest_textarea.find('.post-source').html(`
|
||||||
|
<span>${tr('source')}: <a target='_blank' href='${source_value.escapeHtml()}'>${ovk_proc_strtr(source_value.escapeHtml(), 50)}</a></span>
|
||||||
|
<div id='remove_source_button'></div>
|
||||||
|
`)
|
||||||
|
|
||||||
|
nearest_textarea.find('.post-source #remove_source_button').on('click', () => {
|
||||||
|
nearest_textarea.find('.post-source').html('')
|
||||||
|
source_output.attr('value', 'none')
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
u('.ovk-diag-body').attr('style', `padding:8px;`)
|
||||||
|
u('.ovk-diag-cont').attr('style', 'width: 325px;')
|
||||||
|
u('#source_flex_kunteynir input').nodes[0].focus()
|
||||||
|
})
|
||||||
|
|
|
@ -286,6 +286,31 @@ function ovk_scheme(bool $with_slashes = false): string
|
||||||
return $scheme;
|
return $scheme;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function check_copyright_link(string $link = ''): bool
|
||||||
|
{
|
||||||
|
if(!str_contains($link, "https://") && !str_contains($link, "http://"))
|
||||||
|
$link = "https://" . $link;
|
||||||
|
|
||||||
|
# Existability
|
||||||
|
if(is_null($link) || empty($link))
|
||||||
|
throw new \InvalidArgumentException("Empty link");
|
||||||
|
|
||||||
|
# Length
|
||||||
|
if(iconv_strlen($link) < 2 || iconv_strlen($link) > 400)
|
||||||
|
throw new \LengthException("Link is too long");
|
||||||
|
|
||||||
|
# Match URL regex
|
||||||
|
# stolen from http://urlregex.com/
|
||||||
|
if (!preg_match("%^(?:(?:https?|ftp)://)(?:\S+(?::\S*)?@|\d{1,3}(?:\.\d{1,3}){3}|(?:(?:[a-z\d\x{00a1}-\x{ffff}]+-?)*[a-z\d\x{00a1}-\x{ffff}]+|xn--[a-z\d-]+)(?:\.(?:[a-z\d\x{00a1}-\x{ffff}]+-?)*[a-z\d\x{00a1}-\x{ffff}]+)*(?:\.(?:xn--[a-z\d-]+|[a-z\x{00a1}-\x{ffff}]{2,6})))(?::\d+)?(?:[^\s]*)?$%iu", $link))
|
||||||
|
throw new \InvalidArgumentException("Invalid link format");
|
||||||
|
|
||||||
|
$banEntries = (new openvk\Web\Models\Repositories\BannedLinks)->check($link);
|
||||||
|
if(sizeof($banEntries) > 0)
|
||||||
|
throw new \LogicException("Suspicious link");
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
return (function() {
|
return (function() {
|
||||||
_ovk_check_environment();
|
_ovk_check_environment();
|
||||||
require __DIR__ . "/vendor/autoload.php";
|
require __DIR__ . "/vendor/autoload.php";
|
||||||
|
|
|
@ -223,8 +223,12 @@
|
||||||
"attachment" = "Attachment";
|
"attachment" = "Attachment";
|
||||||
"post_as_group" = "Post as group";
|
"post_as_group" = "Post as group";
|
||||||
"comment_as_group" = "Comment as group";
|
"comment_as_group" = "Comment as group";
|
||||||
"set_source" = "Set source";
|
|
||||||
|
"add_source" = "Add source";
|
||||||
|
"set_source" = "Apply source";
|
||||||
"source" = "Source";
|
"source" = "Source";
|
||||||
|
"set_source_tip" = "If you are using content from other authors, it is important to provide a source to the original. You can do this below.";
|
||||||
|
|
||||||
"add_signature" = "Add signature";
|
"add_signature" = "Add signature";
|
||||||
/* ^ can be translated as "author's signature". ^ */
|
/* ^ can be translated as "author's signature". ^ */
|
||||||
"contains_nsfw" = "Contains NSFW content";
|
"contains_nsfw" = "Contains NSFW content";
|
||||||
|
@ -836,6 +840,7 @@
|
||||||
|
|
||||||
/* Audios */
|
/* Audios */
|
||||||
|
|
||||||
|
"my" = "My";
|
||||||
"audios" = "Audios";
|
"audios" = "Audios";
|
||||||
"audio" = "Audio";
|
"audio" = "Audio";
|
||||||
"playlist" = "Playlist";
|
"playlist" = "Playlist";
|
||||||
|
@ -1555,6 +1560,10 @@
|
||||||
"ffmpeg_not_installed" = "Failed to proccess the file. It looks like ffmpeg is not installed on this server.";
|
"ffmpeg_not_installed" = "Failed to proccess the file. It looks like ffmpeg is not installed on this server.";
|
||||||
"too_many_or_to_lack" = "Too few or too many sources.";
|
"too_many_or_to_lack" = "Too few or too many sources.";
|
||||||
|
|
||||||
|
"error_adding_source_regex" = "Error adding source: incorrect link.";
|
||||||
|
"error_adding_source_long" = "Error adding source: link is too long.";
|
||||||
|
"error_adding_source_sus" = "Error adding source: suspicious link.";
|
||||||
|
|
||||||
/* Admin actions */
|
/* Admin actions */
|
||||||
|
|
||||||
"login_as" = "Login as $1";
|
"login_as" = "Login as $1";
|
||||||
|
@ -1995,6 +2004,7 @@
|
||||||
|
|
||||||
/* Search */
|
/* Search */
|
||||||
|
|
||||||
|
"s_params" = "Search params";
|
||||||
"s_people" = "Users";
|
"s_people" = "Users";
|
||||||
"s_groups" = "Clubs";
|
"s_groups" = "Clubs";
|
||||||
"s_apps" = "Applications";
|
"s_apps" = "Applications";
|
||||||
|
|
|
@ -207,8 +207,12 @@
|
||||||
"attachment" = "Вложение";
|
"attachment" = "Вложение";
|
||||||
"post_as_group" = "От имени сообщества";
|
"post_as_group" = "От имени сообщества";
|
||||||
"comment_as_group" = "От имени сообщества";
|
"comment_as_group" = "От имени сообщества";
|
||||||
|
|
||||||
|
"add_source" = "Добавление источника";
|
||||||
"set_source" = "Указать источник";
|
"set_source" = "Указать источник";
|
||||||
"source" = "Источник";
|
"source" = "Источник";
|
||||||
|
"set_source_tip" = "Если вы используете материалы других авторов, важно указывать ссылку на оригинал. Это вы можете сделать ниже.";
|
||||||
|
|
||||||
"add_signature" = "Подпись автора";
|
"add_signature" = "Подпись автора";
|
||||||
"contains_nsfw" = "Содержит NSFW-контент";
|
"contains_nsfw" = "Содержит NSFW-контент";
|
||||||
"nsfw_warning" = "Данный пост может содержать 18+ контент";
|
"nsfw_warning" = "Данный пост может содержать 18+ контент";
|
||||||
|
@ -793,6 +797,7 @@
|
||||||
|
|
||||||
/* Audios */
|
/* Audios */
|
||||||
|
|
||||||
|
"my" = "Моё";
|
||||||
"audios" = "Аудиозаписи";
|
"audios" = "Аудиозаписи";
|
||||||
"audio" = "Аудиозапись";
|
"audio" = "Аудиозапись";
|
||||||
"playlist" = "Плейлист";
|
"playlist" = "Плейлист";
|
||||||
|
@ -872,7 +877,7 @@
|
||||||
"remove_from_playlist" = "Удалить из плейлиста";
|
"remove_from_playlist" = "Удалить из плейлиста";
|
||||||
"delete_playlist" = "Удалить плейлист";
|
"delete_playlist" = "Удалить плейлист";
|
||||||
"playlist_cover" = "Обложка плейлиста";
|
"playlist_cover" = "Обложка плейлиста";
|
||||||
"playlists_user" = "Плейлисты польз.";
|
"playlists_user" = "Плейлисты пользователя";
|
||||||
"playlists_club" = "Плейлисты группы";
|
"playlists_club" = "Плейлисты группы";
|
||||||
"change_cover" = "Сменить обложку";
|
"change_cover" = "Сменить обложку";
|
||||||
"playlist_cover" = "Обложка плейлиста";
|
"playlist_cover" = "Обложка плейлиста";
|
||||||
|
@ -1457,6 +1462,10 @@
|
||||||
"ffmpeg_not_installed" = "Не удалось обработать файл. Похоже, на сервере не установлен ffmpeg.";
|
"ffmpeg_not_installed" = "Не удалось обработать файл. Похоже, на сервере не установлен ffmpeg.";
|
||||||
"too_many_or_to_lack" = "Слишком мало либо слишком много источников.";
|
"too_many_or_to_lack" = "Слишком мало либо слишком много источников.";
|
||||||
|
|
||||||
|
"error_adding_source_regex" = "Ошибка добавления источника: некорректная ссылка.";
|
||||||
|
"error_adding_source_long" = "Ошибка добавления источника: слишком длинная ссылка.";
|
||||||
|
"error_adding_source_sus" = "Ошибка добавления источника: подозрительная ссылка.";
|
||||||
|
|
||||||
/* Admin actions */
|
/* Admin actions */
|
||||||
|
|
||||||
"login_as" = "Войти как $1";
|
"login_as" = "Войти как $1";
|
||||||
|
@ -1885,6 +1894,7 @@
|
||||||
|
|
||||||
/* Search */
|
/* Search */
|
||||||
|
|
||||||
|
"s_params" = "Параметры поиска";
|
||||||
"s_people" = "Пользователи";
|
"s_people" = "Пользователи";
|
||||||
"s_groups" = "Группы";
|
"s_groups" = "Группы";
|
||||||
"s_apps" = "Приложения";
|
"s_apps" = "Приложения";
|
||||||
|
|
Loading…
Reference in a new issue