(type, gd, v)
| 22 | var SLICES_TEXT_SELECTOR = '.treemaplayer text.slicetext'; |
| 23 | |
| 24 | function _mouseEvent(type, gd, v) { |
| 25 | return function () { |
| 26 | if (Array.isArray(v)) { |
| 27 | // px-based position |
| 28 | mouseEvent(type, v[0], v[1]); |
| 29 | } else { |
| 30 | // position from slice number |
| 31 | var gd3 = d3Select(gd); |
| 32 | var el = gd3.select('.slice:nth-child(' + v + ')').node(); |
| 33 | mouseEvent(type, 0, 0, { element: el }); |
| 34 | } |
| 35 | }; |
| 36 | } |
| 37 | |
| 38 | function hover(gd, v) { |
| 39 | return _mouseEvent('mouseover', gd, v); |
no test coverage detected
searching dependent graphs…