From 2a2f025388b2f47cff4162adc207af2ba68d64d9 Mon Sep 17 00:00:00 2001 From: FuXiaoHei Date: Tue, 25 Mar 2014 18:44:37 +0800 Subject: change css name style --- public/js/app.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'public/js') diff --git a/public/js/app.js b/public/js/app.js index f98fd03f..0973398a 100644 --- a/public/js/app.js +++ b/public/js/app.js @@ -243,7 +243,7 @@ function initCore() { function initRegister() { $.getScript("/js/jquery.validate.min.js", function () { - Gogits.validateForm("#gogs-login-card", { + Gogits.validateForm("#login-card", { rules: { "username": { required: true, @@ -268,7 +268,7 @@ function initRegister() { } function initUserSetting() { - $('#gogs-ssh-keys .delete').confirmation({ + $('#ssh-keys .delete').confirmation({ singleton: true, onConfirm: function (e, $this) { Gogits.ajaxDelete("", {"id": $this.data("del")}, function (json) { @@ -303,7 +303,7 @@ function initRepository() { // watching script (function () { - var $watch = $('#gogs-repo-watching'), + var $watch = $('#repo-watching'), watchLink = $watch.data("watch"), unwatchLink = $watch.data("unwatch"); $watch.on('click', '.to-watch',function () { @@ -354,14 +354,14 @@ function initRepository() { (function ($) { $(function () { initCore(); - var body = $("#gogs-body"); + var body = $("#body"); if (body.data("page") == "user-signup") { initRegister(); } if (body.data("page") == "user") { initUserSetting(); } - if ($('.gogs-repo-nav').length) { + if ($('.repo-nav').length) { initRepository(); } }); -- cgit v1.2.3 From e5d8fe41c4fd8331352c77d8a17d5c035f0787a2 Mon Sep 17 00:00:00 2001 From: FuXiaoHei Date: Tue, 25 Mar 2014 21:14:05 +0800 Subject: issue create page ui --- public/css/gogs.css | 30 ++++++++++++++++++++++++++++-- public/js/app.js | 1 + templates/issue/create.tmpl | 36 ++++++++++++++++++++++++++++++++++-- templates/repo/toolbar.tmpl | 5 +++++ 4 files changed, 68 insertions(+), 4 deletions(-) (limited to 'public/js') diff --git a/public/css/gogs.css b/public/css/gogs.css index 74dce472..eeead844 100755 --- a/public/css/gogs.css +++ b/public/css/gogs.css @@ -512,6 +512,14 @@ html, body { height: 39px; } +#repo-toolbar .nav .tmp a:hover { + text-decoration: none; +} + +#repo-toolbar .nav .tmp .btn { + margin-top: -2px; +} + #repo-toolbar .nav .active { color: #F6F6F6; } @@ -602,7 +610,7 @@ html, body { } /* #source */ -#source { +#source, #commits { margin-top: -20px; } @@ -857,7 +865,7 @@ html, body { } .guide-box, .diff-head-box { - margin-top: 20px; + margin-top: 4px; } .diff-head-box h4 { @@ -991,6 +999,24 @@ html, body { color: #AAA; } +/* issue */ + +#issue-create-form .panel-body { + padding: 15px 0 0 0; +} + +#issue-create-form .panel-body.form-group, #issue-create-form .tab-pane .form-group { + margin-bottom: 0; +} + +#issue-create-form .nav-tabs { + margin-bottom: 10px; +} + +#issue-create-form .md-help{ + margin-top: 6px; +} + /* wrapper and footer */ #wrapper { diff --git a/public/js/app.js b/public/js/app.js index 0973398a..8b0e5cd6 100644 --- a/public/js/app.js +++ b/public/js/app.js @@ -111,6 +111,7 @@ var Gogits = { }; Gogits.initTabs = function () { var $tabs = $('[data-init=tabs]'); + $tabs.tab("show"); $tabs.find("li:eq(0) a").tab("show"); }; // fix dropdown inside click diff --git a/templates/issue/create.tmpl b/templates/issue/create.tmpl index 2fb29d1b..34c7f40a 100644 --- a/templates/issue/create.tmpl +++ b/templates/issue/create.tmpl @@ -3,8 +3,40 @@ {{template "repo/nav" .}} {{template "repo/toolbar" .}}
-
- new-issues +
+
+
+ +
+
+
+ +
+
+
+ Content with Markdown +
+ +
+
+
+ +
+
+
preview
+
+
+
+
+ + +
+
+
+
{{template "base/footer" .}} \ No newline at end of file diff --git a/templates/repo/toolbar.tmpl b/templates/repo/toolbar.tmpl index 1f8a7098..17d4e5b1 100644 --- a/templates/repo/toolbar.tmpl +++ b/templates/repo/toolbar.tmpl @@ -9,6 +9,11 @@
  • Issues
  • + {{if .IsRepoToolbarIssues}} +
  • + +
  • + {{end}}