Anastasia Poupeney 7 years ago
committed by Gaëtan Renaudeau
parent
commit
282934f73f
  1. 4
      src/components/base/Chart/handleMouseEvents.js
  2. 1
      src/styles/reset.js

4
src/components/base/Chart/handleMouseEvents.js

@ -65,7 +65,7 @@ export default function handleMouseEvents({
NODES.tooltip
.style('transition', '100ms cubic-bezier(.61,1,.53,1) opacity')
.style('opacity', 1)
.style('transform', `translate3d(${MARGINS.left + x(d.parsedDate)}px, 0, 0)`)
.style('left', `${Math.floor(MARGINS.left + x(d.parsedDate))}px`)
NODES.focus.style('opacity', 1)
NODES.xBar.style('opacity', 1)
}
@ -102,7 +102,7 @@ export default function handleMouseEvents({
</Provider>,
),
)
.style('transform', `translate3d(${MARGINS.left + x(d.parsedDate)}px, 0, 0)`)
.style('left', `${Math.floor(MARGINS.left + x(d.parsedDate))}px`)
NODES.xBar
.attr('x1', x(d.parsedDate))
.attr('x2', x(d.parsedDate))

1
src/styles/reset.js

@ -1,5 +1,6 @@
module.exports = `* {
-webkit-font-smoothing: antialiased;
backface-visibility: hidden;
box-sizing: border-box;
margin: 0;
padding: 0;

Loading…
Cancel
Save