Loading plugins/mirador_viewer/mirador_viewer.xsl +27 −5 Original line number Diff line number Diff line Loading @@ -28,21 +28,43 @@ <span onclick="window.open('{$iiifLink}','Mirador Viewer','width=800,height=600,location=no')" class="mirador-link"><xsl:value-of select="."/></span> </xsl:template> <!-- dao avec imagette --> <!-- dao avec imagette --> <xsl:template match="ead:dao[@entityref='iiif_manifest']"> <xsl:variable name="iiifLink"> <xsl:value-of select="$baseuri"/> <xsl:value-of select="$project"/> <xsl:text>/mirador/?link=</xsl:text> <xsl:choose> <xsl:when test="contains(@xlink:href,'#')"> <xsl:value-of select="substring-before(@xlink:href,'#')"/> <xsl:choose> <xsl:when test="contains(@xlink:href,'#http')"> <xsl:text>&canvasId=</xsl:text> <xsl:value-of select="substring-after(@xlink:href,'#')"/> <xsl:text>&canvasIndex=</xsl:text> </xsl:when> <xsl:otherwise> <xsl:text>&canvasId=&canvasIndex=</xsl:text> <xsl:value-of select="substring-after(@xlink:href,'#')"/> </xsl:otherwise> </xsl:choose> </xsl:when> <xsl:otherwise> <xsl:value-of select="@xlink:href"/> <xsl:text>&canvasId=&canvasIndex=</xsl:text> </xsl:otherwise> </xsl:choose> </xsl:variable> <xsl:variable name="imgId"> <xsl:text>thumbnail</xsl:text><xsl:value-of select="count(preceding::*:dao[@entityref='iiif_manifest'])+1"/> <xsl:text>thumbnail</xsl:text> <xsl:value-of select="count(preceding::*:dao[@entityref='iiif_manifest'])+1"/> </xsl:variable> <span onclick="window.open('{$iiifLink}','Mirador Viewer','width=800,height=600,location=no')" class="mirador-link"><xsl:value-of select="."/></span> <span onclick="window.open('{$iiifLink}','Mirador Viewer','width=800,height=600,location=no')" class="mirador-link"> <xsl:value-of select="."/> </span> <figure> <img id="{$imgId}" src="{@xlink:href}" onclick="window.open('{$iiifLink}','Mirador Viewer','width=800,height=600,location=no')" class="mirador-link"> <img id="{$imgId}" src="{@xpointer}" onclick="window.open('{$iiifLink}','Mirador Viewer','width=800,height=600,location=no')" class="mirador-link"> </img> </figure> </xsl:template> Loading Loading
plugins/mirador_viewer/mirador_viewer.xsl +27 −5 Original line number Diff line number Diff line Loading @@ -28,21 +28,43 @@ <span onclick="window.open('{$iiifLink}','Mirador Viewer','width=800,height=600,location=no')" class="mirador-link"><xsl:value-of select="."/></span> </xsl:template> <!-- dao avec imagette --> <!-- dao avec imagette --> <xsl:template match="ead:dao[@entityref='iiif_manifest']"> <xsl:variable name="iiifLink"> <xsl:value-of select="$baseuri"/> <xsl:value-of select="$project"/> <xsl:text>/mirador/?link=</xsl:text> <xsl:choose> <xsl:when test="contains(@xlink:href,'#')"> <xsl:value-of select="substring-before(@xlink:href,'#')"/> <xsl:choose> <xsl:when test="contains(@xlink:href,'#http')"> <xsl:text>&canvasId=</xsl:text> <xsl:value-of select="substring-after(@xlink:href,'#')"/> <xsl:text>&canvasIndex=</xsl:text> </xsl:when> <xsl:otherwise> <xsl:text>&canvasId=&canvasIndex=</xsl:text> <xsl:value-of select="substring-after(@xlink:href,'#')"/> </xsl:otherwise> </xsl:choose> </xsl:when> <xsl:otherwise> <xsl:value-of select="@xlink:href"/> <xsl:text>&canvasId=&canvasIndex=</xsl:text> </xsl:otherwise> </xsl:choose> </xsl:variable> <xsl:variable name="imgId"> <xsl:text>thumbnail</xsl:text><xsl:value-of select="count(preceding::*:dao[@entityref='iiif_manifest'])+1"/> <xsl:text>thumbnail</xsl:text> <xsl:value-of select="count(preceding::*:dao[@entityref='iiif_manifest'])+1"/> </xsl:variable> <span onclick="window.open('{$iiifLink}','Mirador Viewer','width=800,height=600,location=no')" class="mirador-link"><xsl:value-of select="."/></span> <span onclick="window.open('{$iiifLink}','Mirador Viewer','width=800,height=600,location=no')" class="mirador-link"> <xsl:value-of select="."/> </span> <figure> <img id="{$imgId}" src="{@xlink:href}" onclick="window.open('{$iiifLink}','Mirador Viewer','width=800,height=600,location=no')" class="mirador-link"> <img id="{$imgId}" src="{@xpointer}" onclick="window.open('{$iiifLink}','Mirador Viewer','width=800,height=600,location=no')" class="mirador-link"> </img> </figure> </xsl:template> Loading