mirror of https://gitlab.com/bashrc2/epicyon
SHOW MOVE removed in conversation view for text mode browsers
parent
d10637a832
commit
d5459e1fab
|
@ -573,7 +573,7 @@ def daemon_http_get(self) -> None:
|
||||||
self.server.port,
|
self.server.port,
|
||||||
self.server.debug,
|
self.server.debug,
|
||||||
self.server.session,
|
self.server.session,
|
||||||
cookie):
|
cookie, ua_str):
|
||||||
fitness_performance(getreq_start_time, self.server.fitness,
|
fitness_performance(getreq_start_time, self.server.fitness,
|
||||||
'_GET', '_show_conversation_thread',
|
'_GET', '_show_conversation_thread',
|
||||||
self.server.debug)
|
self.server.debug)
|
||||||
|
|
|
@ -995,7 +995,7 @@ def show_conversation_thread(self, authorized: bool,
|
||||||
base_dir: str, http_prefix: str,
|
base_dir: str, http_prefix: str,
|
||||||
domain: str, port: int,
|
domain: str, port: int,
|
||||||
debug: str, curr_session,
|
debug: str, curr_session,
|
||||||
cookie: str) -> bool:
|
cookie: str, ua_str: str) -> bool:
|
||||||
"""get conversation thread from the date link on a post
|
"""get conversation thread from the date link on a post
|
||||||
"""
|
"""
|
||||||
if not path.startswith('/users/'):
|
if not path.startswith('/users/'):
|
||||||
|
@ -1056,7 +1056,8 @@ def show_conversation_thread(self, authorized: bool,
|
||||||
self.server.buy_sites,
|
self.server.buy_sites,
|
||||||
self.server.blocked_cache,
|
self.server.blocked_cache,
|
||||||
self.server.block_federated,
|
self.server.block_federated,
|
||||||
self.server.auto_cw_cache)
|
self.server.auto_cw_cache,
|
||||||
|
ua_str)
|
||||||
if conv_str:
|
if conv_str:
|
||||||
msg = conv_str.encode('utf-8')
|
msg = conv_str.encode('utf-8')
|
||||||
msglen = len(msg)
|
msglen = len(msg)
|
||||||
|
|
|
@ -16,6 +16,7 @@ from utils import get_domain_from_actor
|
||||||
from utils import is_public_post
|
from utils import is_public_post
|
||||||
from utils import get_attributed_to
|
from utils import get_attributed_to
|
||||||
from blocking import is_blocked
|
from blocking import is_blocked
|
||||||
|
from webapp_utils import text_mode_browser
|
||||||
from webapp_utils import html_header_with_external_style
|
from webapp_utils import html_header_with_external_style
|
||||||
from webapp_utils import html_post_separator
|
from webapp_utils import html_post_separator
|
||||||
from webapp_utils import html_footer
|
from webapp_utils import html_footer
|
||||||
|
@ -50,7 +51,8 @@ def html_conversation_view(authorized: bool, post_id: str,
|
||||||
debug: bool, buy_sites: {},
|
debug: bool, buy_sites: {},
|
||||||
blocked_cache: [],
|
blocked_cache: [],
|
||||||
block_federated: [],
|
block_federated: [],
|
||||||
auto_cw_cache: {}) -> str:
|
auto_cw_cache: {},
|
||||||
|
ua_str: str) -> str:
|
||||||
"""Show a page containing a conversation thread
|
"""Show a page containing a conversation thread
|
||||||
"""
|
"""
|
||||||
conv_posts = \
|
conv_posts = \
|
||||||
|
@ -125,5 +127,10 @@ def html_conversation_view(authorized: bool, post_id: str,
|
||||||
if post_str:
|
if post_str:
|
||||||
conv_str += text_mode_separator + separator_str + post_str
|
conv_str += text_mode_separator + separator_str + post_str
|
||||||
|
|
||||||
|
# if using a text mode browser then don't show SHOW MORE because there
|
||||||
|
# is no way to hide/expand sections
|
||||||
|
if text_mode_browser(ua_str):
|
||||||
|
conv_str = conv_str.replace(translate['SHOW MORE'], '')
|
||||||
|
|
||||||
conv_str += text_mode_separator + html_footer()
|
conv_str += text_mode_separator + html_footer()
|
||||||
return conv_str
|
return conv_str
|
||||||
|
|
|
@ -835,7 +835,7 @@ def html_timeline(default_timeline: str,
|
||||||
|
|
||||||
# left column
|
# left column
|
||||||
left_column_str = ''
|
left_column_str = ''
|
||||||
if not text_mode_browser(ua_str):
|
if not is_text_browser:
|
||||||
left_column_str = \
|
left_column_str = \
|
||||||
get_left_column_content(base_dir, nickname, domain_full,
|
get_left_column_content(base_dir, nickname, domain_full,
|
||||||
http_prefix, translate,
|
http_prefix, translate,
|
||||||
|
|
Loading…
Reference in New Issue