旋转标签 nvd3 折线图
Rotate Labels nvd3 line chart
我想将 x 轴标签旋转 90 度,因为它们相互重叠。我已经使用了 rotateLabels 但它不是 wotking
<nvd3-line-chart
data="singleLineChartData"
id="singleLineChart"
width="800"
height="200"
showXAxis="true"
showYAxis="true"
tooltips="true"
interactive="true"
rotateLabels="90"
useinteractiveguideline="true"
xAxisTickValues="xAxisTickValuesFunction()"
xAxisTickFormat="xAxisTickFormat()"
color="colorFunction()"
isArea="false"
margin="{left:50,top:50,bottom:50,right:50}"
showLegend="true"
legendColor="colorFunction()"
noData="No Data!">
<svg></svg>
</nvd3-line-chart>
您必须使用 'xaxisrotatelabels'
而不是 rotateLabels
<div ng-app='nvd3TestApp'>
<div ng-controller="ExampleCtrl">
<nvd3-line-chart
data="exampleData"
showXAxis="true"
showYAxis="true"
tooltips="true"
xaxisrotatelabels ="90"
interactive="true">
</nvd3-line-chart>
</div>
</div>
我想将 x 轴标签旋转 90 度,因为它们相互重叠。我已经使用了 rotateLabels 但它不是 wotking
<nvd3-line-chart
data="singleLineChartData"
id="singleLineChart"
width="800"
height="200"
showXAxis="true"
showYAxis="true"
tooltips="true"
interactive="true"
rotateLabels="90"
useinteractiveguideline="true"
xAxisTickValues="xAxisTickValuesFunction()"
xAxisTickFormat="xAxisTickFormat()"
color="colorFunction()"
isArea="false"
margin="{left:50,top:50,bottom:50,right:50}"
showLegend="true"
legendColor="colorFunction()"
noData="No Data!">
<svg></svg>
</nvd3-line-chart>
您必须使用 'xaxisrotatelabels'
而不是 rotateLabels
<div ng-app='nvd3TestApp'>
<div ng-controller="ExampleCtrl">
<nvd3-line-chart
data="exampleData"
showXAxis="true"
showYAxis="true"
tooltips="true"
xaxisrotatelabels ="90"
interactive="true">
</nvd3-line-chart>
</div>
</div>