Tobias Cornille commited on
Commit
9620a3b
1 Parent(s): 2d1ab2c

Update index.js

Browse files
Files changed (1) hide show
  1. index.js +4 -4
index.js CHANGED
@@ -61,10 +61,10 @@ function renderBox({ box, label }) {
61
  boxElement.className = 'bounding-box';
62
  Object.assign(boxElement.style, {
63
  borderColor: color,
64
- left: 100 * xmin + '%',
65
- top: 100 * ymin + '%',
66
- width: 100 * (xmax - xmin) + '%',
67
- height: 100 * (ymax - ymin) + '%',
68
  })
69
 
70
  // Draw label
 
61
  boxElement.className = 'bounding-box';
62
  Object.assign(boxElement.style, {
63
  borderColor: color,
64
+ left: xmin + 'px',
65
+ top: ymin + 'px',
66
+ width: (xmax - xmin) + 'px',
67
+ height: (ymax - ymin) + 'px',
68
  })
69
 
70
  // Draw label