Skip to content

Commit 0d9c3ab

Browse files
authoredJun 27, 2023
Add files via upload
1 parent ca6d674 commit 0d9c3ab

6 files changed

+296
-59
lines changed
 

‎.gitignore

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Avoid accidental upload of the Sketch and Figma design files
2+
#####################################################
3+
## Please do not remove lines 5 and 6 - thanks! 🙂 ##
4+
#####################################################
5+
*.sketch
6+
*.fig
7+
8+
# Avoid accidental XD upload if you convert the design file
9+
###############################################
10+
## Please do not remove line 12 - thanks! 🙂 ##
11+
###############################################
12+
*.xd
13+
14+
# Avoid your project being littered with annoying .DS_Store files!
15+
.DS_Store
16+
.prettierignore

‎README-template.md

+103
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,103 @@
1+
# Frontend Mentor - QR code component solution
2+
3+
This is a solution to the [QR code component challenge on Frontend Mentor](https://www.frontendmentor.io/challenges/qr-code-component-iux_sIO_H). Frontend Mentor challenges help you improve your coding skills by building realistic projects.
4+
5+
## Table of contents
6+
7+
- [Overview](#overview)
8+
- [Screenshot](#screenshot)
9+
- [Links](#links)
10+
- [My process](#my-process)
11+
- [Built with](#built-with)
12+
- [What I learned](#what-i-learned)
13+
- [Continued development](#continued-development)
14+
- [Useful resources](#useful-resources)
15+
- [Author](#author)
16+
- [Acknowledgments](#acknowledgments)
17+
18+
**Note: Delete this note and update the table of contents based on what sections you keep.**
19+
20+
## Overview
21+
22+
### Screenshot
23+
24+
![](./screenshot.jpg)
25+
26+
Add a screenshot of your solution. The easiest way to do this is to use Firefox to view your project, right-click the page and select "Take a Screenshot". You can choose either a full-height screenshot or a cropped one based on how long the page is. If it's very long, it might be best to crop it.
27+
28+
Alternatively, you can use a tool like [FireShot](https://getfireshot.com/) to take the screenshot. FireShot has a free option, so you don't need to purchase it.
29+
30+
Then crop/optimize/edit your image however you like, add it to your project, and update the file path in the image above.
31+
32+
**Note: Delete this note and the paragraphs above when you add your screenshot. If you prefer not to add a screenshot, feel free to remove this entire section.**
33+
34+
### Links
35+
36+
- Solution URL: [Add solution URL here](https://your-solution-url.com)
37+
- Live Site URL: [Add live site URL here](https://your-live-site-url.com)
38+
39+
## My process
40+
41+
### Built with
42+
43+
- Semantic HTML5 markup
44+
- CSS custom properties
45+
- Flexbox
46+
- CSS Grid
47+
- Mobile-first workflow
48+
- [React](https://reactjs.org/) - JS library
49+
- [Next.js](https://nextjs.org/) - React framework
50+
- [Styled Components](https://styled-components.com/) - For styles
51+
52+
**Note: These are just examples. Delete this note and replace the list above with your own choices**
53+
54+
### What I learned
55+
56+
Use this section to recap over some of your major learnings while working through this project. Writing these out and providing code samples of areas you want to highlight is a great way to reinforce your own knowledge.
57+
58+
To see how you can add code snippets, see below:
59+
60+
```html
61+
<h1>Some HTML code I'm proud of</h1>
62+
```
63+
```css
64+
.proud-of-this-css {
65+
color: papayawhip;
66+
}
67+
```
68+
```js
69+
const proudOfThisFunc = () => {
70+
console.log('🎉')
71+
}
72+
```
73+
74+
If you want more help with writing markdown, we'd recommend checking out [The Markdown Guide](https://www.markdownguide.org/) to learn more.
75+
76+
**Note: Delete this note and the content within this section and replace with your own learnings.**
77+
78+
### Continued development
79+
80+
Use this section to outline areas that you want to continue focusing on in future projects. These could be concepts you're still not completely comfortable with or techniques you found useful that you want to refine and perfect.
81+
82+
**Note: Delete this note and the content within this section and replace with your own plans for continued development.**
83+
84+
### Useful resources
85+
86+
- [Example resource 1](https://www.example.com) - This helped me for XYZ reason. I really liked this pattern and will use it going forward.
87+
- [Example resource 2](https://www.example.com) - This is an amazing article which helped me finally understand XYZ. I'd recommend it to anyone still learning this concept.
88+
89+
**Note: Delete this note and replace the list above with resources that helped you during the challenge. These could come in handy for anyone viewing your solution or for yourself when you look back on this project in the future.**
90+
91+
## Author
92+
93+
- Website - [Add your name here](https://www.your-site.com)
94+
- Frontend Mentor - [@yourusername](https://www.frontendmentor.io/profile/yourusername)
95+
- Twitter - [@yourusername](https://www.twitter.com/yourusername)
96+
97+
**Note: Delete this note and add/remove/edit lines above based on what links you'd like to share.**
98+
99+
## Acknowledgments
100+
101+
This is where you can give a hat tip to anyone who helped you out on this project. Perhaps you worked in a team or got some inspiration from someone else's solution. This is the perfect place to give them some credit.
102+
103+
**Note: Delete this note and edit this section's content as necessary. If you completed this challenge by yourself, feel free to delete this section entirely.**

‎README.md

+67-59
Original file line numberDiff line numberDiff line change
@@ -1,79 +1,87 @@
1-
# Frontend Mentor - QR code component solution
1+
# Frontend Mentor - QR code component
22

3-
This is a solution to the [QR code component challenge on Frontend Mentor](https://www.frontendmentor.io/challenges/qr-code-component-iux_sIO_H). Frontend Mentor challenges help you improve your coding skills by building realistic projects.
3+
![Design preview for the QR code component coding challenge](./design/desktop-preview.jpg)
44

5-
## Table of contents
5+
## Welcome! 👋
66

7-
- [Overview](#overview)
8-
- [Screenshot](#screenshot)
9-
- [Links](#links)
10-
- [My process](#my-process)
11-
- [Built with](#built-with)
12-
- [What I learned](#what-i-learned)
13-
- [Continued development](#continued-development)
14-
- [Useful resources](#useful-resources)
15-
- [Author](#author)
16-
- [Acknowledgments](#acknowledgments)
7+
Thanks for checking out this front-end coding challenge.
178

9+
[Frontend Mentor](https://www.frontendmentor.io) challenges help you improve your coding skills by building realistic projects.
1810

19-
## Overview
11+
**To do this challenge, you need a basic understanding of HTML and CSS.**
2012

21-
### Screenshot
13+
## The challenge
2214

23-
![](image.png), ![](image-1.png)
15+
Your challenge is to build out this QR code component and get it looking as close to the design as possible.
2416

17+
You can use any tools you like to help you complete the challenge. So if you've got something you'd like to practice, feel free to give it a go.
2518

26-
### Links
19+
Want some support on the challenge? [Join our Slack community](https://www.frontendmentor.io/slack) and ask questions in the **#help** channel.
2720

28-
- Live Site URL: [Add live site URL here](https://github.com/Egbe-Fred/qr-code-component-main-HTML-and-CSS)
21+
## Where to find everything
2922

30-
## My process
31-
The process was educating and I most say i learnt a lot while trying to build it the most important takeaway lesson was centering a <div> which was difficult to approached at first but with the help of Stark-Overflow and Google at the end of the day it was win win.
32-
### Built with
23+
Your task is to build out the project to the designs inside the `/design` folder. You will find both a mobile and a desktop version of the design.
3324

34-
- Semantic HTML5 markup
35-
- CSS custom properties
36-
- CSS Grid
37-
- CSS Flex
25+
The designs are in JPG static format. Using JPGs will mean that you'll need to use your best judgment for styles such as `font-size`, `padding` and `margin`.
3826

39-
### What I learned
40-
I learnt how to center a div using the CSS grid. also the importance of a well structured HTML.
27+
If you would like the design files (we provide Sketch & Figma versions) to inspect the design in more detail, you can [subscribe as a PRO member](https://www.frontendmentor.io/pro).
4128

42-
Use this section to recap over some of your major learnings while working through this project. Writing these out and providing code samples of areas you want to highlight is a great way to reinforce your own knowledge.
29+
You will find all the required assets in the `/images` folder. The assets are already optimized.
4330

44-
To see how you can add code snippets, see below:
31+
There is also a `style-guide.md` file containing the information you'll need, such as color palette and fonts.
4532

46-
```html
47-
this was the structure of my HTML
48-
<div class="background">
49-
<div class="card">
50-
<div class="codescan"></div>
51-
<div class="typo-div">
52-
<h3>Improve your front-end skills by building projects</h3>
53-
<p> Scan the QR code to visit Frontend Mentor and take your coding skills to the next level</p>
54-
</div>
55-
</div>
56-
</div>
57-
````
33+
## Building your project
5834

35+
Feel free to use any workflow that you feel comfortable with. Below is a suggested process, but do not feel like you need to follow these steps:
5936

37+
1. Initialize your project as a public repository on [GitHub](https://github.com/). Creating a repo will make it easier to share your code with the community if you need help. If you're not sure how to do this, [have a read-through of this Try Git resource](https://try.github.io/).
38+
2. Configure your repository to publish your code to a web address. This will also be useful if you need some help during a challenge as you can share the URL for your project with your repo URL. There are a number of ways to do this, and we provide some recommendations below.
39+
3. Look through the designs to start planning out how you'll tackle the project. This step is crucial to help you think ahead for CSS classes to create reusable styles.
40+
4. Before adding any styles, structure your content with HTML. Writing your HTML first can help focus your attention on creating well-structured content.
41+
5. Write out the base styles for your project, including general content styles, such as `font-family` and `font-size`.
42+
6. Start adding styles to the top of the page and work down. Only move on to the next section once you're happy you've completed the area you're working on.
6043

61-
```css
62-
.background {
63-
display: grid;
64-
place-items: center;
65-
margin: 0 auto;
66-
}
44+
## Deploying your project
6745

68-
.card {
69-
display: flex;
70-
flex-direction: column;
71-
background-color: hsl(0, 0%, 100%);
72-
border-radius: 6%;
73-
min-height: 350px;
74-
width: 235px;
75-
padding: 15px;
76-
margin: 100px 0;
77-
box-shadow: 30px;
78-
}
79-
```
46+
As mentioned above, there are many ways to host your project for free. Our recommend hosts are:
47+
48+
- [GitHub Pages](https://pages.github.com/)
49+
- [Vercel](https://vercel.com/)
50+
- [Netlify](https://www.netlify.com/)
51+
52+
You can host your site using one of these solutions or any of our other trusted providers. [Read more about our recommended and trusted hosts](https://medium.com/frontend-mentor/frontend-mentor-trusted-hosting-providers-bf000dfebe).
53+
54+
## Create a custom `README.md`
55+
56+
We strongly recommend overwriting this `README.md` with a custom one. We've provided a template inside the [`README-template.md`](./README-template.md) file in this starter code.
57+
58+
The template provides a guide for what to add. A custom `README` will help you explain your project and reflect on your learnings. Please feel free to edit our template as much as you like.
59+
60+
Once you've added your information to the template, delete this file and rename the `README-template.md` file to `README.md`. That will make it show up as your repository's README file.
61+
62+
## Submitting your solution
63+
64+
Submit your solution on the platform for the rest of the community to see. Follow our ["Complete guide to submitting solutions"](https://medium.com/frontend-mentor/a-complete-guide-to-submitting-solutions-on-frontend-mentor-ac6384162248) for tips on how to do this.
65+
66+
Remember, if you're looking for feedback on your solution, be sure to ask questions when submitting it. The more specific and detailed you are with your questions, the higher the chance you'll get valuable feedback from the community.
67+
68+
## Sharing your solution
69+
70+
There are multiple places you can share your solution:
71+
72+
1. Share your solution page in the **#finished-projects** channel of the [Slack community](https://www.frontendmentor.io/slack).
73+
2. Tweet [@frontendmentor](https://twitter.com/frontendmentor) and mention **@frontendmentor**, including the repo and live URLs in the tweet. We'd love to take a look at what you've built and help share it around.
74+
3. Share your solution on other social channels like LinkedIn.
75+
4. Blog about your experience building your project. Writing about your workflow, technical choices, and talking through your code is a brilliant way to reinforce what you've learned. Great platforms to write on are [dev.to](https://dev.to/), [Hashnode](https://hashnode.com/), and [CodeNewbie](https://community.codenewbie.org/).
76+
77+
We provide templates to help you share your solution once you've submitted it on the platform. Please do edit them and include specific questions when you're looking for feedback.
78+
79+
The more specific you are with your questions the more likely it is that another member of the community will give you feedback.
80+
81+
## Got feedback for us?
82+
83+
We love receiving feedback! We're always looking to improve our challenges and our platform. So if you have anything you'd like to mention, please email hi[at]frontendmentor[dot]io.
84+
85+
This challenge is completely free. Please share it with anyone who will find it useful for practice.
86+
87+
**Have fun building!** 🚀

‎index.html

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8">
5+
<meta name="viewport" content="width=device-width, initial-scale=1.0"> <!-- displays site properly based on user's device -->
6+
7+
<link rel="icon" type="image/png" sizes="32x32" href="./images/favicon-32x32.png">
8+
9+
<title>QR code component</title>
10+
<link rel="stylesheet" href="./styles.css">
11+
12+
</head>
13+
<body>
14+
15+
<div id="wrapper" class="wrapper">
16+
<div id="inner" class="inner">
17+
<img src="./images/image-qr-code.png" id="img">
18+
</div>
19+
<h1>Improve your front-end skills by building projects</h1>
20+
<p>Scan this QR-code to visit Frontend Mentor and take your skills to next level</p>
21+
</div>
22+
23+
24+
25+
</body>
26+
</html>

‎style-guide.md

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# Front-end Style Guide
2+
3+
## Layout
4+
5+
The designs were created to the following widths:
6+
7+
- Mobile: 375px
8+
- Desktop: 1440px
9+
10+
## Colors
11+
12+
- White: hsl(0, 0%, 100%)
13+
- Light gray: hsl(212, 45%, 89%)
14+
- Grayish blue: hsl(220, 15%, 55%)
15+
- Dark blue: hsl(218, 44%, 22%)
16+
17+
## Typography
18+
19+
### Body Copy
20+
21+
- Font size (paragraph): 15px
22+
23+
### Font
24+
25+
- Family: [Outfit](https://fonts.google.com/specimen/Outfit)
26+
- Weights: 400, 700

‎styles.css

+58
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
@import url('https://fonts.googleapis.com/css2?family=Outfit&display=swap');
2+
3+
:root{
4+
--white: hsl(0, 0%, 100%);
5+
--light-gray: hsl(212, 45%, 89%);
6+
--grayish-blue: hsl(220, 15%, 55%);
7+
--dark-blue: hsl(218, 44%, 22%);
8+
}
9+
body {
10+
display: flex;
11+
justify-content: center;
12+
align-items: center;
13+
background-color: var(--light-gray);
14+
font-size: 15px;
15+
font-family: 'Outfit', sans-serif;
16+
font-weight: 400;
17+
height: 100%;
18+
19+
}
20+
21+
.wrapper {
22+
display: grid;
23+
grid-template-rows: auto auto auto;
24+
align-items: center;
25+
justify-content: center;
26+
width: 20%;
27+
height: 60%;
28+
text-align: center;
29+
background-color: var(--white);
30+
padding: 1%;
31+
margin-top: 10%;
32+
border-radius: 5%;
33+
}
34+
35+
#img {
36+
width: 90%;
37+
height: 80%;
38+
border-radius: 5%;
39+
margin: 1.5%;
40+
}
41+
42+
h1,
43+
p {
44+
padding: 3px;
45+
margin-bottom: 1%;
46+
47+
}
48+
h1{
49+
font-size:1.5rem;
50+
font-weight: 700;
51+
color: var(--dark-blue);
52+
}
53+
p{
54+
font-size: 0.9rem;
55+
color: var(--grayish-blue);
56+
}
57+
58+

0 commit comments

Comments
 (0)
Please sign in to comment.