<script id="coding-rules-detail-template" type="text/x-handlebars-template">
- <h3 class="coding-rules-detail-header">
- {{#notEq status 'READY'}}
- <span class="coding-rules-detail-status">{{status}}</span>
- {{/notEq}}
- <span class="coding-rules-detail-key">{{key}}</span> : {{name}}
- </h3>
+ <h3 class="coding-rules-detail-header">{{name}}</h3>
<ul class="coding-rules-detail-properties">
<li class="coding-rules-detail-property">{{severityIcon severity}} {{t "severity" severity}}</li>
- <li class="coding-rules-detail-property"><i class="icon-lang"></i> {{language}}</li>
- <li class="coding-rules-detail-property"><i class="icon-calendar"></i> {{fCreationDate}}</li>
+ <li class="coding-rules-detail-property">
+ <span class="coding-rules-detail-status">{{language}}</span>
+ </li>
+ {{#notEq status 'READY'}}
+ <li class="coding-rules-detail-property">
+ <span class="coding-rules-detail-status">{{status}}</span>
+ </li>
+ {{/notEq}}
<li class="coding-rules-detail-property coding-rules-detail-tag-list">
<i class="icon-tags"></i>
{{join tags ', '}}
<input class="coding-rules-detail-tag-input" type="text" value="{{join tags ','}}">
<a class="link-action coding-rules-detail-tag-edit-done">{{t 'done'}}</a>
</li>
+ <li class="coding-rules-detail-property">{{t 'coding_rules.available_since'}} {{fCreationDate}}</li>
+ <li class="coding-rules-detail-property">{{t 'coding_rules.repository'}} {{repository}}</li>
+ <li class="coding-rules-detail-property">{{t 'coding_rules.key'}} {{key}}</li>
</ul>
<div class="coding-rules-detail-description rule-desc">{{{description}}}</div>
</div>
</div>
- <table class="data zebra coding-rules-detail-parameters">
- <thead>
- <tr>
- <th>{{t 'coding_rules.parameters.key'}}</th>
- <th>{{t 'coding_rules.parameters.default_value'}}</th>
- <th>{{t 'coding_rules.parameters.description'}}</th>
- </tr>
- </thead>
- <tbody>
+
+ {{#if parameters}}
+ <h3 class="coding-rules-detail-title">{{t 'coding_rules.parameters'}}</h3>
+ <ul class="coding-rules-detail-parameters">
{{#each parameters}}
- <tr class="coding-rules-detail-parameter">
- <td>{{key}}</td>
- <td>{{#if default}}{{default}}{{else}}—{{/if}}</td>
- <td>{{description}}</td>
- </tr>
+ <li class="coding-rules-detail-parameter">
+ <h3 class="coding-rules-detail-parameter-name">{{key}}</h3>
+ <div class="coding-rules-detail-parameter-description">
+ {{description}}
+
+ {{#if default}}
+ <div>{{t 'coding_rules.parameters.default_value'}} {{default}}</div>
+ {{/if}}
+ </div>
+ </li>
{{/each}}
- </tbody>
- </table>
+ </ul>
+ {{/if}}
{{!--
<div class="line line-small">
{{#if qualityProfile}}
<i class="icon-quality-profile"></i> {{qualityProfileName}}
+ {{severityIcon severity}}{{t "severity" severity}}
{{/if}}
- {{severityIcon severity}}{{t "severity" severity}}
- <i class="icon-lang"></i> {{language}}
+ <span class="coding-rules-detail-status">{{language}}</span>
+
+ <div class="line-right">{{#notEq status 'READY'}}{{status}}{{/notEq}}</div>
</div>
<div class="line line-nowrap" title="{{name}}">{{name}}</div>
</script>
'severity.INFO': 'Info'
'coding_rules.activate_quality_profile': 'Activate Quality Profile'
+ 'coding_rules.available_since': 'Available Since'
'coding_rules.bulk_change': 'Bulk Change'
'coding_rules.extend_description': 'Extend Description'
'coding_rules.deactivate_quality_profile': 'Deactivate'
'coding_rules.found': 'Found'
+ 'coding_rules.key': 'Key:'
'coding_rules.new_search': 'New Search'
'coding_rules.no_results': 'No Coding Rules'
'coding_rules.order': 'Order'
'coding_rules.ordered_by': 'Ordered By'
'coding_rules.page': 'Coding Rules'
+ 'coding_rules.parameters': 'Parameters'
+ 'coding_rules.parameters.default_value': 'Default Value:'
'coding_rules.quality_profiles': 'Quality Profiles'
+ 'coding_rules.repository': 'Repository:'
'coding_rules._rules': 'rule(s)'
'coding_rules.select_tag': 'Select Tag'
'coding_rules.filters.status': 'Status'
'coding_rules.filters.tag': 'Tag'
- 'coding_rules.parameters.key': 'Key'
- 'coding_rules.parameters.default_value': 'Default Value'
- 'coding_rules.parameters.description': 'Description'
-
'coding_rules.sort.creation_date': 'Creation Date'
'coding_rules.sort.name': 'Name'
name: 'Array designators "[]" should be located after the type in method signatures'
language: 'Java'
severity: 'MAJOR'
+ status: 'DEPRECATED'
},
{
name: 'Avoid Array Loops'
language: 'Java'
severity: 'CRITICAL'
+ status: 'READY'
},
{
name: 'Bad practice - Abstract class defines covariant compareTo() method'
language: 'Java'
severity: 'MAJOR'
+ status: 'READY'
},
{
name: 'Correctness - Use of class without a hashCode() method in a hashed data structure'
language: 'Java'
severity: 'MINOR'
+ status: 'BETA'
},
{
name: 'Useless Operation On Immutable'
language: 'Java'
severity: 'MAJOR'
+ status: 'READY'
}
]
paging:
'severity.MINOR': 'Minor',
'severity.INFO': 'Info',
'coding_rules.activate_quality_profile': 'Activate Quality Profile',
+ 'coding_rules.available_since': 'Available Since',
'coding_rules.bulk_change': 'Bulk Change',
'coding_rules.extend_description': 'Extend Description',
'coding_rules.deactivate_quality_profile': 'Deactivate',
'coding_rules.found': 'Found',
+ 'coding_rules.key': 'Key:',
'coding_rules.new_search': 'New Search',
'coding_rules.no_results': 'No Coding Rules',
'coding_rules.order': 'Order',
'coding_rules.ordered_by': 'Ordered By',
'coding_rules.page': 'Coding Rules',
+ 'coding_rules.parameters': 'Parameters',
+ 'coding_rules.parameters.default_value': 'Default Value:',
'coding_rules.quality_profiles': 'Quality Profiles',
+ 'coding_rules.repository': 'Repository:',
'coding_rules._rules': 'rule(s)',
'coding_rules.select_tag': 'Select Tag',
'coding_rules.filters.availableSince': 'Available Since',
'coding_rules.filters.severity': 'Severity',
'coding_rules.filters.status': 'Status',
'coding_rules.filters.tag': 'Tag',
- 'coding_rules.parameters.key': 'Key',
- 'coding_rules.parameters.default_value': 'Default Value',
- 'coding_rules.parameters.description': 'Description',
'coding_rules.sort.creation_date': 'Creation Date',
'coding_rules.sort.name': 'Name'
}
{
name: 'Array designators "[]" should be located after the type in method signatures',
language: 'Java',
- severity: 'MAJOR'
+ severity: 'MAJOR',
+ status: 'DEPRECATED'
}, {
name: 'Avoid Array Loops',
language: 'Java',
- severity: 'CRITICAL'
+ severity: 'CRITICAL',
+ status: 'READY'
}, {
name: 'Bad practice - Abstract class defines covariant compareTo() method',
language: 'Java',
- severity: 'MAJOR'
+ severity: 'MAJOR',
+ status: 'READY'
}, {
name: 'Correctness - Use of class without a hashCode() method in a hashed data structure',
language: 'Java',
- severity: 'MINOR'
+ severity: 'MINOR',
+ status: 'BETA'
}, {
name: 'Useless Operation On Immutable',
language: 'Java',
- severity: 'MAJOR'
+ severity: 'MAJOR',
+ status: 'READY'
}
],
paging: {
/*
* Detail
*/
-.coding-rules-detail-header {
- margin-bottom: 20px;
+.coding-rules-detail-header,
+.coding-rules-detail-title {
+ margin-bottom: 10px;
line-height: 1.5;
font-weight: bold;
+}
+.coding-rules-detail-title {
text-transform: uppercase;
}
.coding-rules-detail-status {
background-color: #efefef;
color: #777;
font-size: 11px;
- text-transform: uppercase;
}
.coding-rules-detail-properties {
- margin: 20px 0;
+ margin: 10px 0;
font-size: 0;
}
.coding-rules-detail-property {
display: inline-block;
vertical-align: middle;
- font-size: 13px;
+ font-size: 11px;
height: 22px;
line-height: 22px;
}
.coding-rules-detail-tag + .coding-rules-detail-tag {
margin-left: 10px;
}
-.coding-rules-detail-tag-delete {
- position: relative;
- top: -1px;
- transition: all 0.3s ease;
-}
-.coding-rules-detail-tag-delete:hover,
-.coding-rules-detail-tag-delete:focus {
- color: #d4333f;
-}
-.coding-rules-detail-tag-add {
- transition: all 0.3s ease;
-}
-.coding-rules-detail-tag-add:hover,
-.coding-rules-detail-tag-add:focus {
- color: #85bb43;
-}
-.coding-rules-detail-tag + .coding-rules-detail-tags-change {
- margin-left: 15px;
-}
-.coding-rules-detail-add-tag-box {
- position: absolute;
- width: 200px;
- padding: 10px;
- border: 1px solid #e1e1e1;
- background-color: #fff;
-}
-.coding-rules-detail-add-tag-list-item {
- padding: 3px 0;
-}
-.coding-rules-detail-add-tag-list-item input[type=text] {
- width: 120px;
-}
.coding-rules-detail-description {
margin: 20px 0;
- padding-left: 10px;
- border-left: 5px solid #4b9fd5;
-}
-.coding-rules-detail-description *:first-child {
- margin-top: 0;
- padding-top: 0;
-}
-.coding-rules-detail-description *:last-child {
- margin-bottom: 0;
- padding-bottom: 0;
}
.coding-rules-detail-description-extra {
margin-top: -10px;
- border-left-color: #cdcdcd;
}
.coding-rules-detail-parameters {
- margin: 20px 0;
+ margin: 10px 0 20px;
}
.coding-rules-detail-parameter {
margin: 10px 0;
+ font-size: 0;
+}
+.coding-rules-detail-parameter-name {
+ display: inline-block;
+ visibility: top;
+ width: 150px;
+ font-size: 13px;
+ font-weight: bold;
+ text-align: right;
+}
+.coding-rules-detail-parameter-description {
+ display: inline-block;
+ vertical-align: top;
+ margin-left: 20px;
+ font-size: 13px;
}
.coding-rules-detail-quality-profiles-header {
margin-top: 30px;
* Detail
*/
-.coding-rules-detail-header {
- margin-bottom: 2 * @navigatorPadding;
+.coding-rules-detail-header,
+.coding-rules-detail-title {
+ margin-bottom: @navigatorPadding;
line-height: 1.5;
font-weight: bold;
+}
+
+.coding-rules-detail-title {
text-transform: uppercase;
}
background-color: @navigatorBarBackground;
color: #777;
font-size: @smallFontSize;
- text-transform: uppercase;
}
.coding-rules-detail-key {
}
.coding-rules-detail-properties {
- margin: 2 * @navigatorPadding 0;
+ margin: @navigatorPadding 0;
font-size: 0;
}
.coding-rules-detail-property {
display: inline-block;
vertical-align: middle;
- font-size: @baseFontSize;
+ font-size: @smallFontSize;
height: 22px;
line-height: 22px;
margin-left: @navigatorPadding;
}
-.coding-rules-detail-tag-delete {
- position: relative;
- top: -1px;
- .trans;
-
- &:hover, &:focus { color: @red; }
-}
-
-.coding-rules-detail-tag-add {
- .trans;
-
- &:hover, &:focus { color: @green; }
-}
-
-.coding-rules-detail-tag + .coding-rules-detail-tags-change {
- margin-left: 1.5 * @navigatorPadding;
-}
-
-.coding-rules-detail-add-tag-box {
- position: absolute;
- width: 200px;
- padding: @navigatorPadding;
- border: 1px solid @navigatorBorderLightColor;
- background-color: #fff;
-}
-
-.coding-rules-detail-add-tag-list-item {
- padding: 3px 0;
-
- input[type=text] { width: 120px; }
-}
-
.coding-rules-detail-description {
margin: 2 * @navigatorPadding 0;
- padding-left: @navigatorPadding;
- border-left: 5px solid @blue;
-
- *:first-child {
- margin-top: 0;
- padding-top: 0;
- }
-
- *:last-child {
- margin-bottom: 0;
- padding-bottom: 0;
- }
}
.coding-rules-detail-description-extra {
margin-top: -@navigatorPadding;
- border-left-color: @darkGrey;
}
.coding-rules-detail-parameters {
- margin: 2 * @navigatorPadding 0;
+ margin: @navigatorPadding 0 @navigatorPadding * 2;
}
.coding-rules-detail-parameter {
margin: @navigatorPadding 0;
+ font-size: 0;
+}
+
+.coding-rules-detail-parameter-name {
+ display: inline-block;
+ visibility: top;
+ width: 150px;
+ font-size: @baseFontSize;
+ font-weight: bold;
+ text-align: right;
+}
+
+.coding-rules-detail-parameter-description {
+ display: inline-block;
+ vertical-align: top;
+ margin-left: 2 * @navigatorPadding;
+ font-size: @baseFontSize;
}