-
Notifications
You must be signed in to change notification settings - Fork 389
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
Johanna Eriksson Portfolio #393
Open
joheri1
wants to merge
54
commits into
Technigo:main
Choose a base branch
from
joheri1:main
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 50 commits
Commits
Show all changes
54 commits
Select commit
Hold shift + click to select a range
d5411c4
Add new folder for components
joheri1 9d1c46f
Initialize using Vire and install my-portfolio template. Add instruct…
joheri1 84ebd9f
Add global styles in index.css
joheri1 681332d
Start adding the structure. Create folders for components, create com…
joheri1 77589c1
Add components for section, image, card, button, typography, tag, and…
joheri1 a01f9de
Start writing the README file
joheri1 2c97cfc
Add icons to the icons folder
joheri1 f4e4ed5
”To the Section folder, add TextSection.jsx, CardSection.jsx, and Foo…
joheri1 f55838f
Add unsaved changes, if any
joheri1 d81fc7a
Mount components to App.jsx. Add some first lines of code to the comp…
joheri1 3a34966
Rename component TextSection CSS, that mistakingly was given the wron…
joheri1 e41cbf2
Update paths, etc to make the code work. Import the Footer component …
joheri1 327cbc3
Fix code for the section since it is using a mix of children and expl…
joheri1 3e6d557
Change px to rem on the font sizes
joheri1 89e25cd
Changed px to rem on each components css file
joheri1 70384dc
Correct variable names for the h1 and h2 fonts in the sections.
joheri1 9b619c9
Add image to Assets.
joheri1 26e7511
Add styling to Hero. Add social icons to hero incl css
joheri1 c98ce11
Add more styling to Hero
joheri1 427b246
Add styling to Tech text section. Update section comments in the fini…
joheri1 8bc2301
Complete the Footer component and add styling to it. Create a new com…
joheri1 d982320
Save any unsaved changes
joheri1 dc08902
Add more default data in the project.json and move the json file to w…
joheri1 2037740
Update Button components. Import the Button components to the CardSec…
joheri1 3f64d37
Add descriptions to the components
joheri1 b89ea56
Delete second, unused README file. Update the correct README
joheri1 f7e6adc
Fix file path to Typography.css
joheri1 6727ae0
Correct paths to Icon components
joheri1 3509fba
Correct the paths to Icons in the Hero and Footer components
joheri1 12f1279
Add more styling to CardSection
joheri1 69649c6
Force Netlify redeploy
joheri1 065c881
Rename Icons to SocialIcons to trigger a change
joheri1 aa9a8b2
Correct path to Button.css
joheri1 eb44194
Change how props are being passed in the ProjectCard to a heading pro…
joheri1 961b8b9
Added more info to the readme file.
joheri1 52861e9
Save any unsaved changes
joheri1 020816c
Add global responsive styling for fonts and font-sizes for Tablet, De…
joheri1 79be27b
Change margin for body text in skills columns
joheri1 54884e1
Add styling to media queries for Mobile. Fix syntax error in Global s…
joheri1 6212b49
Add styling to Hero
joheri1 9528dc5
Add styling for media query Tablet
joheri1 aa8ccc5
Add more styling to Media queries css
joheri1 788b246
Update README file
joheri1 190224c
Delete CSS file for responsiveness since it is not used. Update comme…
joheri1 df67203
Add gap to icons in Hero for mobile
joheri1 c6844b5
Add font weight to the fonts in the global styling
joheri1 246b065
Update README.md
joheri1 eaf0ce4
Update CardSection.css by giving the cards-container a max-width of 1…
joheri1 2607592
Updated local README to match GitHub version
joheri1 6e20615
Update Footer.css by giving the footer-container a max-width of 1200p…
joheri1 7bbbc80
Add scrolling to card-container in the CardSection.css
joheri1 b7b8c05
Add more styling to CardSection.css to make the scrolling look ok. Ad…
joheri1 a9ea511
Make the article-card h3 to have a height of two rows. Add ellipsis i…
joheri1 c8fc81f
Restore tablet responsiveness for Footer component
joheri1 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Binary file not shown.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Logs | ||
logs | ||
*.log | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
pnpm-debug.log* | ||
lerna-debug.log* | ||
|
||
node_modules | ||
dist | ||
dist-ssr | ||
*.local | ||
|
||
# Editor directories and files | ||
.vscode/* | ||
!.vscode/extensions.json | ||
.idea | ||
.DS_Store | ||
*.suo | ||
*.ntvs* | ||
*.njsproj | ||
*.sln | ||
*.sw? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
|
||
# React Portfolio | ||
|
||
I'm using React to build my very own portfolio website. | ||
|
||
## Dependency Installation & Startup Development Server | ||
|
||
This project uses npm (Node Package Manager) to handle its dependencies and run the development server. | ||
|
||
```bash | ||
npm i && code . && npm run dev | ||
``` | ||
|
||
Comment on lines
+6
to
+13
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Improve setup instructions for better clarity and reliability. The current setup command combines multiple operations which might fail silently. Consider:
Example structure: ## Prerequisites
- Node.js (v16 or higher)
- npm (v8 or higher)
- VS Code (optional)
## Setup
1. Install dependencies:
```bash
npm install
|
||
### Project workflow | ||
I began by sketching the layout on paper, mapping out each element (like h2, body, sections, etc.) to visualize the structure. This approach helped me identify reusable components, such as the cards for articles and projects, which share elements like an image, h3, body, and buttons. It also made me notice that the design were missing an h1, and a paragraph tag styled to look like an h3. | ||
|
||
After completing the sketch, I focused on typography and global styling by setting up all the CSS variables. Once the foundation was in place, I began adding folders and empty components, and establishing the structure of the app. Finally, I added the code and styling for each component. | ||
|
||
### Problems | ||
**- Finding a good structure** | ||
I didn't want to start coding before that was set, as I find it hard to reorganize components and code later, especially when there are a lot of changes to make. Hopefully spending time on the structure will make the rest of the project run smoothly. | ||
|
||
**- Creating the components and structure first** | ||
Since I started by setting up the entire structure of folders and components before adding any code, I found that I needed to create a lot of code at once just to be able to see any content in the app. Most components and CSS files were empty which made other components render without styles or not appear as intended. Some components couldn’t find the files they were trying to import (e.g., Typography, Footer, etc.) due to incorrect file paths. I needed to add some basic styling for each component, some basic code for each component etc. The paths were tricky to set right, and I mixed up some names like using FooterSection when the component was actually named Footer. | ||
|
||
**- The design** | ||
I made some adjustments to the structure. The original design was missing an h1 but included two different font sizes for h2, so I used h1 for the largest text. In the Skills section, the design used two text/paragraph tags with different font sizes, and the larger one matched the h3 style, so I used h3 for consistency. | ||
|
||
**- Passing content** | ||
I used a mix of children and explicit props for passing content, so I couldn't see some sections in my app. Went for explicit props since I couldn't really grasp how children actually work. | ||
|
||
**- Overriding the Global styling** | ||
In a couple of places the different heading tags had different styling. One example is the Date in the ArticleSection, which had heading h3 but font size 1.125rem, and I solved that issue by changing the h3 to a paragraph. | ||
|
||
**- Time** | ||
I would have needed another week to complete this project. Time was really an issue this week, yet I spent over 20 hours on the course, made a plan, and kept a good pace, and had a lot of help from the components templates we did on the lab, and used ChatGPT to solve issues when I got stuck. | ||
|
||
**- Deploying to Netlify** | ||
During deployment to Netlify, I encountered several build errors caused by the file paths, even though the paths appeared to be correct and they worked locally. Even Git reported that everything was up to date when I tried to rewrite the imports. In some cases, I had to rename the components to make it work. | ||
|
||
### If I had more time | ||
1. For the card effect, I found this [CodePen](https://codepen.io/william-goldsworthy/pen/JzVajj) and modified it in [My Code Pen](https://codepen.io/joheri1/pen/GRVxByV). If I had more time, I would apply this. | ||
|
||
2. I would create a component for the image in the Hero and Footer component. | ||
|
||
3. I would used a component for the cards in the CardSection component. | ||
|
||
4. I would create a component for Bio containing the profile image, header, body text, and the social icons/links. This component could then be used in both the Hero and Footer sections. I noticed this while working with the Footer, because I more or less were copying and pasting from the Hero section. | ||
|
||
5. I would use styled components! | ||
|
||
### A handful of useful sources in this project: | ||
- CodePen was used to test smaller design components, like the borders between the columns in the Skills text section I found this [Code Pen](https://codepen.io/brendanfalkowski/pen/Mwrywj) and modified it in [My Code Pen](https://codepen.io/joheri1/pen/qBeKLVL). | ||
|
||
### View it live | ||
[Visit My Portfolio](https://johanna-eriksson-portfolio.netlify.app/) | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
import js from '@eslint/js' | ||
import globals from 'globals' | ||
import react from 'eslint-plugin-react' | ||
import reactHooks from 'eslint-plugin-react-hooks' | ||
import reactRefresh from 'eslint-plugin-react-refresh' | ||
|
||
export default [ | ||
{ ignores: ['dist'] }, | ||
{ | ||
files: ['**/*.{js,jsx}'], | ||
languageOptions: { | ||
ecmaVersion: 2020, | ||
globals: globals.browser, | ||
parserOptions: { | ||
ecmaVersion: 'latest', | ||
ecmaFeatures: { jsx: true }, | ||
sourceType: 'module', | ||
}, | ||
}, | ||
settings: { react: { version: '18.3' } }, | ||
plugins: { | ||
react, | ||
'react-hooks': reactHooks, | ||
'react-refresh': reactRefresh, | ||
}, | ||
rules: { | ||
...js.configs.recommended.rules, | ||
...react.configs.recommended.rules, | ||
...react.configs['jsx-runtime'].rules, | ||
...reactHooks.configs.recommended.rules, | ||
'react/jsx-no-target-blank': 'off', | ||
'react-refresh/only-export-components': [ | ||
'warn', | ||
{ allowConstantExport: true }, | ||
], | ||
}, | ||
}, | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<!doctype html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<link rel="icon" type="image/svg+xml" href="/vite.svg" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
<title>Johannas Portfolio</title> | ||
<!-- Link to Google Fonts --> | ||
<link href="https://fonts.googleapis.com/css2?family=Urbanist:wght@400;500;700&family=Poppins:wght@400;500;700&display=swap" rel="stylesheet"> | ||
</head> | ||
<body> | ||
<div id="root"></div> | ||
<script type="module" src="/src/main.jsx"></script> | ||
</body> | ||
</html> |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very good comments in the readme file! I really feel the struggle and I can relate to most of the problems regarding this project week. It is also good to have when looking back on what you have created and learned. 🌟