OSDN Git Service

Make ui-box-show more visible. Refactor some css classes
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Wed, 16 Oct 2013 17:42:42 +0000 (20:42 +0300)
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Wed, 16 Oct 2013 17:42:42 +0000 (20:42 +0300)
app/assets/stylesheets/common.scss
app/assets/stylesheets/gitlab_bootstrap/blocks.scss
app/assets/stylesheets/gitlab_bootstrap/common.scss
app/views/projects/issues/show.html.haml
app/views/projects/merge_requests/show/_mr_box.html.haml
app/views/projects/milestones/show.html.haml

index a3156ec..dc36d6f 100644 (file)
@@ -140,27 +140,6 @@ p.time {
   border-bottom: 2px solid #F90;
 }
 
-.status_info {
-  font-size: 14px;
-  padding: 5px 15px;
-  line-height: 26px;
-  text-align: center;
-  float: right;
-  position: relative;
-  top: -5px;
-  @include border-radius(4px);
-
-  &.success {
-    background: #4A4;
-    color: #FFF;
-  }
-
-  &.error {
-    background: #DA4E49;
-    color: #FFF;
-  }
-}
-
 .thin_area{
   height: 150px;
 }
index f0a77bb..1493367 100644 (file)
@@ -34,6 +34,8 @@
   &.ui-box-show {
     margin:20px 0;
     background: #FFF;
+    box-shadow: inset 0 1px 0 #fff, 0 1px 5px #f1f1f1;
+    @include linear-gradient(#fafafa, #f1f1f1);
 
     .control-group {
       margin-bottom: 0;
index bc6c786..e7780b9 100644 (file)
@@ -87,3 +87,24 @@ pre.well-pre {
   font-weight: bold;
   @include box-shadow(inset 0 2px 4px rgba(0,0,0,.15));
 }
+
+/** Big Labels **/
+.state-label {
+  font-size: 14px;
+  padding: 5px 15px;
+  text-align: center;
+  float: right;
+  position: relative;
+  top: -5px;
+  @include border-radius(4px);
+
+  &.state-label-green {
+    background: #4A4;
+    color: #FFF;
+  }
+
+  &.state-label-red {
+    background: #DA4E49;
+    color: #FFF;
+  }
+}
index 6d1a088..d08a8af 100644 (file)
@@ -32,7 +32,7 @@
   .ui-box-head
     %h4.box-title
       - if @issue.closed?
-        .error.status_info Closed
+        .state-label.state-label-red Closed
       = gfm escape_once(@issue.title)
 
   .ui-box-body
index 1f750e2..93ae602 100644 (file)
@@ -3,11 +3,12 @@
     %h4.box-title
       = gfm escape_once(@merge_request.title)
       - if @merge_request.merged?
-        .success.status_info
+        .state-label.state-label-green
           %i.icon-ok
           Merged
       - elsif @merge_request.closed?
-        .error.status_info Closed
+        .state-label.state-label-red
+          Closed
 
   .ui-box-body
     %div
@@ -32,7 +33,7 @@
       %span
         %i.icon-remove
         Closed by #{link_to_member(@project, @merge_request.closed_event.author)}
-        %small #{time_ago_in_words(@merge_request.closed_event.created_at)} ago.
+        %span #{time_ago_in_words(@merge_request.closed_event.created_at)} ago.
   - if @merge_request.merged?
     .ui-box-bottom.alert-success
       %span
index dc7fd40..2e11502 100644 (file)
@@ -26,9 +26,9 @@
   .ui-box-head
     %h4.box-title
       - if @milestone.closed?
-        .error.status_info Closed
+        .state-label.state-label-red Closed
       - elsif @milestone.expired?
-        .error.status_info Expired
+        .state-label.state-label-red Expired
 
       = gfm escape_once(@milestone.title)