Bug 39144 - OPAC virtual card page is missing custom CSS from OPACUserCSS
Summary: OPAC virtual card page is missing custom CSS from OPACUserCSS
Status: Pushed to main
Alias: None
Product: Koha
Classification: Unclassified
Component: OPAC (show other bugs)
Version: Main
Hardware: All All
: P5 - low trivial
Assignee: David Cook
QA Contact: Marcel de Rooy
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-02-14 17:50 UTC by Jason Robb
Modified: 2025-02-21 15:45 UTC (History)
2 users (show)

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


Attachments
Bug 39144: Remove second call to opac.css (1.36 KB, patch)
2025-02-16 23:34 UTC, David Cook
Details | Diff | Splinter Review
Bug 39144: Remove second call to opac.css (1.41 KB, patch)
2025-02-18 18:07 UTC, David Nind
Details | Diff | Splinter Review
Bug 39144: Remove second call to opac.css (1.51 KB, patch)
2025-02-21 08:41 UTC, Marcel de Rooy
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Jason Robb 2025-02-14 17:50:00 UTC
Custom CSS is not applied to the OPAC virtual card page (opac-virtual-card.pl).

To replicate:

1. Set OPACVirtualCard syspref to Allow
2. Add an obvious change to OPACUserCSS syspref ( body {background-color: pink;} )
3. Switch to the OPAC, notice the CSS is in effect
4. Log in and go to 'Your account' then 'My virtual card' from the menu on the left
5. Notice the custom CSS is no longer in effect
Comment 1 David Cook 2025-02-16 23:32:34 UTC
Good catch!

Funny story... it looks like OPACUserCSS is being rendered in the HTML, but the OPAC virtual card page mistakenly applies the opac.css twice. Once before and once after OPACUserCSS.
Comment 2 David Cook 2025-02-16 23:34:22 UTC
Created attachment 178129 [details] [review]
Bug 39144: Remove second call to opac.css

This change removes an unnecessary second call to opac.css on
the opac-virtual-card.pl page.

Test plan:
1. Set OPACVirtualCard syspref to Allow
2. Add an obvious change to OPACUserCSS syspref ( body {background-color: pink;} )
3. Switch to the OPAC, notice the CSS is in effect
4. Log in and go to 'Your account' then 'My virtual card' from the menu on the left
5. Notice the custom CSS affects the virtual card page too
Comment 3 David Nind 2025-02-18 18:07:03 UTC
Created attachment 178300 [details] [review]
Bug 39144: Remove second call to opac.css

This change removes an unnecessary second call to opac.css on
the opac-virtual-card.pl page.

Test plan:
1. Set OPACVirtualCard syspref to Allow
2. Add an obvious change to OPACUserCSS syspref ( body {background-color: pink;} )
3. Switch to the OPAC, notice the CSS is in effect
4. Log in and go to 'Your account' then 'My virtual card' from the menu on the left
5. Notice the custom CSS affects the virtual card page too

Signed-off-by: David Nind <david@davidnind.com>
Comment 4 Marcel de Rooy 2025-02-21 08:41:52 UTC
Created attachment 178450 [details] [review]
Bug 39144: Remove second call to opac.css

This change removes an unnecessary second call to opac.css on
the opac-virtual-card.pl page.

Test plan:
1. Set OPACVirtualCard syspref to Allow
2. Add an obvious change to OPACUserCSS syspref ( body {background-color: pink;} )
3. Switch to the OPAC, notice the CSS is in effect
4. Log in and go to 'Your account' then 'My virtual card' from the menu on the left
5. Notice the custom CSS affects the virtual card page too

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 5 Katrin Fischer 2025-02-21 15:45:06 UTC
Pushed for 25.05!

Well done everyone, thank you!