Hi Sorin,
We have analyzed your query. From that, we would like to let you know that the chart is responsive with respect to the width and height of its parent element. Since while using EjsChart tag a dynamic div will be created for which height and width of the parent div element is not set, the chart will render with its default size(600 * 450). Hence we suggest you to use the below workaround solution to achieve your requirement. In which we have provided the required height for parent div and the style of the chart has been set to inherit to get parent size. Please find below the sample, code snippet and screenshot.
Code Snippet:
<div style="height:100vh">
<EjsChart Height="100%">
<ChartPrimaryXAxis ValueType="Syncfusion.EJ2.Blazor.Charts.ValueType.Category" Interval="1">
</ChartPrimaryXAxis>
<ChartSeriesCollection>
<ChartSeries DataSource="@dataSource" XName="x" YName="y" Type="ChartSeriesType.Column">
</ChartSeries>
</ChartSeriesCollection>
</EjsChart>
</div>
<style>
.e-chart {
height:inherit
}
</style> |
Screenshot:
Let us know if you have any concerns.
Thanks,
Srihari