From 84cbf0b9379d025d68f381e6dc7ca3772cc7d093 Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Tue, 18 Aug 2020 10:35:59 +0100 Subject: [PATCH] Bug 25242: (QA follow-up) Colwidth on results table Prior to this patch, the column width on the opac-results table were not fixed or calculated by a datatable; As such when we introduced the 'table-layout: fixed' property all columns were given equal share of the table, which resulted in most cases in a three way split between a checkbox, an empty cell and the actual content. This patch sets the width for the selectcol to '1ch' for the single character checkbox and updates the second columns class to 'numcol' as it is not used for selection but rather result numbering and sets a fixed width of '4ch' allowing for results upto 3 digits (plus the period) to display correctly without wrapping. Test plan 1/ Apply the patches and run the yarn build process to update the .css 2/ Perform a search and varify that the results table looks reasonable 3/ Disable OPACHiddenItems and perform a search again. 4/ Confirm the table looks reasonable still 5/ Signoff Signed-off-by: Jonathan Druart --- koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss | 8 ++++++++ koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-results.tt | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss b/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss index e59ab8d173..dfc4c6e6e3 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss +++ b/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss @@ -229,6 +229,14 @@ td { background-color: #FFF; word-wrap: break-all; word-wrap: break-word; + + &.selectcol { + width: 1ch; + } + + &.numcol { + width: 3ch; + } } tr { diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-results.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-results.tt index e199aa77bf..8f8aa642bc 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-results.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-results.tt @@ -261,7 +261,7 @@ [% END # IF opacbookbag%] [% # Cell 2: Show result number if OpacHiddenItems is empty %] - + [% UNLESS suppress_result_number %] [% SEARCH_RESULT.result_number | html %]. [% END %] -- 2.39.5