mirror of https://gitlab.com/bashrc2/epicyon
Indicate new followers during keyboard navigation
parent
36963fe3fc
commit
17a334bd29
|
@ -392,7 +392,8 @@ def htmlTimeline(cssCache: {}, defaultTimeline: str,
|
||||||
}
|
}
|
||||||
if moderator:
|
if moderator:
|
||||||
navLinks[translate['Mod']] = usersPath + '/moderation'
|
navLinks[translate['Mod']] = usersPath + '/moderation'
|
||||||
tlStr += htmlKeyboardNavigation(navLinks)
|
tlStr += htmlKeyboardNavigation(navLinks,
|
||||||
|
usersPath, translate, followApprovals)
|
||||||
|
|
||||||
# banner and row of buttons
|
# banner and row of buttons
|
||||||
tlStr += \
|
tlStr += \
|
||||||
|
|
|
@ -880,10 +880,21 @@ def getAvatarImageUrl(session,
|
||||||
return avatarUrl
|
return avatarUrl
|
||||||
|
|
||||||
|
|
||||||
def htmlKeyboardNavigation(links: {}) -> str:
|
def htmlKeyboardNavigation(links: {},
|
||||||
|
usersPath=None, translate=None,
|
||||||
|
followApprovals=False) -> str:
|
||||||
"""Given a set of links return the html for keyboard navigation
|
"""Given a set of links return the html for keyboard navigation
|
||||||
"""
|
"""
|
||||||
htmlStr = '<div class="transparent"><ul>'
|
htmlStr = '<div class="transparent"><ul>'
|
||||||
|
|
||||||
|
# show new follower approvals
|
||||||
|
if usersPath and translate and followApprovals:
|
||||||
|
htmlStr += '<label class="transparent">' + \
|
||||||
|
'<a href="' + usersPath + '/followers#timeline">' + \
|
||||||
|
translate['Approve follow requests'] + '</a>' + \
|
||||||
|
'</label><br><br>'
|
||||||
|
|
||||||
|
# show the list of links
|
||||||
for title, url in links.items():
|
for title, url in links.items():
|
||||||
htmlStr += '<li><label class="transparent">' + \
|
htmlStr += '<li><label class="transparent">' + \
|
||||||
'<a href="' + str(url) + '">' + \
|
'<a href="' + str(url) + '">' + \
|
||||||
|
|
Loading…
Reference in New Issue