]> source.dussan.org Git - sonarqube.git/commitdiff
New Issues Page: improve rendering of sidebar items
authorStas Vilchik <vilchiks@gmail.com>
Mon, 3 Feb 2014 06:14:08 +0000 (12:14 +0600)
committerStas Vilchik <vilchiks@gmail.com>
Mon, 3 Feb 2014 06:14:08 +0000 (12:14 +0600)
sonar-server/src/main/webapp/WEB-INF/app/views/issues/templates/_issue.hbs.erb
sonar-server/src/main/webapp/WEB-INF/app/views/issues/templates/_issues_actions.hbs.erb
sonar-server/src/main/webapp/javascripts/navigator/issues.js
sonar-server/src/main/webapp/stylesheets/navigator.css
sonar-server/src/main/webapp/stylesheets/navigator/base.css
sonar-server/src/main/webapp/stylesheets/navigator/base.less

index 9cd21c89fd759b52e0b255ff1ab5a6f7229c9bbb..0cc63fe2f6699caa79217d6eb39020cb38005155 100644 (file)
@@ -19,6 +19,6 @@
       {{#unless singleProject}}
         <div class="subtitle">{{projectLongName}}</div>
       {{/unless}}
-      <div class="subtitle">{{componentLongName}}</div>
+      <div class="subtitle component">{{componentLongName}}</div>
     </div>
 </script>
index 442c668b20efc3aed0292ad2f2fef7ee6c098989..784e4c0ea1c010e1fefc4979bc34857698f97937 100644 (file)
@@ -2,7 +2,7 @@
   {{#unless maxResultsReached}}
     <div class="navigator-actions-order">
       {{#if sorting}}
-        Ordered by {{sorting.sortText}} {{#if sorting.asc}}<i class="icon-arrow-up"></i>{{else}}<i class="icon-arrow-down"></i>{{/if}}
+        Ordered by <strong>{{sorting.sortText}}</strong> {{#if sorting.asc}}<i class="icon-arrow-up"></i>{{else}}<i class="icon-arrow-down"></i>{{/if}}
       {{else}}
         Order
       {{/if}}
@@ -17,7 +17,7 @@
     </ul>
   {{/unless}}
   <div class="navigator-actions-total">
-    Found: {{paging.total}}
+    Found: <strong>{{paging.total}}</strong>
     {{#if appState.canBulkChange}}
       <a href="<%= url_for params.merge({:action => 'bulk_change_form'}) -%>?{{query}}"
          class="navigator-actions-bulk open-modal"
index 7d53ff98209480c8130e03a244a594ffea514750..54358aca1ae74b05b2835b88649d5a95fc31119d 100644 (file)
@@ -150,6 +150,11 @@ jQuery(function() {
     tagName: 'li',
 
 
+    ui: {
+      component: '.component'
+    },
+
+
     events: {
       'click': 'showDetails'
     },
index 9006b453d65507879ad0e60c9cd87d27974f5287..d57c487e2dc8bef560fcae4b0846f9846b2ebc99 100644 (file)
@@ -35,8 +35,8 @@
   z-index: 2;
   -moz-box-sizing: border-box;
   box-sizing: border-box;
-  top: 104px;
-  bottom: 30px;
+  top: 134px;
+  bottom: 0;
   left: 0;
   width: 320px;
 }
@@ -55,7 +55,7 @@
   z-index: 2;
   -moz-box-sizing: border-box;
   box-sizing: border-box;
-  bottom: 0;
+  top: 104px;
   left: 0;
   width: 320px;
   height: 30px;
   overflow-y: auto;
 }
 .navigator-results-list > li {
-  padding-top: 10px;
+  padding: 5px 0;
   cursor: pointer;
+  transition: all 0.3s ease;
 }
 .navigator-results-list > li:first-child {
-  padding-top: 0;
+  border-top: 1px solid transparent;
 }
-.navigator-results-list > li:first-child:hover .line:first-child {
-  border-top-color: transparent;
+.navigator-results-list > li:first-child.active {
+  border-top-color: #4B9FD5;
 }
 .navigator-results-list > li .line {
   padding: 5px 10px;
   line-height: 1;
-  transition: all 0.3s ease;
-}
-.navigator-results-list > li .line:first-child {
-  border-top: 1px solid transparent;
-  background-color: #efefef;
-}
-.navigator-results-list > li .line:last-child {
-  border-bottom: 1px solid transparent;
 }
 .navigator-results-list > li .line-small {
   font-size: 11px;
   text-overflow: ellipsis;
   white-space: nowrap;
 }
-.navigator-results-list > li:hover .line,
-.navigator-results-list > li.active .line {
+.navigator-results-list > li:hover {
   background-color: #efefef;
 }
-.navigator-results-list > li:hover .line:first-child,
-.navigator-results-list > li.active .line:first-child {
-  border-top-color: #e1e1e1;
+.navigator-results-list > li.active {
+  background-color: #CAE3F2;
+  border-color: #4B9FD5;
+}
+.navigator-results-list > li + li {
+  border-top: 1px solid #e1e1e1;
 }
-.navigator-results-list > li:hover .line:last-child,
-.navigator-results-list > li.active .line:last-child {
-  border-bottom-color: #e1e1e1;
+.navigator-results-list > li.active + li {
+  border-top-color: #4B9FD5;
 }
 .navigator-results-no-issues {
   padding-top: 20%;
 }
 .navigator-actions {
   padding: 0 10px 0 0;
-  line-height: 30px;
   border-right: 1px solid #e1e1e1;
-  border-top: 1px solid #e1e1e1;
+  border-bottom: 1px solid #e1e1e1;
   background-color: #ffffff;
+  font-size: 11px;
+}
+.navigator-actions strong {
+  font-weight: bold;
 }
 .navigator-actions-order {
   float: left;
   padding: 0 10px;
+  line-height: 30px;
   cursor: pointer;
   transition: all 0.3s ease;
 }
   z-index: 2;
   -moz-box-sizing: border-box;
   box-sizing: border-box;
-  bottom: 30px;
+  top: 134px;
   left: 0;
   min-width: 160px;
   background-color: #fff;
-  border-top: 1px solid #e1e1e1;
+  border-bottom: 1px solid #e1e1e1;
   border-right: 1px solid #e1e1e1;
   overflow: scroll;
   display: none;
 }
 .navigator-actions-total {
   float: right;
+  line-height: 26px;
 }
 .navigator-actions-bulk {
   position: relative;
index f3e6c83887da5ed08833977ae90b5493adb7f165..abd78b59ff623595ba0e4395e9f7d6fcd34b405c 100644 (file)
@@ -35,8 +35,8 @@
   z-index: 2;
   -moz-box-sizing: border-box;
   box-sizing: border-box;
-  top: 104px;
-  bottom: 30px;
+  top: 134px;
+  bottom: 0;
   left: 0;
   width: 320px;
 }
@@ -55,7 +55,7 @@
   z-index: 2;
   -moz-box-sizing: border-box;
   box-sizing: border-box;
-  bottom: 0;
+  top: 104px;
   left: 0;
   width: 320px;
   height: 30px;
   overflow-y: auto;
 }
 .navigator-results-list > li {
-  padding-top: 10px;
+  padding: 5px 0;
   cursor: pointer;
+  transition: all 0.3s ease;
 }
 .navigator-results-list > li:first-child {
-  padding-top: 0;
+  border-top: 1px solid transparent;
 }
-.navigator-results-list > li:first-child:hover .line:first-child {
-  border-top-color: transparent;
+.navigator-results-list > li:first-child.active {
+  border-top-color: #4B9FD5;
 }
 .navigator-results-list > li .line {
   padding: 5px 10px;
   line-height: 1;
-  transition: all 0.3s ease;
-}
-.navigator-results-list > li .line:first-child {
-  border-top: 1px solid transparent;
-  background-color: #efefef;
-}
-.navigator-results-list > li .line:last-child {
-  border-bottom: 1px solid transparent;
 }
 .navigator-results-list > li .line-small {
   font-size: 11px;
   text-overflow: ellipsis;
   white-space: nowrap;
 }
-.navigator-results-list > li:hover .line,
-.navigator-results-list > li.active .line {
+.navigator-results-list > li:hover {
   background-color: #efefef;
 }
-.navigator-results-list > li:hover .line:first-child,
-.navigator-results-list > li.active .line:first-child {
-  border-top-color: #e1e1e1;
+.navigator-results-list > li.active {
+  background-color: #CAE3F2;
+  border-color: #4B9FD5;
+}
+.navigator-results-list > li + li {
+  border-top: 1px solid #e1e1e1;
 }
-.navigator-results-list > li:hover .line:last-child,
-.navigator-results-list > li.active .line:last-child {
-  border-bottom-color: #e1e1e1;
+.navigator-results-list > li.active + li {
+  border-top-color: #4B9FD5;
 }
 .navigator-results-no-issues {
   padding-top: 20%;
 }
 .navigator-actions {
   padding: 0 10px 0 0;
-  line-height: 30px;
   border-right: 1px solid #e1e1e1;
-  border-top: 1px solid #e1e1e1;
+  border-bottom: 1px solid #e1e1e1;
   background-color: #ffffff;
+  font-size: 11px;
+}
+.navigator-actions strong {
+  font-weight: bold;
 }
 .navigator-actions-order {
   float: left;
   padding: 0 10px;
+  line-height: 30px;
   cursor: pointer;
   transition: all 0.3s ease;
 }
   z-index: 2;
   -moz-box-sizing: border-box;
   box-sizing: border-box;
-  bottom: 30px;
+  top: 134px;
   left: 0;
   min-width: 160px;
   background-color: #fff;
-  border-top: 1px solid #e1e1e1;
+  border-bottom: 1px solid #e1e1e1;
   border-right: 1px solid #e1e1e1;
   overflow: scroll;
   display: none;
 }
 .navigator-actions-total {
   float: right;
+  line-height: 26px;
 }
 .navigator-actions-bulk {
   position: relative;
index 36207aa7b2e6de1099c00be2d539c345386747ac..3089076a1acd2979562ee4396c8794884eeb7248 100644 (file)
@@ -29,8 +29,8 @@
 
 .navigator-results {
   .navigator-element;
-  top: @navigatorTopOffset + @navigatorHeaderHeight + @navigatorFiltersHeight;
-  bottom: @navigatorStatusHeight;
+  top: @navigatorTopOffset + @navigatorHeaderHeight + @navigatorFiltersHeight + @navigatorStatusHeight;
+  bottom: 0;
   left: 0;
   width: @navigatorResultsWidth;
 }
@@ -45,7 +45,7 @@
 
 .navigator-actions {
   .navigator-element;
-  bottom: 0;
+  top: @navigatorTopOffset + @navigatorHeaderHeight + @navigatorFiltersHeight;
   left: 0;
   .size(@navigatorResultsWidth, @navigatorStatusHeight);
 }
 .navigator-results-list {
 
   & > li {
-    padding-top: @navigatorPadding;
+    padding: @navigatorPadding / 2 0;
     cursor: pointer;
+    .trans;
 
     &:first-child {
-      padding-top: 0;
+      border-top: 1px solid transparent;
 
-      &:hover .line:first-child {
-        border-top-color: transparent;
+      &.active {
+        border-top-color: #4B9FD5;
       }
     }
 
     .line {
       padding: @navigatorPadding / 2 @navigatorPadding;
       line-height: 1;
-      .trans;
-
-      &:first-child {
-        border-top: 1px solid transparent;
-        background-color: @navigatorBarBackground;
-      }
-
-      &:last-child {
-        border-bottom: 1px solid transparent;
-      }
     }
 
     .line-small {
       white-space: nowrap;
     }
 
-    &:hover,
-    &.active {
-      .line {
-        background-color: @navigatorBarBackground;
-
-        &:first-child {
-          border-top-color: @navigatorBorderLightColor;
-        }
+    &:hover {
+      background-color: @navigatorBarBackground;
+    }
 
-        &:last-child {
-          border-bottom-color: @navigatorBorderLightColor;
-        }
-      }
+    &.active {
+      background-color: #CAE3F2;
+      border-color: #4B9FD5;
     }
+  }
 
+  & > li + li {
+    border-top: 1px solid @navigatorBorderLightColor;
+  }
+
+  & > li.active + li {
+    border-top-color: #4B9FD5;
   }
 }
 
 // Status
 .navigator-actions {
   padding: 0 @navigatorPadding 0 0;
-  line-height: @navigatorStatusHeight;
+
   border-right: 1px solid @navigatorBorderLightColor;
-  border-top: 1px solid @navigatorBorderLightColor;
+  border-bottom: 1px solid @navigatorBorderLightColor;
   background-color: @white;
+  font-size: @smallFontSize;
+
+  strong { font-weight: bold; }
 }
 
 .navigator-actions-order {
   float: left;
   padding: 0 @navigatorPadding;
+  line-height: @navigatorStatusHeight;
   cursor: pointer;
   .trans;
 
 
 .navigator-actions-order-choices {
   .navigator-element;
-  bottom: @navigatorStatusHeight;
+  top: @navigatorTopOffset + @navigatorHeaderHeight + @navigatorFiltersHeight + @navigatorStatusHeight;
   left: 0;
   min-width: @navigatorResultsWidth / 2;
   background-color: #fff;
-  border-top: 1px solid @navigatorBorderLightColor;
+  border-bottom: 1px solid @navigatorBorderLightColor;
   border-right: 1px solid @navigatorBorderLightColor;
   overflow: scroll;
   display: none;
 
 .navigator-actions-total {
   float: right;
+  line-height: @navigatorStatusHeight - 4px;
 }
 
 .navigator-actions-bulk {