Bug 40727 - Minor styling bug in print/email receipt pop-up menu
Summary: Minor styling bug in print/email receipt pop-up menu
Status: Signed Off
Alias: None
Product: Koha
Classification: Unclassified
Component: Templates (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Laura Escamilla
QA Contact: Owen Leonard
URL:
Keywords:
Depends on: 39448 33473
Blocks:
  Show dependency treegraph
 
Reported: 2025-08-28 19:50 UTC by Caroline Cyr La Rose
Modified: 2026-02-06 13:10 UTC (History)
3 users (show)

See Also:
GIT URL:
Initiative type: ---
Sponsorship status: ---
Comma delimited list of Sponsors:
Crowdfunding goal: 0
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Bug 40727: Fix minor styling bug (1.58 KB, patch)
2025-09-04 15:57 UTC, Laura Escamilla
Details | Diff | Splinter Review
Bug 40727: Fix minor styling bug (1.65 KB, patch)
2025-09-08 16:14 UTC, Caroline Cyr La Rose
Details | Diff | Splinter Review
Bug 40727: (alternate) Remove unnecessary .actions CSS (1.31 KB, patch)
2026-01-15 14:15 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 40727: (alternate) Remove unnecessary .actions CSS (1.38 KB, patch)
2026-01-15 14:38 UTC, Caroline Cyr La Rose
Details | Diff | Splinter Review
Bug 40727: (alternate) Remove unnecessary .actions CSS (1.46 KB, patch)
2026-02-06 13:08 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 40727: (alternate) Remove unnecessary .actions CSS (1.38 KB, patch)
2026-02-06 13:10 UTC, Owen Leonard
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Caroline Cyr La Rose 2025-08-28 19:50:33 UTC
I was documenting Bug 33473 and noticed a very tiny bug in the styling of the pop-up menu options to print or send a receipt by email.

To recreate:
1. Go to a patron's account
2. Make sure they have an email address in their account
3. Go to their Accounting tab
4. Create a manual invoice
5. Pay the fee
6. Go to the Transactions tab and click the Receipt button
   --> There should be two options: Print and Email
   --> Note that the options are slightly misaligned (the Print is slightly more to the left)
7. Hover the mouse cursor over one option and then the next
   --> The background for the Email option goes over the edge of the pop-up menu on the right
Comment 1 Caroline Cyr La Rose 2025-08-28 20:14:40 UTC
Possibly caused by bug 39448
Comment 2 Laura Escamilla 2025-09-04 15:57:20 UTC Comment hidden (obsolete)
Comment 3 Owen Leonard 2025-09-04 17:39:52 UTC
I think a simpler solution would be to remove these lines from staff-global.scss, starting at line 2220:

td {
    &.actions {
        white-space: nowrap;

        a,
        button {
            display: inline-block;
-            margin-left: .3rem;
-
-
-            &:first-child {
-                margin-left: 0;
-            }
        }
    }

It doesn't appear to be necessary for us to add the left margin manually.
Comment 4 Laura Escamilla 2025-09-04 18:46:49 UTC
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=39448 added minor spacing to the action buttons. Without this spacing, the layout can look a bit tight—though that might come down to personal preference. My patch just ensures that "Email" isn’t affected by the spacing applied to the action buttons. I'm open to whatever might work best though
Comment 5 Caroline Cyr La Rose 2025-09-08 16:14:28 UTC Comment hidden (obsolete)
Comment 6 Caroline Cyr La Rose 2025-09-08 16:15:32 UTC
The fix works. I don't have an opinions as to how the change was made, but it does fix the problem that I noticed.

Thank you Laura!
Comment 7 Owen Leonard 2026-01-15 14:15:52 UTC Comment hidden (obsolete)
Comment 8 Owen Leonard 2026-01-15 14:17:59 UTC
Laura's patch isn't incorrect, but I think it's better to remove CSS where we have the option.
Comment 9 Caroline Cyr La Rose 2026-01-15 14:38:17 UTC Comment hidden (obsolete)
Comment 10 Caroline Cyr La Rose 2026-01-15 14:39:48 UTC
idem as my previous comment :) The alternate fix works as well. I'm not knowledgeable enough to have an opinion as to how it is fixed. 

Thanks Owen!
Comment 11 Emmi Takkinen 2026-02-06 10:58:25 UTC
Applying patches fails on merge conflict.
Comment 12 Owen Leonard 2026-02-06 13:08:15 UTC Comment hidden (obsolete)
Comment 13 Owen Leonard 2026-02-06 13:10:55 UTC
Created attachment 192614 [details] [review]
Bug 40727: (alternate) Remove unnecessary .actions CSS

This patch takes an alternate approach of removing some CSS which isn't
strictly necessary. I think there was a time when the Bootstrap buttons
didn't come with their own margins and we needed to add it manually.

This change will slightly affect the margins of any buttons inside a
td.actions, but the default margin looks fine to me. Examples:

- Administration -> Patron categories
- Tools -> Notices and slips

Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com>