I have created chart using D3js and react. I am using grid system of react semantic ui. I want to place chart inside column but the chart is not getting placed inside the column. On barchart is getting placed on left column but piechart should be in right column but it is showing in left side why so ?
Note: I have not added any CSS for piechart and barchart.Barchart component returns svg of width= 550 height=450. Piechart component returns svg of width=height=100
How can I place Piechart inside column in grid system ?
Code:
dashboard.js
import React, { Component } from 'react';
import { Card, Icon, Image, Grid } from 'semantic-ui-react';
import styles from './dashboard.module.css';
import BarChart from './barchart';
import PieChart from './piechart';
const DashBoard = () => (
<Grid columns='two' divided className={styles.container}>
<Grid.Row>
<Grid.Column>
<BarChart/>
</Grid.Column>
<Grid.Column>
<PieChart/>
</Grid.Column>
</Grid.Row>
</Grid>
)
export default DashBoard;
dashboard.module.css:
.container {
margin-left: 100px !important;
margin-top: 100px !important;
margin-right: 100px !important;
height: 400px;
}
Screenshot:

