I have 2 graphs each in separate angular directive
<chart1 ng-model="data" style="display:block;" id="plot1" class="ng-pristine ng-valid">
<svg width="960" height="500" style="right: 0px;">Some data</svg>
</chart1>
<chart2 ng-model="data" style="display:block;" id="plot1" class="ng-pristine ng-valid">
<svg width="960" height="500" style="right: 0px;">Some data</svg>
</chart2>
chart1 generation of svg:
var svg = d3.select("#plot1").append("svg")
.attr("width", width + margin.left + margin.right)
.attr("height", height + margin.top + margin.bottom).style({'right': '0'});
chart 2 :
var svg = d3.select("#plot2").append("svg")
.attr("width", width + margin.left + margin.right)
.attr("height", height + margin.top + margin.bottom).style({'right': '0'});
for some reason those two graphs ends on top of each other, in html i can see that svg is stylled as position: absolute. if i remove this style everything works, but it i sstyle this way for a reason probably...
i come accross this guid: http://www.d3noob.org/2013/07/arranging-more-than-one-d3js-graph-on.html
but it didnt helped.
How can i solve this problem?