mirror of
https://github.com/klaussilveira/gitlist.git
synced 2025-11-18 03:30:55 +01:00
Add tab to draw a graphical representation of the commit history
This commit is contained in:
17
themes/default/js/draw.js
Normal file
17
themes/default/js/draw.js
Normal file
@@ -0,0 +1,17 @@
|
||||
$(document).ready(function () {
|
||||
var graphList = [];
|
||||
|
||||
if (!document.getElementById('graph-canvas')) {
|
||||
return;
|
||||
}
|
||||
|
||||
$("#graph-raw-list li span.node-relation").each(function () {
|
||||
graphList.push($(this).text());
|
||||
})
|
||||
|
||||
gitGraph(document.getElementById('graph-canvas'), graphList);
|
||||
|
||||
if ($("#rev-container")) {
|
||||
$("#rev-container").css("width", $('#git-graph-container').width() - $('#graph-canvas').width());
|
||||
}
|
||||
})
|
||||
Reference in New Issue
Block a user