From 8389dd29ee0b65eb911d3bc5a7783800fcae4679 Mon Sep 17 00:00:00 2001 From: Efrain Villanueva Date: Sun, 2 May 2021 09:20:58 -0500 Subject: [PATCH 1/2] Restructure and add blog - Remove unsued pages - Add blog link, route, and page to the router --- src/components/Common/Links/index.js | 38 +++++-- src/components/Layout/index.js | 5 +- src/components/Pages/About/index.jsx | 70 ------------ src/components/Pages/Contact/index.js | 112 ------------------- src/components/Pages/Experience/index.jsx | 100 ----------------- src/components/Pages/Hireme/index.jsx | 32 ------ src/components/Pages/Projects/index.js | 101 ----------------- src/components/Pages/Skills/index.jsx | 127 ---------------------- src/components/Routes/index.js | 14 --- 9 files changed, 29 insertions(+), 570 deletions(-) delete mode 100644 src/components/Pages/About/index.jsx delete mode 100644 src/components/Pages/Contact/index.js delete mode 100644 src/components/Pages/Experience/index.jsx delete mode 100644 src/components/Pages/Hireme/index.jsx delete mode 100644 src/components/Pages/Projects/index.js delete mode 100644 src/components/Pages/Skills/index.jsx diff --git a/src/components/Common/Links/index.js b/src/components/Common/Links/index.js index ce4b838..748906f 100644 --- a/src/components/Common/Links/index.js +++ b/src/components/Common/Links/index.js @@ -1,5 +1,8 @@ import React from 'react'; -import { Link } from 'react-scroll'; +import { Link as Anchor } from 'react-scroll'; +import { + Link +} from "react-router-dom"; import withWidth, { isWidthDown } from '@material-ui/core/withWidth'; import IconButton from '@material-ui/core/IconButton'; @@ -13,6 +16,14 @@ const Links = (props) => { const menuBehaviour = props.opened ? 'open' : ''; const linksData = [ + { + props: { + props: { + link: '/blog' + }, + title: 'Blog' + } + }, { props: { containerId: 'homeAboutSection', @@ -55,16 +66,21 @@ const Links = (props) => { ) : null} {linksData.map((link, index) => (
  • - props.behaviourHandler(false)} - smooth={true} - spy={true} - to={link.props.containerId} - > - {link.title} - + { + link.props.containerId ? + props.behaviourHandler(false)} + smooth={true} + spy={true} + to={link.props.containerId} + > + {link.title} + + : + {link.title} + }
  • ))} diff --git a/src/components/Layout/index.js b/src/components/Layout/index.js index 47c3140..05ef05a 100644 --- a/src/components/Layout/index.js +++ b/src/components/Layout/index.js @@ -6,8 +6,7 @@ import CssBaseline from '@material-ui/core/CssBaseline'; import Grid from '@material-ui/core/Grid'; -// import Routes from '../Routes'; -import Home from '../Pages/Home'; +import Routes from '../Routes'; import Header from '../Common/Header'; import Footer from '../Common/Footer'; import SocialMedia from '../Common/SocialMedia'; @@ -23,7 +22,7 @@ const Layout = (props) => {
    - +
    diff --git a/src/components/Pages/About/index.jsx b/src/components/Pages/About/index.jsx deleted file mode 100644 index 94c45fb..0000000 --- a/src/components/Pages/About/index.jsx +++ /dev/null @@ -1,70 +0,0 @@ -import React from 'react'; -import Container from '@material-ui/core/Container'; - -const About = () => ( -
    - -
    -
    -
    -
    -
    -
    -
    -
    -
    -
    -
    -

    About

    -

    About Me

    -

    - A small river named Duden flows by their place and supplies it - with the necessary regelialia. -

    -
      -
    • - Name: Clark Thompson -
    • -
    • - Date of birth: January 01, 1987 -
    • -
    • - Address:{' '} - San Francisco CA 97987 USA -
    • -
    • - Zip code: 1000 -
    • -
    • - Email: clarkthomp@gmail.com -
    • -
    • - Phone: +1-2234-5678-9-0 -
    • -
    -
    -
    -
    -
    -

    - - 0 - - Project complete -

    -
    -
    -
    -
    -
    -
    -
    -); - -export default About; diff --git a/src/components/Pages/Contact/index.js b/src/components/Pages/Contact/index.js deleted file mode 100644 index b76f7ad..0000000 --- a/src/components/Pages/Contact/index.js +++ /dev/null @@ -1,112 +0,0 @@ -import React from 'react'; -import Container from '@material-ui/core/Container'; - -const Contact = () => ( -
    - -
    -
    -
    -

    Contact

    -

    Contact Me

    -

    - Far far away, behind the word mountains, far from the countries - Vokalia and Consonantia -

    -
    -
    - -
    -
    -
    -
    - -
    -

    Address

    -

    198 West 21th Street, Suite 721 New York NY 10016

    -
    -
    -
    -
    -
    - -
    -

    Contact Number

    -

    - + 1235 2355 98 -

    -
    -
    -
    -
    -
    - -
    -

    Email Address

    -

    - info@yoursite.com -

    -
    -
    -
    - -
    -
    -
    -
    - -
    -
    - -
    -
    - -
    -
    - -
    -
    - -
    -
    -
    - -
    -
    -
    -
    -
    -
    -
    -); - -export default Contact; diff --git a/src/components/Pages/Experience/index.jsx b/src/components/Pages/Experience/index.jsx deleted file mode 100644 index c12a542..0000000 --- a/src/components/Pages/Experience/index.jsx +++ /dev/null @@ -1,100 +0,0 @@ -import React from 'react'; -import Container from '@material-ui/core/Container'; - -const Resume = () => ( -
    - -
    -
    -
    -

    Resume

    -

    Resume

    -

    - A small river named Duden flows by their place and supplies it - with the necessary regelialia. It is a paradisematic country, in - which roasted parts of sentences fly into your mouth. -

    -
    -
    -
    -
    -
    - 2014-2015 -

    Master Degree of Design

    - Cambridge University -

    - A small river named Duden flows by their place and supplies it - with the necessary regelialia. It is a paradisematic country, in - which roasted parts of sentences fly into your mouth. -

    -
    -
    - 2014-2015 -

    Bachelor's Degree of C.A

    - Cambridge University -

    - A small river named Duden flows by their place and supplies it - with the necessary regelialia. It is a paradisematic country, in - which roasted parts of sentences fly into your mouth. -

    -
    -
    - 2014-2015 -

    Diploma in Computer

    - Cambridge University -

    - A small river named Duden flows by their place and supplies it - with the necessary regelialia. It is a paradisematic country, in - which roasted parts of sentences fly into your mouth. -

    -
    -
    - -
    -
    - 2014-2015 -

    Art & Creative Director

    - Cambridge University -

    - A small river named Duden flows by their place and supplies it - with the necessary regelialia. It is a paradisematic country, in - which roasted parts of sentences fly into your mouth. -

    -
    -
    - 2014-2015 -

    Wordpress Developer

    - Cambridge University -

    - A small river named Duden flows by their place and supplies it - with the necessary regelialia. It is a paradisematic country, in - which roasted parts of sentences fly into your mouth. -

    -
    -
    - 2017-2018 -

    UI/UX Designer

    - Cambridge University -

    - A small river named Duden flows by their place and supplies it - with the necessary regelialia. It is a paradisematic country, in - which roasted parts of sentences fly into your mouth. -

    -
    -
    -
    -
    - -
    -
    -
    -
    -); - -export default Resume; diff --git a/src/components/Pages/Hireme/index.jsx b/src/components/Pages/Hireme/index.jsx deleted file mode 100644 index e2ec59d..0000000 --- a/src/components/Pages/Hireme/index.jsx +++ /dev/null @@ -1,32 +0,0 @@ -import React from 'react'; - -const Hireme = () => ( -
    -
    -
    -
    -

    - I'm Available for freelancing -

    -

    - A small river named Duden flows by their place and supplies it with - the necessary regelialia. -

    -

    - - Hire me - -

    -
    -
    -
    -
    -); - -export default Hireme; diff --git a/src/components/Pages/Projects/index.js b/src/components/Pages/Projects/index.js deleted file mode 100644 index 2a14803..0000000 --- a/src/components/Pages/Projects/index.js +++ /dev/null @@ -1,101 +0,0 @@ -import React from 'react'; -import Container from '@material-ui/core/Container'; - -const Projects = () => ( -
    - -
    -
    -
    -

    Projects

    -

    Our Projects

    -

    - Far far away, behind the word mountains, far from the countries - Vokalia and Consonantia -

    -
    -
    -
    -
    -
    -
    -
    -

    Branding & Illustration Design

    - Web Design -
    -
    -
    -
    -
    -
    -
    -

    Branding & Illustration Design

    - Web Design -
    -
    -
    - -
    -
    -
    -
    -

    Branding & Illustration Design

    - Web Design -
    -
    - -
    -
    -
    -

    Branding & Illustration Design

    - Web Design -
    -
    -
    -
    -
    -
    -
    -
    -
    -

    Branding & Illustration Design

    - Web Design -
    -
    -
    -
    -
    -
    -
    -

    Branding & Illustration Design

    - Web Design -
    -
    -
    -
    -
    -
    -
    -
    -
    -); - -export default Projects; diff --git a/src/components/Pages/Skills/index.jsx b/src/components/Pages/Skills/index.jsx deleted file mode 100644 index 9e58e7e..0000000 --- a/src/components/Pages/Skills/index.jsx +++ /dev/null @@ -1,127 +0,0 @@ -import React from 'react'; -import Container from '@material-ui/core/Container'; - -const Skills = () => ( -
    - -
    -
    -
    -

    Skills

    -

    My Skills

    -

    - Far far away, behind the word mountains, far from the countries - Vokalia and Consonantia -

    -
    -
    -
    -
    -
    -

    Photoshop

    -
    -
    - 90% -
    -
    -
    -
    -
    -
    -

    jQuery

    -
    -
    - 85% -
    -
    -
    -
    -
    -
    -

    HTML5

    -
    -
    - 95% -
    -
    -
    -
    -
    -
    -

    CSS3

    -
    -
    - 90% -
    -
    -
    -
    -
    -
    -

    WordPress

    -
    -
    - 70% -
    -
    -
    -
    -
    -
    -

    SEO

    -
    -
    - 80% -
    -
    -
    -
    -
    -
    -
    -
    -); - -export default Skills; diff --git a/src/components/Routes/index.js b/src/components/Routes/index.js index f6c995d..47aeb09 100644 --- a/src/components/Routes/index.js +++ b/src/components/Routes/index.js @@ -2,28 +2,14 @@ import React, { Component } from 'react'; import { Route } from 'react-router'; import Home from '../Pages/Home'; -import About from '../Pages/About'; import Blog from '../Pages/Blog'; -import Contact from '../Pages/Contact'; -import Counter from '../Common/Counter'; -import Hireme from '../Pages/Hireme'; -import Projects from '../Pages/Projects'; -import Experience from '../Pages/Experience'; -import Skills from '../Pages/Skills'; class Routes extends Component { render() { return ( - - - - - - - ); } From b6b4320052e780a91a52fa57d423e705a71ebde8 Mon Sep 17 00:00:00 2001 From: Efrain Villanueva Date: Wed, 26 May 2021 18:31:04 -0500 Subject: [PATCH 2/2] Create blog Create blog stream Create post template Configured multiple route Add README file to explain WHAT IS HAPPENING AAdapt links to use react scroll and react router --- .prettierrc | 8 + package.json | 2 +- src/assets/images/efra_avatar.gif | Bin 0 -> 17076 bytes src/components/Common/Links/index.js | 168 ++++++------ src/components/Layout/index.js | 34 +-- src/components/Pages/Blog/EntriesSkelleton.js | 63 +++++ src/components/Pages/Blog/README.md | 3 + src/components/Pages/Blog/index.js | 75 +----- src/components/Pages/Blog/styles.js | 9 +- src/components/Pages/Home/AboutSection.js | 219 ++++++++-------- src/components/Pages/Home/ContactSection.js | 72 ++--- src/components/Pages/Home/HeroSection.js | 80 +++--- src/components/Pages/Home/ProjectsSection.js | 242 +++++++++-------- src/components/Pages/Home/WorkedSection.js | 248 ++++++++++-------- src/components/Pages/Home/index.js | 41 ++- src/components/Pages/Post/Footer.js | 30 +++ src/components/Pages/Post/Header.js | 37 +++ src/components/Pages/Post/index.js | 45 ++++ src/components/Pages/Post/styles.js | 63 +++++ src/components/Routes/index.js | 19 +- src/constants/blogEntries.js | 180 +++++++++++++ yarn.lock | 8 +- 22 files changed, 1062 insertions(+), 584 deletions(-) create mode 100644 .prettierrc create mode 100644 src/assets/images/efra_avatar.gif create mode 100644 src/components/Pages/Blog/EntriesSkelleton.js create mode 100644 src/components/Pages/Blog/README.md create mode 100644 src/components/Pages/Post/Footer.js create mode 100644 src/components/Pages/Post/Header.js create mode 100644 src/components/Pages/Post/index.js create mode 100644 src/components/Pages/Post/styles.js create mode 100644 src/constants/blogEntries.js diff --git a/.prettierrc b/.prettierrc new file mode 100644 index 0000000..9bdf4a6 --- /dev/null +++ b/.prettierrc @@ -0,0 +1,8 @@ +{ + "semi": true, + "trailingComma": "all", + "singleQuote": true, + "tabWidth": 2, + "useTabs": false, + "printWidth": 70 +} diff --git a/package.json b/package.json index 6e139a1..2cb79da 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,7 @@ "dependencies": { "@babel/core": "7.9.0", "@material-ui/core": "^4.11.0", - "@material-ui/icons": "^4.9.1", + "@material-ui/icons": "^4.11.2", "@material-ui/lab": "^4.0.0-alpha.56", "@material-ui/styles": "^4.10.0", "@svgr/webpack": "4.3.3", diff --git a/src/assets/images/efra_avatar.gif b/src/assets/images/efra_avatar.gif new file mode 100644 index 0000000000000000000000000000000000000000..bbe168b98ada4d6830ade373296443c791a44673 GIT binary patch literal 17076 zcmY(qXIK+m)Ha$5AtVrbhtLC30s_)W=tvO+rE6#skP?bYH-!><=tYoFlu!)_h}aT( zQ$bKcQ9)1;QBm;`eN>Lmd%p92*O?zPYxdlG?R&4;vu4d&*El%Y8=C}i035(~z<(Pr z1e$#@-p9t|=Iurk$B3AV%rilrQp)B=$}&yN#)kS*M;lxJ&;;^DGErIh*1cIqV$?-j z>!QYy%V(TD!b;usRdb3OH`nJPcz`!E{2M|~K=?6}?G4F^@iWC?7rks{M1(u?Xbk?8K{bgQGjn}4clh2+A&3S$)GdQuTgpv1n;kt8RR*0nu zqv2N4F>_)lAxd9aTTC#XejR^U+sDpsY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N6Mxt|6QYg&0LzNjuhtK1IW|4M&(+tWC6gVVsoDs+j0-Pq{(izXrgJaJ zKbdv&M7qo0|45N=Ux=&+L1qsqGFwz>101N~A*54UHfmm_W#k8%tP6`hOC5o@lt}N5 zJkh5}@4iLa*CVgKfT6{dr-8;=U}KC-Z%g2JCzQ-0TUH@U-Ce}+2OhZ?Ws0&vdw8Q- z&xjLgyVe9~rj1++@%#t8LzZ^KN4#KxwV+LxKuaJL7p=1eI9fC!v_&4`;&19q+*~^f5Jg!FFvI1YmH@zFR46{ z0}b)aZsd##cmb_#7cH{oQwJ~&{ew2BfimdW?92h6rKk$LVl=BjF63a^^#TNpb=paR z0j=;Uw86=`HD)L3#XE2w%~l}$ literal 0 HcmV?d00001 diff --git a/src/components/Common/Links/index.js b/src/components/Common/Links/index.js index 748906f..5cfd200 100644 --- a/src/components/Common/Links/index.js +++ b/src/components/Common/Links/index.js @@ -1,8 +1,6 @@ import React from 'react'; import { Link as Anchor } from 'react-scroll'; -import { - Link -} from "react-router-dom"; +import { Link, useLocation } from 'react-router-dom'; import withWidth, { isWidthDown } from '@material-ui/core/withWidth'; import IconButton from '@material-ui/core/IconButton'; @@ -10,83 +8,99 @@ import CloseIcon from '@material-ui/icons/Close'; import useStyles from './styles'; -const Links = (props) => { - const classes = useStyles(); +const Links = ({ behaviourHandler, opened, width }) => { + const classes = useStyles(); - const menuBehaviour = props.opened ? 'open' : ''; + const menuBehaviour = opened ? 'open' : ''; - const linksData = [ - { - props: { - props: { - link: '/blog' - }, - title: 'Blog' - } - }, - { - props: { - containerId: 'homeAboutSection', - }, - title: 'About', - }, - { - props: { - containerId: 'homeWorkedSection', - }, - title: 'Experience', - }, - { - props: { - containerId: 'homeProjectsSection', - }, - title: 'Projects', - }, - { - props: { - containerId: 'homeContactSection', - }, - title: 'Contact', - }, - ]; + const linksData = [ + { + props: { + link: '/blog', + }, + title: 'Blog', + }, + { + props: { + containerId: 'homeAboutSection', + }, + title: 'About', + }, + { + props: { + containerId: 'homeWorkedSection', + }, + title: 'Experience', + }, + { + props: { + containerId: 'homeProjectsSection', + }, + title: 'Projects', + }, + { + props: { + containerId: 'homeContactSection', + }, + title: 'Contact', + }, + ]; - return ( - - - - ); + return ( + <> + + + ); +}; + +const AppLink = (link, behaviourHandler) => { + const { pathname } = useLocation(); + + return pathname !== '/' ? ( + link.props.containerId ? ( + + {link.title} + + ) : ( + {link.title} + ) + ) : !link.props.containerId ? ( + {link.title} + ) : ( + behaviourHandler(false)} + smooth={true} + spy={true} + to={link.props.containerId} + > + {link.title} + + ); }; export default withWidth()(Links); diff --git a/src/components/Layout/index.js b/src/components/Layout/index.js index 05ef05a..c300480 100644 --- a/src/components/Layout/index.js +++ b/src/components/Layout/index.js @@ -1,11 +1,9 @@ import React from 'react'; -import { BrowserRouter } from 'react-router-dom'; +import { BrowserRouter, Switch } from 'react-router-dom'; import { ThemeProvider } from '@material-ui/core/styles'; import withWidth, { isWidthDown } from '@material-ui/core/withWidth'; import CssBaseline from '@material-ui/core/CssBaseline'; -import Grid from '@material-ui/core/Grid'; - import Routes from '../Routes'; import Header from '../Common/Header'; import Footer from '../Common/Footer'; @@ -14,23 +12,19 @@ import SocialMedia from '../Common/SocialMedia'; import { darkTheme } from './styles'; const Layout = (props) => { - return ( - - - -
    -
    - - - - - -
    -