krispo / angular-nvd3

AngularJS directive for NVD3 reusable charting library (based on D3). Easily customize your charts via JSON API.
http://krispo.github.io/angular-nvd3
MIT License
1.29k stars 377 forks source link

Interactive guideline is far away #358

Open oravecz opened 8 years ago

oravecz commented 8 years ago

feb 20 2016 08 11

chart: {
    type: 'lineChart',
    color: ['#4caf50', '#3f51b5', '#ff5722'],
    height: 320,
    x: function ( d, i ) {
        return d.x;
    },
    y: function ( d ) {
        return d.y;
    }
}

I've stripped my chart down considerably (it doesn't always look this raw), but I can't get the tooltip window to appear closer to my guideline. I have tried various gravity settings with no effect, and most of the positional overrides don't seem to be picked up by nvd3. Any thoughts on how I can correct this?

Demesheo commented 8 years ago

I get this same issue when using multiple charts of the same type in the same window, except the interactive guidelines will only show up over the first charts SVG...

oravecz commented 8 years ago

For me, it's the only chart in my DOM.

Demesheo commented 8 years ago

Which version are you using? I just solved my similar problem by updating to angular-nvd3 version 1.8.2 and d3 version 3.5.16 as well as wrapping each nvd3 html tag inside of a div with position set to be absolute