Sha256: 5b1e661679c79a718905cd298abd014f70bd1780529c1ba0b85c53e107dab49c
Contents?: true
Size: 1.46 KB
Versions: 2
Compression:
Stored size: 1.46 KB
Contents
- block(:commitchart) do .blockdiagram #commitchart{ :style => 'height:240px; width:640px' } - lst = Array.new - stats.date_stats.each_sorted do |a, b| - lst << "['#{a}', #{b.commits}]" :javascript $(document).ready(function(){ var line = [#{lst.join(',')}]; var plot = $.jqplot('commitchart', [line], { legend: { show: true, rowSpacing: '0', location: 'nw', }, axes: { xaxis: { pad: 0, renderer: $.jqplot.DateAxisRenderer, tickRenderer: $.jqplot.CanvasAxisTickRenderer, tickOptions: { angle: 30 } }, yaxis: { label: 'Commits', min: 0, labelRenderer: $.jqplot.CanvasAxisLabelRenderer, tickRenderer: $.jqplot.CanvasAxisTickRenderer, tickOptions: { angle: 30, formatString: '%d' } } }, series: [ { label: 'Commits', showMarker: false } ], cursor: { show: true, zoom: true, looseZoom: false, constrainZoomTo: 'x', showTooltip: true, tooltipLocation: 'sw', showTooltipUnitPosition: false, showTooltipDataPosition: true, showVerticalLine: true, tooltipFormatString: '<b>%2$s</b> %1$s: %3$s' } }); plot.target.bind('jqplotZoom', jqplot_zoom); plot.target.bind('jqplotResetZoom', jqplot_zoom_reset); });
Version data entries
2 entries across 2 versions & 2 rubygems
Version | Path |
---|---|
gitstats-rb-2.0.0 | template/gnuplot/partials/commitchart.haml |
gitstats-ruby-1.0.1 | template/partials/commitchart.haml |