mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-11-09 21:57:28 -06:00
[bugfix] Fix a couple accessibility issues with :focus elements (#3979)
* [bugfix/frontend] Fix accessibility/focus issues in settings + web ui * fix little error * tweaks
This commit is contained in:
parent
365b575341
commit
19cfa8d126
24 changed files with 405 additions and 152 deletions
|
|
@ -184,21 +184,24 @@ function ReportListEntry({ report, linkTo, backLocation }: ReportEntryProps) {
|
|||
const created = new Date(report.created_at).toLocaleString();
|
||||
const title = `${status}. @${target.account.acct} was reported by @${from.account.acct} on ${created}. Reason: "${comment}"`;
|
||||
|
||||
const onClick = () => {
|
||||
// When clicking on a report, direct
|
||||
// to the detail view for that report.
|
||||
setLocation(linkTo, {
|
||||
// Store the back location in history so
|
||||
// the detail view can use it to return to
|
||||
// this page (including query parameters).
|
||||
state: { backLocation: backLocation }
|
||||
});
|
||||
};
|
||||
|
||||
return (
|
||||
<span
|
||||
className={`pseudolink report entry${report.action_taken ? " resolved" : ""}`}
|
||||
aria-label={title}
|
||||
title={title}
|
||||
onClick={() => {
|
||||
// When clicking on a report, direct
|
||||
// to the detail view for that report.
|
||||
setLocation(linkTo, {
|
||||
// Store the back location in history so
|
||||
// the detail view can use it to return to
|
||||
// this page (including query parameters).
|
||||
state: { backLocation: backLocation }
|
||||
});
|
||||
}}
|
||||
onClick={onClick}
|
||||
onKeyDown={e => e.key === "Enter" && onClick()}
|
||||
role="link"
|
||||
tabIndex={0}
|
||||
>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue