Skip to content

Commit

Permalink
fixes folder hover
Browse files Browse the repository at this point in the history
resolves #5
  • Loading branch information
meodai committed Oct 22, 2014
1 parent c499ddc commit 6322a7b
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 10 deletions.
9 changes: 8 additions & 1 deletion .theme/footer.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<script>
<!--
(function($,w,d){
var parseList, parseTitle, fixTable, setTheme;
var parseList, parseTitle, fixTable, setTheme, setFolderHover;

//fixes for older apache versions
fixTable = function( $table ){
Expand Down Expand Up @@ -100,6 +100,13 @@
/* sets a body class of the default theme */
setTheme( $(".wrap").data("theme") );

/*sets the hover icons for folders */
setFolderHover = function( src ){
$(".type--DIR .indexcolicon a").append("<img class='hover' src='" + src + "' alt='folder hover' />")
};

setFolderHover( $(".type--PARENTDIR img:eq(0)").attr("src") );

}(jQuery,window,document));
-->
</script>
12 changes: 3 additions & 9 deletions .theme/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -168,22 +168,16 @@ a[href$="/"]:hover,a[href$="/"]:hover,a.link--breadcrumb:hover {
.type--DIR .indexcolicon a {
position: relative;
}
.type--DIR .indexcolicon a img.hover,
.type--DIR:hover .indexcolicon a img {
opacity: 0;
display: none;
}
.type--DIR:hover .indexcolicon a:after {
position: absolute;
.type--DIR:hover .indexcolicon a img.hover {
display: block;
top: 0; left: 0;
content: "";
width: 1.4em; height: 1.4em;
background: url('/~meodai/.meta/icons/[email protected]');
background-size: 100%;
}

/* footer */
.footer {
padding: 1em 0 0;
font-size: 0.7em;
}

0 comments on commit 6322a7b

Please sign in to comment.