LP#1922273: (follow-up) adjust positioning of filters
authorGalen Charlton <gmc@equinoxOLI.org>
Mon, 20 Sep 2021 15:48:47 +0000 (11:48 -0400)
committerGalen Charlton <gmc@equinoxOLI.org>
Mon, 20 Sep 2021 15:56:58 +0000 (11:56 -0400)
This patch puts all of the filters in a single row div
but preserves the styling that displays up to four columns
of them on large screens. This way, if you use the library
setting to hide some of the filters, the ones that remain
won't end up randomly appearing in two rows unless you've
retained more than four of them.

Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
Open-ILS/src/eg2/src/app/staff/catalog/search-form.component.html

index 8f3ed84..18bae19 100644 (file)
                 </div>
               </div>
           </div>
-          <div class="row mt-3" *ngIf="showFilters()">
-            <div class="col-lg-3" *ngIf="searchFilters().includes('item_type')">
+          <div class="row" *ngIf="showFilters()">
+            <div class="col-lg-3 mt-3" *ngIf="searchFilters().includes('item_type')">
               <select class="form-control"  multiple="true"
                 [(ngModel)]="context.termSearch.ccvmFilters.item_type">
                 <option value='' i18n>All Item Types</option>
                 </ng-container> 
               </select>
             </div>
-            <div class="col-lg-3" *ngIf="searchFilters().includes('item_form')">
+            <div class="col-lg-3 mt-3" *ngIf="searchFilters().includes('item_form')">
               <select class="form-control" multiple="true"
                 [(ngModel)]="context.termSearch.ccvmFilters.item_form">
                 <option value='' i18n>All Item Forms</option>
                 </ng-container> 
               </select>
             </div>
-            <div class="col-lg-3" *ngIf="searchFilters().includes('item_lang')">
+            <div class="col-lg-3 mt-3" *ngIf="searchFilters().includes('item_lang')">
               <select class="form-control" 
                 [(ngModel)]="context.termSearch.ccvmFilters.item_lang" multiple="true">
                 <option value='' i18n>All Languages</option>
                 </ng-container> 
               </select>
             </div>
-            <div class="col-lg-3" *ngIf="searchFilters().includes('audience')">
+            <div class="col-lg-3 mt-3" *ngIf="searchFilters().includes('audience')">
               <select class="form-control" 
                 [(ngModel)]="context.termSearch.ccvmFilters.audience" multiple="true">
                 <option value='' i18n>All Audiences</option>
                 </ng-container> 
               </select>
             </div>
-          </div>
-          <div class="row mt-3" *ngIf="showFilters()">
-            <div class="col-lg-3" *ngIf="searchFilters().includes('vr_format')">
+            <div class="col-lg-3 mt-3" *ngIf="searchFilters().includes('vr_format')">
               <select class="form-control" 
                 [(ngModel)]="context.termSearch.ccvmFilters.vr_format" multiple="true">
                 <option value='' i18n>All Video Formats</option>
                 </ng-container> 
               </select>
             </div>
-            <div class="col-lg-3" *ngIf="searchFilters().includes('bib_level')">
+            <div class="col-lg-3 mt-3" *ngIf="searchFilters().includes('bib_level')">
               <select class="form-control" 
                 [(ngModel)]="context.termSearch.ccvmFilters.bib_level" multiple="true">
                 <option value='' i18n>All Bib Levels</option>
                 </ng-container> 
               </select>
             </div>
-            <div class="col-lg-3" *ngIf="searchFilters().includes('lit_form')">
+            <div class="col-lg-3 mt-3" *ngIf="searchFilters().includes('lit_form')">
               <select class="form-control" 
                 [(ngModel)]="context.termSearch.ccvmFilters.lit_form" multiple="true">
                 <option value='' i18n>All Literary Forms</option>
                 </ng-container> 
               </select>
             </div>
-            <div class="col-lg-3">
+            <div class="col-lg-3 mt-3">
               <select class="form-control" 
                 [(ngModel)]="context.termSearch.copyLocations" multiple="true">
                 <option value='' i18n>All Shelving Locations</option>