Skip to content

Commit

Permalink
Fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
ehmicky committed Sep 5, 2021
1 parent 22d57fd commit dc155e1
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/report/reporters/boxplot/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,10 @@ const getPosition = function ({

// eslint-disable-next-line complexity, max-statements
const getBox = function ({ min, q1, median, q3, max }, minBlockWidth) {
const leftSpaceWidth = minBlockWidth + min.index - min.length - PADDING_WIDTH
const leftSpaceWidth = Math.max(
minBlockWidth + min.index - min.length - PADDING_WIDTH,
0,
)
const leftSpace = ' '.repeat(leftSpaceWidth)
const minPadded = addPadding(min.prettyColor)
const minCharacter = min.index === q1.index ? '' : MIN_CHARACTER
Expand Down

0 comments on commit dc155e1

Please sign in to comment.