Bug 28868

Summary: Masthead.inc is missing class name
Product: Koha Reporter: Lucas Gass <lucas>
Component: OPACAssignee: Lucas Gass <lucas>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: normal    
Priority: P5 - low CC: fridolin.somers, jonathan.druart, kyle, sally.healey, victor
Version: master   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Trivial patch
Documentation contact: Documentation submission:
Text to go in the release notes:
This patch adds back the class 'mastheadsearch' which was lost during the upgrade to Bootstrap 4 in Bug 20168.
Version(s) released in:
21.11.00,21.05.03,20.11.09
Bug Depends on: 20168    
Bug Blocks:    
Attachments: Bug 28868: Add back mastheadsearch class name
Bug 28868: Add back mastheadsearch class name
Bug 28868: Add back mastheadsearch class name
Bug 28868: Add back mastheadsearch class name

Description Lucas Gass 2021-08-16 21:21:40 UTC
In masthead.inc there is a wrapper for the main search bar called #opac-main-search. Prior to Bug 20168 that warpper had a class name of 'mastheadsearch'. 

Historically CSS/JS customization of the main search bar was done via the mastheadsearch class. Can we add that back so we don't disrupt customization?
Comment 1 Lucas Gass 2021-08-16 21:28:22 UTC
Created attachment 123863 [details] [review]
Bug 28868: Add back mastheadsearch class name

Test plan:
1. Inscept the element on the OPAC main page and see the element with an ID of 'opac-main-search'.
2. Apply patch
3. Inscept that same element and you should now also see a class of 'mastheadsearch'.
4. Nothing visually should be different with the patch applied.
Comment 2 Fridolin Somers 2021-08-17 05:21:14 UTC
Mmm this is changed since 20.11.00.
We at Biblibre have fixed each broken customisation of OPAC.
This is not the only change, and for me it makes sens to have an id instead of a class for a tag existing only once in the page.
Comment 3 Lucas Gass 2021-08-17 13:17:00 UTC
(In reply to Fridolin Somers from comment #2)
> Mmm this is changed since 20.11.00.
> We at Biblibre have fixed each broken customisation of OPAC.
> This is not the only change, and for me it makes sens to have an id instead
> of a class for a tag existing only once in the page.

Why can't it have both?
Comment 4 Fridolin Somers 2021-08-18 09:23:01 UTC
(In reply to Lucas Gass from comment #3)
> (In reply to Fridolin Somers from comment #2)
> > Mmm this is changed since 20.11.00.
> > We at Biblibre have fixed each broken customisation of OPAC.
> > This is not the only change, and for me it makes sens to have an id instead
> > of a class for a tag existing only once in the page.
> 
> Why can't it have both?

It can, I'm not against it.
Comment 5 Biblibre Sandboxes 2021-08-18 10:06:46 UTC
Created attachment 123933 [details] [review]
Bug 28868: Add back mastheadsearch class name

Test plan:
1. Inscept the element on the OPAC main page and see the element with an ID of 'opac-main-search'.
2. Apply patch
3. Inscept that same element and you should now also see a class of 'mastheadsearch'.
4. Nothing visually should be different with the patch applied.

Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk>
Comment 6 Sally 2021-08-18 10:07:10 UTC
Works as described - thanks Lucas!
Comment 7 Katrin Fischer 2021-08-18 10:20:04 UTC
Created attachment 123936 [details] [review]
Bug 28868: Add back mastheadsearch class name

Test plan:
1. Inscept the element on the OPAC main page and see the element with an ID of 'opac-main-search'.
2. Apply patch
3. Inscept that same element and you should now also see a class of 'mastheadsearch'.
4. Nothing visually should be different with the patch applied.

Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 8 Jonathan Druart 2021-08-18 13:11:39 UTC
Lucas, don't forget the commit message to describe a bit the context please (not only the commit title)
Comment 9 Jonathan Druart 2021-08-18 13:11:49 UTC
Created attachment 123960 [details] [review]
Bug 28868: Add back mastheadsearch class name

In masthead.inc there is a wrapper for the main search bar called #opac-main-search. Prior to Bug 20168 that warpper had a class name of 'mastheadsearch'.

Historically CSS/JS customization of the main search bar was done via the mastheadsearch class.

Test plan:
1. Inscept the element on the OPAC main page and see the element with an ID of 'opac-main-search'.
2. Apply patch
3. Inscept that same element and you should now also see a class of 'mastheadsearch'.
4. Nothing visually should be different with the patch applied.

Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 10 Jonathan Druart 2021-08-18 13:37:01 UTC
Pushed to master for 21.11, thanks to everybody involved!
Comment 11 Kyle M Hall 2021-08-18 14:00:43 UTC
Pushed to 21.05.x for 21.05.03
Comment 12 Lucas Gass 2021-08-18 15:07:30 UTC
I very much appreciate everyone's efforts on this one, thanks!
Comment 13 Fridolin Somers 2021-08-18 18:55:59 UTC
Pushed to 20.11.x for 20.11.09
Comment 14 Victor Grousset/tuxayo 2021-08-19 21:41:09 UTC
Missing dependencies for 20.05.x, it shouldn't be affected, no backport.