summaryrefslogtreecommitdiffstats
path: root/public
diff options
context:
space:
mode:
authorslene <vslene@gmail.com>2014-03-17 18:13:07 +0800
committerslene <vslene@gmail.com>2014-03-17 18:13:07 +0800
commit26f9962b6e0089773615ca34ab80ca01ede79790 (patch)
tree80a02f6ccd8bdf418dae3b5fea90269d59f3a84a /public
parentdf1985e1e8ff8a5173b3a80a6bcdaee13f6a0b1a (diff)
downloadgitea-26f9962b6e0089773615ca34ab80ca01ede79790.tar.gz
gitea-26f9962b6e0089773615ca34ab80ca01ede79790.zip
clone in ssh
Diffstat (limited to 'public')
-rwxr-xr-xpublic/css/gogs.css12
-rw-r--r--public/js/app.js20
2 files changed, 22 insertions, 10 deletions
diff --git a/public/css/gogs.css b/public/css/gogs.css
index 668df4f7c7..5352f8e397 100755
--- a/public/css/gogs.css
+++ b/public/css/gogs.css
@@ -415,16 +415,8 @@ html, body {
margin-left: 0;
}
-.gogs-repo-btns {
- margin-top: 18px;
-}
-
-.gogs-repo-btns .btn-group {
- margin-left: 1em;
-}
-
-.gogs-repo-btns .btn-group .btn {
- padding-left: 6px;
+.gogs-repo-nav .actions {
+ padding-top: 20px;
}
#gogs-repo-watching .dropdown-menu {
diff --git a/public/js/app.js b/public/js/app.js
index 58633718fc..30296bc337 100644
--- a/public/js/app.js
+++ b/public/js/app.js
@@ -40,6 +40,25 @@ var Gogits = {
//container: "body"
});
};
+ Gogits.initPopovers = function () {
+ var hideAllPopovers = function() {
+ $('[data-toggle=popover]').each(function() {
+ $(this).popover('hide');
+ });
+ };
+
+ $(document).on('click', function(e) {
+ var $e = $(e.target);
+ if($e.data('toggle') == 'popover'||$e.parents("[data-toggle=popover], .popover").length > 0){
+ return;
+ }
+ hideAllPopovers();
+ });
+
+ $("body").popover({
+ selector: "[data-toggle=popover]"
+ });
+ };
Gogits.initTabs = function () {
var $tabs = $('[data-init=tabs]');
$tabs.find("li:eq(0) a").tab("show");
@@ -76,6 +95,7 @@ var Gogits = {
function initCore() {
Gogits.initTooltips();
+ Gogits.initPopovers();
Gogits.initTabs();
Gogits.initModals();
Gogits.renderMarkdown();