Skip to content

Commit accb2f2

Browse files
committed
Pack using the change indices instead of the measured heights of the change outputs.
1 parent 8966ca6 commit accb2f2

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lib/styles.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -450,8 +450,8 @@ module.exports = function (expect) {
450450
var lastChangeIndex = Math.max(moveSourceAndMoveTarget.source.changeIndex, moveSourceAndMoveTarget.target.changeIndex);
451451

452452
arrowSpecs.push({
453-
start: topByChangeNumber[firstChangeIndex],
454-
end: topByChangeNumber[lastChangeIndex] + 1,
453+
start: firstChangeIndex,
454+
end: lastChangeIndex,
455455
direction: moveSourceAndMoveTarget.source.changeIndex < moveSourceAndMoveTarget.target.changeIndex ? 'down' : 'up'
456456
});
457457
});
@@ -461,9 +461,9 @@ module.exports = function (expect) {
461461
columnSet.forEach(function (entry) {
462462
arrows.push(that.clone().arrow({
463463
left: i * 2,
464-
top: entry.start,
464+
top: topByChangeNumber[entry.start],
465465
width: 1 + (packing.length - i) * 2,
466-
height: entry.end - entry.start,
466+
height: topByChangeNumber[entry.end] - topByChangeNumber[entry.start] + 1,
467467
direction: entry.direction
468468
}));
469469
});

0 commit comments

Comments
 (0)