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

fix part of #3: created seperate css file for explore page #38

Merged
merged 4 commits into from
Dec 23, 2021
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
14 changes: 14 additions & 0 deletions src/pages/explore/Explore.module.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
.paperPosition {
height: 60px;
padding: 5px 10px;
align-items: center;
display: flex;
position: relative;
}
.arrow {
position: absolute;
right: 10px;
}
.gridContainer {
margin-top: 10;
}
19 changes: 5 additions & 14 deletions src/pages/explore/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,31 +2,22 @@ import React from "react";
import { Typography, Paper, Grid } from "@material-ui/core";
import { Link } from "react-router-dom";
import { ArrowForward } from "@material-ui/icons";

import styles from "./Explore.module.css"
import { Components_Index } from "../../containers/Navigation";

function Expore() {
return (
<section>
<Typography variant="h2">Explore</Typography>

<Grid container spacing={1} style={{ marginTop: 20 }}>
<Grid container spacing={1} className={styles.gridContainer} >
{Components_Index.map((elm, idx) => {
return (
<Grid item xs={12} sm={6} md={4} lg={3}>
<Link to={elm.path}>
<Paper
style={{
height: 60,
padding: "5px 10px",
alignItems: "center",
display: "flex",
position: "relative",
}}
>
<Paper className={styles.paperPosition}>
<Typography variant="h5">{elm.name}</Typography>

<ArrowForward style={{ position: "absolute", right: 10 }} />
<ArrowForward className={styles.arrow} />
</Paper>
</Link>
</Grid>
Expand All @@ -37,4 +28,4 @@ function Expore() {
);
}

export default Expore;
export default Expore;