mirror of
https://codeberg.org/PostERG/xamxam.git
synced 2026-05-07 03:29:19 +02:00
wcag: fix 2.4.4 duplicate link text on home page cards
Add <span class="sr-only">, YEAR</span> to each thesis card <p> in public/index.php. Screen readers now read "Author – Title, 2024" instead of bare "Author – Title", so two theses sharing the same title produce distinct accessible names (WCAG 2.4.4 Link Purpose — In Context). Also audit and close WCAG 2.4.3: the tfe.php back link (<a class="tfe-back-link"> ← Retour</a>) is already the first child of <header class="tfe-left"> in DOM order, preceding <h1 class="tfe-title">. No code change needed; TODO item marked done.
This commit is contained in:
@@ -34,11 +34,11 @@
|
||||
|
||||
## 2.4.3 Focus order
|
||||
|
||||
- [ ] **On `tfe.php` the `← Retour` back link is at the bottom of the left column in DOM** — consider moving above `<h1>` or adding a copy at the top so keyboard users can exit quickly
|
||||
- [x] **On `tfe.php` the `← Retour` back link is at the bottom of the left column in DOM** — already fixed; `<a class="tfe-back-link">← Retour</a>` is the first child of `<header class="tfe-left">`, which precedes `<h1 class="tfe-title">` in DOM order
|
||||
|
||||
## 2.4.4 Link purpose
|
||||
|
||||
- [ ] **Home page cards: if two theses share the same title, identical link texts exist** — append year in `<span class="sr-only">` to disambiguate
|
||||
- [x] **Home page cards: if two theses share the same title, identical link texts exist** — `public/index.php` card `<p>` now appends `<span class="sr-only">, YEAR</span>` when `$item['year']` is set, giving screen-reader users a unique link name per thesis
|
||||
|
||||
## 2.5.3 Label in name
|
||||
|
||||
|
||||
Reference in New Issue
Block a user