Web:Common: enable add button when navigation is open

This commit is contained in:
Timofey Boyko 2022-03-10 14:00:15 +03:00
parent b572b84410
commit eb11e51576
2 changed files with 11 additions and 5 deletions

View File

@ -15,13 +15,17 @@ const StyledContainer = styled.div`
margin-right: 12px;
min-width: 17px;
@media ${tablet} {
display: none;
}
${(props) =>
!props.isDropBox &&
css`
@media ${tablet} {
display: none;
}
`}
${isMobile &&
css`
display: none;
${(props) => !props.isDropBox && "display: none"};
`}
}
@ -37,6 +41,7 @@ const StyledContainer = styled.div`
const ControlButtons = ({
personal,
isDropBox,
isRootFolder,
canCreate,
getContextOptionsFolder,
@ -46,7 +51,7 @@ const ControlButtons = ({
clearTrash,
}) => {
return (
<StyledContainer>
<StyledContainer isDropBox={isDropBox}>
{!isRootFolder && canCreate ? (
<>
<ContextMenuButton

View File

@ -131,6 +131,7 @@ const DropBox = React.forwardRef(
<ControlButtons
personal={personal}
isRootFolder={isRootFolder}
isDropBox={true}
canCreate={canCreate}
getContextOptionsFolder={getContextOptionsFolder}
getContextOptionsPlus={getContextOptionsPlus}