Revert "migrate some components to Mui5 new styling system (#72)"

This reverts commit 72ef61e286.
This commit is contained in:
Aria Moradi
2021-11-15 17:21:31 +03:30
parent 0eedbe6626
commit 04a1898ea7
28 changed files with 501 additions and 341 deletions

View File

@@ -12,7 +12,7 @@ import {
Redirect,
} from 'react-router-dom';
import { QueryParamProvider } from 'use-query-params';
import { Container } from '@mui/material';
import { Container, useMediaQuery } from '@mui/material';
import CssBaseline from '@mui/material/CssBaseline';
import {
createTheme, ThemeProvider, Theme, StyledEngineProvider,
@@ -90,6 +90,8 @@ export default function App() {
}),
[darkTheme],
);
// this can only be used after the theme object is created
const isMobileWidth = useMediaQuery(theme.breakpoints.down('sm'));
return (
<Router>
@@ -103,10 +105,10 @@ export default function App() {
id="appMainContainer"
maxWidth={false}
disableGutters
sx={{
mt: 8,
ml: { sm: 8 },
mb: { xs: 8, sm: 4 },
style={{
marginTop: theme.spacing(8),
marginLeft: isMobileWidth ? '' : theme.spacing(8),
marginBottom: isMobileWidth ? theme.spacing(8) : '',
width: 'auto',
overflow: 'auto',
}}