Bug 18546

Summary: Unhide the 'Hide window' link in OPAC cart
Product: Koha Reporter: Marc Véron <veron>
Component: OPACAssignee: Owen Leonard <oleonard>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: normal    
Priority: P5 - low CC: fridolin.somers, jonathan.druart, katrin.fischer
Version: Main   
Hardware: All   
OS: All   
See Also: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18545
Change sponsored?: --- Patch complexity: Small patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Bug Depends on: 18545    
Bug Blocks:    
Attachments: Bug 18546 - Unhide the 'Hide window' link in OPAC cart
Bug 18546 - Unhide the 'Hide window' link in OPAC cart
Bug 18546 - Unhide the 'Hide window' link in OPAC cart
[SIGNED-OFF] Bug 18546 - Unhide the 'Hide window' link in OPAC cart

Description Marc Véron 2017-05-05 04:46:19 UTC
Opac cart has does not have a link "Empty and close", but no link or button for "Close". Would be nice to have one.
Comment 1 Owen Leonard 2017-05-05 14:15:42 UTC
It's there, but it's hidden because of a collision with Bootstrap's CSS:

<a class="hide close" href="opac-basket.pl">Hide window</a>

The "hide" class makes it disappear :( I'm glad someone noticed because I didn't!
Comment 2 Marc Véron 2017-05-28 16:44:58 UTC Comment hidden (obsolete)
Comment 3 Marc Véron 2017-05-28 16:51:34 UTC
Note: I did not touch the second toolbar (Select all, Clear all etc.) 
It has a problem as well: On a small screen, it is hidden (with and without this patch.

Maybe the whole cart window needs a rewrite - but that is out of my scope.
Comment 4 Marc Véron 2017-05-28 16:53:13 UTC
Setting to NSO.
If there is a better solution, I'll be happy to sign off on an alternative patch.
Comment 5 Owen Leonard 2017-05-30 17:44:55 UTC
The "close" class on that link is what gives it its functionality. There's a globally-defined trigger for "windows.close()" on .close.

Otherwise I think this is a good solution.
Comment 6 Marc Véron 2017-05-30 19:19:13 UTC Comment hidden (obsolete)
Comment 7 Marc Véron 2017-05-31 18:29:20 UTC
Created attachment 63884 [details] [review]
Bug 18546 - Unhide the 'Hide window' link in OPAC cart

In OPAC cart, the link 'Hide window' is hidden because of a conflict with bootstrap css.

This patch replaces the sprites for the toolbar with Fafamfam icons to make the 'Hide window'
link visible.

(Amended for comment #5 / 2017-05-31 mv)
Comment 8 Owen Leonard 2017-05-31 18:39:29 UTC
Created attachment 63885 [details] [review]
[SIGNED-OFF] Bug 18546 - Unhide the 'Hide window' link in OPAC cart

In OPAC cart, the link 'Hide window' is hidden because of a conflict with bootstrap css.

This patch replaces the sprites for the toolbar with Fafamfam icons to make the 'Hide window'
link visible.

(Amended for comment #5 / 2017-05-31 mv)

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Comment 9 Jonathan Druart 2017-06-09 15:12:58 UTC
Blocked by bug 18545?
Comment 10 Fridolin Somers 2017-07-31 08:09:29 UTC
(In reply to Jonathan Druart from comment #9)
> Blocked by bug 18545?

Bug 18545 is now pushed master, rebase this one ?
Comment 11 Marc Véron 2017-07-31 17:05:30 UTC
This solution does no longer work on top of Bug 18545 because the JavaScript is triggered by classes "brief", "detail" etc., and they display the original sprites / icons. 
As a result, we get two icons if we add the Famfamfam icons.

For the original aim of this bug see comment #1
Comment 12 Owen Leonard 2020-01-15 18:50:15 UTC
This looks to me to be fixed now.