From bbbe5cf52e56ca617e095b0cade5ce6e9d7b7829 Mon Sep 17 00:00:00 2001 From: Jared Camins-Esakov Date: Sat, 28 Jul 2012 22:58:31 -0400 Subject: [PATCH] [3.8.x] Bug 6617: Improve MARC21 enhanced contents display Content-Type: text/plain; charset="UTF-8" The display of "Enhanced" 505 (contents) fields in the MARC21 XSLT is very poor, resulting in large, unreadable blocks of text, and -- for some series -- so much unnecessary duplication in the Notes tab that important information is entirely obscured. This patch reformats "enhanced" contents fields (MARC21 505 fields with $t and $r) so as to be more readable by breaking up entries on separate lines and making titles bold (to make them stand out more). This patch does not address duplication of information in the Notes tab, per discussion on the #koha IRC channel. To test: 1) View record with enhanced 505 field before applying patch. Observe it is very unfriendly. 2) Apply patch. 3) View same record, note that display is much improved. Signed-off-by: Nicole C. Engard This first patch works as advertised. It formats the table of contents on the opac detail display in a cleaner format. I recommend that future follow ups fix the staff client to match and update the title notes tabs on the opac and staff client to also match the cleaner format for table of contents. Signed-off-by: Jared Camins-Esakov --- koha-tmpl/opac-tmpl/prog/en/css/opac.css | 27 +++++++++++++++ .../prog/en/xslt/MARC21slim2OPACDetail.xsl | 36 +++++++++++--------- .../opac-tmpl/prog/en/xslt/MARC21slimUtils.xsl | 20 +++++++++++ 3 files changed, 67 insertions(+), 16 deletions(-) diff --git a/koha-tmpl/opac-tmpl/prog/en/css/opac.css b/koha-tmpl/opac-tmpl/prog/en/css/opac.css index c2113d9..c43cf5b 100644 --- a/koha-tmpl/opac-tmpl/prog/en/css/opac.css +++ b/koha-tmpl/opac-tmpl/prog/en/css/opac.css @@ -2540,3 +2540,30 @@ span.sep { } */ + +.contents { + width: 75%; +} + +.contentblock { + position: relative; + margin-left: 2em; +} + +.contents .t:first-child:before { + content: "→ "; +} + +.contents .t:before { + content: "\A→ "; + white-space: pre; +} + +.contents .t { + font-weight: bold; + display: inline; +} + +.contents .r { + display: inline; +} diff --git a/koha-tmpl/opac-tmpl/prog/en/xslt/MARC21slim2OPACDetail.xsl b/koha-tmpl/opac-tmpl/prog/en/xslt/MARC21slim2OPACDetail.xsl index 5daff77..3c7968f 100644 --- a/koha-tmpl/opac-tmpl/prog/en/xslt/MARC21slim2OPACDetail.xsl +++ b/koha-tmpl/opac-tmpl/prog/en/xslt/MARC21slim2OPACDetail.xsl @@ -569,33 +569,37 @@ +
- - - - Incomplete contents: - - - Partial contents: - - - Contents: - - + + + + Incomplete contents: + + + Partial contents: + + + Contents: + + + +
- + tru - - au + + atru - +
+
diff --git a/koha-tmpl/opac-tmpl/prog/en/xslt/MARC21slimUtils.xsl b/koha-tmpl/opac-tmpl/prog/en/xslt/MARC21slimUtils.xsl index 8a7d511..df7c450 100644 --- a/koha-tmpl/opac-tmpl/prog/en/xslt/MARC21slimUtils.xsl +++ b/koha-tmpl/opac-tmpl/prog/en/xslt/MARC21slimUtils.xsl @@ -40,6 +40,26 @@ + + + + + + + + + + + + + + + + + + + + -- 1.7.2.5