forked from indymedia/epicyon
Indentation
parent
213feadd32
commit
7a7c96eac7
|
@ -4143,7 +4143,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
if timeDiff > 100:
|
if timeDiff > 100:
|
||||||
print('TIMING INDIV ' + boxName + ' 7 = ' + str(timeDiff))
|
print('TIMING INDIV ' + boxName + ' 7 = ' + str(timeDiff))
|
||||||
|
|
||||||
avatarLink = ' <a class="imageAnchor" href="' + postActor + '">'
|
avatarLink = ' <a class="imageAnchor" href="' + postActor + '">'
|
||||||
avatarLink += \
|
avatarLink += \
|
||||||
' <img loading="lazy" src="' + avatarUrl + '" title="' + \
|
' <img loading="lazy" src="' + avatarUrl + '" title="' + \
|
||||||
translate['Show profile'] + '" alt=" "' + avatarPosition + '/></a>\n'
|
translate['Show profile'] + '" alt=" "' + avatarPosition + '/></a>\n'
|
||||||
|
@ -4151,7 +4151,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
if showAvatarOptions and \
|
if showAvatarOptions and \
|
||||||
fullDomain + '/users/' + nickname not in postActor:
|
fullDomain + '/users/' + nickname not in postActor:
|
||||||
avatarLink = \
|
avatarLink = \
|
||||||
' <a class="imageAnchor" href="/users/' + \
|
' <a class="imageAnchor" href="/users/' + \
|
||||||
nickname + '?options=' + postActor + \
|
nickname + '?options=' + postActor + \
|
||||||
';' + str(pageNumber) + ';' + avatarUrl + messageIdStr + '">\n'
|
';' + str(pageNumber) + ';' + avatarUrl + messageIdStr + '">\n'
|
||||||
avatarLink += \
|
avatarLink += \
|
||||||
|
@ -4230,7 +4230,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
nickname, domain,
|
nickname, domain,
|
||||||
displayName, False)
|
displayName, False)
|
||||||
titleStr += \
|
titleStr += \
|
||||||
' <a class="imageAnchor" href="/users/' + \
|
' <a class="imageAnchor" href="/users/' + \
|
||||||
nickname + '?options=' + postActor + \
|
nickname + '?options=' + postActor + \
|
||||||
';' + str(pageNumber) + ';' + avatarUrl + messageIdStr + \
|
';' + str(pageNumber) + ';' + avatarUrl + messageIdStr + \
|
||||||
'">' + displayName + '</a>\n'
|
'">' + displayName + '</a>\n'
|
||||||
|
@ -4245,7 +4245,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
# pprint(postJsonObject)
|
# pprint(postJsonObject)
|
||||||
print('ERROR: no actorDomain')
|
print('ERROR: no actorDomain')
|
||||||
titleStr += \
|
titleStr += \
|
||||||
' <a class="imageAnchor" href="/users/' + \
|
' <a class="imageAnchor" href="/users/' + \
|
||||||
nickname + '?options=' + postActor + \
|
nickname + '?options=' + postActor + \
|
||||||
';' + str(pageNumber) + ';' + avatarUrl + messageIdStr + \
|
';' + str(pageNumber) + ';' + avatarUrl + messageIdStr + \
|
||||||
'">@' + actorNickname + '@' + actorDomain + '</a>\n'
|
'">@' + actorNickname + '@' + actorDomain + '</a>\n'
|
||||||
|
@ -4289,20 +4289,20 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
replyStr = ''
|
replyStr = ''
|
||||||
if isPublicRepeat:
|
if isPublicRepeat:
|
||||||
replyStr += \
|
replyStr += \
|
||||||
' <a class="imageAnchor" href="/users/' + \
|
' <a class="imageAnchor" href="/users/' + \
|
||||||
nickname + '?replyto=' + replyToLink + \
|
nickname + '?replyto=' + replyToLink + \
|
||||||
'?actor=' + postJsonObject['actor'] + \
|
'?actor=' + postJsonObject['actor'] + \
|
||||||
'" title="' + translate['Reply to this post'] + '">\n'
|
'" title="' + translate['Reply to this post'] + '">\n'
|
||||||
else:
|
else:
|
||||||
if isDM(postJsonObject):
|
if isDM(postJsonObject):
|
||||||
replyStr += \
|
replyStr += \
|
||||||
' <a class="imageAnchor" href="/users/' + nickname + \
|
' <a class="imageAnchor" href="/users/' + nickname + \
|
||||||
'?replydm=' + replyToLink + \
|
'?replydm=' + replyToLink + \
|
||||||
'?actor=' + postJsonObject['actor'] + \
|
'?actor=' + postJsonObject['actor'] + \
|
||||||
'" title="' + translate['Reply to this post'] + '">\n'
|
'" title="' + translate['Reply to this post'] + '">\n'
|
||||||
else:
|
else:
|
||||||
replyStr += \
|
replyStr += \
|
||||||
' <a class="imageAnchor" href="/users/' + nickname + \
|
' <a class="imageAnchor" href="/users/' + nickname + \
|
||||||
'?replyfollowers=' + replyToLink + \
|
'?replyfollowers=' + replyToLink + \
|
||||||
'?actor=' + postJsonObject['actor'] + \
|
'?actor=' + postJsonObject['actor'] + \
|
||||||
'" title="' + translate['Reply to this post'] + '">\n'
|
'" title="' + translate['Reply to this post'] + '">\n'
|
||||||
|
@ -4333,7 +4333,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
if isBlogPost(postJsonObject):
|
if isBlogPost(postJsonObject):
|
||||||
blogPostId = postJsonObject['object']['id']
|
blogPostId = postJsonObject['object']['id']
|
||||||
editStr += \
|
editStr += \
|
||||||
' <a class="imageAnchor" href="/users/' + nickname + \
|
' <a class="imageAnchor" href="/users/' + nickname + \
|
||||||
'/tlblogs?editblogpost=' + \
|
'/tlblogs?editblogpost=' + \
|
||||||
blogPostId.split('/statuses/')[1] + \
|
blogPostId.split('/statuses/')[1] + \
|
||||||
'?actor=' + actorNickname + \
|
'?actor=' + actorNickname + \
|
||||||
|
@ -4345,7 +4345,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
elif isEvent:
|
elif isEvent:
|
||||||
eventPostId = postJsonObject['object']['id']
|
eventPostId = postJsonObject['object']['id']
|
||||||
editStr += \
|
editStr += \
|
||||||
' <a class="imageAnchor" href="/users/' + nickname + \
|
' <a class="imageAnchor" href="/users/' + nickname + \
|
||||||
'/tlblogs?editeventpost=' + \
|
'/tlblogs?editeventpost=' + \
|
||||||
eventPostId.split('/statuses/')[1] + \
|
eventPostId.split('/statuses/')[1] + \
|
||||||
'?actor=' + actorNickname + \
|
'?actor=' + actorNickname + \
|
||||||
|
@ -4369,7 +4369,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
announceLink = 'unrepeatprivate'
|
announceLink = 'unrepeatprivate'
|
||||||
announceTitle = translate['Undo the repeat']
|
announceTitle = translate['Undo the repeat']
|
||||||
announceStr = \
|
announceStr = \
|
||||||
' <a class="imageAnchor" href="/users/' + \
|
' <a class="imageAnchor" href="/users/' + \
|
||||||
nickname + '?' + announceLink + \
|
nickname + '?' + announceLink + \
|
||||||
'=' + postJsonObject['object']['id'] + pageNumberParam + \
|
'=' + postJsonObject['object']['id'] + pageNumberParam + \
|
||||||
'?actor=' + postJsonObject['actor'] + \
|
'?actor=' + postJsonObject['actor'] + \
|
||||||
|
@ -4433,7 +4433,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
likeStr += likeCountStr.replace('(', '').replace(')', '').strip()
|
likeStr += likeCountStr.replace('(', '').replace(')', '').strip()
|
||||||
likeStr += '</label>\n'
|
likeStr += '</label>\n'
|
||||||
likeStr += \
|
likeStr += \
|
||||||
' <a class="imageAnchor" href="/users/' + nickname + '?' + \
|
' <a class="imageAnchor" href="/users/' + nickname + '?' + \
|
||||||
likeLink + '=' + postJsonObject['object']['id'] + \
|
likeLink + '=' + postJsonObject['object']['id'] + \
|
||||||
pageNumberParam + \
|
pageNumberParam + \
|
||||||
'?actor=' + postJsonObject['actor'] + \
|
'?actor=' + postJsonObject['actor'] + \
|
||||||
|
@ -4466,7 +4466,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
if timeDiff > 100:
|
if timeDiff > 100:
|
||||||
print('TIMING INDIV ' + boxName + ' 12.6 = ' + str(timeDiff))
|
print('TIMING INDIV ' + boxName + ' 12.6 = ' + str(timeDiff))
|
||||||
bookmarkStr = \
|
bookmarkStr = \
|
||||||
' <a class="imageAnchor" href="/users/' + nickname + '?' + \
|
' <a class="imageAnchor" href="/users/' + nickname + '?' + \
|
||||||
bookmarkLink + '=' + postJsonObject['object']['id'] + \
|
bookmarkLink + '=' + postJsonObject['object']['id'] + \
|
||||||
pageNumberParam + \
|
pageNumberParam + \
|
||||||
'?actor=' + postJsonObject['actor'] + \
|
'?actor=' + postJsonObject['actor'] + \
|
||||||
|
@ -4498,7 +4498,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
messageId.startswith(postActor))):
|
messageId.startswith(postActor))):
|
||||||
if '/users/' + nickname + '/' in messageId:
|
if '/users/' + nickname + '/' in messageId:
|
||||||
deleteStr = \
|
deleteStr = \
|
||||||
' <a class="imageAnchor" href="/users/' + nickname + \
|
' <a class="imageAnchor" href="/users/' + nickname + \
|
||||||
'?delete=' + messageId + pageNumberParam + \
|
'?delete=' + messageId + pageNumberParam + \
|
||||||
'" title="' + translate['Delete this post'] + '">\n'
|
'" title="' + translate['Delete this post'] + '">\n'
|
||||||
deleteStr += \
|
deleteStr += \
|
||||||
|
@ -4508,7 +4508,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
else:
|
else:
|
||||||
if not isMuted:
|
if not isMuted:
|
||||||
muteStr = \
|
muteStr = \
|
||||||
' <a class="imageAnchor" href="/users/' + nickname + \
|
' <a class="imageAnchor" href="/users/' + nickname + \
|
||||||
'?mute=' + messageId + pageNumberParam + '?tl=' + boxName + \
|
'?mute=' + messageId + pageNumberParam + '?tl=' + boxName + \
|
||||||
'?bm=' + timelinePostBookmark + \
|
'?bm=' + timelinePostBookmark + \
|
||||||
'" title="' + translate['Mute this post'] + '">\n'
|
'" title="' + translate['Mute this post'] + '">\n'
|
||||||
|
@ -4519,7 +4519,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
'" src="/' + iconsDir + '/mute.png"/></a>\n'
|
'" src="/' + iconsDir + '/mute.png"/></a>\n'
|
||||||
else:
|
else:
|
||||||
muteStr = \
|
muteStr = \
|
||||||
' <a class="imageAnchor" href="/users/' + \
|
' <a class="imageAnchor" href="/users/' + \
|
||||||
nickname + '?unmute=' + messageId + \
|
nickname + '?unmute=' + messageId + \
|
||||||
pageNumberParam + '?tl=' + boxName + '?bm=' + \
|
pageNumberParam + '?tl=' + boxName + '?bm=' + \
|
||||||
timelinePostBookmark + '" title="' + \
|
timelinePostBookmark + '" title="' + \
|
||||||
|
@ -4866,7 +4866,7 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
containerClass = 'container dm'
|
containerClass = 'container dm'
|
||||||
|
|
||||||
if showIcons:
|
if showIcons:
|
||||||
footerStr = ' <div class="' + containerClassIcons + '">\n'
|
footerStr = ' <div class="' + containerClassIcons + '">\n'
|
||||||
footerStr += replyStr + announceStr + likeStr + bookmarkStr + \
|
footerStr += replyStr + announceStr + likeStr + bookmarkStr + \
|
||||||
deleteStr + muteStr + editStr
|
deleteStr + muteStr + editStr
|
||||||
footerStr += ' <a href="' + publishedLink + '" class="' + \
|
footerStr += ' <a href="' + publishedLink + '" class="' + \
|
||||||
|
@ -4965,7 +4965,8 @@ def individualPostAsHtml(allowDownloads: bool,
|
||||||
contentStr = ''
|
contentStr = ''
|
||||||
else:
|
else:
|
||||||
if not isPatch:
|
if not isPatch:
|
||||||
contentStr = ' <div class="message">' + contentStr + '</div>\n'
|
contentStr = ' <div class="message">' + \
|
||||||
|
contentStr + '</div>\n'
|
||||||
else:
|
else:
|
||||||
contentStr = \
|
contentStr = \
|
||||||
'<div class="gitpatch"><pre><code>' + contentStr + \
|
'<div class="gitpatch"><pre><code>' + contentStr + \
|
||||||
|
|
Loading…
Reference in New Issue