[yelp-xsl] [mal2html-facets] Don't filter non-facet links
- From: Shaun McCance <shaunm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [yelp-xsl] [mal2html-facets] Don't filter non-facet links
- Date: Wed, 22 Dec 2010 20:01:00 +0000 (UTC)
commit 1cef5f7ed3bfd44453bca44b3219a887aa644bc4
Author: Shaun McCance <shaunm gnome org>
Date: Wed Dec 22 14:59:09 2010 -0500
[mal2html-facets] Don't filter non-facet links
xslt/mallard/html/mal2html-facets.xsl | 3 ++-
xslt/mallard/html/mal2html-page.xsl | 4 +++-
2 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/xslt/mallard/html/mal2html-facets.xsl b/xslt/mallard/html/mal2html-facets.xsl
index 5f3f94d..a0735e2 100644
--- a/xslt/mallard/html/mal2html-facets.xsl
+++ b/xslt/mallard/html/mal2html-facets.xsl
@@ -105,6 +105,7 @@ tag and VALUES is the values.
<xsl:call-template name="mal2html.page.linkdiv">
<xsl:with-param name="source" select="$node"/>
<xsl:with-param name="target" select="key('mal.cache.key', $xref)"/>
+ <xsl:with-param name="class" select="'facet'"/>
<xsl:with-param name="attrs">
<a>
<xsl:for-each select="$link/facet:tag">
@@ -132,7 +133,7 @@ $(document).ready(function () {
$('input.facet').change(function () {
var control = $(this);
var content = control.closest('div.body,div.sect');
- content.find('a').each(function () {
+ content.find('a.facet').each(function () {
var link = $(this);
var facets = link.parents('div.body,div.sect').children('div.contents').children('div.facets').children('div.facet');
var visible = true;
diff --git a/xslt/mallard/html/mal2html-page.xsl b/xslt/mallard/html/mal2html-page.xsl
index aa18bba..5417ef1 100644
--- a/xslt/mallard/html/mal2html-page.xsl
+++ b/xslt/mallard/html/mal2html-page.xsl
@@ -73,6 +73,7 @@ mal2html.page.linkdiv
Output an automatic link block from a guide to a page.
$source: The #{page} or #{section} element containing the link.
$target: The element from the cache file of the page being linked to.
+$class: An additional string to prepend to the #{class} attribute.
$attrs: A set of extra data attributes to add to the #{a} element.
REMARK: Describe this template
@@ -80,8 +81,9 @@ REMARK: Describe this template
<xsl:template name="mal2html.page.linkdiv">
<xsl:param name="source" select="."/>
<xsl:param name="target"/>
+ <xsl:param name="class" select="''"/>
<xsl:param name="attrs"/>
- <a class="linkdiv">
+ <a class="{concat($class, ' linkdiv')}">
<xsl:attribute name="href">
<xsl:call-template name="mal.link.target">
<xsl:with-param name="node" select="$source"/>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]