├── Browser Tabs
├── .gitignore
├── README.md
├── package-lock.json
├── package.json
├── public
│ ├── index.html
│ ├── manifest.json
│ └── robots.txt
└── src
│ ├── App.css
│ ├── App.js
│ └── index.js
├── Cat Friends
├── .gitignore
├── README.md
├── package-lock.json
├── package.json
├── public
│ ├── index.html
│ ├── manifest.json
│ └── robots.txt
└── src
│ ├── SEGA.woff
│ ├── components
│ ├── Card.js
│ ├── CardList.js
│ ├── ErrorBoundary.js
│ ├── Scroll.js
│ └── SearchBox.js
│ ├── containers
│ └── App.js
│ ├── index.css
│ ├── index.js
│ └── robots.js
├── Markdown Editor
├── .gitignore
├── README.md
├── package-lock.json
├── package.json
├── public
│ ├── index.html
│ ├── manifest.json
│ └── robots.txt
└── src
│ ├── App.css
│ ├── App.js
│ └── index.js
├── Pomodoro Timer
├── .gitignore
├── README.md
├── package-lock.json
├── package.json
├── public
│ ├── index.html
│ ├── manifest.json
│ └── robots.txt
└── src
│ ├── App.css
│ ├── App.js
│ └── index.js
└── README.md
/Browser Tabs/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | /node_modules
5 | /.pnp
6 | .pnp.js
7 |
8 | # testing
9 | /coverage
10 |
11 | # production
12 | /build
13 |
14 | # misc
15 | .DS_Store
16 | .env.local
17 | .env.development.local
18 | .env.test.local
19 | .env.production.local
20 |
21 | npm-debug.log*
22 | yarn-debug.log*
23 | yarn-error.log*
24 |
--------------------------------------------------------------------------------
/Browser Tabs/README.md:
--------------------------------------------------------------------------------
1 | # Getting Started with Create React App
2 |
3 | This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app).
4 |
5 | ## Available Scripts
6 |
7 | In the project directory, you can run:
8 |
9 | ### `npm start`
10 |
11 | Runs the app in the development mode.\
12 | Open [http://localhost:3000](http://localhost:3000) to view it in the browser.
13 |
14 | The page will reload if you make edits.\
15 | You will also see any lint errors in the console.
16 |
17 | ### `npm test`
18 |
19 | Launches the test runner in the interactive watch mode.\
20 | See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.
21 |
22 | ### `npm run build`
23 |
24 | Builds the app for production to the `build` folder.\
25 | It correctly bundles React in production mode and optimizes the build for the best performance.
26 |
27 | The build is minified and the filenames include the hashes.\
28 | Your app is ready to be deployed!
29 |
30 | See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.
31 |
32 | ### `npm run eject`
33 |
34 | **Note: this is a one-way operation. Once you `eject`, you can’t go back!**
35 |
36 | If you aren’t satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project.
37 |
38 | Instead, it will copy all the configuration files and the transitive dependencies (webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you’re on your own.
39 |
40 | You don’t have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it.
41 |
42 | ## Learn More
43 |
44 | You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).
45 |
46 | To learn React, check out the [React documentation](https://reactjs.org/).
47 |
48 | ### Code Splitting
49 |
50 | This section has moved here: [https://facebook.github.io/create-react-app/docs/code-splitting](https://facebook.github.io/create-react-app/docs/code-splitting)
51 |
52 | ### Analyzing the Bundle Size
53 |
54 | This section has moved here: [https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size](https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size)
55 |
56 | ### Making a Progressive Web App
57 |
58 | This section has moved here: [https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app](https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app)
59 |
60 | ### Advanced Configuration
61 |
62 | This section has moved here: [https://facebook.github.io/create-react-app/docs/advanced-configuration](https://facebook.github.io/create-react-app/docs/advanced-configuration)
63 |
64 | ### Deployment
65 |
66 | This section has moved here: [https://facebook.github.io/create-react-app/docs/deployment](https://facebook.github.io/create-react-app/docs/deployment)
67 |
68 | ### `npm run build` fails to minify
69 |
70 | This section has moved here: [https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify](https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify)
71 |
--------------------------------------------------------------------------------
/Browser Tabs/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "browser-tabs",
3 | "version": "0.1.0",
4 | "private": true,
5 | "dependencies": {
6 | "@testing-library/jest-dom": "^5.11.10",
7 | "@testing-library/react": "^11.2.6",
8 | "@testing-library/user-event": "^12.8.3",
9 | "react": "^17.0.2",
10 | "react-dom": "^17.0.2",
11 | "react-scripts": "4.0.3",
12 | "web-vitals": "^1.1.1"
13 | },
14 | "scripts": {
15 | "start": "react-scripts start",
16 | "build": "react-scripts build",
17 | "test": "react-scripts test",
18 | "eject": "react-scripts eject"
19 | },
20 | "eslintConfig": {
21 | "extends": [
22 | "react-app",
23 | "react-app/jest"
24 | ]
25 | },
26 | "browserslist": {
27 | "production": [
28 | ">0.2%",
29 | "not dead",
30 | "not op_mini all"
31 | ],
32 | "development": [
33 | "last 1 chrome version",
34 | "last 1 firefox version",
35 | "last 1 safari version"
36 | ]
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/Browser Tabs/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
12 |
13 |
17 |
18 |
27 | React App
28 |
29 |
30 | You need to enable JavaScript to run this app.
31 |
32 |
42 |
43 |
44 |
--------------------------------------------------------------------------------
/Browser Tabs/public/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "short_name": "React App",
3 | "name": "Create React App Sample",
4 | "icons": [
5 | {
6 | "src": "favicon.ico",
7 | "sizes": "64x64 32x32 24x24 16x16",
8 | "type": "image/x-icon"
9 | },
10 | {
11 | "src": "logo192.png",
12 | "type": "image/png",
13 | "sizes": "192x192"
14 | },
15 | {
16 | "src": "logo512.png",
17 | "type": "image/png",
18 | "sizes": "512x512"
19 | }
20 | ],
21 | "start_url": ".",
22 | "display": "standalone",
23 | "theme_color": "#000000",
24 | "background_color": "#ffffff"
25 | }
26 |
--------------------------------------------------------------------------------
/Browser Tabs/public/robots.txt:
--------------------------------------------------------------------------------
1 | # https://www.robotstxt.org/robotstxt.html
2 | User-agent: *
3 | Disallow:
4 |
--------------------------------------------------------------------------------
/Browser Tabs/src/App.css:
--------------------------------------------------------------------------------
1 | * {
2 | box-sizing: border-box;
3 | }
4 |
5 | body {
6 | font-family: Arial, Helvetica, sans-serif;
7 | font-size: 19px;
8 | margin: 0;
9 | padding: 0;
10 | }
11 |
12 | .app {
13 | display: flex;
14 | align-items: center;
15 | justify-content: center;
16 | background: #634cec;
17 | min-height: 100vh;
18 | }
19 |
20 | .browser {
21 | display: flex;
22 | flex-direction: column;
23 | background: #ffb91f;
24 | border-radius: 5px;
25 | box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
26 | min-width: 60%;
27 | min-height: 50vh;
28 | }
29 |
30 | .tabs {
31 | flex-shrink: 1;
32 | padding-left: 10px;
33 | padding-right: 10px;
34 | display: flex;
35 | padding-top: 10px;
36 | }
37 |
38 | .tab {
39 | position: relative;
40 | background: #6e45df;
41 | min-width: 120px;
42 | font-size: 14px;
43 | border-top-left-radius: 8px;
44 | border-top-right-radius: 8px;
45 | transition: 0.3s ease all;
46 | overflow: hidden;
47 | cursor: pointer;
48 | }
49 |
50 | .tab a {
51 | display: block;
52 | padding: 12px 25px;
53 | color: #e1daf5;
54 | text-decoration: none;
55 | }
56 |
57 | .tab a.is-active {
58 | background: #5131a9;
59 | color: #eee;
60 | }
61 |
62 | .address-bar {
63 | background: #5533b3;
64 | padding: 8px;
65 | }
66 |
67 | .address-bar input {
68 | background: #3a2081;
69 | color: #eee;
70 | border-radius: 20px;
71 | border: none;
72 | outline: none;
73 | width: 100%;
74 | padding: 8px 20px;
75 | font-size: 18px;
76 | }
77 |
78 | .viewport {
79 | display: flex;
80 | align-items: center;
81 | justify-content: center;
82 | background: #5131a9;
83 | color: #dacff7;
84 | flex: 1;
85 | flex-grow: 1;
86 | border-bottom-left-radius: 5px;
87 | border-bottom-right-radius: 5px;
88 | }
89 |
90 | /**
91 | * Add your highlight code here
92 | */
--------------------------------------------------------------------------------
/Browser Tabs/src/App.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import './App.css';
3 |
4 | function App() {
5 | return (
6 |
7 |
8 |
19 |
20 |
Pages Go Here
21 |
22 |
23 | );
24 | }
25 |
26 | export default App;
--------------------------------------------------------------------------------
/Browser Tabs/src/index.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom';
3 | import App from './App';
4 |
5 | ReactDOM.render(
6 |
7 |
8 | ,
9 | document.getElementById('root')
10 | );
--------------------------------------------------------------------------------
/Cat Friends/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | /node_modules
5 | /.pnp
6 | .pnp.js
7 |
8 | # testing
9 | /coverage
10 |
11 | # production
12 | /build
13 |
14 | # misc
15 | .DS_Store
16 | .env.local
17 | .env.development.local
18 | .env.test.local
19 | .env.production.local
20 |
21 | npm-debug.log*
22 | yarn-debug.log*
23 | yarn-error.log*
24 |
--------------------------------------------------------------------------------
/Cat Friends/README.md:
--------------------------------------------------------------------------------
1 | # Getting Started with Create React App
2 |
3 | This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app).
4 |
5 | ## Available Scripts
6 |
7 | In the project directory, you can run:
8 |
9 | ### `npm start`
10 |
11 | Runs the app in the development mode.\
12 | Open [http://localhost:3000](http://localhost:3000) to view it in the browser.
13 |
14 | The page will reload if you make edits.\
15 | You will also see any lint errors in the console.
16 |
17 | ### `npm test`
18 |
19 | Launches the test runner in the interactive watch mode.\
20 | See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.
21 |
22 | ### `npm run build`
23 |
24 | Builds the app for production to the `build` folder.\
25 | It correctly bundles React in production mode and optimizes the build for the best performance.
26 |
27 | The build is minified and the filenames include the hashes.\
28 | Your app is ready to be deployed!
29 |
30 | See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.
31 |
32 | ### `npm run eject`
33 |
34 | **Note: this is a one-way operation. Once you `eject`, you can’t go back!**
35 |
36 | If you aren’t satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project.
37 |
38 | Instead, it will copy all the configuration files and the transitive dependencies (webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you’re on your own.
39 |
40 | You don’t have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it.
41 |
42 | ## Learn More
43 |
44 | You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).
45 |
46 | To learn React, check out the [React documentation](https://reactjs.org/).
47 |
48 | ### Code Splitting
49 |
50 | This section has moved here: [https://facebook.github.io/create-react-app/docs/code-splitting](https://facebook.github.io/create-react-app/docs/code-splitting)
51 |
52 | ### Analyzing the Bundle Size
53 |
54 | This section has moved here: [https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size](https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size)
55 |
56 | ### Making a Progressive Web App
57 |
58 | This section has moved here: [https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app](https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app)
59 |
60 | ### Advanced Configuration
61 |
62 | This section has moved here: [https://facebook.github.io/create-react-app/docs/advanced-configuration](https://facebook.github.io/create-react-app/docs/advanced-configuration)
63 |
64 | ### Deployment
65 |
66 | This section has moved here: [https://facebook.github.io/create-react-app/docs/deployment](https://facebook.github.io/create-react-app/docs/deployment)
67 |
68 | ### `npm run build` fails to minify
69 |
70 | This section has moved here: [https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify](https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify)
71 |
--------------------------------------------------------------------------------
/Cat Friends/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "robofriends",
3 | "version": "0.1.0",
4 | "private": true,
5 | "dependencies": {
6 | "@testing-library/jest-dom": "^5.12.0",
7 | "@testing-library/react": "^11.2.7",
8 | "@testing-library/user-event": "^12.8.3",
9 | "react": "^17.0.2",
10 | "react-dom": "^17.0.2",
11 | "react-scripts": "4.0.3",
12 | "tachyons": "^4.12.0",
13 | "web-vitals": "^1.1.2"
14 | },
15 | "scripts": {
16 | "start": "react-scripts start",
17 | "build": "react-scripts build",
18 | "test": "react-scripts test",
19 | "eject": "react-scripts eject"
20 | },
21 | "eslintConfig": {
22 | "extends": [
23 | "react-app",
24 | "react-app/jest"
25 | ]
26 | },
27 | "browserslist": {
28 | "production": [
29 | ">0.2%",
30 | "not dead",
31 | "not op_mini all"
32 | ],
33 | "development": [
34 | "last 1 chrome version",
35 | "last 1 firefox version",
36 | "last 1 safari version"
37 | ]
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/Cat Friends/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
12 |
13 |
17 |
18 | Cat Friends
19 |
20 |
21 | You need to enable JavaScript to run this app.
22 |
23 |
24 |
25 |
--------------------------------------------------------------------------------
/Cat Friends/public/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "short_name": "React App",
3 | "name": "Create React App Sample",
4 | "icons": [
5 | {
6 | "src": "favicon.ico",
7 | "sizes": "64x64 32x32 24x24 16x16",
8 | "type": "image/x-icon"
9 | },
10 | {
11 | "src": "logo192.png",
12 | "type": "image/png",
13 | "sizes": "192x192"
14 | },
15 | {
16 | "src": "logo512.png",
17 | "type": "image/png",
18 | "sizes": "512x512"
19 | }
20 | ],
21 | "start_url": ".",
22 | "display": "standalone",
23 | "theme_color": "#000000",
24 | "background_color": "#ffffff"
25 | }
26 |
--------------------------------------------------------------------------------
/Cat Friends/public/robots.txt:
--------------------------------------------------------------------------------
1 | # https://www.robotstxt.org/robotstxt.html
2 | User-agent: *
3 | Disallow:
4 |
--------------------------------------------------------------------------------
/Cat Friends/src/SEGA.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mindninjaX/React-Projects-for-Beginners/76e7afb378130e9c2780165e81a22704be8ba3e4/Cat Friends/src/SEGA.woff
--------------------------------------------------------------------------------
/Cat Friends/src/components/Card.js:
--------------------------------------------------------------------------------
1 | import React from "react";
2 |
3 | const Card = ({ id, name, email }) => {
4 | return (
5 |
6 |
7 |
8 |
{name}
9 |
{email}
10 |
11 |
12 | );
13 | };
14 |
15 | export default Card;
16 |
--------------------------------------------------------------------------------
/Cat Friends/src/components/CardList.js:
--------------------------------------------------------------------------------
1 | import React from "react";
2 | import Card from "./Card";
3 |
4 | const CardList = ({ robots }) => {
5 | // if (true) {
6 | // throw new Error("NOOOOO!");
7 | // }
8 | return (
9 |
10 | {robots.map((user, i) => {
11 | return (
12 |
18 | );
19 | })}
20 |
21 | );
22 | };
23 |
24 | export default CardList;
25 |
--------------------------------------------------------------------------------
/Cat Friends/src/components/ErrorBoundary.js:
--------------------------------------------------------------------------------
1 | import React, { Component } from "react";
2 |
3 | class ErrorBoundary extends Component {
4 | constructor(props) {
5 | super(props);
6 | this.state = {
7 | hasError: false,
8 | };
9 | }
10 |
11 | componentDidCatch(error, info) {
12 | this.setState({ hasError: true });
13 | }
14 |
15 | render() {
16 | if (this.state.hasError) {
17 | return Ooopss... ;
18 | }
19 | return this.props.children;
20 | }
21 | }
22 |
23 | export default ErrorBoundary;
24 |
--------------------------------------------------------------------------------
/Cat Friends/src/components/Scroll.js:
--------------------------------------------------------------------------------
1 | import React from "react";
2 |
3 | const Scroll = (props) => {
4 | return (
5 |
12 | {props.children}
13 |
14 | );
15 | };
16 |
17 | export default Scroll;
18 |
--------------------------------------------------------------------------------
/Cat Friends/src/components/SearchBox.js:
--------------------------------------------------------------------------------
1 | import React from "react";
2 |
3 | const SearchBox = ({ filteredRobots, searchChange }) => {
4 | return (
5 |
6 |
12 |
13 | );
14 | };
15 |
16 | export default SearchBox;
17 |
--------------------------------------------------------------------------------
/Cat Friends/src/containers/App.js:
--------------------------------------------------------------------------------
1 | import React, { useState, useEffect } from "react";
2 | import CardList from "../components/CardList";
3 | import SearchBox from "../components/SearchBox";
4 | import Scroll from "../components/Scroll";
5 |
6 | const App = () => {
7 | const [robots, setRobots] = useState([]);
8 | const [searchfield, setSearchfield] = useState("");
9 |
10 | useEffect(() => {
11 | fetch("https://jsonplaceholder.typicode.com/users")
12 | .then((response) => response.json())
13 | .then((users) => setRobots(users));
14 | });
15 |
16 | const onSearchChange = (event) => {
17 | setSearchfield(event.target.value);
18 | };
19 |
20 | const filteredRobots = robots.filter((robots) => {
21 | return robots.name.toLowerCase().includes(searchfield.toLowerCase());
22 | });
23 | if (!robots.length) {
24 | return Loading... ;
25 | }
26 |
27 | return (
28 |
29 |
CatFriends
30 |
31 |
32 |
33 |
34 |
35 | );
36 | };
37 |
38 | export default App;
39 |
--------------------------------------------------------------------------------
/Cat Friends/src/index.css:
--------------------------------------------------------------------------------
1 | @font-face {
2 | font-family: 'SEGA LOGO FONT';
3 | font-style: normal;
4 | font-weight: normal;
5 | src: local('SEGA LOGO FONT'), url('./SEGA.woff') format('woff');
6 | }
7 |
8 | body {
9 | margin: 0;
10 | padding: 0;
11 | font-family: sans-serif;
12 | background: linear-gradient(
13 | to left,
14 | rgba(7, 27, 82, 1) 0%,
15 | rgba(0, 128, 128, 1) 100%
16 | );
17 | }
18 |
19 | h1 {
20 | font-family: "SEGA LOGO FONT";
21 | font-weight: 200;
22 | color: #0ccac4;
23 | }
24 |
--------------------------------------------------------------------------------
/Cat Friends/src/index.js:
--------------------------------------------------------------------------------
1 | import React from "react";
2 | import ReactDOM from "react-dom";
3 | import App from './containers/App'
4 | import "tachyons";
5 | import './index.css'
6 |
7 | ReactDOM.render(
8 |
9 |
10 | ,
11 | document.getElementById("root")
12 | );
13 |
--------------------------------------------------------------------------------
/Cat Friends/src/robots.js:
--------------------------------------------------------------------------------
1 | export const robots = [
2 | {
3 | id: 1,
4 | name: "Leanne Graham",
5 | username: "Bret",
6 | email: "Sincere@april.biz",
7 | },
8 | {
9 | id: 2,
10 | name: "Ervin Howell",
11 | username: "Antonette",
12 | email: "Shanna@melissa.tv",
13 | },
14 | {
15 | id: 3,
16 | name: "Clementine Bauch",
17 | username: "Samantha",
18 | email: "Nathan@yesenia.net",
19 | },
20 | {
21 | id: 4,
22 | name: "Patricia Lebsack",
23 | username: "Karianne",
24 | email: "Julianne.OConner@kory.org",
25 | },
26 | {
27 | id: 5,
28 | name: "Chelsey Dietrich",
29 | username: "Kamren",
30 | email: "Lucio_Hettinger@annie.ca",
31 | },
32 | {
33 | id: 6,
34 | name: "Mrs. Dennis Schulist",
35 | username: "Leopoldo_Corkery",
36 | email: "Karley_Dach@jasper.info",
37 | },
38 | {
39 | id: 7,
40 | name: "Kurtis Weissnat",
41 | username: "Elwyn.Skiles",
42 | email: "Telly.Hoeger@billy.biz",
43 | },
44 | {
45 | id: 8,
46 | name: "Nicholas Runolfsdottir V",
47 | username: "Maxime_Nienow",
48 | email: "Sherwood@rosamond.me",
49 | },
50 | {
51 | id: 9,
52 | name: "Glenna Reichert",
53 | username: "Delphine",
54 | email: "Chaim_McDermott@dana.io",
55 | },
56 | {
57 | id: 10,
58 | name: "Clementina DuBuque",
59 | username: "Moriah.Stanton",
60 | email: "Rey.Padberg@karina.biz",
61 | },
62 | ];
63 |
--------------------------------------------------------------------------------
/Markdown Editor/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | /node_modules
5 | /.pnp
6 | .pnp.js
7 |
8 | # testing
9 | /coverage
10 |
11 | # production
12 | /build
13 |
14 | # misc
15 | .DS_Store
16 | .env.local
17 | .env.development.local
18 | .env.test.local
19 | .env.production.local
20 |
21 | npm-debug.log*
22 | yarn-debug.log*
23 | yarn-error.log*
24 |
--------------------------------------------------------------------------------
/Markdown Editor/README.md:
--------------------------------------------------------------------------------
1 | ## Markdown Editor
2 |
3 | [View Demo](https://markdown-editor-mindninjax.netlify.app/) | [Source Code](https://github.com/mindninjaX/React-Projects-for-Beginners)
4 |
5 | [](https://learn.chrisoncode.io/courses/10-react-apps-series-a/348621-02-markdown-editor/992079-00-markdown-editor-preview)
6 |
7 | ### React skills used in this app
8 |
9 | - React state with useState()
10 | - 3rd Party Packages
--------------------------------------------------------------------------------
/Markdown Editor/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "markdown-editor",
3 | "version": "0.1.0",
4 | "private": true,
5 | "dependencies": {
6 | "@testing-library/jest-dom": "^5.11.10",
7 | "@testing-library/react": "^11.2.6",
8 | "@testing-library/user-event": "^12.8.3",
9 | "react": "^17.0.2",
10 | "react-dom": "^17.0.2",
11 | "react-markdown": "^5.0.3",
12 | "react-scripts": "4.0.3",
13 | "web-vitals": "^1.1.1"
14 | },
15 | "scripts": {
16 | "start": "react-scripts start",
17 | "build": "react-scripts build",
18 | "test": "react-scripts test",
19 | "eject": "react-scripts eject"
20 | },
21 | "eslintConfig": {
22 | "extends": [
23 | "react-app",
24 | "react-app/jest"
25 | ]
26 | },
27 | "browserslist": {
28 | "production": [
29 | ">0.2%",
30 | "not dead",
31 | "not op_mini all"
32 | ],
33 | "development": [
34 | "last 1 chrome version",
35 | "last 1 firefox version",
36 | "last 1 safari version"
37 | ]
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/Markdown Editor/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
12 |
13 |
17 |
18 |
27 | React App
28 |
29 |
30 | You need to enable JavaScript to run this app.
31 |
32 |
42 |
43 |
44 |
--------------------------------------------------------------------------------
/Markdown Editor/public/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "short_name": "React App",
3 | "name": "Create React App Sample",
4 | "icons": [
5 | {
6 | "src": "favicon.ico",
7 | "sizes": "64x64 32x32 24x24 16x16",
8 | "type": "image/x-icon"
9 | },
10 | {
11 | "src": "logo192.png",
12 | "type": "image/png",
13 | "sizes": "192x192"
14 | },
15 | {
16 | "src": "logo512.png",
17 | "type": "image/png",
18 | "sizes": "512x512"
19 | }
20 | ],
21 | "start_url": ".",
22 | "display": "standalone",
23 | "theme_color": "#000000",
24 | "background_color": "#ffffff"
25 | }
26 |
--------------------------------------------------------------------------------
/Markdown Editor/public/robots.txt:
--------------------------------------------------------------------------------
1 | # https://www.robotstxt.org/robotstxt.html
2 | User-agent: *
3 | Disallow:
4 |
--------------------------------------------------------------------------------
/Markdown Editor/src/App.css:
--------------------------------------------------------------------------------
1 | @import url('https://fonts.googleapis.com/css2?family=Hind&display=swap');
2 |
3 | body {
4 | background: #e8eaf1;
5 | font-family: 'Hind', Arial, Helvetica, sans-serif;
6 | }
7 |
8 | .app {
9 | min-height: 100vh;
10 | display: grid;
11 | grid-template-columns: 1fr 1fr;
12 | grid-gap: 15px;
13 | }
14 |
15 | textarea {
16 | background: #eff1f5;
17 | box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
18 | outline: none;
19 | border: none;
20 | border-radius: 5px;
21 | padding: 20px;
22 | font-size: 22px;
23 | }
24 |
25 | .preview {
26 | padding-left: 20px;
27 | padding-right: 20px;
28 | }
29 |
30 | blockquote {
31 | font-size: 30px;
32 | background: #efefef;
33 | border-left: 12px solid rgb(44, 163, 241);
34 | padding: 20px 30px;
35 | border-radius: 5px;
36 | margin: 0;
37 | }
--------------------------------------------------------------------------------
/Markdown Editor/src/App.js:
--------------------------------------------------------------------------------
1 | import React, { useState } from "react";
2 | import ReactMarkdown from "react-markdown";
3 | import "./App.css";
4 |
5 | export default function App() {
6 | const [markdown, setMarkdown] = useState("");
7 |
8 | function handleChange(e) {
9 | setMarkdown(e.target.value);
10 | }
11 |
12 | return (
13 |
14 |
15 |
16 |
17 |
18 | );
19 | }
20 |
--------------------------------------------------------------------------------
/Markdown Editor/src/index.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom';
3 | import App from './App';
4 |
5 | ReactDOM.render(
6 |
7 |
8 | ,
9 | document.getElementById('root')
10 | );
--------------------------------------------------------------------------------
/Pomodoro Timer/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | /node_modules
5 | /.pnp
6 | .pnp.js
7 |
8 | # testing
9 | /coverage
10 |
11 | # production
12 | /build
13 |
14 | # misc
15 | .DS_Store
16 | .env.local
17 | .env.development.local
18 | .env.test.local
19 | .env.production.local
20 |
21 | npm-debug.log*
22 | yarn-debug.log*
23 | yarn-error.log*
24 |
--------------------------------------------------------------------------------
/Pomodoro Timer/README.md:
--------------------------------------------------------------------------------
1 | ## Pomodoro Timer
2 |
3 | [View Demo](https://pomodoro-timer-mindninjax.netlify.app/) | [Source Code](https://github.com/mindninjaX/React-Projects-for-Beginners)
4 |
5 |
6 | [](https://learn.chrisoncode.io/courses/10-react-apps-series-a/348620-01-pomodoro/992082-00-pomodoro-preview)
7 |
8 | ### React skills used in this app
9 |
10 | - Creating timers
11 | - React state w/ useState()
12 | - React effects w/ useEffect()
13 | - React refs w/ useRef()
14 | - Parent and child components
--------------------------------------------------------------------------------
/Pomodoro Timer/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "pomodoro-timer",
3 | "version": "0.1.0",
4 | "private": true,
5 | "dependencies": {
6 | "@testing-library/jest-dom": "^5.11.10",
7 | "@testing-library/react": "^11.2.6",
8 | "@testing-library/user-event": "^12.8.3",
9 | "react": "^17.0.2",
10 | "react-dom": "^17.0.2",
11 | "react-scripts": "4.0.3",
12 | "web-vitals": "^1.1.1"
13 | },
14 | "scripts": {
15 | "start": "react-scripts start",
16 | "build": "react-scripts build",
17 | "test": "react-scripts test",
18 | "eject": "react-scripts eject"
19 | },
20 | "eslintConfig": {
21 | "extends": [
22 | "react-app",
23 | "react-app/jest"
24 | ]
25 | },
26 | "browserslist": {
27 | "production": [
28 | ">0.2%",
29 | "not dead",
30 | "not op_mini all"
31 | ],
32 | "development": [
33 | "last 1 chrome version",
34 | "last 1 firefox version",
35 | "last 1 safari version"
36 | ]
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/Pomodoro Timer/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
12 |
13 |
17 |
18 |
27 | React App
28 |
29 |
30 | You need to enable JavaScript to run this app.
31 |
32 |
42 |
43 |
44 |
--------------------------------------------------------------------------------
/Pomodoro Timer/public/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "short_name": "React App",
3 | "name": "Create React App Sample",
4 | "icons": [
5 | {
6 | "src": "favicon.ico",
7 | "sizes": "64x64 32x32 24x24 16x16",
8 | "type": "image/x-icon"
9 | },
10 | {
11 | "src": "logo192.png",
12 | "type": "image/png",
13 | "sizes": "192x192"
14 | },
15 | {
16 | "src": "logo512.png",
17 | "type": "image/png",
18 | "sizes": "512x512"
19 | }
20 | ],
21 | "start_url": ".",
22 | "display": "standalone",
23 | "theme_color": "#000000",
24 | "background_color": "#ffffff"
25 | }
26 |
--------------------------------------------------------------------------------
/Pomodoro Timer/public/robots.txt:
--------------------------------------------------------------------------------
1 | # https://www.robotstxt.org/robotstxt.html
2 | User-agent: *
3 | Disallow:
4 |
--------------------------------------------------------------------------------
/Pomodoro Timer/src/App.css:
--------------------------------------------------------------------------------
1 | @import url('https://fonts.googleapis.com/css2?family=Major+Mono+Display&display=swap');
2 |
3 | * {
4 | box-sizing: border-box;
5 | }
6 |
7 | body {
8 | padding: 0;
9 | margin: 0;
10 | font-family: 'Major Mono Display', monospace;
11 | line-height: 1.5;
12 | }
13 |
14 | .app {
15 | min-height: 100vh;
16 | padding-left: 20px;
17 | padding-right: 20px;
18 | display: flex;
19 | flex-direction: column;
20 | align-items: center;
21 | justify-content: center;
22 | background: #87d7cc;
23 | color: #2c888d;
24 | }
25 |
26 | h2 {
27 | color: #49b2b8;
28 | font-size: 30px;
29 | text-align: center;
30 | margin: 0;
31 | }
32 |
33 | .timer {
34 | color: #1f6e72;
35 | font-size: 150px;
36 | margin-bottom: 20px;
37 | }
38 |
39 | .buttons button {
40 | outline: none;
41 | border: none;
42 | font-size: 24px;
43 | background: #f7fca0;
44 | color: #878b32;
45 | border-radius: 5px;
46 | box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
47 | padding: 15px 30px;
48 | cursor: pointer;
49 | transition: 0.3s ease all;
50 | }
51 |
52 | .buttons button:hover {
53 | border-radius: 10px;
54 | background: #f5f8ca;
55 | box-shadow: 0 0 10px rgba(0, 0, 0, 0.15);
56 | transform: translateY(-2px);
57 | }
58 |
59 | .buttons button:not(:last-child) {
60 | margin-right: 10px;
61 | }
62 |
63 | @media (max-width: 780px) {
64 | h2 {
65 | font-size: 22px;
66 | }
67 |
68 | .timer {
69 | font-size: 80px;
70 | }
71 |
72 | .buttons button {
73 | font-size: 18px;
74 | }
75 | }
--------------------------------------------------------------------------------
/Pomodoro Timer/src/App.js:
--------------------------------------------------------------------------------
1 | import React, { useState, useRef } from "react";
2 | import "./App.css";
3 |
4 | function padTime(time) {
5 | return time.toString().padStart(2, "0");
6 | }
7 |
8 | export default function App() {
9 | const [title, setTitle] = useState("Let the countdown begin!");
10 | const [timeLeft, setTimeLeft] = useState(25 * 60);
11 | const [isRunning, setIsRunning] = useState(false);
12 | const intervalRef = useRef(null);
13 |
14 | function startTimer() {
15 | if (intervalRef.current !== null) return;
16 |
17 | setTitle("You are doing great!");
18 | setIsRunning(true);
19 | intervalRef.current = setInterval(() => {
20 | setTimeLeft((timeLeft) => {
21 | if (timeLeft > 0) return timeLeft - 1;
22 |
23 | resetTimer();
24 | return 0;
25 | });
26 | }, 1000);
27 | }
28 |
29 | function stopTimer() {
30 | if (intervalRef.current === null) return;
31 | clearInterval(intervalRef.current);
32 | intervalRef.current = null;
33 | setTitle("Keep it going!");
34 | setIsRunning(false);
35 | }
36 |
37 | function resetTimer() {
38 | setTitle("Ready to go for another round?");
39 | clearInterval(intervalRef.current);
40 | intervalRef.current = null;
41 | setTimeLeft(25 * 60);
42 | setIsRunning(false);
43 | }
44 |
45 | const minutes = padTime(Math.floor(timeLeft / 60));
46 | const seconds = padTime(timeLeft - minutes * 60);
47 |
48 | return (
49 |
50 |
51 |
{title}
52 |
53 |
54 | {minutes}
55 | :
56 | {seconds}
57 |
58 |
59 |
60 | {!isRunning && Start }
61 | {isRunning && Stop }
62 | Reset
63 |
64 |
65 |
66 | );
67 | }
68 |
--------------------------------------------------------------------------------
/Pomodoro Timer/src/index.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom';
3 | import App from './App';
4 |
5 | ReactDOM.render(
6 |
7 |
8 | ,
9 | document.getElementById('root')
10 | );
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # React-Projects-for-Beginners
--------------------------------------------------------------------------------