From 991212c4d835634626c25db822f5cfeb386fa141 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Wed, 1 Feb 2017 13:41:36 -0500 Subject: Don't hard-code the Y-axis unit label styles. --- jarmon/jarmon.js | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'jarmon/jarmon.js') diff --git a/jarmon/jarmon.js b/jarmon/jarmon.js index c7af4ed..d62564d 100644 --- a/jarmon/jarmon.js +++ b/jarmon/jarmon.js @@ -671,14 +671,9 @@ jarmon.Chart.prototype.draw = function() { self.template.find('.chart').empty().show(), data, self.options); - // @todo Make this styleable var yaxisUnitLabel = $('
') .text(self.siPrefix + unit) - .css({'width': '100px', - 'position': 'absolute', - 'top': '80px', - 'left': '-110px', - 'text-align': 'right'}); + .addClass('yaxisUnitLabel'); self.template.find('.chart').append(yaxisUnitLabel); // Manipulate and move the Flot generated legend to an @@ -705,7 +700,7 @@ jarmon.Chart.prototype.draw = function() { 'title': ('Data series switch - ' + 'click to turn this data series on or off') }) - .width(orig.width()+20) + .width(orig.width()+20) // @todo Make this styleable .text(label) .prepend( orig.prev() -- cgit v1.2.3-54-g00ecf