Bugzilla – Attachment 112035 Details for
Bug 26695
Set focus for cursor to login box on the login popup modal
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 26695: Add modal "shown" event to set cursor focus
Bug-26695-Add-modal-shown-event-to-set-cursor-focu.patch (text/plain), 1.49 KB, created by
Katrin Fischer
on 2020-10-20 13:21:18 UTC
(
hide
)
Description:
Bug 26695: Add modal "shown" event to set cursor focus
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2020-10-20 13:21:18 UTC
Size:
1.49 KB
patch
obsolete
>From ff940404c562e519640a3790b8d292bd49bcb377 Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Mon, 19 Oct 2020 15:15:13 +0000 >Subject: [PATCH] Bug 26695: Add modal "shown" event to set cursor focus > >This patch attaches a focus() call to the login modal's "shown.bs.modal" >event so that the cursor focus is set to the username field when the >login modal is displayed. > >To test, apply the patch and confirm that your OPAC uses the regular >login process--not casAuthentication or GoogleOpenIDConnect. > >Click the "Log in to your account" link in the header. A the login form >should appear in a modal dialog, and the focus should be on the username >field. > >The same should be true if you trigger the modal from other >locations, for instance: "Log in to add tags" on the bibliographic >detail page or the tag cloud page. > >Signed-off-by: Barbara Johnson <barbara.johnson@bedfordtx.gov> > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> >--- > koha-tmpl/opac-tmpl/bootstrap/js/script.js | 3 +++ > 1 file changed, 3 insertions(+) > >diff --git a/koha-tmpl/opac-tmpl/bootstrap/js/script.js b/koha-tmpl/opac-tmpl/bootstrap/js/script.js >index e762d0e90c..512f4609fb 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/js/script.js >+++ b/koha-tmpl/opac-tmpl/bootstrap/js/script.js >@@ -65,4 +65,7 @@ $(document).ready(function(){ > e.preventDefault(); > $("#loginModal").modal("show"); > }); >+ $("#loginModal").on("shown.bs.modal", function(){ >+ $("#muserid").focus(); >+ }); > }); >-- >2.11.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 26695
:
112001
|
112008
| 112035