summaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorfuxiaohei <fuxiaohei@vip.qq.com>2014-12-22 21:26:05 +0800
committerfuxiaohei <fuxiaohei@vip.qq.com>2014-12-22 21:26:05 +0800
commitc0cfd62b9007122f78f28f4dbbe3c3eeeee5b02b (patch)
tree81e29f747e650a554a43a971420e453c6a92ca16 /templates
parentebbe6177a91e9eb6b4001342728ff099cafd5d65 (diff)
downloadgitea-c0cfd62b9007122f78f28f4dbbe3c3eeeee5b02b.tar.gz
gitea-c0cfd62b9007122f78f28f4dbbe3c3eeeee5b02b.zip
add label-edit and label-delete logic
Diffstat (limited to 'templates')
-rw-r--r--templates/repo/issue2/labels.tmpl34
1 files changed, 30 insertions, 4 deletions
diff --git a/templates/repo/issue2/labels.tmpl b/templates/repo/issue2/labels.tmpl
index c2ddd94d5b..8c656e297d 100644
--- a/templates/repo/issue2/labels.tmpl
+++ b/templates/repo/issue2/labels.tmpl
@@ -12,7 +12,7 @@
</ul>
<form id="label-add-form" action="#" class="form clear hidden">
<input type="text" class="ipt" name="name" placeholder="label name" id="label-add-name"/>
- <div class="inline down drop" id="label-color-drop">
+ <div class="inline down drop label-color-drop">
<label for="label-add-color"></label>
<input class="ipt" name="color" type="text" placeholder="color" id="label-add-color"/>
<div class="drop-down">
@@ -30,10 +30,10 @@
</div>
<ul id="label-list" class="list-no-style">
<li class="item" id="label-id">
- <a class="right" href="#"><i class="octicon octicon-x"></i>Delete</a>
- <a class="right" href="#"><i class="octicon octicon-pencil"></i>Edit</a>
+ <a class="right delete" href="#"><i class="octicon octicon-x"></i>Delete</a>
+ <a class="right edit" href="#"><i class="octicon octicon-pencil"></i>Edit</a>
<a class="right issue-num" href="#"><i class="octicon octicon-issue-opened"></i><strong class="num">12</strong>Issues</a>
- <a class="left label clear" href="#" style="background-color: red"><i class="octicon octicon-tag"></i><strong>bug</strong></a>
+ <a class="left label clear" href="#" style="background-color: #0052cc" data-color-hex="#0052cc"><i class="octicon octicon-tag"></i><strong>bug</strong></a>
</li>
<li class="item" id="label-id">
<a class="right" href="#"><i class="octicon octicon-x"></i>Delete</a>
@@ -45,4 +45,30 @@
</div>
</div>
</div>
+<div id="label-edit-form-tpl" class="hidden">
+ <li class="item"><form id="label-edit-form" action="#" class="form clear">
+ <input type="text" class="ipt" name="name" placeholder="label name" id="label-edit-name"/>
+ <input type="hidden" name="id" value="id"/>
+ <div class="inline down drop label-color-drop">
+ <label for="label-add-color"></label>
+ <input class="ipt" name="color" type="text" placeholder="color" id="label-edit-color"/>
+ <div class="drop-down">
+ <a href="#" class="color" style="background: red"></a>
+ <a href="#" class="color" style="background: green"></a>
+ </div>
+ </div>
+ <button class="btn btn-gray right" type="button" id="label-edit-cancel-btn">Cancel</button>
+ <button class="btn btn-green right" id="label-edit-btn">Save Changes</button>
+ </form></li>
+</div>
+<div id="label-delete-form-tpl" class="hidden">
+ <li class="item">
+ <form id="label-delete-form" action="#">
+ <input type="hidden" name="id" value="id"/>
+ <span><strong class="text-red">Are you sure?</strong> Deleting a label will remove it from all issues and pull requests.</span>
+ <button class="btn btn-gray right" type="button" id="label-del-cancel-btn">Cancel</button>
+ <button class="btn btn-red right" id="label-del-btn">Delete</button>
+ </form>
+ </li>
+</div>
{{template "ng/base/footer" .}} \ No newline at end of file