summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacob Schatz <jacobschatz@Jacobs-MBP.fios-router.home>2016-02-02 19:42:19 -0500
committerJacob Schatz <jacobschatz@Jacobs-MBP.fios-router.home>2016-02-02 19:42:19 -0500
commit599e554ad4df76e0ec270aa0756a98b9044e877f (patch)
tree42ab5c59833c16b2c2396a71f0e4e0f0230efc70
parentd87e317be449274983f5c515edf5285a1bb08c21 (diff)
downloadgitlab-ce-599e554ad4df76e0ec270aa0756a98b9044e877f.tar.gz
Sidebar works after sidebar ajax calls.
-rw-r--r--app/assets/javascripts/application.js.coffee2
-rw-r--r--app/assets/javascripts/issuable_context.js.coffee2
-rw-r--r--app/assets/stylesheets/pages/issuable.scss3
-rw-r--r--app/views/projects/issues/update.js.haml6
-rw-r--r--app/views/projects/merge_requests/update.js.haml4
-rw-r--r--app/views/shared/issuable/_sidebar.html.haml2
6 files changed, 10 insertions, 9 deletions
diff --git a/app/assets/javascripts/application.js.coffee b/app/assets/javascripts/application.js.coffee
index 02b0a32539a..be3b326075d 100644
--- a/app/assets/javascripts/application.js.coffee
+++ b/app/assets/javascripts/application.js.coffee
@@ -212,7 +212,7 @@ $ ->
$this = $(this)
$this.attr 'value', $this.val()
- $('.right-sidebar').on 'click', '.gutter-toggle', (e) ->
+ $(document).on 'click', 'aside .gutter-toggle', (e) ->
e.preventDefault()
$this = $(this)
$thisIcon = $this.find 'i'
diff --git a/app/assets/javascripts/issuable_context.js.coffee b/app/assets/javascripts/issuable_context.js.coffee
index c2144aea25e..d17b1123418 100644
--- a/app/assets/javascripts/issuable_context.js.coffee
+++ b/app/assets/javascripts/issuable_context.js.coffee
@@ -10,7 +10,7 @@ class @IssuableContext
$(".issuable-sidebar .inline-update").on "change", ".js-assignee", ->
$(this).submit()
- $(".edit-link").click (e) ->
+ $(document).on "click",".edit-link", (e) ->
block = $(@).parents('.block')
block.find('.selectbox').show()
block.find('.value').hide()
diff --git a/app/assets/stylesheets/pages/issuable.scss b/app/assets/stylesheets/pages/issuable.scss
index 2c8fc509f20..b10670afd40 100644
--- a/app/assets/stylesheets/pages/issuable.scss
+++ b/app/assets/stylesheets/pages/issuable.scss
@@ -97,7 +97,7 @@
.gutter-toggle {
margin-left: 10px;
- border-left: 1px solid #F0F0F0;
+ border-left: 1px solid $border-gray-light;
padding-left: 10px;
}
}
@@ -221,6 +221,7 @@
text-align: center;
margin-left: -19px;
padding-bottom: 10px;
+ color: #999999;
span {
display: block;
diff --git a/app/views/projects/issues/update.js.haml b/app/views/projects/issues/update.js.haml
index 2f0f3fcfb06..3cec66d262b 100644
--- a/app/views/projects/issues/update.js.haml
+++ b/app/views/projects/issues/update.js.haml
@@ -1,3 +1,3 @@
-$('.issuable-sidebar').html("#{escape_javascript(render 'shared/issuable/sidebar', issuable: @issue)}");
-$('.issuable-sidebar').parent().effect('highlight')
-new Issue();
+$('aside.right-sidebar').parent().html("#{escape_javascript(render 'shared/issuable/sidebar', issuable: @issue)}");
+$('aside.right-sidebar').effect('highlight')
+new Issue(); \ No newline at end of file
diff --git a/app/views/projects/merge_requests/update.js.haml b/app/views/projects/merge_requests/update.js.haml
index 93db65ddf79..ce5157d69a2 100644
--- a/app/views/projects/merge_requests/update.js.haml
+++ b/app/views/projects/merge_requests/update.js.haml
@@ -1,3 +1,3 @@
-$('.issuable-sidebar').html("#{escape_javascript(render 'shared/issuable/sidebar', issuable: @merge_request)}");
-$('.issuable-sidebar').parent().effect('highlight')
+$('aside.right-sidebar')[0].outerHTML= "#{escape_javascript(render 'shared/issuable/sidebar', issuable: @merge_request)}";
+$('aside.right-sidebar').effect('highlight')
merge_request = new MergeRequest();
diff --git a/app/views/shared/issuable/_sidebar.html.haml b/app/views/shared/issuable/_sidebar.html.haml
index 0ed2c9c710d..f4f04a42196 100644
--- a/app/views/shared/issuable/_sidebar.html.haml
+++ b/app/views/shared/issuable/_sidebar.html.haml
@@ -23,7 +23,7 @@
%a.btn.btn-default.disabled{href: '#'}
Next
- = form_for [@project.namespace.becomes(Namespace), @project, issuable], remote: true, html: {class: 'issuable-context-form inline-update js-issuable-update', 'data-type' => 'json'} do |f|
+ = form_for [@project.namespace.becomes(Namespace), @project, issuable], remote: true, html: {class: 'issuable-context-form inline-update js-issuable-update'} do |f|
.block.assignee
.sidebar-collapsed-icon
- if issuable.assignee