From 226ebca75b9cd1a862adc93b4ef9745b9e09e3dd Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Tue, 26 Nov 2019 18:34:41 +0000 Subject: [PATCH] Titles on post icons --- webinterface.py | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/webinterface.py b/webinterface.py index b7f04370..6226c912 100644 --- a/webinterface.py +++ b/webinterface.py @@ -2076,7 +2076,7 @@ def individualPostAsHtml(recentPostsCache: {},maxRecentPosts: int, \ if isAnnounced: if postJsonObject['object'].get('attributedTo'): if postJsonObject['object']['attributedTo'].startswith(postActor): - titleStr+=' '+translate['announces']+'' + titleStr+=' '+translate['announces']+'' else: announceNickname=getNicknameFromActor(postJsonObject['object']['attributedTo']) if announceNickname: @@ -2089,7 +2089,7 @@ def individualPostAsHtml(recentPostsCache: {},maxRecentPosts: int, \ addEmojiToDisplayName(baseDir,httpPrefix, \ nickname,domain, \ announceDisplayName,False) - titleStr+=' '+translate['announces']+' '+announceDisplayName+'' + titleStr+=' '+translate['announces']+' '+announceDisplayName+'' # show avatar of person replied to announceActor=postJsonObject['object']['attributedTo'] announceAvatarUrl=getPersonAvatarUrl(baseDir,announceActor,personCache) @@ -2101,18 +2101,18 @@ def individualPostAsHtml(recentPostsCache: {},maxRecentPosts: int, \ 'title="'+translate['Show options for this person']+ \ '" alt=" "'+avatarPosition+'/>' else: - titleStr+=' '+translate['announces']+' @'+announceNickname+'@'+announceDomain+'' + titleStr+=' '+translate['announces']+' @'+announceNickname+'@'+announceDomain+'' else: - titleStr+=' '+translate['announces']+' @unattributed' + titleStr+=' '+translate['announces']+' @unattributed' else: - titleStr+=' '+translate['announces']+' @unattributed' + titleStr+=' '+translate['announces']+' @unattributed' else: if postJsonObject['object'].get('inReplyTo'): containerClassIcons='containericons darker' containerClass='container darker' #avatarPosition=' class="right"' if postJsonObject['object']['inReplyTo'].startswith(postActor): - titleStr+=' '+translate['replying to']+'' + titleStr+=' '+translate['replying to']+'' else: if '/statuses/' in postJsonObject['object']['inReplyTo']: replyActor=postJsonObject['object']['inReplyTo'].split('/statuses/')[0] @@ -2128,7 +2128,7 @@ def individualPostAsHtml(recentPostsCache: {},maxRecentPosts: int, \ addEmojiToDisplayName(baseDir,httpPrefix, \ nickname,domain, \ replyDisplayName,False) - titleStr+=' '+translate['replying to']+' '+replyDisplayName+'' + titleStr+=' '+translate['replying to']+' '+replyDisplayName+'' # show avatar of person replied to replyAvatarUrl=getPersonAvatarUrl(baseDir,replyActor,personCache) @@ -2139,15 +2139,15 @@ def individualPostAsHtml(recentPostsCache: {},maxRecentPosts: int, \ replyAvatarImageInPost+='title="'+translate['Show profile'] replyAvatarImageInPost+='" alt=" "'+avatarPosition+'/>' else: - titleStr+=' '+translate['replying to']+' @'+replyNickname+'@'+replyDomain+'' + titleStr+=' '+translate['replying to']+' @'+replyNickname+'@'+replyDomain+'' else: - titleStr+=' '+translate['replying to']+' @unknown' + titleStr+=' '+translate['replying to']+' @unknown' else: postDomain=postJsonObject['object']['inReplyTo'].replace('https://','').replace('http://','').replace('dat://','') if '/' in postDomain: postDomain=postDomain.split('/',1)[0] if postDomain: - titleStr+=' '+translate['replying to']+' '+postDomain+'' + titleStr+=' '+translate['replying to']+' '+postDomain+'' attachmentStr='' if postJsonObject['object'].get('attachment'): if isinstance(postJsonObject['object']['attachment'], list): @@ -2298,7 +2298,7 @@ def individualPostAsHtml(recentPostsCache: {},maxRecentPosts: int, \ '?actor='+postJsonObject['actor']+ \ '?bm='+timelinePostBookmark+ \ '?tl='+boxName+'" title="'+announceTitle+'">' - announceStr+=''+translate['Repeat this post']+'' + announceStr+=''+translate['Repeat this post']+'' likeStr='' if not isModerationPost: @@ -2316,7 +2316,7 @@ def individualPostAsHtml(recentPostsCache: {},maxRecentPosts: int, \ '?actor='+postJsonObject['actor']+ \ '?bm='+timelinePostBookmark+ \ '?tl='+boxName+'" title="'+likeTitle+'">' - likeStr+=''+likeTitle+'' + likeStr+=''+likeTitle+'' bookmarkStr='' if not isModerationPost: @@ -2333,7 +2333,7 @@ def individualPostAsHtml(recentPostsCache: {},maxRecentPosts: int, \ '?actor='+postJsonObject['actor']+ \ '?bm='+timelinePostBookmark+ \ '?tl='+boxName+'" title="'+bookmarkTitle+'">' - bookmarkStr+=''+bookmarkTitle+'' + bookmarkStr+=''+bookmarkTitle+'' deleteStr='' if allowDeletion or \ @@ -2379,7 +2379,7 @@ def individualPostAsHtml(recentPostsCache: {},maxRecentPosts: int, \ '' - footerStr+=''+translate['Reply to this post']+'' + footerStr+=''+translate['Reply to this post']+'' footerStr+=announceStr+likeStr+bookmarkStr+deleteStr footerStr+=''+publishedStr+'' footerStr+=''