@WidgetProperty(key = "chartTitle", type = WidgetPropertyType.STRING),
@WidgetProperty(key = "colorMetric", type = WidgetPropertyType.METRIC, defaultValue = CoreMetrics.COVERAGE_KEY, options = "type:PERCENT"),
@WidgetProperty(key = "sizeMetric", type = WidgetPropertyType.METRIC, defaultValue = CoreMetrics.COMPLEXITY_KEY, options = {WidgetConstants.FILTER_OUT_NEW_METRICS}),
- @WidgetProperty(key = "maxItems", type = WidgetPropertyType.INTEGER, defaultValue = "100"),
- @WidgetProperty(key = "reverseColor", type = WidgetPropertyType.BOOLEAN, defaultValue = "false")
-
+ @WidgetProperty(key = "maxItems", type = WidgetPropertyType.INTEGER, defaultValue = "100")
})
public class ProjectFileCloudWidget extends CoreWidget {
public ProjectFileCloudWidget() {
widget.project_file_cloud.property.sizeMetric.name=Size Metric
widget.project_file_cloud.property.maxItems.name=Max components
widget.project_file_cloud.property.maxItems.desc=Maximum number of components to show
-widget.project_file_cloud.property.reverseColor.name=Reverse Order on Color
widget.time_machine.name=History Table
widget.time_machine.description=Displays up to 10 metrics in a table, showing their value for a specified number of past snapshots.
sizeMetric = widget_properties['sizeMetric']
chartTitle = widget_properties['chartTitle']
maxItems = widget_properties['maxItems'].to_i
- reverseColor = widget_properties['reverseColor']
%>
<div class="word-cloud-widget" id="<%= containerId %>">
.metricsPriority(['<%= colorMetric.name -%>', '<%= sizeMetric.name -%>'])
.components(data.components)
.options({
- baseUrl: baseUrl + '/dashboard/index/',
- reverseColor: <%= reverseColor -%>
+ baseUrl: baseUrl + '/dashboard/index/'
})
.render('#<%= containerId -%>');