Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/assets/stylesheets/commits.css.scss19
-rw-r--r--app/models/note.rb4
-rw-r--r--app/views/commits/_text_file.html.haml4
-rw-r--r--app/views/notes/_per_line_form.html.haml18
4 files changed, 34 insertions, 11 deletions
diff --git a/app/assets/stylesheets/commits.css.scss b/app/assets/stylesheets/commits.css.scss
index 90e3b9019d9..b78088f7b25 100644
--- a/app/assets/stylesheets/commits.css.scss
+++ b/app/assets/stylesheets/commits.css.scss
@@ -78,7 +78,7 @@ body.project-page.commits-page .commits-date a.commit span.commit-author strong{
padding:0px;
border:none;
background:#F7F7F7;
- color:#333;
+ color:#aaa;
padding: 0px 5px;
border-right: 1px solid #ccc;
text-align:right;
@@ -89,7 +89,7 @@ body.project-page.commits-page .commits-date a.commit span.commit-author strong{
float:left;
width:35px;
font-weight:normal;
- color:#888;
+ color:#aaa;
&:hover {
text-decoration:underline;
}
@@ -146,3 +146,18 @@ ul.bordered-list li:last-child { border:none }
}
}
}
+
+.per_line_form {
+ background: #79C3E0;
+
+ form {
+ width: 743px;
+ border: 1px solid #CCC;
+ padding: 20px;
+ background: white;
+ }
+
+ .hide-button {
+ color:#c33;
+ }
+}
diff --git a/app/models/note.rb b/app/models/note.rb
index 48cc2d80f8a..689b620d23f 100644
--- a/app/models/note.rb
+++ b/app/models/note.rb
@@ -52,6 +52,10 @@ class Note < ActiveRecord::Base
else
noteable
end
+ # Temp fix to prevent app crash
+ # if note commit id doesnt exist
+ rescue
+ nil
end
def line_file_id
diff --git a/app/views/commits/_text_file.html.haml b/app/views/commits/_text_file.html.haml
index c61d82d31cf..1456257ce3d 100644
--- a/app/views/commits/_text_file.html.haml
+++ b/app/views/commits/_text_file.html.haml
@@ -10,6 +10,10 @@
- if line.match(/^@@ -/)
- line_old = line.match(/\-[0-9]*/)[0].to_i.abs rescue 0
- line_new = line.match(/\+[0-9]*/)[0].to_i.abs rescue 0
+ %tr.line_holder
+ %td.old_line= "..."
+ %td.new_line= "..."
+ %td.line_content &nbsp;
- next
- full_line = html_escape(line.gsub(/\n/, ''))
diff --git a/app/views/notes/_per_line_form.html.haml b/app/views/notes/_per_line_form.html.haml
index 1381811336e..02bbecd0637 100644
--- a/app/views/notes/_per_line_form.html.haml
+++ b/app/views/notes/_per_line_form.html.haml
@@ -18,17 +18,17 @@
%br
%br
= f.text_area :note, :size => 255
-
- %p.notify_controls
- %span Notify:
- = check_box_tag :notify, 1, @note.noteable_type != "Commit"
- = label_tag :notify, "Project team"
-
- -if @note.noteable_type == "Commit"
- = check_box_tag :notify_author, 1 , @note.noteable_type == "Commit"
- = label_tag :notify_author, "Commit author"
.clear
%br
= f.submit 'Add note', :class => "grey-button", :id => "submit_note"
+ .right
+ = link_to "remove", "#", :class => "hide-button"
+:javascript
+ $(function(){
+ $(".per_line_form .hide-button").bind("click", function(){
+ $('.per_line_form').hide();
+ return false;
+ });
+ });