Skip to content
Snippets Groups Projects
Verified Commit 6be66a1a authored by Rafael László's avatar Rafael László :speech_balloon:
Browse files

Update proxy to use env and move about loading under members

parent 8871352e
No related branches found
No related tags found
2 merge requests!19fix type imports,!16About page
...@@ -9,10 +9,6 @@ import Page from './Page'; ...@@ -9,10 +9,6 @@ import Page from './Page';
const AboutPage: React.FC = () => { const AboutPage: React.FC = () => {
const { data, status } = useGetStaff(); const { data, status } = useGetStaff();
if (!data || status === 'loading') {
return <CircularProgress />;
}
return ( return (
<Page> <Page>
<Box display="flex" flexDirection="column" alignItems="center" padding={3}> <Box display="flex" flexDirection="column" alignItems="center" padding={3}>
...@@ -30,7 +26,10 @@ const AboutPage: React.FC = () => { ...@@ -30,7 +26,10 @@ const AboutPage: React.FC = () => {
</Typography> </Typography>
</Box> </Box>
<Box marginBottom={8} display="flex" justifyContent="center" flexWrap="wrap"> <Box marginBottom={8} display="flex" justifyContent="center" flexWrap="wrap">
{data?.map((m) => ( {!data || status === 'loading' ? (
<CircularProgress />
) : (
data?.map((m) => (
<Box m={3} key={m.email}> <Box m={3} key={m.email}>
<MemberCard <MemberCard
name={m.name} name={m.name}
...@@ -39,7 +38,8 @@ const AboutPage: React.FC = () => { ...@@ -39,7 +38,8 @@ const AboutPage: React.FC = () => {
staffMemberText={m.staffMemberText} staffMemberText={m.staffMemberText}
/> />
</Box> </Box>
))} ))
)}
</Box> </Box>
<Box marginY={4}> <Box marginY={4}>
<Typography variant="h4" color="textPrimary"> <Typography variant="h4" color="textPrimary">
......
...@@ -4,7 +4,7 @@ module.exports = function (app) { ...@@ -4,7 +4,7 @@ module.exports = function (app) {
app.use( app.use(
'/api/v1', '/api/v1',
createProxyMiddleware({ createProxyMiddleware({
target: 'https://body-dev.maze.sch.bme.hu/dev', target: process.env.REACT_APP_PROXY_TARGET,
changeOrigin: true, changeOrigin: true,
}), }),
); );
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment