From 1adc7abcde9ae5afd24f8feac68074279785e1e5 Mon Sep 17 00:00:00 2001 From: Stephanie Leary Date: Wed, 6 Dec 2023 17:45:53 +0000 Subject: [PATCH] LP1615805 No inputs after submit in patron search (AngularJS) Updates the source order of the AngularJS patron search form's reset and submit buttons to the end so that no input fields appear after the submit button, as required for accessibility. This results in an awkward tabbing order for sighted users, but is intended as an interim step toward better accessibility while we rethink the overall design of the form. The visual layout of the form has not changed at desktop sizes, but there are now phone and tablet layouts as well. The Reset button now uses the .btn-destroy style. Release-note: Moves submit button to end of AngularJS patron search form Signed-off-by: Stephanie Leary --- Open-ILS/src/templates/staff/css/circ.css.tt2 | 57 +++++- .../staff/share/t_patron_search_form.tt2 | 165 ++++++------------ 2 files changed, 112 insertions(+), 110 deletions(-) diff --git a/Open-ILS/src/templates/staff/css/circ.css.tt2 b/Open-ILS/src/templates/staff/css/circ.css.tt2 index 5a921017bc..ae4b5694d9 100644 --- a/Open-ILS/src/templates/staff/css/circ.css.tt2 +++ b/Open-ILS/src/templates/staff/css/circ.css.tt2 @@ -48,8 +48,6 @@ but the ones I'm finding aren't quite cutting it..*/ } /* let search form elements fill their containers w/ slight padding */ -#patron-search-form-row {margin-left: 0px;} -#patron-search-form div.col-md-2 { padding: 2px; } #patron-search-form input:not([type="checkbox"]) { width: 100%; } #patron-search-form .eg-org-selector, #patron-search-form .eg-org-selector button, @@ -59,6 +57,61 @@ but the ones I'm finding aren't quite cutting it..*/ text-align: left } +.patron-search-container { + container-type: inline-size; +} + +/* mobile-first layout: flexbox */ +.patron-search-form { + display: flex; + flex-wrap: wrap; + align-items: start; + gap: 0.5rem; +} + +/* Bootstrap sm breakpoint */ +@container (min-width: 576px) { + .patron-search-form > * { + flex-basis: 40%; + } + + .actions-more { + position: absolute; + right: 0; + top: 0; + } +} + +/* not a Bootstrap breakpoint, but where col-lg-9 can break */ +@container (min-width: 680px) { + .patron-search-form { + display: grid; + grid-template-columns: repeat(5, 1fr) max-content; + grid-template-rows: repeat(5, auto); + } + + .actions-more { + position: revert; + } +} + +/* place in the next to last column, first row */ +.actions-search { + grid-row: 1; + grid-column: 5; +} + +/* place in the next to last column, second row */ +.actions-reset { + grid-row: 2; + grid-column: 5; +} + +/* place in the last column, spanning all rows */ +.actions-more { + grid-column: 6; + grid-row: 1 / 5; +} #patron-payments-spreadsheet { margin-top: 10px; diff --git a/Open-ILS/src/templates/staff/share/t_patron_search_form.tt2 b/Open-ILS/src/templates/staff/share/t_patron_search_form.tt2 index 2152cab70c..efad3248e3 100644 --- a/Open-ILS/src/templates/staff/share/t_patron_search_form.tt2 +++ b/Open-ILS/src/templates/staff/share/t_patron_search_form.tt2 @@ -1,122 +1,74 @@ - - -
-
+
-
+ +
+ + +
-
-
-
-
-
-
-
-
- -
- -
- - -
- - -
-
- -
-
- -
-
- + + -
-
- -
-
- -
-
- -
-
-
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
-
+
-
-
- -
-
- -
-
-
-
- -
-
- -
-
- -
-
- -
-
-
+
-
+ +
+
+ + +
-- 2.43.2