Skip to content

Commit bc46784

Browse files
committed
fixed logic
1 parent 4eea97b commit bc46784

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/components/Layout/Layout.jsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ class Layout extends React.PureComponent {
7171
// use classes insted of overrideClasses as material-ui
7272
const classes = { ...defaultClasses, ...overrideClasses };
7373

74-
const mainShift = drawerOpen && (drawerType === 'permanent' || drawerType === 'persistent');
74+
const mainShift = drawerType === 'permanent' || (drawerOpen && drawerType === 'persistent');
7575
const mainClassnames = classNames(
7676
classes.main,
7777
{ [`${classes.mainFixedAppBar}`]: appBarPosition === 'fixed' },
@@ -80,7 +80,7 @@ class Layout extends React.PureComponent {
8080
);
8181

8282
const appBarShift =
83-
drawerOpen && !drawerUnder && (drawerType === 'permanent' || drawerType === 'persistent');
83+
!drawerUnder && ((drawerOpen && drawerType === 'persistent') || drawerType === 'permanent');
8484

8585
const appBarClassnames = classNames(classes.appBar, {
8686
[`${classes.appBarShift}`]: appBarShift,

0 commit comments

Comments
 (0)