mirror of https://gitlab.com/bashrc2/epicyon
Tab indexes on profile screen
parent
6374fdd9af
commit
5390b0ac28
|
@ -471,7 +471,8 @@ def _get_profile_header(base_dir: str, http_prefix: str,
|
||||||
ctr += 1
|
ctr += 1
|
||||||
alt_domain, _ = get_domain_from_actor(alt_actor)
|
alt_domain, _ = get_domain_from_actor(alt_actor)
|
||||||
other_accounts_html += \
|
other_accounts_html += \
|
||||||
'<a href="' + alt_actor + '">' + alt_domain + '</a>'
|
'<a href="' + alt_actor + \
|
||||||
|
'" tabindex="1">' + alt_domain + '</a>'
|
||||||
elif isinstance(also_known_as, str):
|
elif isinstance(also_known_as, str):
|
||||||
if also_known_as != actor:
|
if also_known_as != actor:
|
||||||
ctr += 1
|
ctr += 1
|
||||||
|
@ -484,7 +485,7 @@ def _get_profile_header(base_dir: str, http_prefix: str,
|
||||||
html_str += \
|
html_str += \
|
||||||
' <a href="/users/' + nickname + \
|
' <a href="/users/' + nickname + \
|
||||||
'/qrcode.png" alt="' + translate['QR Code'] + '" title="' + \
|
'/qrcode.png" alt="' + translate['QR Code'] + '" title="' + \
|
||||||
translate['QR Code'] + '">' + \
|
translate['QR Code'] + '" tabindex="1">' + \
|
||||||
'<img class="qrcode" alt="' + translate['QR Code'] + \
|
'<img class="qrcode" alt="' + translate['QR Code'] + \
|
||||||
'" src="/icons/qrcode.png" /></a></p>\n' + \
|
'" src="/icons/qrcode.png" /></a></p>\n' + \
|
||||||
' <p>' + profile_description_short + '</p>\n' + login_button
|
' <p>' + profile_description_short + '</p>\n' + login_button
|
||||||
|
@ -494,7 +495,8 @@ def _get_profile_header(base_dir: str, http_prefix: str,
|
||||||
# show vcard download link
|
# show vcard download link
|
||||||
html_str += \
|
html_str += \
|
||||||
' <a href="/users/' + nickname + '.vcf" ' + \
|
' <a href="/users/' + nickname + '.vcf" ' + \
|
||||||
'download="contact_' + nickname + '@' + domain_full + '.vcf">' + \
|
'download="contact_' + nickname + '@' + domain_full + \
|
||||||
|
'.vcf" tabindex="1">' + \
|
||||||
'<img class="vcard" src="/icons/vcard.png" ' + \
|
'<img class="vcard" src="/icons/vcard.png" ' + \
|
||||||
'title="vCard" alt="vCard" /></a>\n'
|
'title="vCard" alt="vCard" /></a>\n'
|
||||||
|
|
||||||
|
@ -572,7 +574,8 @@ def _get_profile_header_after_search(base_dir: str,
|
||||||
ctr += 1
|
ctr += 1
|
||||||
alt_domain, _ = get_domain_from_actor(alt_actor)
|
alt_domain, _ = get_domain_from_actor(alt_actor)
|
||||||
other_accounts_html += \
|
other_accounts_html += \
|
||||||
'<a href="' + alt_actor + '">' + alt_domain + '</a>'
|
'<a href="' + alt_actor + \
|
||||||
|
'" tabindex="1">' + alt_domain + '</a>'
|
||||||
elif isinstance(also_known_as, str):
|
elif isinstance(also_known_as, str):
|
||||||
if also_known_as != actor:
|
if also_known_as != actor:
|
||||||
ctr += 1
|
ctr += 1
|
||||||
|
@ -704,25 +707,26 @@ def html_profile(signing_priv_key_pem: str,
|
||||||
donate_section += ' <center>\n'
|
donate_section += ' <center>\n'
|
||||||
if donate_url and not is_system_account(nickname):
|
if donate_url and not is_system_account(nickname):
|
||||||
donate_section += \
|
donate_section += \
|
||||||
' <p><a href="' + donate_url + \
|
' <p><a href="' + donate_url + '" tabindex="1">' + \
|
||||||
'"><button class="donateButton">' + translate['Donate'] + \
|
'<button class="donateButton">' + translate['Donate'] + \
|
||||||
'</button></a></p>\n'
|
'</button></a></p>\n'
|
||||||
if website_url:
|
if website_url:
|
||||||
donate_section += \
|
donate_section += \
|
||||||
'<p>' + translate['Website'] + ': <a href="' + \
|
'<p>' + translate['Website'] + ': <a href="' + \
|
||||||
website_url + '">' + website_url + '</a></p>\n'
|
website_url + '" tabindex="1">' + website_url + '</a></p>\n'
|
||||||
if email_address:
|
if email_address:
|
||||||
donate_section += \
|
donate_section += \
|
||||||
'<p>' + translate['Email'] + ': <a href="mailto:' + \
|
'<p>' + translate['Email'] + ': <a href="mailto:' + \
|
||||||
email_address + '">' + email_address + '</a></p>\n'
|
email_address + '" tabindex="1">' + \
|
||||||
|
email_address + '</a></p>\n'
|
||||||
if blog_address:
|
if blog_address:
|
||||||
donate_section += \
|
donate_section += \
|
||||||
'<p>Blog: <a href="' + \
|
'<p>Blog: <a href="' + \
|
||||||
blog_address + '">' + blog_address + '</a></p>\n'
|
blog_address + '" tabindex="1">' + blog_address + '</a></p>\n'
|
||||||
if xmpp_address:
|
if xmpp_address:
|
||||||
donate_section += \
|
donate_section += \
|
||||||
'<p>' + translate['XMPP'] + ': <a href="xmpp:' + \
|
'<p>' + translate['XMPP'] + ': <a href="xmpp:' + \
|
||||||
xmpp_address + '">' + xmpp_address + '</a></p>\n'
|
xmpp_address + '" tabindex="1">' + xmpp_address + '</a></p>\n'
|
||||||
if matrix_address:
|
if matrix_address:
|
||||||
donate_section += \
|
donate_section += \
|
||||||
'<p>' + translate['Matrix'] + ': ' + matrix_address + '</p>\n'
|
'<p>' + translate['Matrix'] + ': ' + matrix_address + '</p>\n'
|
||||||
|
@ -764,13 +768,14 @@ def html_profile(signing_priv_key_pem: str,
|
||||||
|
|
||||||
if authorized:
|
if authorized:
|
||||||
edit_profile_str = \
|
edit_profile_str = \
|
||||||
'<a class="imageAnchor" href="' + users_path + '/editprofile">' + \
|
'<a class="imageAnchor" href="' + users_path + \
|
||||||
|
'/editprofile" tabindex="1">' + \
|
||||||
'<img loading="lazy" decoding="async" src="/icons' + \
|
'<img loading="lazy" decoding="async" src="/icons' + \
|
||||||
'/edit.png" title="' + translate['Edit'] + \
|
'/edit.png" title="' + translate['Edit'] + \
|
||||||
'" alt="| ' + translate['Edit'] + '" class="timelineicon"/></a>\n'
|
'" alt="| ' + translate['Edit'] + '" class="timelineicon"/></a>\n'
|
||||||
|
|
||||||
logout_str = \
|
logout_str = \
|
||||||
'<a class="imageAnchor" href="/logout">' + \
|
'<a class="imageAnchor" href="/logout" tabindex="1">' + \
|
||||||
'<img loading="lazy" decoding="async" src="/icons' + \
|
'<img loading="lazy" decoding="async" src="/icons' + \
|
||||||
'/logout.png" title="' + translate['Logout'] + \
|
'/logout.png" title="' + translate['Logout'] + \
|
||||||
'" alt="| ' + translate['Logout'] + \
|
'" alt="| ' + translate['Logout'] + \
|
||||||
|
@ -816,7 +821,8 @@ def html_profile(signing_priv_key_pem: str,
|
||||||
follow_approvals_section += \
|
follow_approvals_section += \
|
||||||
'<div class="container">'
|
'<div class="container">'
|
||||||
follow_approvals_section += \
|
follow_approvals_section += \
|
||||||
'<a href="' + follower_actor + '">'
|
'<a href="' + follower_actor + \
|
||||||
|
'" tabindex="2">'
|
||||||
follow_approvals_section += \
|
follow_approvals_section += \
|
||||||
'<span class="followRequestHandle">' + \
|
'<span class="followRequestHandle">' + \
|
||||||
follower_handle + \
|
follower_handle + \
|
||||||
|
@ -825,13 +831,15 @@ def html_profile(signing_priv_key_pem: str,
|
||||||
# show Approve and Deny buttons
|
# show Approve and Deny buttons
|
||||||
follow_approvals_section += \
|
follow_approvals_section += \
|
||||||
'<a href="' + base_path + \
|
'<a href="' + base_path + \
|
||||||
'/followapprove=' + follower_handle + '">'
|
'/followapprove=' + follower_handle + \
|
||||||
|
'" tabindex="2">'
|
||||||
follow_approvals_section += \
|
follow_approvals_section += \
|
||||||
'<button class="followApprove">' + \
|
'<button class="followApprove">' + \
|
||||||
translate['Approve'] + '</button></a><br><br>'
|
translate['Approve'] + '</button></a><br><br>'
|
||||||
follow_approvals_section += \
|
follow_approvals_section += \
|
||||||
'<a href="' + base_path + \
|
'<a href="' + base_path + \
|
||||||
'/followdeny=' + follower_handle + '">'
|
'/followdeny=' + follower_handle + \
|
||||||
|
'" tabindex="3">'
|
||||||
follow_approvals_section += \
|
follow_approvals_section += \
|
||||||
'<button class="followDeny">' + \
|
'<button class="followDeny">' + \
|
||||||
translate['Deny'] + '</button></a>'
|
translate['Deny'] + '</button></a>'
|
||||||
|
@ -953,34 +961,41 @@ def html_profile(signing_priv_key_pem: str,
|
||||||
profile_str += '<div class="container" id="buttonheader">\n'
|
profile_str += '<div class="container" id="buttonheader">\n'
|
||||||
profile_str += ' <center>'
|
profile_str += ' <center>'
|
||||||
profile_str += \
|
profile_str += \
|
||||||
' <a href="' + users_path + '#buttonheader"><button class="' + \
|
' <a href="' + users_path + '#buttonheader" tabindex="2">' + \
|
||||||
|
'<button class="' + \
|
||||||
posts_button + '"><span>' + translate['Posts'] + \
|
posts_button + '"><span>' + translate['Posts'] + \
|
||||||
' </span></button></a>'
|
' </span></button></a>'
|
||||||
if not is_group:
|
if not is_group:
|
||||||
profile_str += \
|
profile_str += \
|
||||||
' <a href="' + users_path + '/following#buttonheader">' + \
|
' <a href="' + users_path + \
|
||||||
|
'/following#buttonheader" tabindex="2">' + \
|
||||||
'<button class="' + following_button + '"><span>' + \
|
'<button class="' + following_button + '"><span>' + \
|
||||||
translate['Following'] + ' </span></button></a>'
|
translate['Following'] + ' </span></button></a>'
|
||||||
profile_str += \
|
profile_str += \
|
||||||
' <a href="' + users_path + '/followers#buttonheader">' + \
|
' <a href="' + users_path + \
|
||||||
|
'/followers#buttonheader" tabindex="2">' + \
|
||||||
'<button class="' + followers_button + \
|
'<button class="' + followers_button + \
|
||||||
'"><span>' + followers_str + ' </span></button></a>'
|
'"><span>' + followers_str + ' </span></button></a>'
|
||||||
if not is_group:
|
if not is_group:
|
||||||
profile_str += \
|
profile_str += \
|
||||||
' <a href="' + users_path + '/roles#buttonheader">' + \
|
' <a href="' + users_path + \
|
||||||
|
'/roles#buttonheader" tabindex="2">' + \
|
||||||
'<button class="' + roles_button + '"><span>' + \
|
'<button class="' + roles_button + '"><span>' + \
|
||||||
translate['Roles'] + \
|
translate['Roles'] + \
|
||||||
' </span></button></a>'
|
' </span></button></a>'
|
||||||
profile_str += \
|
profile_str += \
|
||||||
' <a href="' + users_path + '/skills#buttonheader">' + \
|
' <a href="' + users_path + \
|
||||||
|
'/skills#buttonheader" tabindex="2">' + \
|
||||||
'<button class="' + skills_button + '"><span>' + \
|
'<button class="' + skills_button + '"><span>' + \
|
||||||
translate['Skills'] + ' </span></button></a>'
|
translate['Skills'] + ' </span></button></a>'
|
||||||
# profile_str += \
|
# profile_str += \
|
||||||
# ' <a href="' + users_path + '/shares#buttonheader">' + \
|
# ' <a href="' + users_path + \
|
||||||
|
# '/shares#buttonheader" tabindex="2">' + \
|
||||||
# '<button class="' + shares_button + '"><span>' + \
|
# '<button class="' + shares_button + '"><span>' + \
|
||||||
# translate['Shares'] + ' </span></button></a>'
|
# translate['Shares'] + ' </span></button></a>'
|
||||||
# profile_str += \
|
# profile_str += \
|
||||||
# ' <a href="' + users_path + '/wanted#buttonheader">' + \
|
# ' <a href="' + users_path + \
|
||||||
|
# '/wanted#buttonheader" tabindex="2">' + \
|
||||||
# '<button class="' + wanted_button + '"><span>' + \
|
# '<button class="' + wanted_button + '"><span>' + \
|
||||||
# translate['Wanted'] + ' </span></button></a>'
|
# translate['Wanted'] + ' </span></button></a>'
|
||||||
profile_str += logout_str + edit_profile_str
|
profile_str += logout_str + edit_profile_str
|
||||||
|
@ -997,7 +1012,7 @@ def html_profile(signing_priv_key_pem: str,
|
||||||
css_filename = base_dir + '/epicyon.css'
|
css_filename = base_dir + '/epicyon.css'
|
||||||
|
|
||||||
license_str = \
|
license_str = \
|
||||||
'<a href="https://gitlab.com/bashrc2/epicyon">' + \
|
'<a href="https://gitlab.com/bashrc2/epicyon" tabindex="2">' + \
|
||||||
'<img loading="lazy" decoding="async" class="license" alt="' + \
|
'<img loading="lazy" decoding="async" class="license" alt="' + \
|
||||||
translate['Get the source code'] + '" title="' + \
|
translate['Get the source code'] + '" title="' + \
|
||||||
translate['Get the source code'] + '" src="/icons/agpl.png" /></a>'
|
translate['Get the source code'] + '" src="/icons/agpl.png" /></a>'
|
||||||
|
|
Loading…
Reference in New Issue