Bug 35689: Add id and classes to each MARC note in OPAC bibliographic details
Building on Bug 14156, this patch updates the OPAC bibliographic detail page's display of MARC notes to add the tag number in both a class (for consistent styling across the same tag number) and id (for unique styling for each repeated tag). To test: - As a quick test for custom CSS, go to Administration -> System preferences and locate the OPACUserCSS preference. - Add this testing CSS: .marcnote { font-size:140%; font-family: serif; } .marcnote-500 { background-color: #66FFCC; } .marcnote-511 { background-color: #99FFFF; } .marcnote-520 { background-color: #CCFF00; } .marcnote-521 { background-color: #CCFFFF; } .marcnote-538 { background-color: #FFCCCC; } .marcnote-546 { background-color: #FFFFCC; } - Locate a record with multiple notes fields. In the sample data, record 46, "Viridiana" is a good example which works well with the above CSS. - On the bibliographic detail page for the record, click the "Descriptions" tab. - Each MARC note should be colored according to the tag it comes from. - Inspect the HTML to confirm that each paragraph also has its own unique ID. Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de> (cherry picked from commitdfd4894acb
) Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com> (cherry picked from commit0a5dbec797
) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
This commit is contained in:
parent
6bea7de002
commit
7578b93c12
1 changed files with 6 additions and 6 deletions
|
@ -602,7 +602,7 @@
|
||||||
[% IF ( MARCNOTES ) %]
|
[% IF ( MARCNOTES ) %]
|
||||||
<div id="marcnotes">
|
<div id="marcnotes">
|
||||||
[% FOREACH MARCNOTE IN MARCNOTES %]
|
[% FOREACH MARCNOTE IN MARCNOTES %]
|
||||||
<p>
|
<p class="marcnote marcnote-[% MARCNOTE.tag | html %]" id="marcnote-[% MARCNOTE.tag | html %]-[% loop.count | html %]">
|
||||||
[% IF MARCNOTE.marcnote.match('^https?://\S+$') %]
|
[% IF MARCNOTE.marcnote.match('^https?://\S+$') %]
|
||||||
<a href="[% MARCNOTE.marcnote | url %]">[% MARCNOTE.marcnote | html %]</a>
|
<a href="[% MARCNOTE.marcnote | url %]">[% MARCNOTE.marcnote | html %]</a>
|
||||||
[% ELSE %]
|
[% ELSE %]
|
||||||
|
|
Loading…
Reference in a new issue