Koha/koha-tmpl/intranet-tmpl/prog/en/includes/acquisitions-search.inc
Owen Leonard 086810633b
Bug 34135: Show the icons for selected tab to the left of the search bar in the staff interface
This patch modifies header search forms so that the form label has the
same icon used by the "tab" link.

The patch also improves the responsive behavior of the header search by
using the icon as the form label when the browser window is narrow
enough to hide the label text.

I've added the "aria-hidden" attribute to other icons in the modified
templates and made the "fa-fw" class consistent for all tab icons.

To test, apply the patch and rebuild the staff interface CSS. Clear your
browser cache if necessary.

View the header search form at various browser sizes to confirm that
content is shown and hidden correctly. Test at least one page which uses
each of the modified header search includes:

 - Staff client home page
 - Acquisitions -> Acquisitions home
   - Vendor ->
     - Basket -> Add to basket -> From suggestion
     - Contracts
 - Administration ->
   - Budgets
   - Currencies
   - Desks (with UseCirculationDesks enabled)
   - System preferences
   - Z39.50/SRU servers
 - Catalog advanced search
   - Search results
 - Authorities -> Authorities home
 - Cataloging -> Cataloging home
 - Circulation -> Check out
 - E-resource management (with ERMModule enabled)
 - Patrons -> Patrons home
 - Serials -> Serials home
 - Tools -> Notices

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-09-01 11:43:47 -03:00

56 lines
3.4 KiB
HTML

<!-- acquisitions-search.inc -->
<div id="header_search" role="tablist">
<div class="tab-content">
<div id="supplier_search" role="tabpanel" class="tab-pane active">
<form name="findsupplier" action="/cgi-bin/koha/acqui/booksellers.pl" method="post">
<div class="form-title">
<label class="control-label"><span class="control-text">Vendor search</span> <i class="fa fa-fw fa-upload" aria-hidden="true"></i></label>
</div>
<div class="form-content">
<input type="text" name="supplier" id="supplier" class="head-searchbox form-control" placeholder="Search vendors" />
</div>
<button type="submit"><i class="fa fa-arrow-right"></i></button>
</form>
</div>
<div id="orders_search" role="tabpanel" class="tab-pane">
<form action="/cgi-bin/koha/acqui/histsearch.pl" method="post">
<div class="form-title">
<label class="control-label"><span class="control-text">Orders search</span> <i class="fa fa-fw fa-download" aria-hidden="true"></i></label>
</div>
<div class="form-content">
<input type="text" id="title" class="form-control" placeholder="Title" name="title" size="13" value="[% title | html %]" />
<input type="text" id="searchsupplier" class="form-control" placeholder="Vendor" name="name" size="13" value="[% name | html %]" />
<button type="button" class="form-extra-content-toggle" title="More options"><i class="form-extra-content-icon fa-solid fa-sliders" aria-hidden="true"></i></button>
<input type="hidden" id="do_search" name="do_search" value="do" />
</div>
<button type="submit"><i class="fa fa-arrow-right"></i></button>
<div class="form-extra-content">
<div>
<label for="basket" class="control-label">Basket</label>
<input type="text" class="form-control" placeholder="Basket" name="basket" id="basket" />
</div>
<div>
<label for="booksellerinvoicenumber" class="control-label">Invoice number</label>
<input type="text" class="form-control" placeholder="Invoice number" name="booksellerinvoicenumber" id="booksellerinvoicenumber" />
</div>
<div>
<a href="/cgi-bin/koha/acqui/histsearch.pl">Advanced search</a>
</div>
</div>
</form>
</div>
</div><!-- /.tab-content -->
<ul class="nav nav-tabs" role="tablist">
<li role="presentation" class="active">
<a title="Vendor search" href="#supplier_search" aria-controls="supplier_search" role="tab" aria-expanded="true" data-toggle="tab" class="keep_text"><i class="fa fa-upload" aria-hidden="true"></i> <span class="tab-title">Vendor search</span></a>
</li>
<li role="presentation">
<a title="Orders search" href="#orders_search" aria-controls="orders_search" role="tab" data-toggle="tab" class="keep_text"><i class="fa fa-download" aria-hidden="true"></i> <span class="tab-title">Orders search</span></a>
</li>
</ul>
</div><!-- /#header_search -->
<!-- /acquisitions-search.inc -->