--- a/templates/fancy.html Sun Feb 07 22:55:52 2016 +0800
+++ b/templates/fancy.html Sun Feb 07 22:57:31 2016 +0800
<script type="application/json" id="data">{% raw json_encode(data) %}</script>
+ var data = JSON.parse(document.getElementById('data').firstChild.nodeValue);
var chart = c3.generate({
- tooltip: {format: {title: function(x) { return x; }}},
- data: JSON.parse(document.getElementById('data').firstChild.nodeValue)
+ tooltip: {format: {title: function(x) { return data.titles[-x]; }}},
axis: {x: {tick: {format: function(x) { return -x; }}}},
--- a/viewer.py Sun Feb 07 22:55:52 2016 +0800
+++ b/viewer.py Sun Feb 07 22:57:31 2016 +0800
marks, moremarks = self.getmarks()
results, _ = self.getresults(changesets, marks=marks, colors=False)
item = {'rev': -cset['rev']}
+ extra = [cset['branch']] + cset['tags']
+ if len(cset['parents']) > 1:
+ extra.append('(merge)')
+ titles[cset['rev']] = '{}:{}: {} {}'.format(
+ cset['desc'].partition('\n')[0])
- 'keys': {'x': 'rev', 'value': marks.keys()}
+ 'keys': {'x': 'rev', 'value': marks.keys()},
'changesets': changesets,