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

redesign home page #74

Merged
merged 1 commit into from
Jul 19, 2023
Merged
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
73 changes: 45 additions & 28 deletions src/pages/index.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import { Stack, Container } from "@mui/material";
import { Stack, Container, Typography, Box } from "@mui/material";
import { useAtom } from "jotai";
import type { NextPage } from "next";
import Image from "next/image";
import { useEffect } from "react";

import AppBar from "components/ui/AppBar/AppBar";
import AppLink from "src/components/ui/Buttons/AppLink";
import ObjectiveCard from "src/components/ui/Cards/ObjectiveCard/ObjectiveCard";
import PageTextTemplate from "src/components/ui/PageTextTemplate/PageTextTemplate";
import { cartAtom } from "src/store/cart";

const Home: NextPage = () => {
Expand All @@ -16,34 +16,51 @@ const Home: NextPage = () => {
setCart({});
}, [setCart]);

return (
<>
<AppBar />
<Container
sx={{
height: "100%",
display: "flex",
alignItems: "center",
justifyContent: "center",
}}
>
<Stack
py="2em"
spacing="5em"
textAlign="center"
justifyContent="center"
marginTop="5em"
>
<Stack direction="row" justifyContent="space-around" spacing="5em">
<Image src={require("../../public/images/apple-pie.jpeg")} alt="" />

<ObjectiveCard></ObjectiveCard>
</Stack>
<AppLink text="Commencer l'expérience" link="/fruits" />
const emphasisStyle = { color: "primary.main", fontWeight: "bold" };

const presentationText = (
<Typography>
A11Y INYERFACE est un projet visant à{" "}
<Box component="span" sx={emphasisStyle}>
sensibiliser les utilisateurs aux principes de l&apos;accessibilité{" "}
</Box>
et à les encourager à{" "}
<Box component="span" sx={emphasisStyle}>
adopter des pratiques{" "}
</Box>{" "}
qui rendent le web{" "}
<Box component="span" sx={emphasisStyle}>
plus inclusif
</Box>{" "}
pour tous.
</Typography>
);

const content = (
<Container
sx={{
display: "flex",
flexDirection: "column",
justifyContent: "center",
textAlign: "center",
marginTop: "3em",
width: "120%",
marginLeft: "-10%",
marginBottom: "-5em",
loona-rvr marked this conversation as resolved.
Show resolved Hide resolved
}}
>
{presentationText}
<Stack py="2em" spacing="5em" textAlign="center" justifyContent="center">
<Stack direction="row" justifyContent="space-around" spacing="5em">
<Image src={require("/public/images/apple-pie.jpeg")} alt="" />
<ObjectiveCard />
</Stack>
</Container>
</>
<AppLink text="Commencer l'expérience" link="/fruits" />
</Stack>
</Container>
);

return <PageTextTemplate content={content} />;
loona-rvr marked this conversation as resolved.
Show resolved Hide resolved
};

export default Home;