Bug 31064

Summary: Local login is difficult to style using CSS
Product: Koha Reporter: David Cook <dcook>
Component: OPACAssignee: David Cook <dcook>
Status: CLOSED FIXED QA Contact: Fridolin Somers <fridolin.somers>
Severity: enhancement    
Priority: P5 - low CC: arthur.suzuki, fridolin.somers, lucas, victor
Version: Main   
Hardware: All   
OS: All   
See Also: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25405
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=30988
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33614
Change sponsored?: --- Patch complexity: Trivial patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
22.11.00, 22.05.04, 21.11.11
Bug Depends on: 29458    
Bug Blocks:    
Attachments: Bug 31064: Wrap local login with stylable element
Bug 31064: Wrap local login with stylable element
Bug 31064: Wrap local login with stylable element

Description David Cook 2022-06-29 07:39:51 UTC
There are times where it would be nice to style the local login inputs.

For my purposes, that's usually to hide them in favour of button/link provided by OpacUserJS, but I'm sure people could use it for other things too.
Comment 1 David Cook 2022-06-29 08:47:53 UTC
Created attachment 136705 [details] [review]
Bug 31064: Wrap local login with stylable element

Test plan:
0. Apply patch
1. Go to http://localhost:8081/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=OPACUserCSS
2. Set syspref to the following:
.local-login {
      display: none;
}
3. Go to http://localhost:8080/cgi-bin/koha/opac-main.pl
3b. Note that the local login boxes are hidden
("Log in to your account:" remains so that other login options can be supplied by OpacUserJS)

4. Click on "Log in to your account" on the top toolbar
4b. Note that the local login boxes are hidden
("Log in to your account:" remains so that other login options can be supplied by OpacUserJS)

5. Go to http://localhost:8080/cgi-bin/koha/opac-user.pl
5b. Note that the local login boxes are hidden
("Log in to your account" remains so that other login options can be supplied by OpacUserJS)
Comment 2 Fridolin Somers 2022-06-29 08:54:25 UTC
+1 I have the same problem for CSS tunning
Comment 3 Owen Leonard 2022-06-29 11:25:52 UTC
Created attachment 136709 [details] [review]
Bug 31064: Wrap local login with stylable element

Test plan:
0. Apply patch
1. Go to http://localhost:8081/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=OPACUserCSS
2. Set syspref to the following:
.local-login {
      display: none;
}
3. Go to http://localhost:8080/cgi-bin/koha/opac-main.pl
3b. Note that the local login boxes are hidden
    ("Log in to your account:" remains so that other login options can
    be supplied by OpacUserJS)

4. Click on "Log in to your account" on the top toolbar
4b. Note that the local login boxes are hidden
    ("Log in to your account:" remains so that other login options can
    be supplied by OpacUserJS)

5. Go to http://localhost:8080/cgi-bin/koha/opac-user.pl
5b. Note that the local login boxes are hidden
    ("Log in to your account" remains so that other login options can be
    supplied by OpacUserJS)

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Comment 4 Fridolin Somers 2022-06-30 05:21:20 UTC
Created attachment 136764 [details] [review]
Bug 31064: Wrap local login with stylable element

Test plan:
0. Apply patch
1. Go to http://localhost:8081/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=OPACUserCSS
2. Set syspref to the following:
.local-login {
      display: none;
}
3. Go to http://localhost:8080/cgi-bin/koha/opac-main.pl
3b. Note that the local login boxes are hidden
    ("Log in to your account:" remains so that other login options can
    be supplied by OpacUserJS)

4. Click on "Log in to your account" on the top toolbar
4b. Note that the local login boxes are hidden
    ("Log in to your account:" remains so that other login options can
    be supplied by OpacUserJS)

5. Go to http://localhost:8080/cgi-bin/koha/opac-user.pl
5b. Note that the local login boxes are hidden
    ("Log in to your account" remains so that other login options can be
    supplied by OpacUserJS)

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Comment 5 Fridolin Somers 2022-06-30 05:24:19 UTC
Trivial but very useful, PQA

BTW : a class on <h3>Local login</h3> would also be very useful.
Comment 6 David Cook 2022-07-01 04:41:54 UTC
(In reply to Fridolin Somers from comment #5)
> Trivial but very useful, PQA
> 
> BTW : a class on <h3>Local login</h3> would also be very useful.

I was thinking that too. Once this one is in, I could do another patch.
Comment 7 Tomás Cohen Arazi 2022-07-01 19:43:44 UTC
Pushed to master for 22.11.

Nice work everyone, thanks!
Comment 8 Lucas Gass 2022-08-09 21:58:27 UTC
Backported to 22.05.x for 22.05.04
Comment 9 Arthur Suzuki 2022-08-12 07:27:16 UTC
pushed to 21.11.x for 21.11.x
Comment 10 Victor Grousset/tuxayo 2022-08-17 19:32:18 UTC
Not backported to oldoldstable (21.05.x). Feel free to ask if it's needed.

It looks like there is nothing to document, correct me if I'm wrong, marking resolved.