Bug 38057 - Fix checkmarks in change framework menu in advanced editor after Bootstrap5 update
Summary: Fix checkmarks in change framework menu in advanced editor after Bootstrap5 u...
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Cataloging (show other bugs)
Version: Main
Hardware: All All
: P1 - high normal
Assignee: Phil Ringnalda
QA Contact: Owen Leonard
URL:
Keywords:
Depends on: 35402
Blocks:
  Show dependency treegraph
 
Reported: 2024-10-02 04:27 UTC by Phil Ringnalda
Modified: 2024-11-06 00:47 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
24.11.00
Circulation function:


Attachments
Bug 38057: Fix checkmarks in Change framework menu in Advanced editor after Bootstrap5 update (1.56 KB, patch)
2024-10-02 05:04 UTC, Phil Ringnalda
Details | Diff | Splinter Review
Bug 38057: Fix checkmarks in Change framework menu in Advanced editor after Bootstrap5 update (1.62 KB, patch)
2024-10-02 11:01 UTC, Pedro Amorim
Details | Diff | Splinter Review
Bug 38057: Fix checkmarks in Change framework menu in Advanced editor after Bootstrap5 update (1.67 KB, patch)
2024-10-08 15:53 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 38057: Fix checkmarks in Change framework menu in Advanced editor after Bootstrap5 update (1.72 KB, patch)
2024-10-10 16:22 UTC, Lucas Gass (lukeg)
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Phil Ringnalda 2024-10-02 04:27:25 UTC
The advanced editor apparently thought it could get away with using the class hidden from bootstrap.min.css to hide and show the checkmarks in the Settings menu next to framework names as you switch to a different framework.

Boy did the Bootstrap5 upgrade show it that it was wrong, by just getting rid of bootstrap.min.css.
Comment 1 Phil Ringnalda 2024-10-02 05:04:49 UTC
Created attachment 172293 [details] [review]
Bug 38057: Fix checkmarks in Change framework menu in Advanced editor after Bootstrap5 update

The advanced editor was using a class hidden from bootstrap.min.css to hide
checkmarks in the part of the Settings menu that lets you change frameworks.
Now that's gone, so it needs to have its own class.

Test plan:
1. Set the preference EnableAdvancedCatalogingEditor to Enable
2. Cataloging - Advanced editor - click the Settings menu
3. In Change framework, ... checkmarks, checkmarks everywhere, and they
   don't change when you choose a different one, so after the first
   change you can't even tell what's current
4. Apply patch, Shift+Reload the advanced editor page to bypass the cache
5. Click the Setting menu, see that only the current framework has a
   checkmark, change to a different one and reopen the Settings menu,
   see that the one you changed to now has the only checkmark

Sponsored-by: Chetco Community Public Library
Comment 2 Pedro Amorim 2024-10-02 11:01:33 UTC
Created attachment 172296 [details] [review]
Bug 38057: Fix checkmarks in Change framework menu in Advanced editor after Bootstrap5 update

The advanced editor was using a class hidden from bootstrap.min.css to hide
checkmarks in the part of the Settings menu that lets you change frameworks.
Now that's gone, so it needs to have its own class.

Test plan:
1. Set the preference EnableAdvancedCatalogingEditor to Enable
2. Cataloging - Advanced editor - click the Settings menu
3. In Change framework, ... checkmarks, checkmarks everywhere, and they
   don't change when you choose a different one, so after the first
   change you can't even tell what's current
4. Apply patch, Shift+Reload the advanced editor page to bypass the cache
5. Click the Setting menu, see that only the current framework has a
   checkmark, change to a different one and reopen the Settings menu,
   see that the one you changed to now has the only checkmark

Sponsored-by: Chetco Community Public Library
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Comment 3 Pedro Amorim 2024-10-02 11:02:47 UTC
Adding Owen here as this is bootstrap related and would be good to have his say here, I think.
Comment 4 Owen Leonard 2024-10-08 15:53:17 UTC
Created attachment 172537 [details] [review]
Bug 38057: Fix checkmarks in Change framework menu in Advanced editor after Bootstrap5 update

The advanced editor was using a class hidden from bootstrap.min.css to
hide checkmarks in the part of the Settings menu that lets you change
frameworks. Now that's gone, so it needs to have its own class.

Test plan:
1. Set the preference EnableAdvancedCatalogingEditor to Enable
2. Cataloging - Advanced editor - click the Settings menu
3. In Change framework, ... checkmarks, checkmarks everywhere, and they
   don't change when you choose a different one, so after the first
   change you can't even tell what's current
4. Apply patch, Shift+Reload the advanced editor page to bypass the cache
5. Click the Setting menu, see that only the current framework has a
   checkmark, change to a different one and reopen the Settings menu,
   see that the one you changed to now has the only checkmark

Sponsored-by: Chetco Community Public Library
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Comment 5 Owen Leonard 2024-10-08 15:54:01 UTC
The bug could also have been fixed by replacing the "hidden" class with the BS5 version, "invisible." But either way works!
Comment 6 Phil Ringnalda 2024-10-08 17:01:35 UTC
I see an .invisible in the opac, but I don't see where it is in intranet-tmpl.
Comment 7 Phil Ringnalda 2024-10-09 22:00:05 UTC
Ah, it magically appears (from outside the tree?) in staff-global.css.
Comment 8 Owen Leonard 2024-10-10 10:37:01 UTC
(In reply to Phil Ringnalda from comment #7)
> Ah, it magically appears (from outside the tree?) in staff-global.css.

SCSS magic. Bootstrap is bundled into staff-global.css. https://getbootstrap.com/docs/5.3/utilities/visibility/
Comment 9 Lucas Gass (lukeg) 2024-10-10 16:22:33 UTC
Created attachment 172664 [details] [review]
Bug 38057: Fix checkmarks in Change framework menu in Advanced editor after Bootstrap5 update

The advanced editor was using a class hidden from bootstrap.min.css to
hide checkmarks in the part of the Settings menu that lets you change
frameworks. Now that's gone, so it needs to have its own class.

Test plan:
1. Set the preference EnableAdvancedCatalogingEditor to Enable
2. Cataloging - Advanced editor - click the Settings menu
3. In Change framework, ... checkmarks, checkmarks everywhere, and they
   don't change when you choose a different one, so after the first
   change you can't even tell what's current
4. Apply patch, Shift+Reload the advanced editor page to bypass the cache
5. Click the Setting menu, see that only the current framework has a
   checkmark, change to a different one and reopen the Settings menu,
   see that the one you changed to now has the only checkmark

Sponsored-by: Chetco Community Public Library
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Comment 10 Katrin Fischer 2024-10-11 10:27:54 UTC
Pushed for 24.11!

Well done everyone, thank you!
Comment 11 Phil Ringnalda 2024-10-25 20:07:25 UTC
BS5 isn't going to 24.05, so this won't need to either.