From 92a6058e29eb5f9cd655c3b1f8f43fd6d46fe5a4 Mon Sep 17 00:00:00 2001 From: FuXiaoHei Date: Mon, 24 Mar 2014 23:53:26 +0800 Subject: [PATCH 1/2] zip download button, repo single file buttons --- public/js/app.js | 2 +- templates/repo/nav.tmpl | 4 ++++ templates/repo/single.tmpl | 2 +- templates/repo/single_file.tmpl | 8 +++++++- 4 files changed, 13 insertions(+), 3 deletions(-) diff --git a/public/js/app.js b/public/js/app.js index 9a58a6f2f2..f98fd03f82 100644 --- a/public/js/app.js +++ b/public/js/app.js @@ -291,7 +291,7 @@ function initRepository() { $clone.find('button[data-link]').on("click",function (e) { var $this = $(this); if (!$this.hasClass('btn-primary')) { - $clone.find('.btn-primary').removeClass('btn-primary').addClass("btn-default"); + $clone.find('.input-group-btn .btn-primary').removeClass('btn-primary').addClass("btn-default"); $(this).addClass('btn-primary').removeClass('btn-default'); $url.val($this.data("link")); $clone.find('span.clone-url').text($this.data('link')); diff --git a/templates/repo/nav.tmpl b/templates/repo/nav.tmpl index 080cb72e57..2770328cb1 100644 --- a/templates/repo/nav.tmpl +++ b/templates/repo/nav.tmpl @@ -30,6 +30,10 @@

Need help cloning? Visit Help!

+
+
+ Download ZIP +
diff --git a/templates/repo/single.tmpl b/templates/repo/single.tmpl index a1c3cfbb26..56e6746c76 100644 --- a/templates/repo/single.tmpl +++ b/templates/repo/single.tmpl @@ -9,7 +9,7 @@ {{else}}
{{ $n := len .Treenames}} - {{if not .IsFile}}{{end}} + {{if not .IsFile}}{{end}} {{if .FileIsLarge}} - {{if .FileIsLarge}} -