mirror of https://gitlab.com/bashrc2/epicyon
Show banner on history search screen
parent
dbd6fb8290
commit
a0f38af3f3
|
@ -4081,7 +4081,8 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.cw_lists,
|
self.server.cw_lists,
|
||||||
self.server.lists_enabled,
|
self.server.lists_enabled,
|
||||||
timezone, bold_reading,
|
timezone, bold_reading,
|
||||||
self.server.dogwhistles)
|
self.server.dogwhistles,
|
||||||
|
self.server.access_keys)
|
||||||
if history_str:
|
if history_str:
|
||||||
msg = history_str.encode('utf-8')
|
msg = history_str.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
@ -4162,7 +4163,8 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.cw_lists,
|
self.server.cw_lists,
|
||||||
self.server.lists_enabled,
|
self.server.lists_enabled,
|
||||||
timezone, bold_reading,
|
timezone, bold_reading,
|
||||||
self.server.dogwhistles)
|
self.server.dogwhistles,
|
||||||
|
self.server.access_keys)
|
||||||
if bookmarks_str:
|
if bookmarks_str:
|
||||||
msg = bookmarks_str.encode('utf-8')
|
msg = bookmarks_str.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
|
|
@ -655,7 +655,7 @@ def html_history_search(translate: {}, base_dir: str,
|
||||||
cw_lists: {},
|
cw_lists: {},
|
||||||
lists_enabled: str,
|
lists_enabled: str,
|
||||||
timezone: str, bold_reading: bool,
|
timezone: str, bold_reading: bool,
|
||||||
dogwhistles: {}) -> str:
|
dogwhistles: {}, access_keys: {}) -> str:
|
||||||
"""Show a page containing search results for your post history
|
"""Show a page containing search results for your post history
|
||||||
"""
|
"""
|
||||||
if historysearch.startswith("'"):
|
if historysearch.startswith("'"):
|
||||||
|
@ -683,6 +683,22 @@ def html_history_search(translate: {}, base_dir: str,
|
||||||
if box_name == 'bookmarks':
|
if box_name == 'bookmarks':
|
||||||
history_search_title = '🔍 ' + translate['Bookmarks']
|
history_search_title = '🔍 ' + translate['Bookmarks']
|
||||||
|
|
||||||
|
if nickname and domain and theme_name:
|
||||||
|
banner_file, _ = \
|
||||||
|
get_banner_file(base_dir, nickname, domain, theme_name)
|
||||||
|
history_search_form += \
|
||||||
|
'<header>\n' + \
|
||||||
|
'<a href="/users/' + nickname + '/search" title="' + \
|
||||||
|
translate['Search and follow'] + '" alt="' + \
|
||||||
|
translate['Search and follow'] + '" ' + \
|
||||||
|
'aria-flowto="containerHeader" tabindex="1" accesskey="' + \
|
||||||
|
access_keys['menuSearch'] + '">\n'
|
||||||
|
history_search_form += \
|
||||||
|
'<img loading="lazy" decoding="async" ' + \
|
||||||
|
'class="timeline-banner" alt="" ' + \
|
||||||
|
'src="/users/' + nickname + '/' + banner_file + '" /></a>\n' + \
|
||||||
|
'</header>\n'
|
||||||
|
|
||||||
history_search_form += \
|
history_search_form += \
|
||||||
'<center><h1><a href="' + actor + '/search">' + \
|
'<center><h1><a href="' + actor + '/search">' + \
|
||||||
history_search_title + '</a></h1></center>'
|
history_search_title + '</a></h1></center>'
|
||||||
|
|
Loading…
Reference in New Issue