Bug 31419: Add accesskeys for modals
authorNick Clemens <nick@bywatersolutions.com>
Fri, 19 Aug 2022 10:04:56 +0000 (10:04 +0000)
committerTomas Cohen Arazi <tomascohen@theke.io>
Mon, 26 Sep 2022 13:50:09 +0000 (10:50 -0300)
This patch simply adds accesskey elements to the buttons, and changes an icon to be
consistent with bug 26626

For tips on how to access the accesskeys:
https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/accesskey

To test:
1 - Generate a recall
2 - Fill it/check in
3 - Note modal now has hints "Confirm (Y)"
4 - Test with Y,P,I keys (may need to recreate recalls)
5 - Confirm the recall and test waiting recall modal too

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt

index be91ab7..023a1af 100644 (file)
 
                                                 <div class="modal-footer">
                                                     [% IF ( transfertodo ) %]
-                                                        <button type="submit" class="btn btn-default approve">
-                                                            <i class="fa fa-check"></i> Confirm recall and transfer
+                                                        <button type="submit" class="btn btn-default approve" accesskey="Y">
+                                                            <i class="fa fa-check"></i> Confirm recall and transfer (Y)
                                                         </button>
-                                                        <button type="button" class="btn btn-default print-recall">
-                                                            <i class="fa fa-print"></i> Print slip, transfer, and confirm
+                                                        <button type="button" class="btn btn-default print-recall" accesskey="P">
+                                                            <i class="fa fa-print"></i> Print slip, transfer, and confirm (P)
                                                         </button>
                                                     [% ELSE %]
-                                                        <button type="submit" class="btn btn-default approve">
-                                                            <i class="fa fa-check"></i> Confirm recall
+                                                        <button type="submit" class="btn btn-default approve" accesskey="Y">
+                                                            <i class="fa fa-check"></i> Confirm recall (Y)
                                                         </button>
-                                                        <button type="button" class="btn btn-default print-recall">
-                                                            <i class="fa fa-print"></i> Print slip and confirm
+                                                        <button type="button" class="btn btn-default print-recall" accesskey="P">
+                                                            <i class="fa fa-print"></i> Print slip and confirm (P)
                                                         </button>
                                                     [% END %]
 
                                                 </div>
 
                                                 <div class="modal-footer">
-                                                    <button type="submit" class="btn btn-default approve">
-                                                        <i class="fa fa-check"></i> Confirm recall
+                                                    <button type="submit" class="btn btn-default approve" accesskey="Y">
+                                                        <i class="fa fa-check"></i> Confirm recall (Y)
                                                     </button>
-                                                    <button type="button" class="btn btn-default print-recall">
-                                                        <i class="fa fa-print"></i> Print slip and confirm
+                                                    <button type="button" class="btn btn-default print-recall" accesskey="P">
+                                                        <i class="fa fa-print"></i> Print slip and confirm (P)
                                                     </button>
 
-                                                    <button data-dismiss="modal" aria-hidden="true" type="submit" class="btn btn-default deny">
-                                                        <i class="fa fa-times"></i> Ignore
+                                                    <button data-dismiss="modal" aria-hidden="true" type="submit" class="btn btn-default deny" accesskey="I">
+                                                        <i class="fa fa-remove"></i> Ignore (I)
                                                     </button>
                                                 </div> <!-- /.modal-footer -->
                                             </form> <!-- /.confirm -->