diff --git a/src/features/HomePage/components/Portfolio/Portfolio.js b/src/features/HomePage/components/Portfolio/Portfolio.js index 089ea37..acfd5c2 100644 --- a/src/features/HomePage/components/Portfolio/Portfolio.js +++ b/src/features/HomePage/components/Portfolio/Portfolio.js @@ -2,7 +2,7 @@ import React from 'react'; import { useStaticQuery, graphql } from 'gatsby'; import { makeStyles } from '@material-ui/core/styles'; -import { Typography, Container } from '@material-ui/core'; +import { Typography, Container, Grid } from '@material-ui/core'; import Section, { BG_COLOR } from '@components/Section'; import Project from './Project'; @@ -18,9 +18,11 @@ const useStyles = makeStyles(theme => ({ margin: '3rem 0', }, }, - projects: { - '& > *:not(:last-child)': { - marginBottom: theme.spacing(2), + gridItem: { + [theme.breakpoints.up(750)]: { + flexGrow: 0, + flexBasis: '50%', + maxWidth: '50%', }, }, })); @@ -39,7 +41,7 @@ function Portfolio() { relativePath childImageSharp { id - fluid(maxWidth: 1000) { + fluid(maxWidth: 1280) { ...GatsbyImageSharpFluid } } @@ -58,8 +60,8 @@ function Portfolio() { My work -
- {projects.map((project, index) => { + + {projects.map(project => { let fluid = undefined; if (project.fluid) { const edge = data.allCoverImages.edges.find( @@ -71,15 +73,17 @@ function Portfolio() { } return ( - + item + xs={12} + className={classes.gridItem} + > + + ); })} -
+ ); @@ -121,26 +125,19 @@ const projects = [ 'GraphQL', 'Golang', 'gqlgen', - 'Echo', + 'Gin', 'PostgreSQL', + 'TypeScript', 'React', + 'React Native', 'Next.JS', 'Material-UI', 'Apollo', - 'React Native', ], github: '', fluid: 'projects/zdam.png', live: 'https://zdamegzaminzawodowy.pl/', }, - { - title: 'matura-z-informatyki.pl', - description: '', - technologies: ['React', 'Next.JS', 'Bulma', 'Ghost'], - github: 'https://github.com/Kichiyaki/matura-z-informatyki.pl', - live: 'https://matura-z-informatyki.pl/', - fluid: 'projects/maturazinf.png', - }, { title: 'dwysokinski.me', description: '', diff --git a/src/features/HomePage/components/Portfolio/Project.js b/src/features/HomePage/components/Portfolio/Project.js index 871afca..a7f41f4 100644 --- a/src/features/HomePage/components/Portfolio/Project.js +++ b/src/features/HomePage/components/Portfolio/Project.js @@ -1,22 +1,20 @@ import React from 'react'; import PropTypes from 'prop-types'; -import classnames from 'classnames'; import notFound from './not-found.jpg'; import { makeStyles } from '@material-ui/core/styles'; import { + Button, Card, CardContent, CardMedia, - Typography, - Button, Chip, Link, + Typography, } from '@material-ui/core'; import BackgroundImage from 'gatsby-background-image'; function Project({ - reverse, title, description, technologies, @@ -27,11 +25,7 @@ function Project({ }) { const classes = useStyles(); return ( - + {fluid ? (
- + {title} {description}
-
+
{technologies.map(technology => { return ( @@ -81,27 +75,27 @@ const useStyles = makeStyles(theme => ({ card: { display: 'flex', minHeight: '400px', - '&.reverse': { - flexDirection: 'row-reverse', - [theme.breakpoints.down('sm')]: { - flexDirection: 'column', - }, - }, - [theme.breakpoints.down('sm')]: { - flexDirection: 'column', - }, + flexDirection: 'column', + height: '100%', }, cardContent: { display: 'flex', flexDirection: 'column', - width: '45%', - [theme.breakpoints.down('sm')]: { - width: '100%', - }, + height: '100%', }, divider: { flex: 1, }, + title: { + overflowWrap: 'break-word', + wordWrap: 'break-word', + '-ms-word-break': 'break-all', + wordBreak: 'break-word', + '-ms-hyphens': 'auto', + '-moz-hyphens': 'auto', + '-webkit-hyphens': 'auto', + hyphens: 'auto', + }, contentContainer: { marginBottom: theme.spacing(8), }, @@ -126,16 +120,12 @@ const useStyles = makeStyles(theme => ({ }, }, cover: { - width: '55%', - [theme.breakpoints.down('sm')]: { - width: '100%', - paddingTop: '56.25%', - }, + width: '100%', + paddingTop: '66.6666%', }, })); Project.defaultProps = { - reverse: false, title: '', description: '', technologies: [], @@ -145,7 +135,6 @@ Project.defaultProps = { }; Project.propTypes = { - reverse: PropTypes.bool.isRequired, title: PropTypes.string.isRequired, description: PropTypes.string.isRequired, technologies: PropTypes.arrayOf(PropTypes.string).isRequired, diff --git a/src/images/projects/amz.png b/src/images/projects/amz.png index 6aab0ae..fca7234 100644 Binary files a/src/images/projects/amz.png and b/src/images/projects/amz.png differ diff --git a/src/images/projects/dw.png b/src/images/projects/dw.png index 8fd5513..a847df9 100644 Binary files a/src/images/projects/dw.png and b/src/images/projects/dw.png differ diff --git a/src/images/projects/freshline.png b/src/images/projects/freshline.png index 7ae283c..e3bd0fc 100644 Binary files a/src/images/projects/freshline.png and b/src/images/projects/freshline.png differ diff --git a/src/images/projects/zdam.png b/src/images/projects/zdam.png index 9aff205..28efd76 100644 Binary files a/src/images/projects/zdam.png and b/src/images/projects/zdam.png differ