Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat/header #3

Merged
merged 2 commits into from
Aug 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@ import PopUpRedirect from './components/atoms/PopUpRedirect';
import WidgetsTemplate from './components/organisms/WidgetsTemplate';
// main components height - must add up to 100

const headerHeight = '5vh';
const headerHeight = '6vh';
const pageContentHeight = '88vh';
const footerHeight = '7vh';
const footerHeight = '6vh';

const useStyles = makeStyles((theme: Theme) =>
createStyles({
pageContent: {
overflow: 'auto',
overflow: 'hidden',
},
}),
);
Expand Down
3 changes: 1 addition & 2 deletions src/components/atoms/AppBar.tsx
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
import React, { FC } from 'react';
import MatAppBar from '@material-ui/core/AppBar';
import { createStyles, makeStyles, Theme } from '@material-ui/core';
import { smokeWhiteColor } from 'style';

const useStyles = makeStyles((theme: Theme) =>
createStyles({
root: {
position: 'relative',
flexGrow: 1,
backgroundColor: smokeWhiteColor,
backgroundColor: '#2081c3',
display: 'flex',
flexDirection: 'row',
alignItems: 'center',
Expand Down
4 changes: 2 additions & 2 deletions src/components/atoms/SignInIcon.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import React from 'react';
import { createStyles, makeStyles, Theme } from '@material-ui/core';
import { blackColor } from 'style';
import { blackColor, whiteColor } from 'style';

const useStyles = makeStyles((theme: Theme) =>
createStyles({
root: {
color: blackColor,
color: whiteColor,
marginRight: '5px',
cursor: 'default',
display: 'flex',
Expand Down
7 changes: 4 additions & 3 deletions src/components/molecules/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ const useStyles = makeStyles({
userSection: {
display: 'flex',
alignItems: 'center',
justifyContent: 'space-between',
width: '12%',
},
});

Expand Down Expand Up @@ -85,10 +87,10 @@ const Header: FC = () => {
);
} else {
authElement = (
<>
<Box style={{ display: 'flex', justifyContent: 'space-between', alignItems: 'center' }}>
<LogInLinkGoogle />
<SignInIcon />
</>
</Box>
);
}
}
Expand All @@ -98,7 +100,6 @@ const Header: FC = () => {
<Logo src={logo} alt={'Anyway'} height={30} onClick={reloadHomePage} />
<Box className={classes.userSection}>
<Button.Standard onClick={() => setOpen(true)}>{t('header.Search')}</Button.Standard>
{FEATURE_FLAGS.language && <LanguageMenu />}
{authElement}
</Box>
<MapDialog
Expand Down
6 changes: 3 additions & 3 deletions src/components/molecules/LogInLinkGoogle.tsx
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
import { makeStyles } from '@material-ui/core/styles';
import { oceanBlueColor, skyBlueColor } from 'style';
import { blackColor, oceanBlueColor, skyBlueColor, smokeWhiteColor, whiteColor } from 'style';
import React from 'react';
import { AUTH_LOGIN_GOOGLE_URL } from 'const/generalConst';
import { openSignInWindow } from 'services/signInWindow';
import { useTranslation } from 'react-i18next';
const useStyles = makeStyles((theme) => ({
userButton: {
padding: theme.spacing(1),
color: `${oceanBlueColor}`,
color: `${whiteColor}`,
textDecoration: 'none',
'&:hover': {
color: `${skyBlueColor}`,
color: `${smokeWhiteColor}`,
},
cursor: 'pointer',
},
Expand Down
2 changes: 1 addition & 1 deletion src/pages/HomePage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const useStyles = makeStyles((theme: Theme) => ({
display: 'flex',
flexDirection: 'row',
flexWrap: 'wrap',
marginTop: '24px',
margin: '16px',
justifyContent: 'center',
overflow: 'auto',
},
Expand Down
Loading