Owen Leonard
9cb89b4639
This patch updates the version of Bootstrap in the OPAC from 2.3.1 to 4.5.0. The Bootstrap JavaScript files have been replaced with custom builds of the 4.5.0 JavaScript source files. The Bootstrap CSS is now built into the OPAC CSS by loading the required Bootstrap 4.5.0 SCSS files in node_modules. OPAC SCSS now starts with Bootstrap customizations: /* Bootstrap variable customizations */ $headings-color: #727272; ... Followed by loading the necessary Bootstrap SCSS files: /* Bootstrap imports */ @import "../../../../../node_modules/bootstrap/scss/functions"; @import "../../../../../node_modules/bootstrap/scss/variables"; ... Followed by our CSS. The build process for generating compiled CSS now creates a file which bundles Bootstrap CSS and ours. Removed from the Koha source: Bootstrap CSS files, Bootstrap "glyphicons" images. The upgrade to Bootstrap 4 involved a lot of markup changes to conform with new Bootstrap classes, especially in classes related to the grid. Besides duplicating the grid we used before, this upgrade adds some new features made possible by Bootstrap 4.5's use of flexbox as a layout tool. This includes custom ordering of columns based on class names: https://getbootstrap.com/docs/4.5/layout/grid/#order-classes. Other areas where the most changes have been made: Navigation menus, breadcrumb menus, buttons, dropdowns. Bootstrap's JavaScript file is now "bootstrap.bundle.min.js" to reflect the fact that a required JavaScript asset is now distributed separately in Bootstrap 4. The "bundle" version includes Popper.js. Unrelated changes: Indentation corrections, removal of invalid "//<![CDATA[" markers, removal of invalid script type attributes. To test, apply the patch and run 'yarn install' to install Bootstrap as an npm module. Run 'yarn build --view opac' to regenerate the OPAC CSS. Test as many aspect of the OPAC as possible, viewing pages at various browser widths to confirm that everything adjusts well. Test with various OPAC interface system preferences enabled and disabled. Test self checkout and self checkin. Known issues: RTL support has not been updated. Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
185 lines
9.9 KiB
Text
185 lines
9.9 KiB
Text
[% USE raw %]
|
|
[% USE Asset %]
|
|
[% USE Koha %]
|
|
[% PROCESS 'opac-authorities.inc' %]
|
|
[% INCLUDE 'doc-head-open.inc' %]
|
|
<title>[% IF ( LibraryNameTitle ) %][% LibraryNameTitle | html %][% ELSE %]Koha online[% END %] catalog › Authority search › [% summary.mainentry | html %][% IF authtypetext %] ([% authtypetext | html %])[% END %]</title>
|
|
[% INCLUDE 'doc-head-close.inc' %]
|
|
[% BLOCK cssinclude %][% END %]
|
|
</head>
|
|
[% INCLUDE 'bodytag.inc' bodyid='opac-authoritiesdetail' bodyclass='scrollto' %]
|
|
[% INCLUDE 'masthead.inc' %]
|
|
|
|
<div class="main">
|
|
<nav aria-label="breadcrumb">
|
|
<ul class="breadcrumb">
|
|
<li class="breadcrumb-item">
|
|
<a href="/cgi-bin/koha/opac-main.pl">Home</a>
|
|
</li>
|
|
<li class="breadcrumb-item">
|
|
<a href="/cgi-bin/koha/opac-authorities-home.pl">Authority search</a>
|
|
</li>
|
|
<li class="breadcrumb-item" aria-current="page">
|
|
<a href="#">[% summary.mainentry | html %][% IF authtypetext %] ([% authtypetext | html %])[% END %]</a>
|
|
</li>
|
|
</ul>
|
|
</nav>
|
|
|
|
<div class="container-fluid">
|
|
<div class="row">
|
|
[% IF ( OpacNav || OpacNavBottom ) %]
|
|
<div class="col col-lg-2 order-2 order-lg-1">
|
|
<div id="navigation">
|
|
[% INCLUDE 'navigation.inc' %]
|
|
</div>
|
|
</div>
|
|
<div class="col-lg-10 order-first order-md-first order-lg-2">
|
|
[% ELSE %]
|
|
<div class="col order-first order-md-first order-lg-2">
|
|
[% END %]
|
|
<div id="userauthdetails" class="maincontent">
|
|
<div id="views">
|
|
<span class="view">
|
|
<span id="Normalview">Normal view</span>
|
|
</span>
|
|
<span class="view">
|
|
<a id="MARCview" href="/cgi-bin/koha/opac-authoritiesdetail.pl?authid=[% authid | html %]&marc=1">MARC view</a>
|
|
</span>
|
|
</div>
|
|
|
|
[% IF ( displayhierarchy ) %]
|
|
<div id="hierarchies">
|
|
[% PROCESS showhierarchy trees = loophierarchies %]
|
|
</div>
|
|
[% END %]
|
|
|
|
<h1>[% summary.mainentry | html %][% IF authtypetext %] ([% authtypetext | html %])[% END %]</h1>
|
|
|
|
<div class="usedin">
|
|
[% IF count %]<a href="/cgi-bin/koha/opac-search.pl?type=opac&q=[% authid | uri %]&idx=an,phr">Number of records used in: [% count | html %]</a>[% ELSE %]This authority is not used in any records.[% END %]
|
|
</div>
|
|
|
|
<div class="authstanza">
|
|
[% FOREACH authorize IN summary.authorized %]
|
|
<div class="heading authorized auth[% seefro.field | html %]">
|
|
<span class="label">Preferred form: </span>
|
|
<span class="authorized">[% authorize.heading | html %]</span>
|
|
</div>
|
|
[% END %]
|
|
[% PROCESS otherscript headings=summary.otherscript wantcategory='preferred' %]
|
|
</div>
|
|
|
|
[% IF summary.seefrom.size %]
|
|
<div class="authstanza seefrom">
|
|
<div class="authstanzaheading">Used for/see from:</div>
|
|
<ul class="seefrom">
|
|
[% FOREACH seefro IN summary.seefrom %]
|
|
<li class="heading seefrom auth[% seefro.field | html %]">
|
|
[% IF seefro.type && seefro.type != 'seefrom' %]
|
|
<span class="label">[% PROCESS authtypelabel type=seefro.type | trim %]:</span>
|
|
[% END %]
|
|
<span class="seefrom">[% PROCESS authheadingdisplay heading=seefro.heading search=seefrosearch authid=seefro.authid %]</span>
|
|
</li>
|
|
[% END %]
|
|
[% PROCESS otherscript headings=summary.otherscript wantcategory='seefrom' %]
|
|
</ul>
|
|
</div>
|
|
[% END %]
|
|
|
|
[% IF summary.seealso.size %]
|
|
<div class="authstanza seealso">
|
|
<div class="authstanzaheading">See also:</div>
|
|
<ul class="seelso">
|
|
[% FOREACH seeals IN summary.seealso %]
|
|
<li class="heading seealso auth[% seeals.field | html %]">
|
|
[% IF seeals.type && seeals.type != 'seealso' %]
|
|
<span class="label">[% PROCESS authtypelabel type=seeals.type | trim %]:</span>
|
|
[% END %]
|
|
<span class="seealso">[% PROCESS authheadingdisplay heading=seeals.heading search=seeals.search authid=seeals.authid %]</span>
|
|
</li>
|
|
[% END %]
|
|
[% PROCESS otherscript headings=summary.otherscript wantcategory='seealso' %]
|
|
</ul>
|
|
</div>
|
|
[% END %]
|
|
|
|
[% IF marcflavour == 'UNIMARC' && summary.otherscript %]
|
|
<div class="authstanza">
|
|
<div class="authstanzaheading">Other forms:</div>
|
|
<ul>
|
|
[% FOREACH otherscrip IN summary.otherscript %]
|
|
<li>
|
|
[% PROCESS language lang=otherscrip.lang | trim %]:
|
|
<span class="otherscript">[% otherscrip.term | html %]</span>
|
|
</li>
|
|
[% END %]
|
|
</ul>
|
|
</div>
|
|
[% END %]
|
|
|
|
[% IF ( MARCURLS ) %]
|
|
<div class="authstanza online_resources">
|
|
<span class="label">Online resources:</span>
|
|
<ul>
|
|
[% FOREACH MARCurl IN MARCURLS %]
|
|
<li>[% IF ( MARCurl.part ) %][% MARCurl.part | html %]<br />[% END %]
|
|
[% IF ( Koha.Preference('OPACURLOpenInNewWindow') ) %]
|
|
<a href="[% MARCurl.MARCURL | url %]" title="[% MARCurl.MARCURL | html %]" target="_blank" rel="noreferrer">
|
|
[% ELSE %]
|
|
<a href="[% MARCurl.MARCURL | url %]" title="[% MARCurl.MARCURL | html %]">
|
|
[% END %]
|
|
[% MARCurl.linktext | html %]</a>
|
|
[% IF ( MARCurl.notes ) %]
|
|
<ul>
|
|
[% FOREACH note IN MARCurl.notes %]
|
|
<li>[% note.note | html %]</li>
|
|
[% END %]
|
|
</ul>
|
|
[% END %]
|
|
</li>
|
|
[% END # /FOREACH MARCURLS %]
|
|
</ul>
|
|
</div>
|
|
[% END # / IF MARCURLS %]
|
|
|
|
<div id="authdescriptions" class="toptabs">
|
|
<ul>
|
|
<li id="tab_descriptions"><a href="#descriptions">Notes</a></li>
|
|
</ul>
|
|
<div id="descriptions">
|
|
<div class="content_set">
|
|
[% FOREACH note IN summary.notes %]
|
|
<p class="note auth[% note.field | html %]">[% note.note | html %]</p>
|
|
[% END %]
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div> <!-- / .#userauthdetails -->
|
|
</div> <!-- / .col-lg-10/12 -->
|
|
</div> <!-- / .row -->
|
|
</div> <!-- / .container-fluid -->
|
|
</div> <!-- / .main -->
|
|
|
|
[% INCLUDE 'opac-bottom.inc' %]
|
|
[% BLOCK jsinclude %]
|
|
[% IF ( displayhierarchy ) %]
|
|
[% Asset.js("lib/jquery/plugins/jquery.jstree.js") | $raw %]
|
|
[% END %]
|
|
<script>
|
|
$(document).ready(function() {
|
|
$('#authdescriptions').tabs();
|
|
[% IF ( displayhierarchy ) %]
|
|
var current_nodes = [];
|
|
$('.currentauth').each(function() {
|
|
current_nodes.push('#' + $(this).parent().parents('li:first').attr('id'));
|
|
});
|
|
$('#hierarchies').jstree({
|
|
"plugins": [ "themes", "html_data"],
|
|
"themes": { "theme": "classic",
|
|
"icons": false },
|
|
"core": { "initially_open": current_nodes }
|
|
});
|
|
[% END %]
|
|
});
|
|
</script>
|
|
[% END %]
|