Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions demo/demo.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import * as d3 from 'd3/build/d3';
import * as d3 from 'd3';

import eventDrops from '../src';
import '../src/style.css';
Expand Down Expand Up @@ -34,7 +34,7 @@ const chart = eventDrops({
},
drop: {
date: d => new Date(d.date),
onMouseOver: commit => {
onMouseOver: (ev, commit) => {
tooltip
.transition()
.duration(200)
Expand Down Expand Up @@ -66,8 +66,8 @@ const chart = eventDrops({
</div>
`
)
.style('left', `${d3.event.pageX - 30}px`)
.style('top', `${d3.event.pageY + 20}px`);
.style('left', `${ev.pageX - 30}px`)
.style('top', `${ev.pageY + 20}px`);
},
onMouseOut: () => {
tooltip
Expand Down
Loading