fix(react): address Doctor findings (#1143)

Accessibility/semantics pass aligned with React Doctor: role-based spans/divs become real buttons, role=status becomes <output>, modals use native <dialog>, author/peer flags render as <img>, and embed/challenge iframes are sandboxed. Includes review follow-ups: correct button chrome/centering/themed dialog colors and focus rings, the missing aria-label i18n keys (all languages), the Yandex image-search URL, clearer .bso setup steps, a keyboard-accessible image-search dropdown, and removal of the post-edit ('comment edited') display (mod edits unchanged).
This commit is contained in:
Tommaso Casaburi
2026-05-29 17:09:07 +07:00
committed by GitHub
parent ac95e58433
commit e082c7b428
132 changed files with 1753 additions and 1224 deletions
@@ -90,7 +90,7 @@ describe('BoardPagination', () => {
expect(container.textContent).toContain('catalog');
expect(container.textContent).toContain('archive');
const allLink = Array.from(container.querySelectorAll<HTMLElement>('[role="button"]')).find((element) => element.textContent === 'all');
const allLink = Array.from(container.querySelectorAll<HTMLButtonElement>('button')).find((element) => element.textContent === 'all');
expect(allLink).toBeTruthy();
await act(async () => {
@@ -45,9 +45,9 @@ const BoardPagination = ({ basePath, currentPage, search = '', totalPages, foote
{currentPage === 1 && (
<span className={styles.footerPageItem}>
<span className={styles.footerPageBracket}>[</span>
<span
<button
type='button'
className={styles.footerPageLink}
role='button'
tabIndex={0}
onClick={() => setEnableInfiniteScroll(true)}
onKeyDown={(e) => {
@@ -58,7 +58,7 @@ const BoardPagination = ({ basePath, currentPage, search = '', totalPages, foote
}}
>
{t('all')}
</span>
</button>
<span className={styles.footerPageBracket}>]</span>
</span>
)}