From d9ae7f5b580a0e8475bbfe84a86e1bd0fd404663 Mon Sep 17 00:00:00 2001 From: Sarah Boyce <42296566+sarahboyce@users.noreply.github.com> Date: Sat, 17 Aug 2024 18:32:40 +0200 Subject: [PATCH] Fixed #35686 -- Added table headers to app list tables for screen readers. --- .../admin/templates/admin/app_list.html | 7 ++++++ tests/admin_changelist/tests.py | 2 +- tests/admin_views/tests.py | 24 +++++++++++++++++-- 3 files changed, 30 insertions(+), 3 deletions(-) diff --git a/django/contrib/admin/templates/admin/app_list.html b/django/contrib/admin/templates/admin/app_list.html index 3b67b5feab..60d874b2b6 100644 --- a/django/contrib/admin/templates/admin/app_list.html +++ b/django/contrib/admin/templates/admin/app_list.html @@ -7,6 +7,13 @@ {{ app.name }} + + + {% translate 'Model name' %} + {% translate 'Add link' %} + {% translate 'Change or view list link' %} + + {% for model in app.models %} {% with model_name=model.object_name|lower %} diff --git a/tests/admin_changelist/tests.py b/tests/admin_changelist/tests.py index 4d8845e11e..ec6820c62f 100644 --- a/tests/admin_changelist/tests.py +++ b/tests/admin_changelist/tests.py @@ -1608,7 +1608,7 @@ class ChangeListTests(TestCase): response = m.changelist_view(request) self.assertIn('