Summary: | Hiding lists with OpacPublic breaks styling for language list | ||
---|---|---|---|
Product: | Koha | Reporter: | Katrin Fischer <katrin.fischer> |
Component: | OPAC | Assignee: | Owen Leonard <oleonard> |
Status: | RESOLVED FIXED | QA Contact: | Jonathan Druart <jonathan.druart> |
Severity: | minor | ||
Priority: | P5 - low | CC: | david, dcook, jonathan.druart, lucas, schodkowy.omegi-0r |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | Trivial patch |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: |
24.11.00
|
|
Circulation function: | |||
Bug Depends on: | 33244, 37833, 37841 | ||
Bug Blocks: | |||
Attachments: |
Bug 36337: Hiding lists with OpacPublic breaks styling for language list
Bug 36337: Hiding lists with OpacPublic breaks styling for language list Bug 36337: Hiding lists with OpacPublic breaks styling for language list Bug 36337: Hiding lists with OpacPublic breaks styling for language list |
Description
Katrin Fischer
2024-03-17 16:59:41 UTC
Thanks for creating the bug. To clarify though: the issue shows up when the lists are NOT hidden (which is the default). They added the feature of hiding lists and fixed the styling when they're hidden, but in turn broke the styling when they're normally shown. So I see three possible ways of fixing it: 1. Somehow making it so that while lists are shown, the languages are on the right as they were, and if hidden, on the left (will probably require adding a new CSS class to toggle the behavior, as I couldn't figure out any CSS trick for this) 2. Reverting and making it so that languages are always on the right, while nothing is shown on the left if lists are disabled 3. Make languages always on the left I wouldn't favor option #3 since that changes the UX and I think language belongs to the right next to user settings. In spirit of the original bug, I think they intended for #1 (to avoid keeping the space on left empty?). I personally think #2 might be the best? I mean there are many sites that have logo on the left and all toolbars on the right, it would look perfectly okay. I could try taking a stab at making a patch, but I'd welcome some opinions on the above I guess... Created attachment 168139 [details] [review] Bug 36337: Hiding lists with OpacPublic breaks styling for language list This patch adjusts the CSS of elements in the OPAC header so that menu items are correctly aligned with various combinations of the OpacPublic and OpacLangSelectorMode system preferences. To test, apply the patch and rebuild the OPAC CSS (https://wiki.koha-community.org/wiki/Working_with_SCSS_in_the_OPAC_and_staff_client) - View the header menu in the OPAC with these combinations of settings: - OpacPublic = On; OpacLangSelectorMode = Top; - OpacPublic = On; OpacLangSelectorMode = Footer; - OpacPublic = Off; OpacLangSelectorMode = Top; - OpacPublic = Off; OpacLangSelectorMode = Footer; - With each configuration, test that the elements in the header (Logo, Cart/List menu, Language selctor, and user menu items) align correctly. The Cart/List menu items should always align to the left, the Language selector and user menu should aways align to the right. Sponsored-by: Athens County Public Libraries Created attachment 168186 [details] [review] Bug 36337: Hiding lists with OpacPublic breaks styling for language list This patch adjusts the CSS of elements in the OPAC header so that menu items are correctly aligned with various combinations of the OpacPublic and OpacLangSelectorMode system preferences. To test, apply the patch and rebuild the OPAC CSS (https://wiki.koha-community.org/wiki/Working_with_SCSS_in_the_OPAC_and_staff_client) - View the header menu in the OPAC with these combinations of settings: - OpacPublic = On; OpacLangSelectorMode = Top; - OpacPublic = On; OpacLangSelectorMode = Footer; - OpacPublic = Off; OpacLangSelectorMode = Top; - OpacPublic = Off; OpacLangSelectorMode = Footer; - With each configuration, test that the elements in the header (Logo, Cart/List menu, Language selctor, and user menu items) align correctly. The Cart/List menu items should always align to the left, the Language selector and user menu should aways align to the right. Sponsored-by: Athens County Public Libraries Signed-off-by: David Nind <david@davidnind.com> Testing notes (using KTD): 1. Need to have another language installed - see https://gitlab.com/koha-community/koha-testing-docker#translation-files . cd misc/translator/po . git fetch origin . git reset --hard origin/main . in the koha shell (ktd --shell), gulp po:update --lang fr-CA . exit from shell, and change to a root shell: ktd --root --shell . cd koha . koha-translate --install fr-CA --dev kohadev . restart_all 2. Enable the language for the OPAC: . OPACLanguages system preference - make sure languages are ticked . opaclanguagesdisplay system preference set to Allow 3. Regenerate the CSS: yarn build 4. Restart everything: restart_all Not sure if this is this patch that needs to fix it, but I found a bad display when en and en-GB are selected: https://snipboard.io/iBNjEn.jpg (bottom left) (In reply to Jonathan Druart from comment #6) > Not sure if this is this patch that needs to fix it, but I found a bad > display when en and en-GB are selected Bug 37841 - Switch OPAC language menu alignment in header and footer Created attachment 171339 [details] [review] Bug 36337: Hiding lists with OpacPublic breaks styling for language list This patch adjusts the CSS of elements in the OPAC header so that menu items are correctly aligned with various combinations of the OpacPublic and OpacLangSelectorMode system preferences. To test, apply the patch and rebuild the OPAC CSS (https://wiki.koha-community.org/wiki/Working_with_SCSS_in_the_OPAC_and_staff_client) - View the header menu in the OPAC with these combinations of settings: - OpacPublic = On; OpacLangSelectorMode = Top; - OpacPublic = On; OpacLangSelectorMode = Footer; - OpacPublic = Off; OpacLangSelectorMode = Top; - OpacPublic = Off; OpacLangSelectorMode = Footer; - With each configuration, test that the elements in the header (Logo, Cart/List menu, Language selctor, and user menu items) align correctly. The Cart/List menu items should always align to the left, the Language selector and user menu should aways align to the right. Sponsored-by: Athens County Public Libraries Signed-off-by: David Nind <david@davidnind.com> Created attachment 171357 [details] [review] Bug 36337: Hiding lists with OpacPublic breaks styling for language list This patch adjusts the CSS of elements in the OPAC header so that menu items are correctly aligned with various combinations of the OpacPublic and OpacLangSelectorMode system preferences. To test, apply the patch and rebuild the OPAC CSS (https://wiki.koha-community.org/wiki/Working_with_SCSS_in_the_OPAC_and_staff_client) - View the header menu in the OPAC with these combinations of settings: - OpacPublic = On; OpacLangSelectorMode = Top; - OpacPublic = On; OpacLangSelectorMode = Footer; - OpacPublic = Off; OpacLangSelectorMode = Top; - OpacPublic = Off; OpacLangSelectorMode = Footer; - With each configuration, test that the elements in the header (Logo, Cart/List menu, Language selctor, and user menu items) align correctly. The Cart/List menu items should always align to the left, the Language selector and user menu should aways align to the right. Sponsored-by: Athens County Public Libraries Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Pushed for 24.11! Well done everyone, thank you! Missing dependencies for 24.05.x Looks like this is needed for 24.05 and 23.11 since bug 33244 caused the regression and they're both affected versions. But then this fix was done in a way that depends on bug 35402 which makes it impossible to backport? That's super frustrating... I suppose the short-term workaround is just to hide div#header_langmenu. I imagine 24.05 and 23.11 specific fixes could be worked out if it becomes necessary... |