]> source.dussan.org Git - sonarqube.git/commitdiff
apply web service api feedback
authorStas Vilchik <vilchiks@gmail.com>
Fri, 20 Feb 2015 14:29:29 +0000 (15:29 +0100)
committerStas Vilchik <vilchiks@gmail.com>
Fri, 20 Feb 2015 14:29:29 +0000 (15:29 +0100)
server/sonar-web/src/main/hbs/api-documentation/api-documentation-action.hbs
server/sonar-web/src/main/hbs/api-documentation/api-documentation-layout.hbs
server/sonar-web/src/main/hbs/api-documentation/api-documentation-web-service.hbs
server/sonar-web/src/main/hbs/nav/nav-shortcuts-help.hbs
server/sonar-web/src/main/less/components.less
server/sonar-web/src/main/less/components/badges.less [new file with mode: 0644]

index d728667dc60979878abdd8cb0af9eecd98673db2..8194aa3b0db605a073fd23c79b8892d2a3d55572 100644 (file)
@@ -4,7 +4,7 @@
 </h3>
 <span class="subtitle">
   {{#if since}}Since {{since}}{{#if internal}} -{{/if}}{{/if}}
-  {{#if internal}}<span class="internal">For internal use only</span>{{/if}}
+  {{#if internal}}<span class="badge">For internal use only</span>{{/if}}
 </span>
 <p>{{{description}}}</p>
 {{#if params}}
index 1d9d56e7be60095f5567bc2f97c72dd4f9ae345f..2527222fad24261bdb4b51bf028f22e2b1d5589f 100644 (file)
@@ -1,6 +1,10 @@
 <div class="search-navigator-side search-navigator-side-light">
   <div class="search-navigator-filters">
     <h1 class="page-title">Web Service API</h1>
+    <div class="page-actions">
+      <input id="api-documentation-show-internals" type="checkbox">
+      <label for="api-documentation-show-internals">Show Internals</label>
+    </div>
   </div>
   <div class="api-documentation-results panel"></div>
 </div>
index d5c585b4f4f04ccf7f4003e94f0dc283fecadf04..2e47c41cc6818e5da4b661f28cb1b592e88f37b0 100644 (file)
@@ -1,5 +1,7 @@
-<h3 class="list-group-item-heading">{{path}}</h3>
+<h3 class="list-group-item-heading">
+  {{path}}
+  {{#if internal}}
+    <span class="badge">internal</span>
+  {{/if}}
+</h3>
 <p class="list-group-item-text">{{{description}}}</p>
-{{#if internal}}
-  <p class="note">internal</p>
-{{/if}}
index 27a774e6137ae4a8e0f25e6077af8863a5a66fa0..f62f5325f4d69061c45b66e2e7c0f13955dcdd4b 100644 (file)
@@ -8,7 +8,7 @@
     <a href="http://www.sonarqube.org/documentation" target="sonar_doc">Documentation</a> -
     <a href="http://www.sonarqube.org/support" target="support">Get Support</a> -
     <a href="http://sonar-plugins.codehaus.org" target="plugins">Plugins</a> -
-    <a href="<%= ApplicationController.root_context -%>/api_documentation">Web Service API</a>
+    <a href="{{link '/api_documentation'}}">Web Service API</a>
   </div>
 
   <div class="shortcuts-section">
index c64d9930a42efa56db6bf80fcc7e7eb88d6cd13f..a20381805dc97a0510e1e2370e4b16ed5dc09125 100644 (file)
@@ -21,3 +21,4 @@
 @import "components/bubble-popup";
 @import "components/list-groups";
 @import "components/panels";
+@import "components/badges";
diff --git a/server/sonar-web/src/main/less/components/badges.less b/server/sonar-web/src/main/less/components/badges.less
new file mode 100644 (file)
index 0000000..f0b6c34
--- /dev/null
@@ -0,0 +1,28 @@
+@import (reference) "../variables";
+@import (reference) "../mixins";
+
+.badge {
+  display: inline-block;
+  min-width: 10px;
+  padding: 2px 7px;
+  font-size: 11px;
+  font-weight: 300;
+  color: #fff;
+  line-height: 12px;
+  vertical-align: baseline;
+  white-space: nowrap;
+  text-align: center;
+  background-color: @blue;
+
+  &:empty { display: none; }
+
+  .list-group-item > &,
+  .list-group-item-heading > & {
+    float: right;
+  }
+
+  .list-group-item > & + &,
+  .list-group-item-heading > & + & {
+    margin-right: 5px;
+  }
+}