Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

DSpace XSL for xmlinclude

  • Loading branch information...
commit 8906e082dcb3a7336dbfca600d7e7d7c9f9356b2 1 parent 6fb6cd5
@ssp ssp authored
Showing with 11,017 additions and 0 deletions.
  1. +53 −0 fileadmin/xsl/Mirage.xsl
  2. +33 −0 fileadmin/xsl/lib/xsl/HTML5Boilerplate.LICENSE
  3. +105 −0 fileadmin/xsl/lib/xsl/aspect/administrative/administrative.xsl
  4. +81 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/COinS.xsl
  5. +141 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/ORE.xsl
  6. +47 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/artifactbrowser.xsl
  7. +47 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/artifactbrowser.xsl~
  8. +105 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/collection-list.xsl
  9. +105 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/collection-list.xsl~
  10. +82 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/collection-view.xsl
  11. +82 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/collection-view.xsl~
  12. +311 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/common.xsl
  13. +310 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/common.xsl~
  14. +108 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/community-list.xsl
  15. +108 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/community-list.xsl~
  16. +81 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/community-view.xsl
  17. +81 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/community-view.xsl~
  18. +275 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/item-list.xsl
  19. +275 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/item-list.xsl~
  20. +689 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/item-view.xsl
  21. +689 −0 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/item-view.xsl~
  22. +410 −0 fileadmin/xsl/lib/xsl/aspect/general/choice-authority-control.xsl
  23. +249 −0 fileadmin/xsl/lib/xsl/core/attribute-handlers.xsl
  24. +249 −0 fileadmin/xsl/lib/xsl/core/attribute-handlers.xsl~
  25. +614 −0 fileadmin/xsl/lib/xsl/core/elements.xsl
  26. +95 −0 fileadmin/xsl/lib/xsl/core/elements.xsl~
  27. +1,205 −0 fileadmin/xsl/lib/xsl/core/forms.xsl
  28. +1,205 −0 fileadmin/xsl/lib/xsl/core/forms.xsl~
  29. +59 −0 fileadmin/xsl/lib/xsl/core/global-variables.xsl
  30. +59 −0 fileadmin/xsl/lib/xsl/core/global-variables.xsl~
  31. +327 −0 fileadmin/xsl/lib/xsl/core/navigation.xsl
  32. +327 −0 fileadmin/xsl/lib/xsl/core/navigation.xsl~
  33. +165 −0 fileadmin/xsl/lib/xsl/core/page-structure.xsl
  34. +694 −0 fileadmin/xsl/lib/xsl/core/page-structure.xsl~
  35. +163 −0 fileadmin/xsl/lib/xsl/core/utils.xsl
  36. +163 −0 fileadmin/xsl/lib/xsl/core/utils.xsl~
  37. +571 −0 fileadmin/xsl/lib/xsl/item-view.xsl
  38. +654 −0 fileadmin/xsl/lib/xsl/page-structure.xsl
View
53 fileadmin/xsl/Mirage.xsl
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ TODO: Describe this XSL file
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet xmlns:i18n="http://apache.org/cocoon/i18n/2.1"
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xhtml="http://www.w3.org/1999/xhtml"
+ xmlns:mods="http://www.loc.gov/mods/v3"
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ exclude-result-prefixes="i18n dri mets xlink xsl dim xhtml mods dc">
+
+
+ <!--<xsl:import href="../dri2xhtml-alt/dri2xhtml.xsl"/> -->
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/core/global-variables.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/core/page-structure.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/core/navigation.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/core/elements.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/core/forms.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/core/attribute-handlers.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/core/utils.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/aspect/general/choice-authority-control.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/aspect/administrative/administrative.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/aspect/artifactbrowser/item-list.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/aspect/artifactbrowser/item-view.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/aspect/artifactbrowser/community-list.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/aspect/artifactbrowser/collection-list.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/aspect/artifactbrowser/artifactbrowser.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/aspect/artifactbrowser/collection-view.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/aspect/artifactbrowser/community-view.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/aspect/artifactbrowser/common.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/aspect/artifactbrowser/ORE.xsl"/>
+ <xsl:import href="/home/ssp/aac/fileadmin/xsl/lib/xsl/aspect/artifactbrowser/COinS.xsl"/>
+
+
+
+</xsl:stylesheet>
View
33 fileadmin/xsl/lib/xsl/HTML5Boilerplate.LICENSE
@@ -0,0 +1,33 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+This is free and unencumbered software released into the public domain.
+
+Anyone is free to copy, modify, publish, use, compile, sell, or
+distribute this software, either in source code form or as a compiled
+binary, for any purpose, commercial or non-commercial, and by any
+means.
+
+In jurisdictions that recognize copyright laws, the author or authors
+of this software dedicate any and all copyright interest in the
+software to the public domain. We make this dedication for the benefit
+of the public at large and to the detriment of our heirs and
+successors. We intend this dedication to be an overt act of
+relinquishment in perpetuity of all present and future rights to this
+software under copyright law.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
+OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
+ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.
+
+For more information, please refer to <http://unlicense.org/>
View
105 fileadmin/xsl/lib/xsl/aspect/administrative/administrative.xsl
@@ -0,0 +1,105 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Modifications to the rendering of elements in the administrative aspect.
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+-->
+
+<xsl:stylesheet xmlns:i18n="http://apache.org/cocoon/i18n/2.1"
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xhtml="http://www.w3.org/1999/xhtml"
+ xmlns:mods="http://www.loc.gov/mods/v3"
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ exclude-result-prefixes="i18n dri mets xlink xsl dim xhtml mods dc">
+
+ <xsl:output indent="yes"/>
+
+ <!--Add the class 'tabbed' to the form for administrative pages containing tabs and wrap the tab content with a div with class 'pane',
+ the rest is just a copy of the default interactive div template-->
+ <xsl:template match="dri:div[contains(@rend, 'administrative') and dri:list[@rend = 'horizontal']]">
+ <xsl:apply-templates select="dri:head"/>
+ <xsl:apply-templates select="@pagination">
+ <xsl:with-param name="position">top</xsl:with-param>
+ </xsl:apply-templates>
+ <form>
+ <xsl:call-template name="standardAttributes">
+ <xsl:with-param name="class">ds-interactive-div tabbed</xsl:with-param>
+ </xsl:call-template>
+ <xsl:attribute name="action"><xsl:value-of select="@action"/></xsl:attribute>
+ <xsl:attribute name="method"><xsl:value-of select="@method"/></xsl:attribute>
+ <xsl:if test="@method='multipart'">
+ <xsl:attribute name="method">post</xsl:attribute>
+ <xsl:attribute name="enctype">multipart/form-data</xsl:attribute>
+ </xsl:if>
+ <xsl:attribute name="onsubmit">javascript:tSubmit(this);</xsl:attribute>
+ <!--For Item Submission process, disable ability to submit a form by pressing 'Enter'-->
+ <xsl:if test="starts-with(@n,'submit')">
+ <xsl:attribute name="onkeydown">javascript:return disableEnterKey(event);</xsl:attribute>
+ </xsl:if>
+ <xsl:apply-templates select="dri:list[@rend = 'horizontal']"/>
+ <div class="pane">
+ <xsl:apply-templates select="*[not(name()='head' or @rend = 'horizontal')]"/>
+ </div>
+
+ </form>
+ <!-- JS to scroll form to DIV parent of "Add" button if jump-to -->
+ <xsl:if test="/dri:document/dri:meta/dri:pageMeta/dri:metadata[@element='page'][@qualifier='jumpTo']">
+ <script type="text/javascript">
+ <xsl:text>var button = document.getElementById('</xsl:text>
+ <xsl:value-of select="translate(@id,'.','_')"/>
+ <xsl:text>').elements['</xsl:text>
+ <xsl:value-of select="concat('submit_',/dri:document/dri:meta/dri:pageMeta/dri:metadata[@element='page'][@qualifier='jumpTo'],'_add')"/>
+ <xsl:text>'];</xsl:text>
+ <xsl:text>
+ if (button != null) {
+ var n = button.parentNode;
+ for (; n != null; n = n.parentNode) {
+ if (n.tagName == 'DIV') {
+ n.scrollIntoView(false);
+ break;
+ }
+ }
+ }
+ </xsl:text>
+ </script>
+ </xsl:if>
+ <xsl:apply-templates select="@pagination">
+ <xsl:with-param name="position">bottom</xsl:with-param>
+ </xsl:apply-templates>
+ </xsl:template>
+
+
+ <!--the tabs are floating, so give the ul the class 'clearfix' to ensure it has a height-->
+ <xsl:template match="dri:div[contains(@rend, 'administrative')]/dri:list[@rend = 'horizontal']">
+ <xsl:apply-templates select="dri:head"/>
+ <ul>
+ <xsl:call-template name="standardAttributes">
+ <xsl:with-param name="class">ds-simple-list clearfix</xsl:with-param>
+ </xsl:call-template>
+ <xsl:apply-templates select="*[not(name()='head')]" mode="nested"/>
+ </ul>
+ </xsl:template>
+
+ <!--give the active tab the class 'active-tab'-->
+ <xsl:template match="dri:div[contains(@rend, 'administrative')]/dri:list[@rend = 'horizontal']/dri:item[dri:hi[@rend = 'bold']]" mode="nested">
+ <li class="active-tab">
+ <xsl:apply-templates />
+ </li>
+ </xsl:template>
+
+</xsl:stylesheet>
View
81 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/COinS.xsl
@@ -0,0 +1,81 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Rendering of the OpenURL COinS references
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:i18n="http://apache.org/cocoon/i18n/2.1"
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ xmlns:encoder="xalan://java.net.URLEncoder"
+ exclude-result-prefixes="xalan encoder i18n dri mets dim xlink xsl">
+
+ <xsl:output indent="yes"/>
+
+
+ <!--
+ *********************************************
+ OpenURL COinS Rendering Template
+ *********************************************
+
+ COinS Example:
+
+ <span class="Z3988"
+ title="ctx_ver=Z39.88-2004&amp;
+ rft_val_fmt=info%3Aofi%2Ffmt%3Akev%3Amtx%3Adc&amp;
+ rfr_id=info%3Asid%2Focoins.info%3Agenerator&amp;
+ rft.title=Making+WordPress+Content+Available+to+Zotero&amp;
+ rft.aulast=Kraus&amp;
+ rft.aufirst=Kari&amp;
+ rft.subject=News&amp;
+ rft.source=Zotero%3A+The+Next-Generation+Research+Tool&amp;
+ rft.date=2007-02-08&amp;
+ rft.type=blogPost&amp;
+ rft.format=text&amp;
+ rft.identifier=http://www.zotero.org/blog/making-wordpress-content-available-to-zotero/&amp;
+ rft.language=English"></span>
+
+ This Code does not parse authors names, instead relying on dc.contributor to populate the
+ coins
+ -->
+
+ <xsl:template name="renderCOinS">
+ <xsl:text>ctx_ver=Z39.88-2004&amp;rft_val_fmt=info%3Aofi%2Ffmt%3Akev%3Amtx%3Adc&amp;</xsl:text>
+ <xsl:for-each select=".//dim:field[@element = 'identifier']">
+ <xsl:text>rft_id=</xsl:text>
+ <xsl:value-of select="encoder:encode(string(.))"/>
+ <xsl:text>&amp;</xsl:text>
+ </xsl:for-each>
+ <xsl:text>rfr_id=info%3Asid%2Fdspace.org%3Arepository&amp;</xsl:text>
+ <xsl:for-each select=".//dim:field[@element != 'description' and @mdschema !='dc' and @qualifier != 'provenance']">
+ <xsl:value-of select="concat('rft.', @element,'=',encoder:encode(string(.))) "/>
+ <xsl:if test="position()!=last()">
+ <xsl:text>&amp;</xsl:text>
+ </xsl:if>
+ </xsl:for-each>
+ </xsl:template>
+
+
+</xsl:stylesheet>
View
141 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/ORE.xsl
@@ -0,0 +1,141 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Files listing rendering specific to the ORE bundle
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:i18n="http://apache.org/cocoon/i18n/2.1"
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ xmlns:encoder="xalan://java.net.URLEncoder"
+ exclude-result-prefixes="xalan encoder i18n dri mets dim xlink xsl">
+
+
+ <xsl:output indent="yes"/>
+
+ <!-- Rendering the file list from an Atom ReM bitstream stored in the ORE bundle -->
+ <xsl:template match="mets:fileGrp[@USE='ORE']">
+ <xsl:variable name="AtomMapURL" select="concat('cocoon:/',substring-after(mets:file/mets:FLocat[@LOCTYPE='URL']//@*[local-name(.)='href'],$context-path))"/>
+ <h2><i18n:text>xmlui.dri2xhtml.METS-1.0.item-files-head</i18n:text></h2>
+ <table class="ds-table file-list">
+ <thead>
+ <tr class="ds-table-header-row">
+ <th><i18n:text>xmlui.dri2xhtml.METS-1.0.item-files-file</i18n:text></th>
+ <th><i18n:text>xmlui.dri2xhtml.METS-1.0.item-files-size</i18n:text></th>
+ <th><i18n:text>xmlui.dri2xhtml.METS-1.0.item-files-format</i18n:text></th>
+ <th><i18n:text>xmlui.dri2xhtml.METS-1.0.item-files-view</i18n:text></th>
+ </tr>
+ </thead>
+ <tbody>
+ <xsl:apply-templates select="document($AtomMapURL)/atom:entry/atom:link[@rel='http://www.openarchives.org/ore/terms/aggregates']">
+ <xsl:sort select="@title"/>
+ </xsl:apply-templates>
+ </tbody>
+ </table>
+ </xsl:template>
+
+
+ <!-- Iterate over the links in the ORE resource maps and make them into bitstream references in the file section -->
+ <xsl:template match="atom:link[@rel='http://www.openarchives.org/ore/terms/aggregates']">
+ <tr>
+ <xsl:attribute name="class">
+ <xsl:text>ds-table-row </xsl:text>
+ <xsl:if test="(position() mod 2 = 0)">even </xsl:if>
+ <xsl:if test="(position() mod 2 = 1)">odd </xsl:if>
+ </xsl:attribute>
+ <td>
+ <a>
+ <xsl:attribute name="href">
+ <xsl:value-of select="@href"/>
+ </xsl:attribute>
+ <xsl:attribute name="title">
+ <xsl:choose>
+ <xsl:when test="@title">
+ <xsl:value-of select="@title"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="@href"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:attribute>
+ <xsl:choose>
+ <xsl:when test="string-length(@title) > 50">
+ <xsl:variable name="title_length" select="string-length(@title)"/>
+ <xsl:value-of select="substring(@title,1,15)"/>
+ <xsl:text> ... </xsl:text>
+ <xsl:value-of select="substring(@title,$title_length - 25,$title_length)"/>
+ </xsl:when>
+ <xsl:when test="@title">
+ <xsl:value-of select="@title"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="@href"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </a>
+ </td>
+ <!-- File size always comes in bytes and thus needs conversion -->
+ <td>
+ <xsl:choose>
+ <xsl:when test="@length &lt; 1000">
+ <xsl:value-of select="@length"/>
+ <i18n:text>xmlui.dri2xhtml.METS-1.0.size-bytes</i18n:text>
+ </xsl:when>
+ <xsl:when test="@length &lt; 1000000">
+ <xsl:value-of select="substring(string(@length div 1000),1,5)"/>
+ <i18n:text>xmlui.dri2xhtml.METS-1.0.size-kilobytes</i18n:text>
+ </xsl:when>
+ <xsl:when test="@length &lt; 1000000001">
+ <xsl:value-of select="substring(string(@length div 1000000),1,5)"/>
+ <i18n:text>xmlui.dri2xhtml.METS-1.0.size-megabytes</i18n:text>
+ </xsl:when>
+ <xsl:when test="@length &gt; 1000000000">
+ <xsl:value-of select="substring(string(@length div 1000000000),1,5)"/>
+ <i18n:text>xmlui.dri2xhtml.METS-1.0.size-gigabytes</i18n:text>
+ </xsl:when>
+ <!-- When one isn't available -->
+ <xsl:otherwise><xsl:text>n/a</xsl:text></xsl:otherwise>
+ </xsl:choose>
+ </td>
+ <!-- Currently format carries forward the mime type. In the original DSpace, this
+ would get resolved to an application via the Bitstream Registry, but we are
+ constrained by the capabilities of METS and can't really pass that info through. -->
+ <td>
+ <xsl:value-of select="substring-before(@type,'/')"/>
+ <xsl:text>/</xsl:text>
+ <xsl:value-of select="substring-after(@type,'/')"/>
+ </td>
+ <td>
+ <a>
+ <xsl:attribute name="href">
+ <xsl:value-of select="@href"/>
+ </xsl:attribute>
+ <i18n:text>xmlui.dri2xhtml.METS-1.0.item-files-viewOpen</i18n:text>
+ </a>
+ </td>
+ </tr>
+ </xsl:template>
+
+</xsl:stylesheet>
View
47 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/artifactbrowser.xsl
@@ -0,0 +1,47 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Starting point of the artifactbrowser transformation.
+ This xsl references all artifactbrowser related dependencies.
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ exclude-result-prefixes="xalan dri mets dim xlink xsl">
+
+ <xsl:import href="common.xsl"/>
+ <xsl:import href="item-list.xsl"/>
+ <xsl:import href="collection-list.xsl"/>
+ <xsl:import href="community-list.xsl"/>
+ <xsl:import href="item-view.xsl"/>
+ <xsl:import href="collection-view.xsl"/>
+ <xsl:import href="community-view.xsl"/>
+
+
+
+ <xsl:output indent="yes"/>
+
+
+</xsl:stylesheet>
View
47 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/artifactbrowser.xsl~
@@ -0,0 +1,47 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Starting point of the artifactbrowser transformation.
+ This xsl references all artifactbrowser related dependencies.
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ exclude-result-prefixes="xalan dri mets dim xlink xsl">
+
+ <xsl:import href="common.xsl"/>
+ <xsl:import href="item-list.xsl"/>
+ <xsl:import href="collection-list.xsl"/>
+ <xsl:import href="community-list.xsl"/>
+ <xsl:import href="item-view.xsl"/>
+ <xsl:import href="collection-view.xsl"/>
+ <xsl:import href="community-view.xsl"/>
+ <xsl:import href="ORE.xsl"/>
+ <xsl:import href="COinS.xsl"/>
+
+ <xsl:output indent="yes"/>
+
+
+</xsl:stylesheet>
View
105 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/collection-list.xsl
@@ -0,0 +1,105 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Rendering of a list of collections (e.g. on a community homepage,
+ or on the community-list page)
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ xmlns:encoder="xalan://java.net.URLEncoder"
+ xmlns:util="org.dspace.app.xmlui.utils.XSLUtils"
+ xmlns:confman="org.dspace.core.ConfigurationManager"
+ exclude-result-prefixes="xalan encoder dri mets dim xlink xsl atom ore oreatom util confman">
+
+ <xsl:output indent="yes"/>
+
+ <!-- A collection rendered in the summaryList pattern. Encountered on the community-list page -->
+ <xsl:template name="collectionSummaryList-DIM">
+ <xsl:variable name="data" select="./mets:dmdSec/mets:mdWrap/mets:xmlData/dim:dim"/>
+ <div class="artifact-description">
+ <div class="artifact-title">
+ <a href="{@OBJID}">
+ <span class="Z3988">
+ <xsl:choose>
+ <xsl:when test="string-length($data/dim:field[@element='title'][1]) &gt; 0">
+ <xsl:value-of select="$data/dim:field[@element='title'][1]"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/i18n/message[@key='xmlui.dri2xhtml.METS-1.0.no-title']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </span>
+ </a>
+ <!--Display community strengths (item counts) if they exist-->
+ <xsl:if test="string-length($data/dim:field[@element='format'][@qualifier='extent'][1]) &gt; 0">
+ <xsl:text> [</xsl:text>
+ <xsl:value-of select="$data/dim:field[@element='format'][@qualifier='extent'][1]"/>
+ <xsl:text>]</xsl:text>
+ </xsl:if>
+ </div>
+ <xsl:variable name="abstract" select="$data/dim:field[@element = 'description' and @qualifier='abstract']/node()"/>
+ <xsl:if test="$abstract and string-length($abstract[1]) &gt; 0">
+ <div class="artifact-info">
+ <span class="short-description">
+ <xsl:value-of select="$abstract"/>
+ </span>
+ </div>
+ </xsl:if>
+ </div>
+ </xsl:template>
+
+ <!-- A collection rendered in the detailList pattern. Encountered on the item view page as
+ the "this item is part of these collections" list -->
+ <xsl:template name="collectionDetailList-DIM">
+ <xsl:variable name="data" select="./mets:dmdSec/mets:mdWrap/mets:xmlData/dim:dim"/>
+ <a href="{@OBJID}">
+ <xsl:choose>
+ <xsl:when test="string-length($data/dim:field[@element='title'][1]) &gt; 0">
+ <xsl:value-of select="$data/dim:field[@element='title'][1]"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/i18n/message[@key='xmlui.dri2xhtml.METS-1.0.no-title']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </a>
+ <!--Display collection strengths (item counts) if they exist-->
+ <xsl:if test="string-length($data/dim:field[@element='format'][@qualifier='extent'][1]) &gt; 0">
+ <xsl:text> [</xsl:text>
+ <xsl:value-of select="$data/dim:field[@element='format'][@qualifier='extent'][1]"/>
+ <xsl:text>]</xsl:text>
+ </xsl:if>
+ <br/>
+ <xsl:choose>
+ <xsl:when test="$data/dim:field[@element='description' and @qualifier='abstract']">
+ <xsl:copy-of select="$data/dim:field[@element='description' and @qualifier='abstract']/node()"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:copy-of select="$data/dim:field[@element='description'][1]/node()"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+</xsl:stylesheet>
View
105 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/collection-list.xsl~
@@ -0,0 +1,105 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Rendering of a list of collections (e.g. on a community homepage,
+ or on the community-list page)
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ xmlns:encoder="xalan://java.net.URLEncoder"
+ xmlns:util="org.dspace.app.xmlui.utils.XSLUtils"
+ xmlns:confman="org.dspace.core.ConfigurationManager"
+ exclude-result-prefixes="xalan encoder dri mets dim xlink xsl">
+
+ <xsl:output indent="yes"/>
+
+ <!-- A collection rendered in the summaryList pattern. Encountered on the community-list page -->
+ <xsl:template name="collectionSummaryList-DIM">
+ <xsl:variable name="data" select="./mets:dmdSec/mets:mdWrap/mets:xmlData/dim:dim"/>
+ <div class="artifact-description">
+ <div class="artifact-title">
+ <a href="{@OBJID}">
+ <span class="Z3988">
+ <xsl:choose>
+ <xsl:when test="string-length($data/dim:field[@element='title'][1]) &gt; 0">
+ <xsl:value-of select="$data/dim:field[@element='title'][1]"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/i18n/message[@key='xmlui.dri2xhtml.METS-1.0.no-title']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </span>
+ </a>
+ <!--Display community strengths (item counts) if they exist-->
+ <xsl:if test="string-length($data/dim:field[@element='format'][@qualifier='extent'][1]) &gt; 0">
+ <xsl:text> [</xsl:text>
+ <xsl:value-of select="$data/dim:field[@element='format'][@qualifier='extent'][1]"/>
+ <xsl:text>]</xsl:text>
+ </xsl:if>
+ </div>
+ <xsl:variable name="abstract" select="$data/dim:field[@element = 'description' and @qualifier='abstract']/node()"/>
+ <xsl:if test="$abstract and string-length($abstract[1]) &gt; 0">
+ <div class="artifact-info">
+ <span class="short-description">
+ <xsl:value-of select="$abstract"/>
+ </span>
+ </div>
+ </xsl:if>
+ </div>
+ </xsl:template>
+
+ <!-- A collection rendered in the detailList pattern. Encountered on the item view page as
+ the "this item is part of these collections" list -->
+ <xsl:template name="collectionDetailList-DIM">
+ <xsl:variable name="data" select="./mets:dmdSec/mets:mdWrap/mets:xmlData/dim:dim"/>
+ <a href="{@OBJID}">
+ <xsl:choose>
+ <xsl:when test="string-length($data/dim:field[@element='title'][1]) &gt; 0">
+ <xsl:value-of select="$data/dim:field[@element='title'][1]"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/i18n/message[@key='xmlui.dri2xhtml.METS-1.0.no-title']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </a>
+ <!--Display collection strengths (item counts) if they exist-->
+ <xsl:if test="string-length($data/dim:field[@element='format'][@qualifier='extent'][1]) &gt; 0">
+ <xsl:text> [</xsl:text>
+ <xsl:value-of select="$data/dim:field[@element='format'][@qualifier='extent'][1]"/>
+ <xsl:text>]</xsl:text>
+ </xsl:if>
+ <br/>
+ <xsl:choose>
+ <xsl:when test="$data/dim:field[@element='description' and @qualifier='abstract']">
+ <xsl:copy-of select="$data/dim:field[@element='description' and @qualifier='abstract']/node()"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:copy-of select="$data/dim:field[@element='description'][1]/node()"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+</xsl:stylesheet>
View
82 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/collection-view.xsl
@@ -0,0 +1,82 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Rendering specific to the collection home page.
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:i18n="http://apache.org/cocoon/i18n/2.1"
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ xmlns:encoder="xalan://java.net.URLEncoder"
+ exclude-result-prefixes="xalan encoder i18n dri mets dim xlink xsl atom ore oreatom">
+
+ <xsl:output indent="yes"/>
+
+ <!-- The summaryView of communities and collections is undefined. -->
+ <xsl:template name="collectionSummaryView-DIM">
+ <xsl:value-of select="/dri:document/dri:18n/dri:message[@key='xmlui.dri2xhtml.METS-1.0.collection-not-implemented']"/>
+ </xsl:template>
+
+ <!-- A collection rendered in the detailView pattern; default way of viewing a collection. -->
+ <xsl:template name="collectionDetailView-DIM">
+ <div class="detail-view">&#160;
+ <!-- Generate the logo, if present, from the file section -->
+ <xsl:apply-templates select="./mets:fileSec/mets:fileGrp[@USE='LOGO']"/>
+ <!-- Generate the info about the collections from the metadata section -->
+ <xsl:apply-templates select="./mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']/mets:xmlData/dim:dim"
+ mode="collectionDetailView-DIM"/>
+ </div>
+ </xsl:template>
+
+ <!-- Generate the info about the collection from the metadata section -->
+ <xsl:template match="dim:dim" mode="collectionDetailView-DIM">
+ <xsl:if test="string-length(dim:field[@element='description'][not(@qualifier)])&gt;0">
+ <p class="intro-text">
+ <xsl:copy-of select="dim:field[@element='description'][not(@qualifier)]/node()"/>
+ </p>
+ </xsl:if>
+
+ <xsl:if test="string-length(dim:field[@element='description'][@qualifier='tableofcontents'])&gt;0">
+ <div class="detail-view-news">
+ <h3><xsl:value-of select="/dri:document/dri:18n/dri:message[@key='xmlui.dri2xhtml.METS-1.0.news']"/></h3>
+ <p class="news-text">
+ <xsl:copy-of select="dim:field[@element='description'][@qualifier='tableofcontents']/node()"/>
+ </p>
+ </div>
+ </xsl:if>
+
+ <xsl:if test="string-length(dim:field[@element='rights'][not(@qualifier)])&gt;0">
+ <div class="detail-view-rights-and-license">
+ <xsl:if test="string-length(dim:field[@element='rights'][not(@qualifier)])&gt;0">
+ <p class="copyright-text">
+ <xsl:copy-of select="dim:field[@element='rights'][not(@qualifier)]/node()"/>
+ </p>
+ </xsl:if>
+ </div>
+ </xsl:if>
+ </xsl:template>
+
+
+</xsl:stylesheet>
View
82 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/collection-view.xsl~
@@ -0,0 +1,82 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Rendering specific to the collection home page.
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:i18n="http://apache.org/cocoon/i18n/2.1"
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ xmlns:encoder="xalan://java.net.URLEncoder"
+ exclude-result-prefixes="xalan encoder i18n dri mets dim xlink xsl">
+
+ <xsl:output indent="yes"/>
+
+ <!-- The summaryView of communities and collections is undefined. -->
+ <xsl:template name="collectionSummaryView-DIM">
+ <xsl:value-of select="/dri:document/dri:18n/dri:message[@key='xmlui.dri2xhtml.METS-1.0.collection-not-implemented']"/>
+ </xsl:template>
+
+ <!-- A collection rendered in the detailView pattern; default way of viewing a collection. -->
+ <xsl:template name="collectionDetailView-DIM">
+ <div class="detail-view">&#160;
+ <!-- Generate the logo, if present, from the file section -->
+ <xsl:apply-templates select="./mets:fileSec/mets:fileGrp[@USE='LOGO']"/>
+ <!-- Generate the info about the collections from the metadata section -->
+ <xsl:apply-templates select="./mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']/mets:xmlData/dim:dim"
+ mode="collectionDetailView-DIM"/>
+ </div>
+ </xsl:template>
+
+ <!-- Generate the info about the collection from the metadata section -->
+ <xsl:template match="dim:dim" mode="collectionDetailView-DIM">
+ <xsl:if test="string-length(dim:field[@element='description'][not(@qualifier)])&gt;0">
+ <p class="intro-text">
+ <xsl:copy-of select="dim:field[@element='description'][not(@qualifier)]/node()"/>
+ </p>
+ </xsl:if>
+
+ <xsl:if test="string-length(dim:field[@element='description'][@qualifier='tableofcontents'])&gt;0">
+ <div class="detail-view-news">
+ <h3><xsl:value-of select="/dri:document/dri:18n/dri:message[@key='xmlui.dri2xhtml.METS-1.0.news']"/></h3>
+ <p class="news-text">
+ <xsl:copy-of select="dim:field[@element='description'][@qualifier='tableofcontents']/node()"/>
+ </p>
+ </div>
+ </xsl:if>
+
+ <xsl:if test="string-length(dim:field[@element='rights'][not(@qualifier)])&gt;0">
+ <div class="detail-view-rights-and-license">
+ <xsl:if test="string-length(dim:field[@element='rights'][not(@qualifier)])&gt;0">
+ <p class="copyright-text">
+ <xsl:copy-of select="dim:field[@element='rights'][not(@qualifier)]/node()"/>
+ </p>
+ </xsl:if>
+ </div>
+ </xsl:if>
+ </xsl:template>
+
+
+</xsl:stylesheet>
View
311 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/common.xsl
@@ -0,0 +1,311 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Parts of the artifactbrowser which are not
+ specific to a single listing or page. These will not
+ frequently be adapted in a theme
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ exclude-result-prefixes="xalan dri mets dim xlink xsl atom ore oreatom">
+
+ <xsl:output indent="yes"/>
+
+<!-- These templates are devoted to handling the referenceSet and reference elements. Although they are considered
+ structural elements, neither of the two contains actual content. Instead, references contain references
+ to object metadata under objectMeta, while referenceSets group references together.
+-->
+
+
+ <!-- Starting off easy here, with a summaryList -->
+
+ <!-- Current issues:
+
+ 1. There is no check for the repository identifier. Need to fix that by concatenating it with the
+ object identifier and using the resulting string as the key on items and reps.
+ 2. The use of a key index across the object store is cryptic and counterintuitive and most likely
+ could benefit from better documentation.
+ -->
+
+ <!-- When you come to an referenceSet you have to make a decision. Since it contains objects, and each
+ object is its own entity (and handled in its own template) the decision of the overall structure
+ would logically (and traditionally) lie with this template. However, to accomplish this we would
+ have to look ahead and check what objects are included in the set, which involves resolving the
+ references ahead of time and getting the information from their METS profiles directly.
+
+ Since this approach creates strong coupling between the set and the objects it contains, and we
+ have tried to avoid that, we use the "pioneer" method. -->
+
+ <!-- Summarylist case. This template used to apply templates to the "pioneer" object (the first object
+ in the set) and let it figure out what to do. This is no longer the case, as everything has been
+ moved to the list model. A special theme, called TableTheme, has beeen created for the purpose of
+ preserving the pioneer model. -->
+
+ <xsl:template match="dri:referenceSet[@type = 'summaryList']" priority="2">
+ <xsl:apply-templates select="dri:head"/>
+ <!-- Here we decide whether we have a hierarchical list or a flat one -->
+ <xsl:choose>
+ <xsl:when test="descendant-or-self::dri:referenceSet/@rend='hierarchy' or ancestor::dri:referenceSet/@rend='hierarchy'">
+ <ul>
+ <xsl:apply-templates select="*[not(name()='head')]" mode="summaryList"/>
+ </ul>
+ </xsl:when>
+ <xsl:otherwise>
+ <ul class="ds-artifact-list">
+ <xsl:apply-templates select="*[not(name()='head')]" mode="summaryList"/>
+ </ul>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+ <!-- First, the detail list case -->
+ <xsl:template match="dri:referenceSet[@type = 'detailList']" priority="2">
+ <xsl:apply-templates select="dri:head"/>
+ <ul class="ds-referenceSet-list">
+ <xsl:apply-templates select="*[not(name()='head')]" mode="detailList"/>
+ </ul>
+ </xsl:template>
+
+
+ <!-- Next up is the summary view case that at this point applies only to items, since communities and
+ collections do not have two separate views. -->
+ <xsl:template match="dri:referenceSet[@type = 'summaryView']" priority="2">
+ <xsl:apply-templates select="dri:head"/>
+ <xsl:apply-templates select="*[not(name()='head')]" mode="summaryView"/>
+ </xsl:template>
+
+ <!-- Finally, we have the detailed view case that is applicable to items, communities and collections.
+ In DRI it constitutes a standard view of collections/communities and a complete metadata listing
+ view of items. -->
+ <xsl:template match="dri:referenceSet[@type = 'detailView']" priority="2">
+ <xsl:apply-templates select="dri:head"/>
+ <xsl:apply-templates select="*[not(name()='head')]" mode="detailView"/>
+ </xsl:template>
+
+
+
+
+
+ <!-- The following options can be appended to the external metadata URL to request specific
+ sections of the METS document:
+
+ sections:
+
+ A comma seperated list of METS sections to included. The possible values are: "metsHdr", "dmdSec",
+ "amdSec", "fileSec", "structMap", "structLink", "behaviorSec", and "extraSec". If no list is provided then *ALL*
+ sections are rendered.
+
+
+ dmdTypes:
+
+ A comma seperated list of metadata formats to provide as descriptive metadata. The list of avaialable metadata
+ types is defined in the dspace.cfg, disseminationcrosswalks. If no formats are provided them DIM - DSpace
+ Intermediate Format - is used.
+
+
+ amdTypes:
+
+ A comma seperated list of metadata formats to provide administative metadata. DSpace does not currently
+ support this type of metadata.
+
+
+ fileGrpTypes:
+
+ A comma seperated list of file groups to render. For DSpace a bundle is translated into a METS fileGrp, so
+ possible values are "THUMBNAIL","CONTENT", "METADATA", etc... If no list is provided then all groups are
+ rendered.
+
+
+ structTypes:
+
+ A comma seperated list of structure types to render. For DSpace there is only one structType: LOGICAL. If this
+ is provided then the logical structType will be rendered, otherwise none will. The default operation is to
+ render all structure types.
+ -->
+
+ <!-- Then we resolve the reference tag to an external mets object -->
+ <xsl:template match="dri:reference" mode="summaryList">
+ <!--<xsl:variable name="externalMetadataURL">
+ <xsl:text>cocoon:/</xsl:text>
+ <xsl:value-of select="@url"/>-->
+ <!-- Since this is a summary only grab the descriptive metadata, and the thumbnails -->
+ <!--<xsl:text>?sections=dmdSec,fileSec&amp;fileGrpTypes=THUMBNAIL</xsl:text>-->
+ <!-- An example of requesting a specific metadata standard (MODS and QDC crosswalks only work for items)->
+ <xsl:if test="@type='DSpace Item'">
+ <xsl:text>&amp;dmdTypes=DC</xsl:text>
+ </xsl:if>-->
+ <!--</xsl:variable>
+ <xsl:comment> External Metadata URL: <xsl:value-of select="$externalMetadataURL"/> </xsl:comment>-->
+ <li>
+ <xsl:attribute name="class">
+ <xsl:text>ds-artifact-item </xsl:text>
+ <xsl:choose>
+ <xsl:when test="position() mod 2 = 0">even</xsl:when>
+ <xsl:otherwise>odd</xsl:otherwise>
+ </xsl:choose>
+ </xsl:attribute>
+ <!--<xsl:apply-templates select="document($externalMetadataURL)" mode="summaryList"/>-->
+ <xsl:apply-templates select="mets:METS" mode="summaryList"/>
+ <xsl:apply-templates />
+ </li>
+ </xsl:template>
+
+ <xsl:template match="dri:reference" mode="detailList">
+ <!--<xsl:variable name="externalMetadataURL">
+ <xsl:text>cocoon:/</xsl:text>
+ <xsl:value-of select="@url"/>
+
+ </xsl:variable>
+ <xsl:comment> External Metadata URL: <xsl:value-of select="$externalMetadataURL"/> </xsl:comment>-->
+ <li>
+ <!--<xsl:apply-templates select="document($externalMetadataURL)" mode="detailList"/>-->
+ <xsl:apply-templates select="mets:METS" mode="detailList"/>
+ <xsl:apply-templates />
+ </li>
+ </xsl:template>
+
+ <xsl:template match="dri:reference" mode="summaryView">
+ <!--<xsl:variable name="externalMetadataURL">
+ <xsl:text>cocoon:/</xsl:text>
+ <xsl:value-of select="@url"/>
+
+ </xsl:variable>
+ <xsl:comment> External Metadata URL: <xsl:value-of select="$externalMetadataURL"/> </xsl:comment>-->
+ <!--<xsl:apply-templates select="document($externalMetadataURL)" mode="summaryView"/>-->
+ <xsl:apply-templates select="mets:METS" mode="summaryView"/>
+ <xsl:apply-templates />
+ </xsl:template>
+
+ <xsl:template match="dri:reference" mode="detailView">
+ <!--<xsl:variable name="externalMetadataURL">
+ <xsl:text>cocoon:/</xsl:text>
+ <xsl:value-of select="@url"/>
+
+ </xsl:variable>
+ <xsl:comment> External Metadata URL: <xsl:value-of select="$externalMetadataURL"/> </xsl:comment>-->
+
+ <!--<xsl:apply-templates select="document($externalMetadataURL)" mode="detailView"/>-->
+ <xsl:apply-templates select="mets:METS" mode="detailView"/>
+ <xsl:apply-templates />
+ </xsl:template>
+
+ <!--
+ The summaryList display type; used to generate simple surrogates for the item involved
+ -->
+
+ <xsl:template match="mets:METS[mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']]" mode="summaryList">
+ <xsl:choose>
+ <xsl:when test="@LABEL='DSpace Item'">
+ <xsl:call-template name="itemSummaryList-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Collection'">
+ <xsl:call-template name="collectionSummaryList-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Community'">
+ <xsl:call-template name="communitySummaryList-DIM"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/i18n/message[@key='xmlui.dri2xhtml.METS-1.0.non-conformant']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+ <!--
+ The detailList display type; used to generate simple surrogates for the item involved, but with
+ a slightly higher level of information provided. Not commonly used.
+ -->
+
+ <xsl:template match="mets:METS[mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']]" mode="detailList">
+ <xsl:choose>
+ <xsl:when test="@LABEL='DSpace Item'">
+ <xsl:call-template name="itemDetailList-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Collection'">
+ <xsl:call-template name="collectionDetailList-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Community'">
+ <xsl:call-template name="communityDetailList-DIM"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/i18n/message[@key='xmlui.dri2xhtml.METS-1.0.non-conformant']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+ <!--
+ The summaryView display type; used to generate a near-complete view of the item involved. It is currently
+ not applicable to communities and collections.
+ -->
+ <xsl:template match="mets:METS[mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']]" mode="summaryView">
+ <xsl:choose>
+ <xsl:when test="@LABEL='DSpace Item'">
+ <xsl:call-template name="itemSummaryView-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Collection'">
+ <xsl:call-template name="collectionSummaryView-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Community'">
+ <xsl:call-template name="communitySummaryView-DIM"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/i18n/message[@key='xmlui.dri2xhtml.METS-1.0.non-conformant']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+ <!--
+ The detailView display type; used to generate a complete view of the object involved. It is currently
+ used with the "full item record" view of items as well as the default views of communities and collections.
+ -->
+ <xsl:template match="mets:METS[mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']]" mode="detailView">
+ <xsl:choose>
+ <xsl:when test="@LABEL='DSpace Item'">
+ <xsl:call-template name="itemDetailView-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Collection'">
+ <xsl:call-template name="collectionDetailView-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Community'">
+ <xsl:call-template name="communityDetailView-DIM"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/i18n/message[@key='xmlui.dri2xhtml.METS-1.0.non-conformant']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+
+ <!-- Generate the logo, if present, from the file section -->
+ <xsl:template match="mets:fileGrp[@USE='LOGO']">
+ <div class="ds-logo-wrapper">
+ <img src="concat(URLPrefix, mets:file/mets:FLocat[@LOCTYPE='URL']/@xlink:href)" class="logo">
+ <xsl:attribute name="alt">xmlui.dri2xhtml.METS-1.0.collection-logo-alt</xsl:attribute>
+ <xsl:attribute name="attr" namespace="http://apache.org/cocoon/i18n/2.1">alt</xsl:attribute>
+ </img>
+ </div>
+ </xsl:template>
+
+</xsl:stylesheet>
View
310 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/common.xsl~
@@ -0,0 +1,310 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Parts of the artifactbrowser which are not
+ specific to a single listing or page. These will not
+ frequently be adapted in a theme
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ exclude-result-prefixes="xalan dri mets dim xlink xsl atom ore oreatom">
+
+ <xsl:output indent="yes"/>
+
+<!-- These templates are devoted to handling the referenceSet and reference elements. Although they are considered
+ structural elements, neither of the two contains actual content. Instead, references contain references
+ to object metadata under objectMeta, while referenceSets group references together.
+-->
+
+
+ <!-- Starting off easy here, with a summaryList -->
+
+ <!-- Current issues:
+
+ 1. There is no check for the repository identifier. Need to fix that by concatenating it with the
+ object identifier and using the resulting string as the key on items and reps.
+ 2. The use of a key index across the object store is cryptic and counterintuitive and most likely
+ could benefit from better documentation.
+ -->
+
+ <!-- When you come to an referenceSet you have to make a decision. Since it contains objects, and each
+ object is its own entity (and handled in its own template) the decision of the overall structure
+ would logically (and traditionally) lie with this template. However, to accomplish this we would
+ have to look ahead and check what objects are included in the set, which involves resolving the
+ references ahead of time and getting the information from their METS profiles directly.
+
+ Since this approach creates strong coupling between the set and the objects it contains, and we
+ have tried to avoid that, we use the "pioneer" method. -->
+
+ <!-- Summarylist case. This template used to apply templates to the "pioneer" object (the first object
+ in the set) and let it figure out what to do. This is no longer the case, as everything has been
+ moved to the list model. A special theme, called TableTheme, has beeen created for the purpose of
+ preserving the pioneer model. -->
+ <xsl:template match="dri:referenceSet[@type = 'summaryList']" priority="2">
+ <xsl:apply-templates select="dri:head"/>
+ <!-- Here we decide whether we have a hierarchical list or a flat one -->
+ <xsl:choose>
+ <xsl:when test="descendant-or-self::dri:referenceSet/@rend='hierarchy' or ancestor::dri:referenceSet/@rend='hierarchy'">
+ <ul>
+ <xsl:apply-templates select="*[not(name()='head')]" mode="summaryList"/>
+ </ul>
+ </xsl:when>
+ <xsl:otherwise>
+ <ul class="ds-artifact-list">
+ <xsl:apply-templates select="*[not(name()='head')]" mode="summaryList"/>
+ </ul>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+ <!-- First, the detail list case -->
+ <xsl:template match="dri:referenceSet[@type = 'detailList']" priority="2">
+ <xsl:apply-templates select="dri:head"/>
+ <ul class="ds-referenceSet-list">
+ <xsl:apply-templates select="*[not(name()='head')]" mode="detailList"/>
+ </ul>
+ </xsl:template>
+
+
+ <!-- Next up is the summary view case that at this point applies only to items, since communities and
+ collections do not have two separate views. -->
+ <xsl:template match="dri:referenceSet[@type = 'summaryView']" priority="2">
+ <xsl:apply-templates select="dri:head"/>
+ <xsl:apply-templates select="*[not(name()='head')]" mode="summaryView"/>
+ </xsl:template>
+
+ <!-- Finally, we have the detailed view case that is applicable to items, communities and collections.
+ In DRI it constitutes a standard view of collections/communities and a complete metadata listing
+ view of items. -->
+ <xsl:template match="dri:referenceSet[@type = 'detailView']" priority="2">
+ <xsl:apply-templates select="dri:head"/>
+ <xsl:apply-templates select="*[not(name()='head')]" mode="detailView"/>
+ </xsl:template>
+
+
+
+
+
+ <!-- The following options can be appended to the external metadata URL to request specific
+ sections of the METS document:
+
+ sections:
+
+ A comma seperated list of METS sections to included. The possible values are: "metsHdr", "dmdSec",
+ "amdSec", "fileSec", "structMap", "structLink", "behaviorSec", and "extraSec". If no list is provided then *ALL*
+ sections are rendered.
+
+
+ dmdTypes:
+
+ A comma seperated list of metadata formats to provide as descriptive metadata. The list of avaialable metadata
+ types is defined in the dspace.cfg, disseminationcrosswalks. If no formats are provided them DIM - DSpace
+ Intermediate Format - is used.
+
+
+ amdTypes:
+
+ A comma seperated list of metadata formats to provide administative metadata. DSpace does not currently
+ support this type of metadata.
+
+
+ fileGrpTypes:
+
+ A comma seperated list of file groups to render. For DSpace a bundle is translated into a METS fileGrp, so
+ possible values are "THUMBNAIL","CONTENT", "METADATA", etc... If no list is provided then all groups are
+ rendered.
+
+
+ structTypes:
+
+ A comma seperated list of structure types to render. For DSpace there is only one structType: LOGICAL. If this
+ is provided then the logical structType will be rendered, otherwise none will. The default operation is to
+ render all structure types.
+ -->
+
+ <!-- Then we resolve the reference tag to an external mets object -->
+ <xsl:template match="dri:reference" mode="summaryList">
+ <!--<xsl:variable name="externalMetadataURL">
+ <xsl:text>cocoon:/</xsl:text>
+ <xsl:value-of select="@url"/>-->
+ <!-- Since this is a summary only grab the descriptive metadata, and the thumbnails -->
+ <!--<xsl:text>?sections=dmdSec,fileSec&amp;fileGrpTypes=THUMBNAIL</xsl:text>-->
+ <!-- An example of requesting a specific metadata standard (MODS and QDC crosswalks only work for items)->
+ <xsl:if test="@type='DSpace Item'">
+ <xsl:text>&amp;dmdTypes=DC</xsl:text>
+ </xsl:if>-->
+ <!--</xsl:variable>
+ <xsl:comment> External Metadata URL: <xsl:value-of select="$externalMetadataURL"/> </xsl:comment>-->
+ <li>
+ <xsl:attribute name="class">
+ <xsl:text>ds-artifact-item </xsl:text>
+ <xsl:choose>
+ <xsl:when test="position() mod 2 = 0">even</xsl:when>
+ <xsl:otherwise>odd</xsl:otherwise>
+ </xsl:choose>
+ </xsl:attribute>
+ <!--<xsl:apply-templates select="document($externalMetadataURL)" mode="summaryList"/>-->
+ <xsl:apply-templates select="mets:METS" mode="summaryList"/>
+ <xsl:apply-templates />
+ </li>
+ </xsl:template>
+
+ <xsl:template match="dri:reference" mode="detailList">
+ <!--<xsl:variable name="externalMetadataURL">
+ <xsl:text>cocoon:/</xsl:text>
+ <xsl:value-of select="@url"/>
+
+ </xsl:variable>
+ <xsl:comment> External Metadata URL: <xsl:value-of select="$externalMetadataURL"/> </xsl:comment>-->
+ <li>
+ <!--<xsl:apply-templates select="document($externalMetadataURL)" mode="detailList"/>-->
+ <xsl:apply-templates select="mets:METS" mode="detailList"/>
+ <xsl:apply-templates />
+ </li>
+ </xsl:template>
+
+ <xsl:template match="dri:reference" mode="summaryView">
+ <!--<xsl:variable name="externalMetadataURL">
+ <xsl:text>cocoon:/</xsl:text>
+ <xsl:value-of select="@url"/>
+
+ </xsl:variable>
+ <xsl:comment> External Metadata URL: <xsl:value-of select="$externalMetadataURL"/> </xsl:comment>-->
+ <!--<xsl:apply-templates select="document($externalMetadataURL)" mode="summaryView"/>-->
+ <xsl:apply-templates select="mets:METS" mode="summaryView"/>
+ <xsl:apply-templates />
+ </xsl:template>
+
+ <xsl:template match="dri:reference" mode="detailView">
+ <!--<xsl:variable name="externalMetadataURL">
+ <xsl:text>cocoon:/</xsl:text>
+ <xsl:value-of select="@url"/>
+
+ </xsl:variable>
+ <xsl:comment> External Metadata URL: <xsl:value-of select="$externalMetadataURL"/> </xsl:comment>-->
+
+ <!--<xsl:apply-templates select="document($externalMetadataURL)" mode="detailView"/>-->
+ <xsl:apply-templates select="mets:METS" mode="detailView"/>
+ <xsl:apply-templates />
+ </xsl:template>
+
+ <!--
+ The summaryList display type; used to generate simple surrogates for the item involved
+ -->
+
+ <xsl:template match="mets:METS[mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']]" mode="summaryList">
+ <xsl:choose>
+ <xsl:when test="@LABEL='DSpace Item'">
+ <xsl:call-template name="itemSummaryList-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Collection'">
+ <xsl:call-template name="collectionSummaryList-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Community'">
+ <xsl:call-template name="communitySummaryList-DIM"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/i18n/message[@key='xmlui.dri2xhtml.METS-1.0.non-conformant']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+ <!--
+ The detailList display type; used to generate simple surrogates for the item involved, but with
+ a slightly higher level of information provided. Not commonly used.
+ -->
+
+ <xsl:template match="mets:METS[mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']]" mode="detailList">
+ <xsl:choose>
+ <xsl:when test="@LABEL='DSpace Item'">
+ <xsl:call-template name="itemDetailList-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Collection'">
+ <xsl:call-template name="collectionDetailList-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Community'">
+ <xsl:call-template name="communityDetailList-DIM"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/i18n/message[@key='xmlui.dri2xhtml.METS-1.0.non-conformant']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+ <!--
+ The summaryView display type; used to generate a near-complete view of the item involved. It is currently
+ not applicable to communities and collections.
+ -->
+ <xsl:template match="mets:METS[mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']]" mode="summaryView">
+ <xsl:choose>
+ <xsl:when test="@LABEL='DSpace Item'">
+ <xsl:call-template name="itemSummaryView-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Collection'">
+ <xsl:call-template name="collectionSummaryView-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Community'">
+ <xsl:call-template name="communitySummaryView-DIM"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/i18n/message[@key='xmlui.dri2xhtml.METS-1.0.non-conformant']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+ <!--
+ The detailView display type; used to generate a complete view of the object involved. It is currently
+ used with the "full item record" view of items as well as the default views of communities and collections.
+ -->
+ <xsl:template match="mets:METS[mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']]" mode="detailView">
+ <xsl:choose>
+ <xsl:when test="@LABEL='DSpace Item'">
+ <xsl:call-template name="itemDetailView-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Collection'">
+ <xsl:call-template name="collectionDetailView-DIM"/>
+ </xsl:when>
+ <xsl:when test="@LABEL='DSpace Community'">
+ <xsl:call-template name="communityDetailView-DIM"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/i18n/message[@key='xmlui.dri2xhtml.METS-1.0.non-conformant']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+
+ <!-- Generate the logo, if present, from the file section -->
+ <xsl:template match="mets:fileGrp[@USE='LOGO']">
+ <div class="ds-logo-wrapper">
+ <img src="{mets:file/mets:FLocat[@LOCTYPE='URL']/@xlink:href}" class="logo">
+ <xsl:attribute name="alt">xmlui.dri2xhtml.METS-1.0.collection-logo-alt</xsl:attribute>
+ <xsl:attribute name="attr" namespace="http://apache.org/cocoon/i18n/2.1">alt</xsl:attribute>
+ </img>
+ </div>
+ </xsl:template>
+
+</xsl:stylesheet>
View
108 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/community-list.xsl
@@ -0,0 +1,108 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Rendering of a list of communities (e.g. on a community homepage,
+ or on the community-list page)
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ xmlns:encoder="xalan://java.net.URLEncoder"
+ xmlns:util="org.dspace.app.xmlui.utils.XSLUtils"
+ xmlns:confman="org.dspace.core.ConfigurationManager"
+ exclude-result-prefixes="xalan encoder dri mets dim xlink xsl atom ore oreatom util confman">
+
+ <xsl:output indent="yes"/>
+
+ <xsl:template match="mets:METS"/>
+ <!-- A community rendered in the summaryList pattern. Encountered on the community-list and on
+ on the front page. -->
+ <xsl:template name="communitySummaryList-DIM">
+ <xsl:variable name="data" select="./mets:dmdSec/mets:mdWrap/mets:xmlData/dim:dim"/>
+ <div class="artifact-description">
+ <div class="artifact-title">
+ <a href="{@OBJID}">
+ <span class="Z3988">
+ <xsl:choose>
+ <xsl:when test="string-length($data/dim:field[@element='title'][1]) &gt; 0">
+ <xsl:value-of select="$data/dim:field[@element='title'][1]"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/dri:i18n/message[@key='xmlui.dri2xhtml.METS-1.0.no-title']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </span>
+ </a>
+ <!--Display community strengths (item counts) if they exist-->
+ <xsl:if test="string-length($data/dim:field[@element='format'][@qualifier='extent'][1]) &gt; 0">
+ <xsl:text> [</xsl:text>
+ <xsl:value-of select="$data/dim:field[@element='format'][@qualifier='extent'][1]"/>
+ <xsl:text>]</xsl:text>
+ </xsl:if>
+ </div>
+ <xsl:variable name="abstract" select="$data/dim:field[@element = 'description' and @qualifier='abstract']/node()"/>
+ <xsl:if test="$abstract and string-length($abstract[1]) &gt; 0">
+ <div class="artifact-info">
+ <span class="short-description">
+ <xsl:value-of select="$abstract"/>
+ </span>
+ </div>
+ </xsl:if>
+ </div>
+ </xsl:template>
+
+ <!-- A community rendered in the detailList pattern. Not currently used. -->
+ <xsl:template name="communityDetailList-DIM">
+ <xsl:variable name="data" select="./mets:dmdSec/mets:mdWrap/mets:xmlData/dim:dim"/>
+ <span class="bold">
+ <a href="{@OBJID}">
+ <xsl:choose>
+ <xsl:when test="string-length($data/dim:field[@element='title'][1]) &gt; 0">
+ <xsl:value-of select="$data/dim:field[@element='title'][1]"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/dri:i18n/message[@key='xmlui.dri2xhtml.METS-1.0.no-title']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </a>
+ <!--Display community strengths (item counts) if they exist-->
+ <xsl:if test="string-length($data/dim:field[@element='format'][@qualifier='extent'][1]) &gt; 0">
+ <xsl:text> [</xsl:text>
+ <xsl:value-of select="$data/dim:field[@element='format'][@qualifier='extent'][1]"/>
+ <xsl:text>]</xsl:text>
+ </xsl:if>
+ <br/>
+ <xsl:choose>
+ <xsl:when test="$data/dim:field[@element='description' and @qualifier='abstract']">
+ <xsl:copy-of select="$data/dim:field[@element='description' and @qualifier='abstract']/node()"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:copy-of select="$data/dim:field[@element='description'][1]/node()"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </span>
+ </xsl:template>
+
+</xsl:stylesheet>
View
108 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/community-list.xsl~
@@ -0,0 +1,108 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Rendering of a list of communities (e.g. on a community homepage,
+ or on the community-list page)
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ xmlns:encoder="xalan://java.net.URLEncoder"
+ xmlns:util="org.dspace.app.xmlui.utils.XSLUtils"
+ xmlns:confman="org.dspace.core.ConfigurationManager"
+ exclude-result-prefixes="xalan encoder dri mets dim xlink xsl atom ore oratom util confman">
+
+ <xsl:output indent="yes"/>
+
+ <xsl:template match="mets:METS"/>
+ <!-- A community rendered in the summaryList pattern. Encountered on the community-list and on
+ on the front page. -->
+ <xsl:template name="communitySummaryList-DIM">
+ <xsl:variable name="data" select="./mets:dmdSec/mets:mdWrap/mets:xmlData/dim:dim"/>
+ <div class="artifact-description">
+ <div class="artifact-title">
+ <a href="{@OBJID}">
+ <span class="Z3988">
+ <xsl:choose>
+ <xsl:when test="string-length($data/dim:field[@element='title'][1]) &gt; 0">
+ <xsl:value-of select="$data/dim:field[@element='title'][1]"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/dri:i18n/message[@key='xmlui.dri2xhtml.METS-1.0.no-title']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </span>
+ </a>
+ <!--Display community strengths (item counts) if they exist-->
+ <xsl:if test="string-length($data/dim:field[@element='format'][@qualifier='extent'][1]) &gt; 0">
+ <xsl:text> [</xsl:text>
+ <xsl:value-of select="$data/dim:field[@element='format'][@qualifier='extent'][1]"/>
+ <xsl:text>]</xsl:text>
+ </xsl:if>
+ </div>
+ <xsl:variable name="abstract" select="$data/dim:field[@element = 'description' and @qualifier='abstract']/node()"/>
+ <xsl:if test="$abstract and string-length($abstract[1]) &gt; 0">
+ <div class="artifact-info">
+ <span class="short-description">
+ <xsl:value-of select="$abstract"/>
+ </span>
+ </div>
+ </xsl:if>
+ </div>
+ </xsl:template>
+
+ <!-- A community rendered in the detailList pattern. Not currently used. -->
+ <xsl:template name="communityDetailList-DIM">
+ <xsl:variable name="data" select="./mets:dmdSec/mets:mdWrap/mets:xmlData/dim:dim"/>
+ <span class="bold">
+ <a href="{@OBJID}">
+ <xsl:choose>
+ <xsl:when test="string-length($data/dim:field[@element='title'][1]) &gt; 0">
+ <xsl:value-of select="$data/dim:field[@element='title'][1]"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/dri:i18n/message[@key='xmlui.dri2xhtml.METS-1.0.no-title']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </a>
+ <!--Display community strengths (item counts) if they exist-->
+ <xsl:if test="string-length($data/dim:field[@element='format'][@qualifier='extent'][1]) &gt; 0">
+ <xsl:text> [</xsl:text>
+ <xsl:value-of select="$data/dim:field[@element='format'][@qualifier='extent'][1]"/>
+ <xsl:text>]</xsl:text>
+ </xsl:if>
+ <br/>
+ <xsl:choose>
+ <xsl:when test="$data/dim:field[@element='description' and @qualifier='abstract']">
+ <xsl:copy-of select="$data/dim:field[@element='description' and @qualifier='abstract']/node()"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:copy-of select="$data/dim:field[@element='description'][1]/node()"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </span>
+ </xsl:template>
+
+</xsl:stylesheet>
View
81 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/community-view.xsl
@@ -0,0 +1,81 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Rendering specific to the community home page.
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:i18n="http://apache.org/cocoon/i18n/2.1"
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ xmlns:encoder="xalan://java.net.URLEncoder"
+ exclude-result-prefixes="xalan encoder i18n dri mets dim xlink xsl atom ore oreatom">
+
+ <xsl:output indent="yes"/>
+
+
+ <xsl:template name="communitySummaryView-DIM">
+ <xsl:value-of select="/dri:document/dri:i18n/dri:message[@key='xmlui.dri2xhtml.METS-1.0.community-not-implemented']"/>
+ </xsl:template>
+
+
+ <!-- A community rendered in the detailView pattern; default way of viewing a community. -->
+ <xsl:template name="communityDetailView-DIM">
+ <div class="detail-view">&#160;
+ <!-- Generate the logo, if present, from the file section -->
+ <xsl:apply-templates select="./mets:fileSec/mets:fileGrp[@USE='LOGO']"/>
+ <!-- Generate the info about the collections from the metadata section -->
+ <xsl:apply-templates select="./mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']/mets:xmlData/dim:dim"
+ mode="communityDetailView-DIM"/>
+ </div>
+ </xsl:template>
+
+ <!-- Generate the info about the community from the metadata section -->
+ <xsl:template match="dim:dim" mode="communityDetailView-DIM">
+ <xsl:if test="string-length(dim:field[@element='description'][not(@qualifier)])&gt;0">
+ <p class="intro-text">
+ <xsl:copy-of select="dim:field[@element='description'][not(@qualifier)]/node()"/>
+ </p>
+ </xsl:if>
+
+ <xsl:if test="string-length(dim:field[@element='description'][@qualifier='tableofcontents'])&gt;0">
+ <div class="detail-view-news">
+ <h3><xsl:value-of select="/dri:document/dri:i18n/dri:message[@key='xmlui.dri2xhtml.METS-1.0.news']"/></h3>
+ <p class="news-text">
+ <xsl:copy-of select="dim:field[@element='description'][@qualifier='tableofcontents']/node()"/>
+ </p>
+ </div>
+ </xsl:if>
+
+ <xsl:if test="string-length(dim:field[@element='rights'][not(@qualifier)])&gt;0">
+ <div class="detail-view-rights-and-license">
+ <p class="copyright-text">
+ <xsl:copy-of select="dim:field[@element='rights'][not(@qualifier)]/node()"/>
+ </p>
+ </div>
+ </xsl:if>
+ </xsl:template>
+
+
+</xsl:stylesheet>
View
81 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/community-view.xsl~
@@ -0,0 +1,81 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Rendering specific to the community home page.
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:i18n="http://apache.org/cocoon/i18n/2.1"
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ xmlns:encoder="xalan://java.net.URLEncoder"
+ exclude-result-prefixes="xalan encoder i18n dri mets dim xlink xsl">
+
+ <xsl:output indent="yes"/>
+
+
+ <xsl:template name="communitySummaryView-DIM">
+ <xsl:value-of select="/dri:document/dri:i18n/dri:message[@key='xmlui.dri2xhtml.METS-1.0.community-not-implemented']"/>
+ </xsl:template>
+
+
+ <!-- A community rendered in the detailView pattern; default way of viewing a community. -->
+ <xsl:template name="communityDetailView-DIM">
+ <div class="detail-view">&#160;
+ <!-- Generate the logo, if present, from the file section -->
+ <xsl:apply-templates select="./mets:fileSec/mets:fileGrp[@USE='LOGO']"/>
+ <!-- Generate the info about the collections from the metadata section -->
+ <xsl:apply-templates select="./mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']/mets:xmlData/dim:dim"
+ mode="communityDetailView-DIM"/>
+ </div>
+ </xsl:template>
+
+ <!-- Generate the info about the community from the metadata section -->
+ <xsl:template match="dim:dim" mode="communityDetailView-DIM">
+ <xsl:if test="string-length(dim:field[@element='description'][not(@qualifier)])&gt;0">
+ <p class="intro-text">
+ <xsl:copy-of select="dim:field[@element='description'][not(@qualifier)]/node()"/>
+ </p>
+ </xsl:if>
+
+ <xsl:if test="string-length(dim:field[@element='description'][@qualifier='tableofcontents'])&gt;0">
+ <div class="detail-view-news">
+ <h3><xsl:value-of select="/dri:document/dri:i18n/dri:message[@key='xmlui.dri2xhtml.METS-1.0.news']"/></h3>
+ <p class="news-text">
+ <xsl:copy-of select="dim:field[@element='description'][@qualifier='tableofcontents']/node()"/>
+ </p>
+ </div>
+ </xsl:if>
+
+ <xsl:if test="string-length(dim:field[@element='rights'][not(@qualifier)])&gt;0">
+ <div class="detail-view-rights-and-license">
+ <p class="copyright-text">
+ <xsl:copy-of select="dim:field[@element='rights'][not(@qualifier)]/node()"/>
+ </p>
+ </div>
+ </xsl:if>
+ </xsl:template>
+
+
+</xsl:stylesheet>
View
275 fileadmin/xsl/lib/xsl/aspect/artifactbrowser/item-list.xsl
@@ -0,0 +1,275 @@
+<!--
+
+ The contents of this file are subject to the license and copyright
+ detailed in the LICENSE and NOTICE files at the root of the source
+ tree and available online at
+
+ http://www.dspace.org/license/
+
+-->
+<!--
+ Rendering of a list of items (e.g. in a search or
+ browse results page)
+
+ Author: art.lowel at atmire.com
+ Author: lieven.droogmans at atmire.com
+ Author: ben at atmire.com
+ Author: Alexey Maslov
+
+-->
+
+<xsl:stylesheet
+ xmlns:i18n="http://apache.org/cocoon/i18n/2.1"
+ xmlns:dri="http://di.tamu.edu/DRI/1.0/"
+ xmlns:mets="http://www.loc.gov/METS/"
+ xmlns:dim="http://www.dspace.org/xmlns/dspace/dim"
+ xmlns:xlink="http://www.w3.org/TR/xlink/"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
+ xmlns:atom="http://www.w3.org/2005/Atom"
+ xmlns:ore="http://www.openarchives.org/ore/terms/"
+ xmlns:oreatom="http://www.openarchives.org/ore/atom/"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xalan="http://xml.apache.org/xalan"
+ xmlns:encoder="xalan://java.net.URLEncoder"
+ xmlns:util="org.dspace.app.xmlui.utils.XSLUtils"
+ xmlns:confman="org.dspace.core.ConfigurationManager"
+ exclude-result-prefixes="xalan encoder i18n dri mets dim xlink xsl atom ore oreatom util confman">
+
+ <xsl:output indent="yes"/>
+
+ <!--these templates are modfied to support the 2 different item list views that
+ can be configured with the property 'xmlui.theme.mirage.item-list.emphasis' in dspace.cfg-->
+
+ <xsl:template name="itemSummaryList-DIM">
+ <xsl:variable name="itemWithdrawn" select="./mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']/mets:xmlData/dim:dim/@withdrawn" />
+
+ <xsl:variable name="href">
+ <xsl:choose>
+ <xsl:when test="$itemWithdrawn">
+ <xsl:value-of select="@OBJEDIT"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="@OBJID"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:variable>
+
+ <xsl:variable name="emphasis">file</xsl:variable>
+ <xsl:choose>
+ <xsl:when test="'file' = $emphasis">
+
+
+ <div class="item-wrapper clearfix">
+ <xsl:apply-templates select="./mets:fileSec" mode="artifact-preview"><xsl:with-param name="href" select="$href"/></xsl:apply-templates>
+ <xsl:apply-templates select="./mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']/mets:xmlData/dim:dim"
+ mode="itemSummaryList-DIM-file"><xsl:with-param name="href" select="$href"/></xsl:apply-templates>
+ </div>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:apply-templates select="./mets:dmdSec/mets:mdWrap[@OTHERMDTYPE='DIM']/mets:xmlData/dim:dim"
+ mode="itemSummaryList-DIM-metadata"><xsl:with-param name="href" select="$href"/></xsl:apply-templates>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+ <!--handles the rendering of a single item in a list in file mode-->
+ <xsl:template match="dim:dim" mode="itemSummaryList-DIM-file">
+ <xsl:param name="href"/>
+ <xsl:variable name="metadataWidth" select="675 - $thumbnail.maxwidth - 30"/>
+ <div class="item-metadata" style="width: {$metadataWidth}px;">
+ <span class="bold"><xsl:value-of select="/dri:document/dri:i18n/dri:message[@key='xmlui.dri2xhtml.pioneer.title']"/><xsl:text>:</xsl:text></span>
+ <span class="content" style="width: {$metadataWidth - 110}px;">
+ <xsl:element name="a">
+ <xsl:attribute name="href">
+ <xsl:value-of select="$href"/>
+ </xsl:attribute>
+ <span class="Z3988">
+ <!--<xsl:attribute name="title">
+ <xsl:call-template name="renderCOinS"/>
+ </xsl:attribute>-->
+ <xsl:choose>
+ <xsl:when test="dim:field[@element='title']">
+ <xsl:value-of select="dim:field[@element='title'][1]/node()"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/dri:i18n/dri:message[@key='xmlui.dri2xhtml.METS-1.0.no-title']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </span>
+ </xsl:element>
+ </span>
+ <span class="bold"><xsl:value-of select="/dri:document/dri:i18n/dri:message[@key='xmlui.dri2xhtml.pioneer.author']"/><xsl:text>:</xsl:text></span>
+ <span class="content" style="width: {$metadataWidth - 110}px;">
+ <xsl:choose>
+ <xsl:when test="dim:field[@element='contributor'][@qualifier='author']">
+ <xsl:for-each select="dim:field[@element='contributor'][@qualifier='author']">
+ <span>
+ <xsl:if test="@authority">
+ <xsl:attribute name="class">
+ <xsl:text>ds-dc_contributor_author-authority</xsl:text>
+ </xsl:attribute>
+ </xsl:if>
+ <xsl:copy-of select="node()"/>
+ </span>
+ <xsl:if test="count(following-sibling::dim:field[@element='contributor'][@qualifier='author']) != 0">
+ <xsl:text>; </xsl:text>
+ </xsl:if>
+ </xsl:for-each>
+ </xsl:when>
+ <xsl:when test="dim:field[@element='creator']">
+ <xsl:for-each select="dim:field[@element='creator']">
+ <xsl:copy-of select="node()"/>
+ <xsl:if test="count(following-sibling::dim:field[@element='creator']) != 0">
+ <xsl:text>; </xsl:text>
+ </xsl:if>
+ </xsl:for-each>
+ </xsl:when>
+ <xsl:when test="dim:field[@element='contributor']">
+ <xsl:for-each select="dim:field[@element='contributor']">
+ <xsl:copy-of select="node()"/>
+ <xsl:if test="count(following-sibling::dim:field[@element='contributor']) != 0">
+ <xsl:text>; </xsl:text>
+ </xsl:if>
+ </xsl:for-each>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/dri:i18n/dri:message[@key='xmlui.dri2xhtml.METS-1.0.no-author']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </span>
+ <xsl:if test="dim:field[@element='date' and @qualifier='issued'] or dim:field[@element='publisher']">
+ <span class="bold"><xsl:value-of select="/dri:document/dri:i18n/dri:message[@key='xmlui.dri2xhtml.pioneer.date']"/><xsl:text>:</xsl:text></span>
+ <span class="content" style="width: {$metadataWidth - 110}px;">
+ <xsl:value-of
+ select="substring(dim:field[@element='date' and @qualifier='issued']/node(),1,10)"/>
+ </span>
+ </xsl:if>
+ <xsl:if test="dim:field[@element='relation' and @qualifier='ispartofseries']">
+ <span class="bold"><xsl:value-of select="/dri:document/dri:i18n/dri:message[@key='xmlui.dri2xhtml.METS-1.0.item-ispartofseries']"/><xsl:text>:</xsl:text></span>
+ <span class="content" style="width: {$metadataWidth - 110}px;">
+ <xsl:value-of
+ select="dim:field[@element='relation' and @qualifier='ispartofseries']"/>
+ </span>
+ </xsl:if>
+
+ </div>
+ </xsl:template>
+
+ <!--handles the rendering of a single item in a list in metadata mode-->
+ <xsl:template match="dim:dim" mode="itemSummaryList-DIM-metadata">
+ <xsl:param name="href"/>
+ <div class="artifact-description">
+ <div class="artifact-title">
+ <xsl:element name="a">
+ <xsl:attribute name="href">
+ <xsl:value-of select="$href"/>
+ </xsl:attribute>
+ <span class="Z3988">
+ <!--<xsl:attribute name="title">
+ <xsl:call-template name="renderCOinS"/>
+ </xsl:attribute>-->
+ <xsl:choose>
+ <xsl:when test="dim:field[@element='title']">
+ <xsl:value-of select="dim:field[@element='title'][1]/node()"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/dri:i18n/dri:message[@key='xmlui.dri2xhtml.METS-1.0.no-title']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </span>
+ </xsl:element>
+ </div>
+ <div class="artifact-info">
+ <span class="author">
+ <xsl:choose>
+ <xsl:when test="dim:field[@element='contributor'][@qualifier='author']">
+ <xsl:for-each select="dim:field[@element='contributor'][@qualifier='author']">
+ <span>
+ <xsl:if test="@authority">
+ <xsl:attribute name="class"><xsl:text>ds-dc_contributor_author-authority</xsl:text></xsl:attribute>
+ </xsl:if>
+ <xsl:copy-of select="node()"/>
+ </span>
+ <xsl:if test="count(following-sibling::dim:field[@element='contributor'][@qualifier='author']) != 0">
+ <xsl:text>; </xsl:text>
+ </xsl:if>
+ </xsl:for-each>
+ </xsl:when>
+ <xsl:when test="dim:field[@element='creator']">
+ <xsl:for-each select="dim:field[@element='creator']">
+ <xsl:copy-of select="node()"/>
+ <xsl:if test="count(following-sibling::dim:field[@element='creator']) != 0">
+ <xsl:text>; </xsl:text>
+ </xsl:if>
+ </xsl:for-each>
+ </xsl:when>
+ <xsl:when test="dim:field[@element='contributor']">
+ <xsl:for-each select="dim:field[@element='contributor']">
+ <xsl:copy-of select="node()"/>
+ <xsl:if test="count(following-sibling::dim:field[@element='contributor']) != 0">
+ <xsl:text>; </xsl:text>
+ </xsl:if>
+ </xsl:for-each>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="/dri:document/dri:i18n/dri:message[@key='xmlui.dri2xhtml.METS-1.0.no-author']"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </span>
+ <xsl:text> </xsl:text>
+ <xsl:if test="dim:field[@element='date' and @qualifier='issued'] or dim:field[@element='publisher']">
+ <span class="publisher-date">
+ <xsl:text>(</xsl:text>
+ <xsl:if test="dim:field[@element='publisher']">
+ <span class="publisher">
+ <xsl:copy-of select="dim:field[@element='publisher']/node()"/>
+ </span>
+ <xsl:text>, </xsl:text>
+ </xsl:if>
+ <span class="date">
+ <xsl:value-of select="substring(dim:field[@element='date' and @qualifier='issued']/node(),1,10)"/>
+ </span>
+ <xsl:text>)</xsl:text>
+ </span>
+ </xsl:if>
+ </div>
+
+ <xsl:if test="dim:field[@element = 'description' and @qualifier='abstract']">
+ <xsl:variable name="abstract" select="dim:field[@element = 'description' and @qualifier='abstract']/node()"/>
+ <div class="artifact-abstract">
+ <xsl:value-of select="util:shortenString($abstract, 220, 10)"/>
+ </div>
+ </xsl:if>
+ </div>
+ </xsl:template>
+
+ <xsl:template name="itemDetailList-DIM">
+ <xsl:call-template name="itemSummaryList-DIM"/>
+ </xsl:template>
+
+
+ <xsl:template match="mets:fileSec" mode="artifact-preview">
+ <xsl:param name="href"/>
+ <div class="thumbnail-wrapper">
+ <div class="artifact-preview">
+ <a class="rewrite-off image-link" href="{$href}">
+ <xsl:choose>
+ <xsl:when test="mets:fileGrp[@USE='THUMBNAIL']">
+ <img alt="Thumbnail">
+ <xsl:attribute name="src">
+ <xsl:value-of
+ select="concat($URLPrefix, mets:fileGrp[@USE='THUMBNAIL']/mets:file/mets:FLocat[@LOCTYPE='URL']/@xlink:href)"/>
+ </xsl:attribute>
+ </img>
+ </xsl:when>
+ <xsl:otherwise>
+ <img alt="Icon" src="{concat($URLPrefix, $theme-path, '/images/mime.png')}" style="height: {$thumbnail.maxheight}px;"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </a>
+ </div>