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