make navbar logo centered

This commit is contained in:
Abhinav 2022-07-05 19:35:12 +05:30
parent 4634bc0253
commit 1563815273
3 changed files with 6 additions and 8 deletions

View file

@ -1,6 +1,5 @@
import { IconButton } from '@mui/material'; import { IconButton } from '@mui/material';
import { FluidContainer } from 'components/Container'; import { FluidContainer } from 'components/Container';
import { EnteLogo } from 'components/EnteLogo';
import React from 'react'; import React from 'react';
import { SearchMobileBox } from './styledComponents'; import { SearchMobileBox } from './styledComponents';
import SearchIcon from '@mui/icons-material/Search'; import SearchIcon from '@mui/icons-material/Search';
@ -11,12 +10,11 @@ export function SearchBarMobile({ show, showSearchInput }) {
} }
return ( return (
<SearchMobileBox> <SearchMobileBox>
<FluidContainer justifyContent="center" mr={1.5}> <FluidContainer justifyContent="flex-end" ml={1.5}>
<EnteLogo /> <IconButton onClick={showSearchInput}>
<SearchIcon />
</IconButton>
</FluidContainer> </FluidContainer>
<IconButton onClick={showSearchInput}>
<SearchIcon />
</IconButton>
</SearchMobileBox> </SearchMobileBox>
); );
} }

View file

@ -33,7 +33,7 @@ export function GalleryNavbar({
setIsInSearchMode, setIsInSearchMode,
}: Iprops) { }: Iprops) {
return ( return (
<NavbarBase> <NavbarBase sx={{ background: 'transparent', position: 'absolute' }}>
{!isInSearchMode && <SidebarToggler openSidebar={openSidebar} />} {!isInSearchMode && <SidebarToggler openSidebar={openSidebar} />}
{isFirstFetch ? ( {isFirstFetch ? (

View file

@ -229,7 +229,7 @@ export default function Gallery() {
}); });
useEffect(() => { useEffect(() => {
appContext.showNavBar(false); appContext.showNavBar(true);
const key = getKey(SESSION_KEYS.ENCRYPTION_KEY); const key = getKey(SESSION_KEYS.ENCRYPTION_KEY);
if (!key) { if (!key) {
appContext.setRedirectURL(router.asPath); appContext.setRedirectURL(router.asPath);