diff --git a/lib/http/templates/index.html b/lib/http/templates/index.html index cec58f1d7..3a4417dd4 100644 --- a/lib/http/templates/index.html +++ b/lib/http/templates/index.html @@ -1,4 +1,4 @@ - @@ -188,17 +188,17 @@ footer { } } td .zip { - opacity: 0; - margin-left: 6px; - transition: opacity 0.15s ease-in-out; + opacity: 0; + margin-left: 6px; + transition: opacity 0.15s ease-in-out; } tr.file:hover td .zip { - opacity: 1; + opacity: 1; } .zip-root { - margin-left: 8px; - vertical-align: middle; - opacity: 1; + margin-left: 8px; + vertical-align: middle; + opacity: 1; } @@ -219,9 +219,9 @@ tr.file:hover td .zip { - - - + + + @@ -249,15 +249,13 @@ tr.file:hover td .zip {

{{range $i, $crumb := .Breadcrumb}}{{html $crumb.Text}}{{if ne $i 0}}/{{end}}{{end}} - - {{- if not .DisableZip}} - - - - - - {{- end}} - + {{- if not .DisableZip}} + + + + + + {{- end}}

@@ -273,7 +271,6 @@ tr.file:hover td .zip { - Name @@ -308,13 +305,13 @@ tr.file:hover td .zip { {{- end}} {{html .Leaf}} - {{- if and .IsDir (not $.DisableZip)}} - - - - - - {{- end}} + {{- if and .IsDir (not $.DisableZip)}} + + + + + + {{- end}} {{- if .IsDir}} — @@ -368,31 +365,25 @@ tr.file:hover td .zip { } var timeList = Array.prototype.slice.call(document.getElementsByTagName("time")); timeList.forEach(localizeDatetime); - var getUrlParameter = function getUrlParameter(sParam) { - var sPageURL = window.location.search.substring(1), - sURLVariables = sPageURL.split('&'), - sParameterName, - i; - - for (i = 0; i < sURLVariables.length; i++) { - sParameterName = sURLVariables[i].split('='); - + var sPageURL = window.location.search.substring(1), sURLVariables = sPageURL.split('&') + for (var i = 0; i < sURLVariables.length; i++) { + var sParameterName = sURLVariables[i].split('='); if (sParameterName[0] === sParam) { return sParameterName[1] === undefined ? true : decodeURIComponent(sParameterName[1]); } } }; - function toggle(className){ + function toggle(className) { var order = getUrlParameter('order'); var elements = document.getElementsByClassName(className); for(var i = 0, length = elements.length; i < length; i++) { var currHref = elements[i].href; - if(order=='desc'){ + if(order=='desc') { var chg = currHref.replace('desc', 'asc'); elements[i].href = chg; } - if(order=='asc'){ + if(order=='asc') { var chg = currHref.replace('asc', 'desc'); elements[i].href = chg; } @@ -407,10 +398,8 @@ tr.file:hover td .zip { } return parseFloat(size).toFixed(2) + ' ' + units[i]; } - function changeSize() { var sizes = document.getElementsByTagName("size"); - for (var i = 0; i < sizes.length; i++) { humanSize = readableFileSize(sizes[i].innerHTML); sizes[i].innerHTML = humanSize