Commit bd1618f4 authored by Shaun McCance's avatar Shaun McCance

Highlight section if we click to its #anchor, plus new linkdiv styling

parent 3a6895ca
......@@ -65,6 +65,15 @@ PKG_CHECK_MODULES(YELP,
yelp-xsl
])
DATADIR=`(
case $prefix in
NONE) prefix=$ac_default_prefix ;;
*) ;;
esac
eval echo $(eval echo $datadir)/yelp
)`
AC_SUBST([DATADIR])
AC_SUBST([YELP_CFLAGS])
AC_SUBST([YELP_LIBS])
......
......@@ -10,7 +10,10 @@ cssdir = $(datadir)/yelp
css_DATA = default.css
jsdir = $(datadir)/yelp
js_DATA = yelp.js
js_DATA = \
jquery-1.4.2.min.js \
jquery-ui-1.8.custom.min.js \
yelp.js
EXTRA_DIST = \
man.xml man.xml.in \
......
This diff is collapsed.
......@@ -55,6 +55,17 @@
</xsl:template>
<xsl:template name="mal2html.css.custom">
<xsl:text>
div.linkdiv { border: none; }
div.linkdiv:hover {
border: none;
outline: solid 1px </xsl:text>
<xsl:value-of select="$theme.color.blue_background"/><xsl:text>;
background: -webkit-gradient(linear, left top, left 80, from(</xsl:text>
<xsl:value-of select="$theme.color.blue_background"/><xsl:text>), to(</xsl:text>
<xsl:value-of select="$theme.color.background"/><xsl:text>));
}
</xsl:text>
<xsl:if test="$yelp.editor_mode">
<xsl:text>
div.head { margin: 0; }
......@@ -76,4 +87,27 @@ div.version:hover { opacity: 1.0; }
</xsl:if>
</xsl:template>
<xsl:template name="mal2html.page.head.extra">
<script type="text/javascript" language="javascript" src="@DATADIR@/jquery-1.4.2.min.js"/>
<script type="text/javascript" language="javascript" src="@DATADIR@/jquery-ui-1.8.custom.min.js"/>
<script type="text/javascript" language="javascript">
<xsl:text>
$(document).ready (function () {
if (location.hash != '') {
$('#' + location.hash).find('div.header').css({
backgroundColor: '</xsl:text><xsl:value-of select="$theme.color.yellow_background"/><xsl:text>'
}).animate({
backgroundColor: '</xsl:text><xsl:value-of select="$theme.color.gray_background"/><xsl:text>'
}, 8000);
$('#' + location.hash).css({
backgroundColor: '</xsl:text><xsl:value-of select="$theme.color.yellow_background"/><xsl:text>'
}).animate({
backgroundColor: '</xsl:text><xsl:value-of select="$theme.color.background"/><xsl:text>'
}, 4000);
}
});
</xsl:text>
</script>
</xsl:template>
</xsl:stylesheet>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment