0
안녕하세요, nvd3.js 라이브러리와 함께 scatterChart를 만들려고합니다. 이제는 두 축 모두 동일한 너비/높이를 갖기를 원합니다. 그러나 코드에서와 같이 CSS의 높이와 너비가 모두 같은 높이로 설정된 경우에도 y 축은 높이가 더 길게 유지됩니다.NVD3.js scatter
JS :
var chart = nv.models.scatterChart()
.width(300)
.height(300)
.showXAxis(true)
.showYAxis(true)
.forceX([-100,100])
.forceY([-100,100])
.tooltips(true)
.showLegend(false)
.tooltipContent(function(){
return 'clock';
});
CSS :
#main-chart {
width: 300px;
height: 300px;
margin: 0 auto;
}
HTML :
<div class="container" ng-controller="film_factor_controller">
<svg bubble-chart id="main-chart"></svg>
희망 누군가가 나를 도울 수
가능한 [nvd3 차트의 높이 및 너비 설정 방법] (http://stackoverflow.com/questions/16474988/how-to-set-height-and-width-of-nvd3-chart) – shabeer90