summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDouwe Maan <douwe@gitlab.com>2015-12-02 14:50:12 +0100
committerDouwe Maan <douwe@gitlab.com>2015-12-02 14:50:12 +0100
commitd5fd9b26b13678a9e09a56890af10babe46362f0 (patch)
tree13dd87dec9ede594a504444643ec695c4c475189
parentba4bf27fe486af1790844ac40bc188c6462720b8 (diff)
downloadgitlab-ce-d5fd9b26b13678a9e09a56890af10babe46362f0.tar.gz
Remove style duplication between snippet and issue detail pages
-rw-r--r--app/assets/stylesheets/pages/snippets.scss44
-rw-r--r--app/views/shared/snippets/_header.html.haml7
2 files changed, 9 insertions, 42 deletions
diff --git a/app/assets/stylesheets/pages/snippets.scss b/app/assets/stylesheets/pages/snippets.scss
index 242783a7b7e..bb74e50151d 100644
--- a/app/assets/stylesheets/pages/snippets.scss
+++ b/app/assets/stylesheets/pages/snippets.scss
@@ -27,56 +27,22 @@
}
.snippet-holder {
- .snippet-details {
- .page-title {
- margin-top: -15px;
- padding: 10px 0;
- margin-bottom: 0;
- color: #5c5d5e;
- font-size: 16px;
-
- .author {
- color: #5c5d5e;
- }
-
- .snippet-id {
- color: #5c5d5e;
- }
- }
-
- .snippet-title {
- margin: 0;
- font-size: 23px;
- color: #313236;
- }
-
- @media (max-width: $screen-md-max) {
- .new-snippet-link {
- display: none;
- }
- }
-
- @media (max-width: $screen-sm-max) {
- .creator,
- .page-title .btn-close {
- display: none;
- }
- }
- }
+ margin-bottom: -$gl-padding;
.file-holder {
border-top: 0;
}
}
-
.snippet-box {
@include border-radius(2px);
- display: inline-block;
- padding: 10px $gl-padding;
+ display: block;
+ float: left;
+ padding: 0 $gl-padding;
font-weight: normal;
margin-right: 10px;
font-size: $gl-font-size;
border: 1px solid;
+ line-height: 40px;
}
diff --git a/app/views/shared/snippets/_header.html.haml b/app/views/shared/snippets/_header.html.haml
index 0a4a790ec5e..35241029288 100644
--- a/app/views/shared/snippets/_header.html.haml
+++ b/app/views/shared/snippets/_header.html.haml
@@ -1,9 +1,9 @@
-.snippet-details
+.issuable-details
.page-title
.snippet-box{class: visibility_level_color(@snippet.visibility_level)}
= visibility_level_icon(@snippet.visibility_level)
= visibility_level_label(@snippet.visibility_level)
- %span.snippet-id Snippet ##{@snippet.id}
+ Snippet ##{@snippet.id}
%span.creator
&middot; created by #{link_to_member(@project, @snippet.author, size: 24)}
&middot;
@@ -19,6 +19,7 @@
= render "projects/snippets/actions"
- else
= render "snippets/actions"
+
.gray-content-block.middle-block
- %h2.snippet-title
+ %h2.issue-title
= gfm escape_once(@snippet.title)