Improve page appearance

This commit is contained in:
Pierre HUBERT 2021-07-12 18:55:28 +02:00
parent e7ab1f1837
commit 322969daa7

View File

@ -102,20 +102,9 @@ export class ComunicUserRoute extends React.Component<
} }
build() { build() {
const properties = this.userProperties.map((p) => {
return ( return (
<> <TableRow key={p.name} hover>
<PageTitle
name={this.user.first_name + " " + this.user.last_name}
/>
<Grid container spacing={3}>
<Grid item xs={6}>
<CustomCard title="General information">
<Table>
<TableBody>
{this.userProperties.map((p) => {
return (
<TableRow key={p.name}>
<TableCell <TableCell
style={{ style={{
fontWeight: "bold", fontWeight: "bold",
@ -136,9 +125,37 @@ export class ComunicUserRoute extends React.Component<
</TableCell> </TableCell>
</TableRow> </TableRow>
); );
})} });
return (
<>
<PageTitle
name={this.user.first_name + " " + this.user.last_name}
/>
<Grid container spacing={3}>
<Grid item xs={12}>
<CustomCard title="General information">
<Grid container>
<Grid item xs={6}>
<Table>
<TableBody>
{properties.slice(
0,
properties.length / 2
)}
</TableBody> </TableBody>
</Table> </Table>
</Grid>
<Grid item xs={6}>
<Table>
<TableBody>
{properties.slice(
properties.length / 2
)}
</TableBody>
</Table>
</Grid>
</Grid>
</CustomCard> </CustomCard>
</Grid> </Grid>
</Grid> </Grid>