mirror of
https://github.com/pcottle/learnGitBranching.git
synced 2025-07-10 06:34:26 +02:00
ok demonstraton view coming along
This commit is contained in:
parent
c1813c346c
commit
c5615fe15a
10 changed files with 444 additions and 64 deletions
|
@ -615,9 +615,14 @@ GitVisuals.prototype.animateEdges = function(speed) {
|
|||
}, this);
|
||||
};
|
||||
|
||||
GitVisuals.prototype.getMinLayers = function() {
|
||||
return (this.options.smallCanvas) ? 4 : 7;
|
||||
};
|
||||
|
||||
GitVisuals.prototype.getDepthIncrement = function(maxDepth) {
|
||||
// assume there are at least 7 layers until later
|
||||
maxDepth = Math.max(maxDepth, 7);
|
||||
// assume there are at least a number of layers until later
|
||||
// to have better visuals
|
||||
maxDepth = Math.max(maxDepth, this.getMinLayers());
|
||||
var increment = 1.0 / maxDepth;
|
||||
return increment;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue