zaini
zaini

Reputation: 57

Angular nvd3 line chart length

I have a line chart. It is ploting okay. I need to show the chart on mobile devices. How do I optimize length of the chart on different devices? When data set is large, the chart resizes and becomes very short lengthwise.

I have had some limited success with following css

.plot {
    height :480px;
    overflow: auto;
}

But I think I need some help now...

Here is my HTML

<div class="container-fluid col-sm-10">
<nvd3-line-chart
    data="data3"
    id="growthChart"
    xAxisTickFormat="xAxisTickFormatFunction()"
    yAxisTickFormat="yAxisTickFormatFunction()"        
    showXAxis="true"
    showYAxis="true"
    >
        <div class="plot">
        <svg ></svg>
        </div>
</nvd3-line-chart>

Upvotes: 0

Views: 109

Answers (1)

zaini
zaini

Reputation: 57

I think I have solved it.

.plot {
   min-height :480px;
   height :480px;
   overflow: auto;
}

It is looking good as of now...

Upvotes: 0

Related Questions