Merge pull request #12186 from nupplaphil/mod/editpost

Move mod/editpost.php to src\Module\Post\Edit
This commit is contained in:
Hypolite Petovan 2022-11-16 16:14:07 -05:00 committed by GitHub
commit 293f147867
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 473 additions and 407 deletions

View file

@ -790,10 +790,6 @@ Here is a complete list of all hook callbacks with file locations (as of 24-Sep-
Hook::callAll('post_local', $datarray); Hook::callAll('post_local', $datarray);
Hook::callAll('post_local_end', $datarray); Hook::callAll('post_local_end', $datarray);
### mod/editpost.php
Hook::callAll('jot_tool', $jotplugins);
### src/Render/FriendicaSmartyEngine.php ### src/Render/FriendicaSmartyEngine.php
Hook::callAll("template_vars", $arr); Hook::callAll("template_vars", $arr);
@ -855,6 +851,10 @@ Here is a complete list of all hook callbacks with file locations (as of 24-Sep-
Hook::callAll('lockview_content', $item); Hook::callAll('lockview_content', $item);
### src/Module/Post/Edit.php
Hook::callAll('jot_tool', $jotplugins);
### src/Module/Settings/Delegation.php ### src/Module/Settings/Delegation.php
Hook::callAll('authenticate', $addon_auth); Hook::callAll('authenticate', $addon_auth);

View file

@ -309,10 +309,6 @@ Eine komplette Liste aller Hook-Callbacks mit den zugehörigen Dateien (am 01-Ap
Hook::callAll('post_local', $datarray); Hook::callAll('post_local', $datarray);
Hook::callAll('post_local_end', $datarray); Hook::callAll('post_local_end', $datarray);
### mod/editpost.php
Hook::callAll('jot_tool', $jotplugins);
### src/Network/FKOAuth1.php ### src/Network/FKOAuth1.php
Hook::callAll('logged_in', $a->user); Hook::callAll('logged_in', $a->user);
@ -422,6 +418,10 @@ Eine komplette Liste aller Hook-Callbacks mit den zugehörigen Dateien (am 01-Ap
Hook::callAll('lockview_content', $item); Hook::callAll('lockview_content', $item);
### src/Module/Post/Edit.php
Hook::callAll('jot_tool', $jotplugins);
### src/Worker/Directory.php ### src/Worker/Directory.php
Hook::callAll('globaldir_update', $arr); Hook::callAll('globaldir_update', $arr);

View file

@ -1,166 +0,0 @@
<?php
/**
* @copyright Copyright (C) 2010-2022, the Friendica project
*
* @license GNU AGPL version 3 or any later version
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*
*/
use Friendica\App;
use Friendica\Content\Feature;
use Friendica\Core\Hook;
use Friendica\Core\Renderer;
use Friendica\Database\DBA;
use Friendica\DI;
use Friendica\Model\Contact;
use Friendica\Model\Post;
use Friendica\Model\User;
use Friendica\Util\Crypto;
function editpost_content(App $a)
{
$o = '';
if (!DI::userSession()->getLocalUserId()) {
DI::sysmsg()->addNotice(DI::l10n()->t('Permission denied.'));
return;
}
$post_id = ((DI::args()->getArgc() > 1) ? intval(DI::args()->getArgv()[1]) : 0);
if (!$post_id) {
DI::sysmsg()->addNotice(DI::l10n()->t('Item not found'));
return;
}
$fields = ['allow_cid', 'allow_gid', 'deny_cid', 'deny_gid',
'body', 'title', 'uri-id', 'wall', 'post-type', 'guid'];
$item = Post::selectFirstForUser(DI::userSession()->getLocalUserId(), $fields, ['id' => $post_id, 'uid' => DI::userSession()->getLocalUserId()]);
if (!DBA::isResult($item)) {
DI::sysmsg()->addNotice(DI::l10n()->t('Item not found'));
return;
}
$user = User::getById(DI::userSession()->getLocalUserId());
$geotag = '';
$o .= Renderer::replaceMacros(Renderer::getMarkupTemplate("section_title.tpl"), [
'$title' => DI::l10n()->t('Edit post')
]);
$tpl = Renderer::getMarkupTemplate('jot-header.tpl');
DI::page()['htmlhead'] .= Renderer::replaceMacros($tpl, [
'$ispublic' => '&nbsp;', // DI::l10n()->t('Visible to <strong>everybody</strong>'),
'$geotag' => $geotag,
'$nickname' => $a->getLoggedInUserNickname(),
'$is_mobile' => DI::mode()->isMobile(),
]);
if (strlen($item['allow_cid']) || strlen($item['allow_gid']) || strlen($item['deny_cid']) || strlen($item['deny_gid'])) {
$lockstate = 'lock';
} else {
$lockstate = 'unlock';
}
$jotplugins = '';
$jotnets = '';
Hook::callAll('jot_tool', $jotplugins);
$tpl = Renderer::getMarkupTemplate('jot.tpl');
$o .= Renderer::replaceMacros($tpl, [
'$is_edit' => true,
'$return_path' => '/display/' . $item['guid'],
'$action' => 'item',
'$share' => DI::l10n()->t('Save'),
'$loading' => DI::l10n()->t('Loading...'),
'$upload' => DI::l10n()->t('Upload photo'),
'$shortupload' => DI::l10n()->t('upload photo'),
'$attach' => DI::l10n()->t('Attach file'),
'$shortattach' => DI::l10n()->t('attach file'),
'$weblink' => DI::l10n()->t('Insert web link'),
'$shortweblink' => DI::l10n()->t('web link'),
'$video' => DI::l10n()->t('Insert video link'),
'$shortvideo' => DI::l10n()->t('video link'),
'$audio' => DI::l10n()->t('Insert audio link'),
'$shortaudio' => DI::l10n()->t('audio link'),
'$setloc' => DI::l10n()->t('Set your location'),
'$shortsetloc' => DI::l10n()->t('set location'),
'$noloc' => DI::l10n()->t('Clear browser location'),
'$shortnoloc' => DI::l10n()->t('clear location'),
'$wait' => DI::l10n()->t('Please wait'),
'$permset' => DI::l10n()->t('Permission settings'),
'$wall' => $item['wall'],
'$posttype' => $item['post-type'],
'$content' => undo_post_tagging($item['body']),
'$post_id' => $post_id,
'$defloc' => $user['default-location'],
'$visitor' => 'none',
'$pvisit' => 'none',
'$emailcc' => DI::l10n()->t('CC: email addresses'),
'$public' => DI::l10n()->t('Public post'),
'$jotnets' => $jotnets,
'$title' => $item['title'],
'$placeholdertitle' => DI::l10n()->t('Set title'),
'$category' => Post\Category::getCSVByURIId($item['uri-id'], DI::userSession()->getLocalUserId(), Post\Category::CATEGORY),
'$placeholdercategory' => (Feature::isEnabled(DI::userSession()->getLocalUserId(),'categories') ? DI::l10n()->t("Categories \x28comma-separated list\x29") : ''),
'$emtitle' => DI::l10n()->t('Example: bob@example.com, mary@example.com'),
'$lockstate' => $lockstate,
'$acl' => '', // populate_acl((($group) ? $group_acl : $a->user)),
'$bang' => ($lockstate === 'lock' ? '!' : ''),
'$profile_uid' => $_SESSION['uid'],
'$preview' => DI::l10n()->t('Preview'),
'$jotplugins' => $jotplugins,
'$cancel' => DI::l10n()->t('Cancel'),
'$rand_num' => Crypto::randomDigits(12),
// Formatting button labels
'$edbold' => DI::l10n()->t('Bold'),
'$editalic' => DI::l10n()->t('Italic'),
'$eduline' => DI::l10n()->t('Underline'),
'$edquote' => DI::l10n()->t('Quote'),
'$edcode' => DI::l10n()->t('Code'),
'$edurl' => DI::l10n()->t('Link'),
'$edattach' => DI::l10n()->t('Link or Media'),
//jot nav tab (used in some themes)
'$message' => DI::l10n()->t('Message'),
'$browser' => DI::l10n()->t('Browser'),
'$shortpermset' => DI::l10n()->t('Permissions'),
'$compose_link_title' => DI::l10n()->t('Open Compose page'),
]);
return $o;
}
function undo_post_tagging($s) {
$matches = null;
$cnt = preg_match_all('/([!#@])\[url=(.*?)\](.*?)\[\/url\]/ism', $s, $matches, PREG_SET_ORDER);
if ($cnt) {
foreach ($matches as $mtch) {
if (in_array($mtch[1], ['!', '@'])) {
$contact = Contact::getByURL($mtch[2], false, ['addr']);
$mtch[3] = empty($contact['addr']) ? $mtch[2] : $contact['addr'];
}
$s = str_replace($mtch[0], $mtch[1] . $mtch[3],$s);
}
}
return $s;
}

227
src/Module/Post/Edit.php Normal file
View file

@ -0,0 +1,227 @@
<?php
/**
* @copyright Copyright (C) 2010-2022, the Friendica project
*
* @license GNU AGPL version 3 or any later version
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*
*/
namespace Friendica\Module\Post;
use Friendica\App;
use Friendica\BaseModule;
use Friendica\Content\Feature;
use Friendica\Core\Hook;
use Friendica\Core\L10n;
use Friendica\Core\Renderer;
use Friendica\Core\Session\Capability\IHandleUserSessions;
use Friendica\Model\Contact;
use Friendica\Model\Post;
use Friendica\Model\User;
use Friendica\Module\Response;
use Friendica\Navigation\SystemMessages;
use Friendica\Network\HTTPException;
use Friendica\Util\Crypto;
use Friendica\Util\Profiler;
use Psr\Log\LoggerInterface;
/**
* Controller to edit a post
*/
class Edit extends BaseModule
{
/** @var IHandleUserSessions */
protected $session;
/** @var SystemMessages */
protected $sysMessages;
/** @var App\Page */
protected $page;
/** @var App\Mode */
protected $mode;
/** @var App */
protected $app;
/** @var bool */
protected $isModal = false;
public function __construct(L10n $l10n, App\BaseURL $baseUrl, App\Arguments $args, LoggerInterface $logger, Profiler $profiler, Response $response, IHandleUserSessions $session, SystemMessages $sysMessages, App\Page $page, App\Mode $mode, App $app, array $server, array $parameters = [])
{
parent::__construct($l10n, $baseUrl, $args, $logger, $profiler, $response, $server, $parameters);
$this->session = $session;
$this->sysMessages = $sysMessages;
$this->page = $page;
$this->mode = $mode;
$this->app = $app;
}
protected function content(array $request = []): string
{
$this->isModal = $request['mode'] ?? '' === 'none';
if (!$this->session->getLocalUserId()) {
$this->errorExit($this->t('Permission denied.'), HTTPException\UnauthorizedException::class);
}
$postId = $this->parameters['post_id'] ?? 0;
if (empty($postId)) {
$this->errorExit($this->t('Post not found.'), HTTPException\BadRequestException::class);
}
$fields = [
'allow_cid', 'allow_gid', 'deny_cid', 'deny_gid',
'body', 'title', 'uri-id', 'wall', 'post-type', 'guid'
];
$item = Post::selectFirstForUser($this->session->getLocalUserId(), $fields, [
'id' => $postId,
'uid' => $this->session->getLocalUserId(),
]);
if (empty($item)) {
$this->errorExit($this->t('Post not found.'), HTTPException\BadRequestException::class);
}
$user = User::getById($this->session->getLocalUserId());
$output = Renderer::replaceMacros(Renderer::getMarkupTemplate('section_title.tpl'), [
'$title' => $this->t('Edit post'),
]);
$this->page['htmlhead'] .= Renderer::replaceMacros(Renderer::getMarkupTemplate('jot-header.tpl'), [
'$ispublic' => '&nbsp;',
'$geotag' => '',
'$nickname' => $this->app->getLoggedInUserNickname(),
'$is_mobile' => $this->mode->isMobile(),
]);
if (strlen($item['allow_cid']) || strlen($item['allow_gid']) || strlen($item['deny_cid']) || strlen($item['deny_gid'])) {
$lockstate = 'lock';
} else {
$lockstate = 'unlock';
}
$jotplugins = '';
Hook::callAll('jot_tool', $jotplugins);
$output .= Renderer::replaceMacros(Renderer::getMarkupTemplate('jot.tpl'), [
'$is_edit' => true,
'$return_path' => '/display/' . $item['guid'],
'$action' => 'item',
'$share' => $this->t('Save'),
'$loading' => $this->t('Loading...'),
'$upload' => $this->t('Upload photo'),
'$shortupload' => $this->t('upload photo'),
'$attach' => $this->t('Attach file'),
'$shortattach' => $this->t('attach file'),
'$weblink' => $this->t('Insert web link'),
'$shortweblink' => $this->t('web link'),
'$video' => $this->t('Insert video link'),
'$shortvideo' => $this->t('video link'),
'$audio' => $this->t('Insert audio link'),
'$shortaudio' => $this->t('audio link'),
'$setloc' => $this->t('Set your location'),
'$shortsetloc' => $this->t('set location'),
'$noloc' => $this->t('Clear browser location'),
'$shortnoloc' => $this->t('clear location'),
'$wait' => $this->t('Please wait'),
'$permset' => $this->t('Permission settings'),
'$wall' => $item['wall'],
'$posttype' => $item['post-type'],
'$content' => $this->undoPostTagging($item['body']),
'$post_id' => $postId,
'$defloc' => $user['default-location'],
'$visitor' => 'none',
'$pvisit' => 'none',
'$emailcc' => $this->t('CC: email addresses'),
'$public' => $this->t('Public post'),
'$title' => $item['title'],
'$placeholdertitle' => $this->t('Set title'),
'$category' => Post\Category::getCSVByURIId($item['uri-id'], $this->session->getLocalUserId(), Post\Category::CATEGORY),
'$placeholdercategory' => (Feature::isEnabled($this->session->getLocalUserId(), 'categories') ? $this->t("Categories \x28comma-separated list\x29") : ''),
'$emtitle' => $this->t('Example: bob@example.com, mary@example.com'),
'$lockstate' => $lockstate,
'$acl' => '',
'$bang' => ($lockstate === 'lock' ? '!' : ''),
'$profile_uid' => $this->session->getLocalUserId(),
'$preview' => $this->t('Preview'),
'$jotplugins' => $jotplugins,
'$cancel' => $this->t('Cancel'),
'$rand_num' => Crypto::randomDigits(12),
// Formatting button labels
'$edbold' => $this->t('Bold'),
'$editalic' => $this->t('Italic'),
'$eduline' => $this->t('Underline'),
'$edquote' => $this->t('Quote'),
'$edcode' => $this->t('Code'),
'$edurl' => $this->t('Link'),
'$edattach' => $this->t('Link or Media'),
//jot nav tab (used in some themes)
'$message' => $this->t('Message'),
'$browser' => $this->t('Browser'),
'$shortpermset' => $this->t('Permissions'),
'$compose_link_title' => $this->t('Open Compose page'),
]);
return $output;
}
/**
* Removes Tags from the item-body
*
* @param string $body The item body
*
* @return string the new item body without tagging
*/
protected function undoPostTagging(string $body)
{
$matches = null;
$content = preg_match_all('/([!#@])\[url=(.*?)\](.*?)\[\/url\]/ism', $body, $matches, PREG_SET_ORDER);
if ($content) {
foreach ($matches as $match) {
if (in_array($match[1], ['!', '@'])) {
$contact = Contact::getByURL($match[2], false, ['addr']);
$match[3] = empty($contact['addr']) ? $match[2] : $contact['addr'];
}
$body = str_replace($match[0], $match[1] . $match[3], $body);
}
}
return $body;
}
/**
* Exists the current Module because of an error
*
* @param string $message The error message
* @param string $exceptionClass In case it's a modal, throw an exception instead of an redirect
*
* @return void
*/
protected function errorExit(string $message, string $exceptionClass)
{
if ($this->isModal) {
throw new $exceptionClass($message);
} else {
$this->sysMessages->addNotice($message);
$this->baseUrl->redirect();
}
}
}

View file

@ -220,7 +220,7 @@ class Post
if ($item['event-id'] != 0) { if ($item['event-id'] != 0) {
$edpost = ['calendar/event/edit/' . $item['event-id'], DI::l10n()->t('Edit')]; $edpost = ['calendar/event/edit/' . $item['event-id'], DI::l10n()->t('Edit')];
} else { } else {
$edpost = ['editpost/' . $item['id'], DI::l10n()->t('Edit')]; $edpost = [sprintf('post/%s/edit', $item['id']), DI::l10n()->t('Edit')];
} }
} }
$dropping = in_array($item['uid'], [0, DI::userSession()->getLocalUserId()]); $dropping = in_array($item['uid'], [0, DI::userSession()->getLocalUserId()]);

View file

@ -552,6 +552,7 @@ return [
'/ping' => [Module\Notifications\Ping::class, [R::GET]], '/ping' => [Module\Notifications\Ping::class, [R::GET]],
'/post' => [ '/post' => [
'/{post_id}/edit' => [Module\Post\Edit::class, [R::GET ]],
'/{post_id}/share' => [Module\Post\Share::class, [R::GET ]], '/{post_id}/share' => [Module\Post\Share::class, [R::GET ]],
'/{item_id}/tag/add' => [Module\Post\Tag\Add::class, [ R::POST]], '/{item_id}/tag/add' => [Module\Post\Tag\Add::class, [ R::POST]],
'/{item_id}/tag/remove[/{tag_name}]' => [Module\Post\Tag\Remove::class, [R::GET, R::POST]], '/{item_id}/tag/remove[/{tag_name}]' => [Module\Post\Tag\Remove::class, [R::GET, R::POST]],

View file

@ -8,7 +8,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: 2022.12-dev\n" "Project-Id-Version: 2022.12-dev\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-11-15 00:00+0000\n" "POT-Creation-Date: 2022-11-15 21:34+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
@ -18,9 +18,36 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n" "Content-Transfer-Encoding: 8bit\n"
#: mod/editpost.php:38 mod/item.php:181 mod/item.php:186 mod/item.php:870 #: mod/fbrowser.php:61 src/Content/Nav.php:195 src/Module/BaseProfile.php:64
#: mod/message.php:69 mod/message.php:114 mod/notes.php:44 mod/photos.php:159 #: view/theme/frio/theme.php:239
#: mod/photos.php:886 src/Module/Attach.php:56 src/Module/BaseApi.php:94 msgid "Photos"
msgstr ""
#: mod/fbrowser.php:119 mod/fbrowser.php:146 mod/photos.php:999
#: mod/photos.php:1100 src/Content/Conversation.php:389
#: src/Module/Contact/Follow.php:171 src/Module/Contact/Revoke.php:109
#: src/Module/Contact/Unfollow.php:126 src/Module/Post/Edit.php:165
#: src/Module/Post/Tag/Remove.php:109 src/Module/Profile/RemoteFollow.php:134
#: src/Module/Security/TwoFactor/SignOut.php:125
msgid "Cancel"
msgstr ""
#: mod/fbrowser.php:121 mod/fbrowser.php:148
#: src/Module/Settings/Profile/Photo/Index.php:128
msgid "Upload"
msgstr ""
#: mod/fbrowser.php:143
msgid "Files"
msgstr ""
#: mod/item.php:131 mod/item.php:135
msgid "Unable to locate original post."
msgstr ""
#: mod/item.php:181 mod/item.php:186 mod/item.php:870 mod/message.php:69
#: mod/message.php:114 mod/notes.php:44 mod/photos.php:159 mod/photos.php:886
#: src/Module/Attach.php:56 src/Module/BaseApi.php:94
#: src/Module/BaseNotifications.php:98 src/Module/BaseSettings.php:52 #: src/Module/BaseNotifications.php:98 src/Module/BaseSettings.php:52
#: src/Module/Calendar/Event/API.php:88 src/Module/Calendar/Event/Form.php:84 #: src/Module/Calendar/Event/API.php:88 src/Module/Calendar/Event/Form.php:84
#: src/Module/Calendar/Event/Show.php:54 src/Module/Calendar/Export.php:62 #: src/Module/Calendar/Event/Show.php:54 src/Module/Calendar/Export.php:62
@ -35,16 +62,17 @@ msgstr ""
#: src/Module/Notifications/Notification.php:76 #: src/Module/Notifications/Notification.php:76
#: src/Module/Notifications/Notification.php:107 #: src/Module/Notifications/Notification.php:107
#: src/Module/OStatus/Repair.php:60 src/Module/OStatus/Subscribe.php:66 #: src/Module/OStatus/Repair.php:60 src/Module/OStatus/Subscribe.php:66
#: src/Module/Profile/Attachment/Upload.php:97 src/Module/Profile/Common.php:55 #: src/Module/Post/Edit.php:76 src/Module/Profile/Attachment/Upload.php:97
#: src/Module/Profile/Contacts.php:55 src/Module/Profile/Photos/Upload.php:108 #: src/Module/Profile/Common.php:55 src/Module/Profile/Contacts.php:55
#: src/Module/Profile/Schedule.php:39 src/Module/Profile/Schedule.php:56 #: src/Module/Profile/Photos/Upload.php:108 src/Module/Profile/Schedule.php:39
#: src/Module/Profile/UnkMail.php:69 src/Module/Profile/UnkMail.php:121 #: src/Module/Profile/Schedule.php:56 src/Module/Profile/UnkMail.php:69
#: src/Module/Profile/UnkMail.php:132 src/Module/Register.php:77 #: src/Module/Profile/UnkMail.php:121 src/Module/Profile/UnkMail.php:132
#: src/Module/Register.php:90 src/Module/Register.php:206 #: src/Module/Register.php:77 src/Module/Register.php:90
#: src/Module/Register.php:245 src/Module/Search/Directory.php:37 #: src/Module/Register.php:206 src/Module/Register.php:245
#: src/Module/Settings/Account.php:50 src/Module/Settings/Account.php:407 #: src/Module/Search/Directory.php:37 src/Module/Settings/Account.php:50
#: src/Module/Settings/Delegation.php:41 src/Module/Settings/Delegation.php:69 #: src/Module/Settings/Account.php:407 src/Module/Settings/Delegation.php:41
#: src/Module/Settings/Display.php:41 src/Module/Settings/Display.php:119 #: src/Module/Settings/Delegation.php:69 src/Module/Settings/Display.php:41
#: src/Module/Settings/Display.php:119
#: src/Module/Settings/Profile/Photo/Crop.php:165 #: src/Module/Settings/Profile/Photo/Crop.php:165
#: src/Module/Settings/Profile/Photo/Index.php:111 #: src/Module/Settings/Profile/Photo/Index.php:111
#: src/Module/Settings/RemoveMe.php:117 src/Module/Settings/UserExport.php:80 #: src/Module/Settings/RemoveMe.php:117 src/Module/Settings/UserExport.php:80
@ -56,206 +84,6 @@ msgstr ""
msgid "Permission denied." msgid "Permission denied."
msgstr "" msgstr ""
#: mod/editpost.php:45 mod/editpost.php:55
#: src/Module/Moderation/Item/Source.php:88
msgid "Item not found"
msgstr ""
#: mod/editpost.php:64
msgid "Edit post"
msgstr ""
#: mod/editpost.php:91 mod/notes.php:56 src/Content/Text/HTML.php:882
#: src/Module/Admin/Storage.php:142 src/Module/Filer/SaveTag.php:74
msgid "Save"
msgstr ""
#: mod/editpost.php:92 mod/photos.php:1335 src/Content/Conversation.php:341
#: src/Object/Post.php:987
msgid "Loading..."
msgstr ""
#: mod/editpost.php:93 mod/message.php:201 mod/message.php:357
#: src/Content/Conversation.php:342
msgid "Upload photo"
msgstr ""
#: mod/editpost.php:94 src/Content/Conversation.php:343
msgid "upload photo"
msgstr ""
#: mod/editpost.php:95 src/Content/Conversation.php:344
msgid "Attach file"
msgstr ""
#: mod/editpost.php:96 src/Content/Conversation.php:345
msgid "attach file"
msgstr ""
#: mod/editpost.php:97 mod/message.php:202 mod/message.php:358
#: src/Module/Profile/UnkMail.php:154
msgid "Insert web link"
msgstr ""
#: mod/editpost.php:98
msgid "web link"
msgstr ""
#: mod/editpost.php:99
msgid "Insert video link"
msgstr ""
#: mod/editpost.php:100
msgid "video link"
msgstr ""
#: mod/editpost.php:101
msgid "Insert audio link"
msgstr ""
#: mod/editpost.php:102
msgid "audio link"
msgstr ""
#: mod/editpost.php:103 src/Content/Conversation.php:355
#: src/Module/Item/Compose.php:200
msgid "Set your location"
msgstr ""
#: mod/editpost.php:104 src/Content/Conversation.php:356
msgid "set location"
msgstr ""
#: mod/editpost.php:105 src/Content/Conversation.php:357
msgid "Clear browser location"
msgstr ""
#: mod/editpost.php:106 src/Content/Conversation.php:358
msgid "clear location"
msgstr ""
#: mod/editpost.php:107 mod/message.php:203 mod/message.php:360
#: mod/photos.php:1486 src/Content/Conversation.php:371
#: src/Content/Conversation.php:717 src/Module/Item/Compose.php:204
#: src/Module/Profile/UnkMail.php:155 src/Object/Post.php:537
msgid "Please wait"
msgstr ""
#: mod/editpost.php:108 src/Content/Conversation.php:372
msgid "Permission settings"
msgstr ""
#: mod/editpost.php:116 src/Core/ACL.php:326
msgid "CC: email addresses"
msgstr ""
#: mod/editpost.php:117 src/Content/Conversation.php:382
msgid "Public post"
msgstr ""
#: mod/editpost.php:120 src/Content/Conversation.php:360
#: src/Module/Item/Compose.php:205
msgid "Set title"
msgstr ""
#: mod/editpost.php:122 src/Content/Conversation.php:362
#: src/Module/Item/Compose.php:206
msgid "Categories (comma-separated list)"
msgstr ""
#: mod/editpost.php:123 src/Core/ACL.php:327
msgid "Example: bob@example.com, mary@example.com"
msgstr ""
#: mod/editpost.php:128 mod/photos.php:1334 mod/photos.php:1390
#: mod/photos.php:1464 src/Content/Conversation.php:386
#: src/Module/Calendar/Event/Form.php:248 src/Module/Item/Compose.php:199
#: src/Object/Post.php:997
msgid "Preview"
msgstr ""
#: mod/editpost.php:130 mod/fbrowser.php:119 mod/fbrowser.php:146
#: mod/photos.php:999 mod/photos.php:1100 src/Content/Conversation.php:389
#: src/Module/Contact/Follow.php:171 src/Module/Contact/Revoke.php:109
#: src/Module/Contact/Unfollow.php:126 src/Module/Post/Tag/Remove.php:109
#: src/Module/Profile/RemoteFollow.php:134
#: src/Module/Security/TwoFactor/SignOut.php:125
msgid "Cancel"
msgstr ""
#: mod/editpost.php:134 src/Content/Conversation.php:346
#: src/Module/Item/Compose.php:190 src/Object/Post.php:988
msgid "Bold"
msgstr ""
#: mod/editpost.php:135 src/Content/Conversation.php:347
#: src/Module/Item/Compose.php:191 src/Object/Post.php:989
msgid "Italic"
msgstr ""
#: mod/editpost.php:136 src/Content/Conversation.php:348
#: src/Module/Item/Compose.php:192 src/Object/Post.php:990
msgid "Underline"
msgstr ""
#: mod/editpost.php:137 src/Content/Conversation.php:349
#: src/Module/Item/Compose.php:193 src/Object/Post.php:991
msgid "Quote"
msgstr ""
#: mod/editpost.php:138 src/Content/Conversation.php:350
#: src/Module/Item/Compose.php:194 src/Object/Post.php:992
msgid "Code"
msgstr ""
#: mod/editpost.php:139 src/Content/Conversation.php:352
#: src/Module/Item/Compose.php:196 src/Object/Post.php:994
msgid "Link"
msgstr ""
#: mod/editpost.php:140 src/Content/Conversation.php:353
#: src/Module/Item/Compose.php:197 src/Object/Post.php:995
msgid "Link or Media"
msgstr ""
#: mod/editpost.php:143 src/Content/Conversation.php:396
#: src/Content/Widget/VCard.php:113 src/Model/Profile.php:465
#: src/Module/Admin/Logs/View.php:93
msgid "Message"
msgstr ""
#: mod/editpost.php:144 src/Content/Conversation.php:397
#: src/Module/Settings/TwoFactor/Trusted.php:139
msgid "Browser"
msgstr ""
#: mod/editpost.php:145 mod/photos.php:934 mod/photos.php:1288
#: src/Content/Conversation.php:373 src/Module/Calendar/Event/Form.php:253
msgid "Permissions"
msgstr ""
#: mod/editpost.php:147 src/Content/Conversation.php:399
msgid "Open Compose page"
msgstr ""
#: mod/fbrowser.php:61 src/Content/Nav.php:195 src/Module/BaseProfile.php:64
#: view/theme/frio/theme.php:239
msgid "Photos"
msgstr ""
#: mod/fbrowser.php:121 mod/fbrowser.php:148
#: src/Module/Settings/Profile/Photo/Index.php:128
msgid "Upload"
msgstr ""
#: mod/fbrowser.php:143
msgid "Files"
msgstr ""
#: mod/item.php:131 mod/item.php:135
msgid "Unable to locate original post."
msgstr ""
#: mod/item.php:337 mod/item.php:342 #: mod/item.php:337 mod/item.php:342
msgid "Empty post discarded." msgid "Empty post discarded."
msgstr "" msgstr ""
@ -274,7 +102,7 @@ msgstr ""
#: mod/item.php:846 src/Module/Admin/Themes/Details.php:39 #: mod/item.php:846 src/Module/Admin/Themes/Details.php:39
#: src/Module/Admin/Themes/Index.php:59 src/Module/Debug/ItemBody.php:42 #: src/Module/Admin/Themes/Index.php:59 src/Module/Debug/ItemBody.php:42
#: src/Module/Debug/ItemBody.php:57 src/Module/Item/Feed.php:81 #: src/Module/Debug/ItemBody.php:57 src/Module/Item/Feed.php:80
msgid "Item not found." msgid "Item not found."
msgstr "" msgstr ""
@ -478,6 +306,23 @@ msgstr ""
msgid "Your message:" msgid "Your message:"
msgstr "" msgstr ""
#: mod/message.php:201 mod/message.php:357 src/Content/Conversation.php:342
#: src/Module/Post/Edit.php:128
msgid "Upload photo"
msgstr ""
#: mod/message.php:202 mod/message.php:358 src/Module/Post/Edit.php:132
#: src/Module/Profile/UnkMail.php:154
msgid "Insert web link"
msgstr ""
#: mod/message.php:203 mod/message.php:360 mod/photos.php:1486
#: src/Content/Conversation.php:371 src/Content/Conversation.php:717
#: src/Module/Item/Compose.php:204 src/Module/Post/Edit.php:142
#: src/Module/Profile/UnkMail.php:155 src/Object/Post.php:537
msgid "Please wait"
msgstr ""
#: mod/message.php:204 mod/message.php:359 mod/photos.php:916 #: mod/message.php:204 mod/message.php:359 mod/photos.php:916
#: mod/photos.php:1020 mod/photos.php:1292 mod/photos.php:1333 #: mod/photos.php:1020 mod/photos.php:1292 mod/photos.php:1333
#: mod/photos.php:1389 mod/photos.php:1463 #: mod/photos.php:1389 mod/photos.php:1463
@ -557,6 +402,12 @@ msgstr ""
msgid "Personal notes are visible only by yourself." msgid "Personal notes are visible only by yourself."
msgstr "" msgstr ""
#: mod/notes.php:56 src/Content/Text/HTML.php:882
#: src/Module/Admin/Storage.php:142 src/Module/Filer/SaveTag.php:74
#: src/Module/Post/Edit.php:126
msgid "Save"
msgstr ""
#: mod/photos.php:68 mod/photos.php:139 mod/photos.php:793 #: mod/photos.php:68 mod/photos.php:139 mod/photos.php:793
#: src/Model/Event.php:514 src/Model/Profile.php:234 #: src/Model/Event.php:514 src/Model/Profile.php:234
#: src/Module/Calendar/Export.php:67 src/Module/Feed.php:72 #: src/Module/Calendar/Export.php:67 src/Module/Feed.php:72
@ -679,6 +530,11 @@ msgstr ""
msgid "Do not show a status post for this upload" msgid "Do not show a status post for this upload"
msgstr "" msgstr ""
#: mod/photos.php:934 mod/photos.php:1288 src/Content/Conversation.php:373
#: src/Module/Calendar/Event/Form.php:253 src/Module/Post/Edit.php:180
msgid "Permissions"
msgstr ""
#: mod/photos.php:997 #: mod/photos.php:997
msgid "Do you really want to delete this photo album and all its photos?" msgid "Do you really want to delete this photo album and all its photos?"
msgstr "" msgstr ""
@ -794,6 +650,18 @@ msgstr ""
msgid "Comment" msgid "Comment"
msgstr "" msgstr ""
#: mod/photos.php:1334 mod/photos.php:1390 mod/photos.php:1464
#: src/Content/Conversation.php:386 src/Module/Calendar/Event/Form.php:248
#: src/Module/Item/Compose.php:199 src/Module/Post/Edit.php:163
#: src/Object/Post.php:997
msgid "Preview"
msgstr ""
#: mod/photos.php:1335 src/Content/Conversation.php:341
#: src/Module/Post/Edit.php:127 src/Object/Post.php:987
msgid "Loading..."
msgstr ""
#: mod/photos.php:1421 src/Content/Conversation.php:633 src/Object/Post.php:255 #: mod/photos.php:1421 src/Content/Conversation.php:633 src/Object/Post.php:255
msgid "Select" msgid "Select"
msgstr "" msgstr ""
@ -1347,19 +1215,116 @@ msgstr ""
msgid "Share" msgid "Share"
msgstr "" msgstr ""
#: src/Content/Conversation.php:343 src/Module/Post/Edit.php:129
msgid "upload photo"
msgstr ""
#: src/Content/Conversation.php:344 src/Module/Post/Edit.php:130
msgid "Attach file"
msgstr ""
#: src/Content/Conversation.php:345 src/Module/Post/Edit.php:131
msgid "attach file"
msgstr ""
#: src/Content/Conversation.php:346 src/Module/Item/Compose.php:190
#: src/Module/Post/Edit.php:169 src/Object/Post.php:988
msgid "Bold"
msgstr ""
#: src/Content/Conversation.php:347 src/Module/Item/Compose.php:191
#: src/Module/Post/Edit.php:170 src/Object/Post.php:989
msgid "Italic"
msgstr ""
#: src/Content/Conversation.php:348 src/Module/Item/Compose.php:192
#: src/Module/Post/Edit.php:171 src/Object/Post.php:990
msgid "Underline"
msgstr ""
#: src/Content/Conversation.php:349 src/Module/Item/Compose.php:193
#: src/Module/Post/Edit.php:172 src/Object/Post.php:991
msgid "Quote"
msgstr ""
#: src/Content/Conversation.php:350 src/Module/Item/Compose.php:194
#: src/Module/Post/Edit.php:173 src/Object/Post.php:992
msgid "Code"
msgstr ""
#: src/Content/Conversation.php:351 src/Module/Item/Compose.php:195 #: src/Content/Conversation.php:351 src/Module/Item/Compose.php:195
#: src/Object/Post.php:993 #: src/Object/Post.php:993
msgid "Image" msgid "Image"
msgstr "" msgstr ""
#: src/Content/Conversation.php:352 src/Module/Item/Compose.php:196
#: src/Module/Post/Edit.php:174 src/Object/Post.php:994
msgid "Link"
msgstr ""
#: src/Content/Conversation.php:353 src/Module/Item/Compose.php:197
#: src/Module/Post/Edit.php:175 src/Object/Post.php:995
msgid "Link or Media"
msgstr ""
#: src/Content/Conversation.php:354 #: src/Content/Conversation.php:354
msgid "Video" msgid "Video"
msgstr "" msgstr ""
#: src/Content/Conversation.php:355 src/Module/Item/Compose.php:200
#: src/Module/Post/Edit.php:138
msgid "Set your location"
msgstr ""
#: src/Content/Conversation.php:356 src/Module/Post/Edit.php:139
msgid "set location"
msgstr ""
#: src/Content/Conversation.php:357 src/Module/Post/Edit.php:140
msgid "Clear browser location"
msgstr ""
#: src/Content/Conversation.php:358 src/Module/Post/Edit.php:141
msgid "clear location"
msgstr ""
#: src/Content/Conversation.php:360 src/Module/Item/Compose.php:205
#: src/Module/Post/Edit.php:155
msgid "Set title"
msgstr ""
#: src/Content/Conversation.php:362 src/Module/Item/Compose.php:206
#: src/Module/Post/Edit.php:157
msgid "Categories (comma-separated list)"
msgstr ""
#: src/Content/Conversation.php:367 src/Module/Item/Compose.php:222 #: src/Content/Conversation.php:367 src/Module/Item/Compose.php:222
msgid "Scheduled at" msgid "Scheduled at"
msgstr "" msgstr ""
#: src/Content/Conversation.php:372 src/Module/Post/Edit.php:143
msgid "Permission settings"
msgstr ""
#: src/Content/Conversation.php:382 src/Module/Post/Edit.php:152
msgid "Public post"
msgstr ""
#: src/Content/Conversation.php:396 src/Content/Widget/VCard.php:113
#: src/Model/Profile.php:465 src/Module/Admin/Logs/View.php:93
#: src/Module/Post/Edit.php:178
msgid "Message"
msgstr ""
#: src/Content/Conversation.php:397 src/Module/Post/Edit.php:179
#: src/Module/Settings/TwoFactor/Trusted.php:139
msgid "Browser"
msgstr ""
#: src/Content/Conversation.php:399 src/Module/Post/Edit.php:182
msgid "Open Compose page"
msgstr ""
#: src/Content/Conversation.php:661 src/Object/Post.php:243 #: src/Content/Conversation.php:661 src/Object/Post.php:243
msgid "Pinned item" msgid "Pinned item"
msgstr "" msgstr ""
@ -1985,8 +1950,8 @@ msgid ""
"<a href=\"%1$s\" target=\"_blank\" rel=\"noopener noreferrer\">%2$s</a> %3$s" "<a href=\"%1$s\" target=\"_blank\" rel=\"noopener noreferrer\">%2$s</a> %3$s"
msgstr "" msgstr ""
#: src/Content/Text/BBCode.php:1245 src/Model/Item.php:3486 #: src/Content/Text/BBCode.php:1245 src/Model/Item.php:3493
#: src/Model/Item.php:3492 src/Model/Item.php:3493 #: src/Model/Item.php:3499 src/Model/Item.php:3500
msgid "Link to source" msgid "Link to source"
msgstr "" msgstr ""
@ -2277,6 +2242,14 @@ msgstr ""
msgid "Except to:" msgid "Except to:"
msgstr "" msgstr ""
#: src/Core/ACL.php:326 src/Module/Post/Edit.php:151
msgid "CC: email addresses"
msgstr ""
#: src/Core/ACL.php:327 src/Module/Post/Edit.php:158
msgid "Example: bob@example.com, mary@example.com"
msgstr ""
#: src/Core/ACL.php:328 #: src/Core/ACL.php:328
msgid "Connectors" msgid "Connectors"
msgstr "" msgstr ""
@ -3037,7 +3010,7 @@ msgstr ""
msgid "No events to display" msgid "No events to display"
msgstr "" msgstr ""
#: src/Model/Event.php:525 src/Module/Item/Display.php:221 #: src/Model/Event.php:525 src/Module/Item/Display.php:224
#: src/Module/Profile/Profile.php:93 src/Module/Profile/Profile.php:108 #: src/Module/Profile/Profile.php:93 src/Module/Profile/Profile.php:108
#: src/Module/Profile/Status.php:109 src/Module/Update/Profile.php:55 #: src/Module/Profile/Status.php:109 src/Module/Update/Profile.php:55
msgid "Access to this profile has been restricted." msgid "Access to this profile has been restricted."
@ -3159,44 +3132,44 @@ msgstr ""
msgid "Content warning: %s" msgid "Content warning: %s"
msgstr "" msgstr ""
#: src/Model/Item.php:3398 #: src/Model/Item.php:3405
msgid "bytes" msgid "bytes"
msgstr "" msgstr ""
#: src/Model/Item.php:3429 #: src/Model/Item.php:3436
#, php-format #, php-format
msgid "%2$s (%3$d%%, %1$d vote)" msgid "%2$s (%3$d%%, %1$d vote)"
msgid_plural "%2$s (%3$d%%, %1$d votes)" msgid_plural "%2$s (%3$d%%, %1$d votes)"
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src/Model/Item.php:3431 #: src/Model/Item.php:3438
#, php-format #, php-format
msgid "%2$s (%1$d vote)" msgid "%2$s (%1$d vote)"
msgid_plural "%2$s (%1$d votes)" msgid_plural "%2$s (%1$d votes)"
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src/Model/Item.php:3436 #: src/Model/Item.php:3443
#, php-format #, php-format
msgid "%d voter. Poll end: %s" msgid "%d voter. Poll end: %s"
msgid_plural "%d voters. Poll end: %s" msgid_plural "%d voters. Poll end: %s"
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src/Model/Item.php:3438 #: src/Model/Item.php:3445
#, php-format #, php-format
msgid "%d voter." msgid "%d voter."
msgid_plural "%d voters." msgid_plural "%d voters."
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src/Model/Item.php:3440 #: src/Model/Item.php:3447
#, php-format #, php-format
msgid "Poll end: %s" msgid "Poll end: %s"
msgstr "" msgstr ""
#: src/Model/Item.php:3474 src/Model/Item.php:3475 #: src/Model/Item.php:3481 src/Model/Item.php:3482
msgid "View on separate page" msgid "View on separate page"
msgstr "" msgstr ""
@ -5854,10 +5827,10 @@ msgstr[1] ""
#: src/Module/Contact/Follow.php:69 src/Module/Contact/Redir.php:62 #: src/Module/Contact/Follow.php:69 src/Module/Contact/Redir.php:62
#: src/Module/Contact/Redir.php:222 src/Module/Conversation/Community.php:193 #: src/Module/Contact/Redir.php:222 src/Module/Conversation/Community.php:193
#: src/Module/Debug/ItemBody.php:38 src/Module/Diaspora/Receive.php:57 #: src/Module/Debug/ItemBody.php:38 src/Module/Diaspora/Receive.php:57
#: src/Module/Item/Display.php:93 src/Module/Item/Feed.php:60 #: src/Module/Item/Display.php:95 src/Module/Item/Feed.php:59
#: src/Module/Item/Follow.php:41 src/Module/Item/Ignore.php:41 #: src/Module/Item/Follow.php:41 src/Module/Item/Ignore.php:41
#: src/Module/Item/Pin.php:41 src/Module/Item/Pin.php:56 #: src/Module/Item/Pin.php:41 src/Module/Item/Pin.php:56
#: src/Module/Item/Star.php:42 src/Module/Update/Display.php:38 #: src/Module/Item/Star.php:42 src/Module/Update/Display.php:37
msgid "Access denied." msgid "Access denied."
msgstr "" msgstr ""
@ -7116,12 +7089,12 @@ msgid ""
"<a href=\"/settings/display\">Theme Customization settings</a>." "<a href=\"/settings/display\">Theme Customization settings</a>."
msgstr "" msgstr ""
#: src/Module/Item/Display.php:133 src/Module/Item/Display.php:247 #: src/Module/Item/Display.php:135 src/Module/Item/Display.php:252
#: src/Module/Update/Display.php:56 #: src/Module/Update/Display.php:55
msgid "The requested item doesn't exist or has been deleted." msgid "The requested item doesn't exist or has been deleted."
msgstr "" msgstr ""
#: src/Module/Item/Feed.php:87 #: src/Module/Item/Feed.php:86
msgid "The feed for this item is unavailable." msgid "The feed for this item is unavailable."
msgstr "" msgstr ""
@ -7600,6 +7573,10 @@ msgstr ""
msgid "Implicit Mention" msgid "Implicit Mention"
msgstr "" msgstr ""
#: src/Module/Moderation/Item/Source.php:88
msgid "Item not found"
msgstr ""
#: src/Module/Moderation/Item/Source.php:89 #: src/Module/Moderation/Item/Source.php:89
msgid "No source recorded" msgid "No source recorded"
msgstr "" msgstr ""
@ -8104,6 +8081,34 @@ msgstr ""
msgid "Invalid photo with id %s." msgid "Invalid photo with id %s."
msgstr "" msgstr ""
#: src/Module/Post/Edit.php:82 src/Module/Post/Edit.php:94
msgid "Post not found."
msgstr ""
#: src/Module/Post/Edit.php:101
msgid "Edit post"
msgstr ""
#: src/Module/Post/Edit.php:133
msgid "web link"
msgstr ""
#: src/Module/Post/Edit.php:134
msgid "Insert video link"
msgstr ""
#: src/Module/Post/Edit.php:135
msgid "video link"
msgstr ""
#: src/Module/Post/Edit.php:136
msgid "Insert audio link"
msgstr ""
#: src/Module/Post/Edit.php:137
msgid "audio link"
msgstr ""
#: src/Module/Post/Tag/Remove.php:106 #: src/Module/Post/Tag/Remove.php:106
msgid "Remove Item Tag" msgid "Remove Item Tag"
msgstr "" msgstr ""
@ -10209,7 +10214,7 @@ msgstr ""
msgid "Privacy Statement" msgid "Privacy Statement"
msgstr "" msgstr ""
#: src/Module/Update/Display.php:46 #: src/Module/Update/Display.php:45
msgid "Parameter uri_id is missing." msgid "Parameter uri_id is missing."
msgstr "" msgstr ""

View file

@ -70,7 +70,6 @@
<div style="display: none;"> <div style="display: none;">
<div id="profile-jot-acl-wrapper" style="width:auto;height:auto;overflow:auto;"> <div id="profile-jot-acl-wrapper" style="width:auto;height:auto;overflow:auto;">
{{$acl nofilter}} {{$acl nofilter}}
{{$jotnets nofilter}}
{{if $scheduled_at}}{{$scheduled_at nofilter}}{{/if}} {{if $scheduled_at}}{{$scheduled_at nofilter}}{{/if}}
{{if $created_at}}{{$created_at nofilter}}{{/if}} {{if $created_at}}{{$created_at nofilter}}{{/if}}
</div> </div>