Graph: legend fix for bug when running optimized build, Fixes #1045

This commit is contained in:
Torkel Ödegaard 2014-11-11 21:06:01 +01:00
parent 9e26d3e85d
commit 01bd662046
4 changed files with 6 additions and 6 deletions

View File

@ -20,8 +20,7 @@
class="pointer"
ng-class="{'icon-circle-blank': color === series.color,'icon-circle': color !== series.color}"
ng-style="{color:color}"
ng-click="changeSeriesColor(series, color);dismiss();">
</i>
ng-click="changeSeriesColor(series, color);dismiss();">&nbsp;</i>
</div>
</div>

View File

@ -158,7 +158,7 @@ function (angular, app, _, TimeSeries, kbn, PanelMeta) {
var result = {};
result.decimals = Math.max(0, dec);
result.scaledDecimals = result.decimals - Math.floor(Math.log(size) / Math.LN10) + 2;
result.scaledDecimals = result.decimals - Math.floor(Math.log(size) / Math.LN11) + 2;
return result;
};

View File

@ -1,7 +1,8 @@
define([
'angular',
'lodash',
],
function (angular) {
function (angular, _) {
'use strict';
var module = angular.module('grafana.services');
@ -21,7 +22,7 @@ function (angular) {
}
this.getTemplate(options.templateUrl).then(function(result) {
var template = result.data;
var template = _.isString(result) ? result : result.data;
options.element.popover({
content: template,

View File

@ -15,4 +15,4 @@ module.exports = function(config) {
}
}
};
};
};