]> source.dussan.org Git - sonarqube.git/commitdiff
New Issues Page: show limit warning
authorStas Vilchik <vilchiks@gmail.com>
Thu, 30 Jan 2014 14:37:06 +0000 (20:37 +0600)
committerStas Vilchik <vilchiks@gmail.com>
Thu, 30 Jan 2014 14:37:18 +0000 (20:37 +0600)
sonar-server/src/main/webapp/WEB-INF/app/views/issues/search.html.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
sonar-server/src/main/webapp/stylesheets/navigator/config.less

index 4deceaa096e951c504487147938a3726ef08c224..33dca1e189ace0dc4e5b024c9ee3154f674b11d4 100644 (file)
@@ -1,5 +1,8 @@
 <div class="navigator">
   <div class="navigator-header"></div>
+  <div class="navigator-notes">
+    <%= message('issue_filter.max_results_reached', :params => 10000) -%>
+  </div>
   <div class="navigator-filters"></div>
   <div class="navigator-results"></div>
   <div class="navigator-details"></div>
index 48404239098af14f35a1edc3dbb3a28ea335b8ed..b7fc3620e9720996a85006222db8ed7aab10aa59 100644 (file)
@@ -250,6 +250,13 @@ jQuery(function() {
     },
 
 
+    onAfterItemAdded: function() {
+      var showLimitNotes = this.collection.maxResultsReached != null && this.collection.maxResultsReached;
+      jQuery('.navigator').toggleClass('navigator-with-notes', showLimitNotes);
+      jQuery('.navigator-notes').toggle(showLimitNotes);
+    },
+
+
     close: function() {
       var scrollEl = jQuery('.navigator-results');
       scrollEl.off('scroll');
index e50deb58eab7d16c739868ed7fca7260465a18c9..09a6e768554e5bb8bcb84eba15d497a3ba91715d 100644 (file)
   width: 320px;
   height: 30px;
 }
+.navigator-notes {
+  position: fixed;
+  z-index: 2;
+  -moz-box-sizing: border-box;
+  box-sizing: border-box;
+  top: 104px;
+  left: 0;
+  width: 100%;
+  height: 20px;
+  display: none;
+}
 .navigator-simple .navigator-filters {
   top: 30px;
 }
   left: 0;
   width: 100%;
 }
+.navigator-with-notes .navigator-results,
+.navigator-with-notes .navigator-details {
+  top: 124px;
+}
+.navigator-with-notes .navigator-notes {
+  display: block;
+}
 .navigator-fetching:before {
   content: " ";
   position: absolute;
 .navigator-header-actions > button + button {
   margin-left: -1px;
 }
+.navigator-notes {
+  padding: 0 10px;
+  border-bottom: 1px solid #cdcdcd;
+  background-color: #efefef;
+  color: #777;
+  font-size: 11px;
+  line-height: 20px;
+  white-space: nowrap;
+  overflow: hidden;
+  text-overflow: ellipsis;
+}
 .navigator-results {
   border-right: 1px solid #e1e1e1;
   background-color: #ffffff;
index 48c5f71bd734cdf90c13e2ad4d9f0a233b5c888b..f3e6c83887da5ed08833977ae90b5493adb7f165 100644 (file)
   width: 320px;
   height: 30px;
 }
+.navigator-notes {
+  position: fixed;
+  z-index: 2;
+  -moz-box-sizing: border-box;
+  box-sizing: border-box;
+  top: 104px;
+  left: 0;
+  width: 100%;
+  height: 20px;
+  display: none;
+}
 .navigator-simple .navigator-filters {
   top: 30px;
 }
   left: 0;
   width: 100%;
 }
+.navigator-with-notes .navigator-results,
+.navigator-with-notes .navigator-details {
+  top: 124px;
+}
+.navigator-with-notes .navigator-notes {
+  display: block;
+}
 .navigator-fetching:before {
   content: " ";
   position: absolute;
 .navigator-header-actions > button + button {
   margin-left: -1px;
 }
+.navigator-notes {
+  padding: 0 10px;
+  border-bottom: 1px solid #cdcdcd;
+  background-color: #efefef;
+  color: #777;
+  font-size: 11px;
+  line-height: 20px;
+  white-space: nowrap;
+  overflow: hidden;
+  text-overflow: ellipsis;
+}
 .navigator-results {
   border-right: 1px solid #e1e1e1;
   background-color: #ffffff;
index 435d20aca372a3d6ad944ddf15655b2bd6420a1d..36207aa7b2e6de1099c00be2d539c345386747ac 100644 (file)
   .size(@navigatorResultsWidth, @navigatorStatusHeight);
 }
 
+.navigator-notes {
+  .navigator-element;
+  top: @navigatorTopOffset + @navigatorHeaderHeight + @navigatorFiltersHeight;
+  left: 0;
+  .size(100%, @navigatorNotesHeight);
+  display: none;
+}
+
 
 .navigator-simple {
   .navigator-filters {
 }
 
 
+.navigator-with-notes {
+
+  .navigator-results,
+  .navigator-details {
+    top: @navigatorTopOffset + @navigatorHeaderHeight + @navigatorFiltersHeight + @navigatorNotesHeight;
+  }
+
+  .navigator-notes {
+    display: block;
+  }
+
+}
+
+
 .navigator-fetching {
   &:before {
     content: " ";
 
 
 
+// Notes
+.navigator-notes {
+  padding: 0 @navigatorPadding;
+  border-bottom: 1px solid @navigatorBorderColor;
+  background-color: @navigatorBarBackground;
+
+  color: #777;
+  font-size: @smallFontSize;
+  line-height: @navigatorNotesHeight;
+
+  white-space: nowrap;
+  overflow: hidden;
+  text-overflow: ellipsis;
+}
+
+
+
 // Results
 .navigator-results {
   border-right: 1px solid @navigatorBorderLightColor;
index 98d883de88eb1d825de31a4cd8398e9228bd778a..14c3fbe75c063e72b22115461a4b7242b8525ca3 100644 (file)
@@ -6,6 +6,7 @@
 @navigatorHeaderHeight: 37px;
 @navigatorFiltersHeight: 37px;
 @navigatorStatusHeight: 30px;
+@navigatorNotesHeight: 20px;
 
 @navigatorResultsWidth: 320px;