From 77bacd5f832f0ff12734dbf2836b4949f9d8342d Mon Sep 17 00:00:00 2001 From: Laura_Escamilla Date: Fri, 25 Jul 2025 22:29:50 +0000 Subject: [PATCH] Bug 38642: Added title and label to the expand row button MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit To test: 1. Apply the patch * Restart all relevant services (e.g., Plack, Apache) to ensure changes take effect. 2. Navigate to a record’s detail page * Example URL:
/cgi-bin/koha/opac-detail.pl?biblionumber=51&query_desc=kw%2Cwrdl%3A code 3. Inspect the holdings table * Locate the expand/collapse button (the first cell in each row, with class dtr-control). 4. Check the accessibility attributes * Right-click on the expand button > Inspect Element (in browser dev tools). * Confirm the following are present on the : * title="Expand or collapse row details" * aria-label="Expand or collapse row details" * tabindex="0" 5. Sign off and have an incredible day! :D --- .../opac-tmpl/bootstrap/en/modules/opac-detail.tt | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt index 2f17db5377..c31f545d47 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt @@ -1878,6 +1878,11 @@ responsive: { details: { type: "column", target: -1 }, }, + createdRow: function(row, data, dataIndex) { + const expandCell = $('td.dtr-control', row).last(); + expandCell.attr('title', 'Expand or collapse row details'); + expandCell.attr('aria-label', 'Expand or collapse row details'); + } }, table_settings ); @@ -1891,6 +1896,11 @@ responsive: { details: { type: "column", target: -1 }, }, + createdRow: function(row, data, dataIndex) { + const expandCell = $('td.dtr-control', row).last(); + expandCell.attr('title', 'Expand or collapse row details'); + expandCell.attr('aria-label', 'Expand or collapse row details'); + } }, table_settings ); @@ -1908,6 +1918,11 @@ columnDefs: [ { className: "dtr-control", orderable: false, targets: -1 }, ], + createdRow: function(row, data, dataIndex) { + const expandCell = $('td.dtr-control', row).last(); + expandCell.attr('title', 'Expand or collapse row details'); + expandCell.attr('aria-label', 'Expand or collapse row details'); + } }, serial_table_settings ); -- 2.39.5