mirror of
https://github.com/friendica/friendica
synced 2024-11-10 07:42:53 +00:00
Merge pull request #13499 from xundeenergie/reference-links
add link to parent of comment
This commit is contained in:
commit
5bc466de55
3 changed files with 65 additions and 52 deletions
|
@ -164,7 +164,7 @@ class Post
|
||||||
* @throws \Friendica\Network\HTTPException\InternalServerErrorException
|
* @throws \Friendica\Network\HTTPException\InternalServerErrorException
|
||||||
* @throws \ImagickException
|
* @throws \ImagickException
|
||||||
*/
|
*/
|
||||||
public function getTemplateData(array $conv_responses, string $formSecurityToken, int $thread_level = 1)
|
public function getTemplateData(array $conv_responses, string $formSecurityToken, int $thread_level = 1, string $parent_guid = "", string $parent_username = "")
|
||||||
{
|
{
|
||||||
$item = $this->getData();
|
$item = $this->getData();
|
||||||
$edited = false;
|
$edited = false;
|
||||||
|
@ -497,6 +497,8 @@ class Post
|
||||||
}
|
}
|
||||||
|
|
||||||
$tmp_item = [
|
$tmp_item = [
|
||||||
|
'parentguid' => $parent_guid,
|
||||||
|
'isreplyto' => DI::l10n()->t('is reply to %s', $parent_username),
|
||||||
'template' => $this->getTemplate(),
|
'template' => $this->getTemplate(),
|
||||||
'type' => implode('', array_slice(explode('/', $item['verb']), -1)),
|
'type' => implode('', array_slice(explode('/', $item['verb']), -1)),
|
||||||
'comment_firstcollapsed' => false,
|
'comment_firstcollapsed' => false,
|
||||||
|
@ -610,7 +612,7 @@ class Post
|
||||||
$nb_children = count($children);
|
$nb_children = count($children);
|
||||||
if ($nb_children > 0) {
|
if ($nb_children > 0) {
|
||||||
foreach ($children as $child) {
|
foreach ($children as $child) {
|
||||||
$result['children'][] = $child->getTemplateData($conv_responses, $formSecurityToken, $thread_level + 1);
|
$result['children'][] = $child->getTemplateData($conv_responses, $formSecurityToken, $thread_level + 1, $tmp_item['guid'], $tmp_item['name']);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Collapse
|
// Collapse
|
||||||
|
|
|
@ -294,7 +294,7 @@ msgstr ""
|
||||||
#: mod/message.php:201 mod/message.php:357 mod/photos.php:1301
|
#: mod/message.php:201 mod/message.php:357 mod/photos.php:1301
|
||||||
#: src/Content/Conversation.php:399 src/Content/Conversation.php:1549
|
#: src/Content/Conversation.php:399 src/Content/Conversation.php:1549
|
||||||
#: src/Module/Item/Compose.php:206 src/Module/Post/Edit.php:145
|
#: src/Module/Item/Compose.php:206 src/Module/Post/Edit.php:145
|
||||||
#: src/Module/Profile/UnkMail.php:154 src/Object/Post.php:578
|
#: src/Module/Profile/UnkMail.php:154 src/Object/Post.php:580
|
||||||
msgid "Please wait"
|
msgid "Please wait"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
@ -316,7 +316,7 @@ msgstr ""
|
||||||
#: src/Module/Moderation/Report/Create.php:263
|
#: src/Module/Moderation/Report/Create.php:263
|
||||||
#: src/Module/Profile/Profile.php:274 src/Module/Profile/UnkMail.php:155
|
#: src/Module/Profile/Profile.php:274 src/Module/Profile/UnkMail.php:155
|
||||||
#: src/Module/Settings/Profile/Index.php:257
|
#: src/Module/Settings/Profile/Index.php:257
|
||||||
#: src/Module/Settings/Server/Action.php:79 src/Object/Post.php:1095
|
#: src/Module/Settings/Server/Action.php:79 src/Object/Post.php:1097
|
||||||
#: view/theme/duepuntozero/config.php:85 view/theme/frio/config.php:171
|
#: view/theme/duepuntozero/config.php:85 view/theme/frio/config.php:171
|
||||||
#: view/theme/quattro/config.php:87 view/theme/vier/config.php:135
|
#: view/theme/quattro/config.php:87 view/theme/vier/config.php:135
|
||||||
msgid "Submit"
|
msgid "Submit"
|
||||||
|
@ -601,25 +601,25 @@ msgstr ""
|
||||||
|
|
||||||
#: mod/photos.php:1139 mod/photos.php:1195 mod/photos.php:1275
|
#: mod/photos.php:1139 mod/photos.php:1195 mod/photos.php:1275
|
||||||
#: src/Module/Contact.php:619 src/Module/Item/Compose.php:188
|
#: src/Module/Contact.php:619 src/Module/Item/Compose.php:188
|
||||||
#: src/Object/Post.php:1092
|
#: src/Object/Post.php:1094
|
||||||
msgid "This is you"
|
msgid "This is you"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: mod/photos.php:1141 mod/photos.php:1197 mod/photos.php:1277
|
#: mod/photos.php:1141 mod/photos.php:1197 mod/photos.php:1277
|
||||||
#: src/Module/Moderation/Reports.php:95 src/Object/Post.php:572
|
#: src/Module/Moderation/Reports.php:95 src/Object/Post.php:574
|
||||||
#: src/Object/Post.php:1094
|
#: src/Object/Post.php:1096
|
||||||
msgid "Comment"
|
msgid "Comment"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: mod/photos.php:1143 mod/photos.php:1199 mod/photos.php:1279
|
#: mod/photos.php:1143 mod/photos.php:1199 mod/photos.php:1279
|
||||||
#: src/Content/Conversation.php:414 src/Module/Calendar/Event/Form.php:248
|
#: src/Content/Conversation.php:414 src/Module/Calendar/Event/Form.php:248
|
||||||
#: src/Module/Item/Compose.php:201 src/Module/Post/Edit.php:165
|
#: src/Module/Item/Compose.php:201 src/Module/Post/Edit.php:165
|
||||||
#: src/Object/Post.php:1108
|
#: src/Object/Post.php:1110
|
||||||
msgid "Preview"
|
msgid "Preview"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: mod/photos.php:1144 src/Content/Conversation.php:367
|
#: mod/photos.php:1144 src/Content/Conversation.php:367
|
||||||
#: src/Module/Post/Edit.php:130 src/Object/Post.php:1096
|
#: src/Module/Post/Edit.php:130 src/Object/Post.php:1098
|
||||||
msgid "Loading..."
|
msgid "Loading..."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
@ -1240,7 +1240,7 @@ msgid "Visible to <strong>everybody</strong>"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:337 src/Module/Item/Compose.php:200
|
#: src/Content/Conversation.php:337 src/Module/Item/Compose.php:200
|
||||||
#: src/Object/Post.php:1107
|
#: src/Object/Post.php:1109
|
||||||
msgid "Please enter a image/video/audio/webpage URL:"
|
msgid "Please enter a image/video/audio/webpage URL:"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
@ -1285,52 +1285,52 @@ msgid "attach file"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:372 src/Module/Item/Compose.php:190
|
#: src/Content/Conversation.php:372 src/Module/Item/Compose.php:190
|
||||||
#: src/Module/Post/Edit.php:171 src/Object/Post.php:1097
|
#: src/Module/Post/Edit.php:171 src/Object/Post.php:1099
|
||||||
msgid "Bold"
|
msgid "Bold"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:373 src/Module/Item/Compose.php:191
|
#: src/Content/Conversation.php:373 src/Module/Item/Compose.php:191
|
||||||
#: src/Module/Post/Edit.php:172 src/Object/Post.php:1098
|
#: src/Module/Post/Edit.php:172 src/Object/Post.php:1100
|
||||||
msgid "Italic"
|
msgid "Italic"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:374 src/Module/Item/Compose.php:192
|
#: src/Content/Conversation.php:374 src/Module/Item/Compose.php:192
|
||||||
#: src/Module/Post/Edit.php:173 src/Object/Post.php:1099
|
#: src/Module/Post/Edit.php:173 src/Object/Post.php:1101
|
||||||
msgid "Underline"
|
msgid "Underline"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:375 src/Module/Item/Compose.php:193
|
#: src/Content/Conversation.php:375 src/Module/Item/Compose.php:193
|
||||||
#: src/Module/Post/Edit.php:174 src/Object/Post.php:1101
|
#: src/Module/Post/Edit.php:174 src/Object/Post.php:1103
|
||||||
msgid "Quote"
|
msgid "Quote"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:376 src/Module/Item/Compose.php:194
|
#: src/Content/Conversation.php:376 src/Module/Item/Compose.php:194
|
||||||
#: src/Module/Post/Edit.php:175 src/Object/Post.php:1102
|
#: src/Module/Post/Edit.php:175 src/Object/Post.php:1104
|
||||||
msgid "Add emojis"
|
msgid "Add emojis"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:377 src/Module/Item/Compose.php:195
|
#: src/Content/Conversation.php:377 src/Module/Item/Compose.php:195
|
||||||
#: src/Object/Post.php:1100
|
#: src/Object/Post.php:1102
|
||||||
msgid "Content Warning"
|
msgid "Content Warning"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:378 src/Module/Item/Compose.php:196
|
#: src/Content/Conversation.php:378 src/Module/Item/Compose.php:196
|
||||||
#: src/Module/Post/Edit.php:176 src/Object/Post.php:1103
|
#: src/Module/Post/Edit.php:176 src/Object/Post.php:1105
|
||||||
msgid "Code"
|
msgid "Code"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:379 src/Module/Item/Compose.php:197
|
#: src/Content/Conversation.php:379 src/Module/Item/Compose.php:197
|
||||||
#: src/Object/Post.php:1104
|
#: src/Object/Post.php:1106
|
||||||
msgid "Image"
|
msgid "Image"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:380 src/Module/Item/Compose.php:198
|
#: src/Content/Conversation.php:380 src/Module/Item/Compose.php:198
|
||||||
#: src/Module/Post/Edit.php:177 src/Object/Post.php:1105
|
#: src/Module/Post/Edit.php:177 src/Object/Post.php:1107
|
||||||
msgid "Link"
|
msgid "Link"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:381 src/Module/Item/Compose.php:199
|
#: src/Content/Conversation.php:381 src/Module/Item/Compose.php:199
|
||||||
#: src/Module/Post/Edit.php:178 src/Object/Post.php:1106
|
#: src/Module/Post/Edit.php:178 src/Object/Post.php:1108
|
||||||
msgid "Link or Media"
|
msgid "Link or Media"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
@ -1490,21 +1490,21 @@ msgstr ""
|
||||||
msgid "Pinned item"
|
msgid "Pinned item"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:1509 src/Object/Post.php:521
|
#: src/Content/Conversation.php:1509 src/Object/Post.php:523
|
||||||
#: src/Object/Post.php:522
|
#: src/Object/Post.php:524
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "View %s's profile @ %s"
|
msgid "View %s's profile @ %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:1522 src/Object/Post.php:509
|
#: src/Content/Conversation.php:1522 src/Object/Post.php:511
|
||||||
msgid "Categories:"
|
msgid "Categories:"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:1523 src/Object/Post.php:510
|
#: src/Content/Conversation.php:1523 src/Object/Post.php:512
|
||||||
msgid "Filed under:"
|
msgid "Filed under:"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Content/Conversation.php:1531 src/Object/Post.php:535
|
#: src/Content/Conversation.php:1531 src/Object/Post.php:537
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "%s from %s"
|
msgid "%s from %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
@ -11930,102 +11930,107 @@ msgstr ""
|
||||||
msgid "Share via external services"
|
msgid "Share via external services"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:523
|
#: src/Object/Post.php:501
|
||||||
msgid "to"
|
#, php-format
|
||||||
msgstr ""
|
msgid "is reply to %s"
|
||||||
|
|
||||||
#: src/Object/Post.php:524
|
|
||||||
msgid "via"
|
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:525
|
#: src/Object/Post.php:525
|
||||||
msgid "Wall-to-Wall"
|
msgid "to"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:526
|
#: src/Object/Post.php:526
|
||||||
|
msgid "via"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: src/Object/Post.php:527
|
||||||
|
msgid "Wall-to-Wall"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: src/Object/Post.php:528
|
||||||
msgid "via Wall-To-Wall:"
|
msgid "via Wall-To-Wall:"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:573
|
#: src/Object/Post.php:575
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "Reply to %s"
|
msgid "Reply to %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:576
|
#: src/Object/Post.php:578
|
||||||
msgid "More"
|
msgid "More"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:595
|
#: src/Object/Post.php:597
|
||||||
msgid "Notifier task is pending"
|
msgid "Notifier task is pending"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:596
|
#: src/Object/Post.php:598
|
||||||
msgid "Delivery to remote servers is pending"
|
msgid "Delivery to remote servers is pending"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:597
|
#: src/Object/Post.php:599
|
||||||
msgid "Delivery to remote servers is underway"
|
msgid "Delivery to remote servers is underway"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:598
|
#: src/Object/Post.php:600
|
||||||
msgid "Delivery to remote servers is mostly done"
|
msgid "Delivery to remote servers is mostly done"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:599
|
#: src/Object/Post.php:601
|
||||||
msgid "Delivery to remote servers is done"
|
msgid "Delivery to remote servers is done"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:619
|
#: src/Object/Post.php:621
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "%d comment"
|
msgid "%d comment"
|
||||||
msgid_plural "%d comments"
|
msgid_plural "%d comments"
|
||||||
msgstr[0] ""
|
msgstr[0] ""
|
||||||
msgstr[1] ""
|
msgstr[1] ""
|
||||||
|
|
||||||
#: src/Object/Post.php:620
|
#: src/Object/Post.php:622
|
||||||
msgid "Show more"
|
msgid "Show more"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:621
|
#: src/Object/Post.php:623
|
||||||
msgid "Show fewer"
|
msgid "Show fewer"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:657
|
#: src/Object/Post.php:659
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "Reshared by: %s"
|
msgid "Reshared by: %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:662
|
#: src/Object/Post.php:664
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "Viewed by: %s"
|
msgid "Viewed by: %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:667
|
#: src/Object/Post.php:669
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "Liked by: %s"
|
msgid "Liked by: %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:672
|
#: src/Object/Post.php:674
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "Disliked by: %s"
|
msgid "Disliked by: %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:677
|
#: src/Object/Post.php:679
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "Attended by: %s"
|
msgid "Attended by: %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:682
|
#: src/Object/Post.php:684
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "Maybe attended by: %s"
|
msgid "Maybe attended by: %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:687
|
#: src/Object/Post.php:689
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "Not attended by: %s"
|
msgid "Not attended by: %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: src/Object/Post.php:692
|
#: src/Object/Post.php:694
|
||||||
#, php-format
|
#, php-format
|
||||||
msgid "Reacted with %s by: %s"
|
msgid "Reacted with %s by: %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
|
@ -59,9 +59,15 @@ as the value of $top_child_total (this is done at the end of this file)
|
||||||
<span class="uriid" style="display: none;">{{$item.uriid}}</span>
|
<span class="uriid" style="display: none;">{{$item.uriid}}</span>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
<div class="media {{$item.shiny}}">
|
<div class="media {{$item.shiny}}">
|
||||||
{{if $item.reshared}}
|
{{if $item.parentguid}}
|
||||||
<p class="wall-item-announce wall-item-responses" id="wall-item-announce-{{$item.id}}"><i class="fa fa-retweet" aria-hidden="true"></i> {{$item.reshared nofilter}}</p>
|
<a id="btn-{{$item.id}}" class="time" href="javascript:;" onclick="scrollToItem('item-' + '{{$item.parentguid}}');">{{$item.isreplyto}}</a>
|
||||||
|
{{if $item.reshared}}<span class="hidden-xs">•</span>{{/if}}
|
||||||
|
<br class="visible-xs">
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
{{if $item.reshared}}
|
||||||
|
<span class="wall-item-announce wall-item-responses" id="wall-item-announce-{{$item.id}}"><i class="fa fa-retweet" aria-hidden="true"></i> {{$item.reshared nofilter}}</span>
|
||||||
|
{{/if}}
|
||||||
|
<p>
|
||||||
{{* The avatar picture and the photo-menu *}}
|
{{* The avatar picture and the photo-menu *}}
|
||||||
<div class="dropdown pull-left"><!-- Dropdown -->
|
<div class="dropdown pull-left"><!-- Dropdown -->
|
||||||
{{if $item.thread_level==1}}
|
{{if $item.thread_level==1}}
|
||||||
|
|
Loading…
Reference in a new issue