From 866ec50736636091bea08ea2eb1a7b4add13a7dc Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Tue, 13 Dec 2016 21:49:30 -0500 Subject: Add some comments. --- jarmon/jarmon.js | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/jarmon/jarmon.js b/jarmon/jarmon.js index bf28d03..586b892 100644 --- a/jarmon/jarmon.js +++ b/jarmon/jarmon.js @@ -453,6 +453,11 @@ jarmon.Chart = function(template, recipe, downloader) { self.draw(); }); + /* @todo The user should be able to override this with `ticks`, `tickSize`, + * or `minTickSize`. + * @todo Look in to implementing this as a tickFormatter, and letting Flot + * take care of scaling. + */ this.options.yaxis.ticks = function(axis) { /* * Choose a suitable SI multiplier based on the min and max values from @@ -654,6 +659,7 @@ 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', @@ -672,6 +678,10 @@ jarmon.Chart.prototype.draw = function() { // table is useful as it generates an optimum label element // width which we can copy to the new divs + a little extra // to accomodate the color box + // + // @todo This seems super hacky + // @todo Look in to implementing this using Flot + // `.legend.container`. var legend = self.template.find('.graph-legend').show(); legend.empty(); self.template.find('.legendLabel').each( @@ -1336,8 +1346,8 @@ jarmon.timeRangeShortcuts = [ * @requires jQuery * @requires Flot * - * @param ui {module:jQuery.jQuery} A one element jQuery containing an input form and - * placeholders for the timeline and for the series of charts. + * @param ui {module:jQuery.jQuery} A one element jQuery containing an input + * form and placeholders for the timeline and for the series of charts. **/ jarmon.ChartCoordinator = function(ui, charts) { var self = this; -- cgit v1.1-4-g5e80