Skip to content
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

FTBC13 Ignatius - Guitar 4 You #36

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
290 changes: 290 additions & 0 deletions package-lock.json

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
{
"homepage": "https://ignatiusgabrieltan.github.io",
"name": "project1-bootcamp",
"version": "0.1.0",
"private": true,
"dependencies": {
"gh-pages": "^6.0.0",
"react": "^18.1.0",
"react-dom": "^18.1.0",
"react-scripts": "5.0.1"
},
"scripts": {
"predeploy": "npm run build",
"deploy": "gh-pages -d build",
"start": "react-scripts start",
"build": "react-scripts build"
},
Expand All @@ -27,5 +31,8 @@
"last 1 firefox version",
"last 1 safari version"
]
},
"devDependencies": {
"web-vitals": "^3.4.0"
}
}
Binary file modified public/favicon.ico
Binary file not shown.
Binary file added public/images/Guitar 4 you-01.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/images/acoustic guitar.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions public/images/acoustic guitar.png:Zone.Identifier
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[ZoneTransfer]
ZoneId=3
ReferrerUrl=https://www.washburn.com/wp-content/uploads/2018/06/AG70CE-FRONT.png
HostUrl=https://www.washburn.com/wp-content/uploads/2018/06/AG70CE-FRONT.png
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[ZoneTransfer]
ZoneId=3
ReferrerUrl=https://www.freepik.com/free-photo/acoustic-guitar-close-up-beautiful-colored-background_9434975.htm
HostUrl=https://downloadscdn6.freepik.com/169016/4/3530.jpg?filename=acoustic-guitar-close-up-beautiful-colored-background.jpg&token=exp=1694859061~hmac=e1bb2e7892462b1c518fad8a741aed6d
Binary file added public/images/chords.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions public/images/chords.jpg:Zone.Identifier
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[ZoneTransfer]
ZoneId=3
ReferrerUrl=https://www.libertyparkmusic.com/wp-content/uploads/Chord-diagram-7.jpg
HostUrl=https://www.libertyparkmusic.com/wp-content/uploads/Chord-diagram-7.jpg
Binary file added public/images/electric guitar.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions public/images/electric guitar.png:Zone.Identifier
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[ZoneTransfer]
ZoneId=3
ReferrerUrl=https://www.prestigeguitars.com/wp-content/uploads/2017/10/classic-sb-front.png
HostUrl=https://www.prestigeguitars.com/wp-content/uploads/2017/10/classic-sb-front.png
4 changes: 4 additions & 0 deletions public/images/guitar.jpg:Zone.Identifier
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[ZoneTransfer]
ZoneId=3
ReferrerUrl=https://www.long-mcquade.com/files/25289/4853647ce0ea63ff32c26bcbe2d89dbb.jpg
HostUrl=https://www.long-mcquade.com/files/25289/4853647ce0ea63ff32c26bcbe2d89dbb.jpg
Binary file added public/images/menu guitar.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 13 additions & 1 deletion public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,18 @@
<head>
<meta charset="utf-8" />
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
href="https://fonts.googleapis.com/css2?family=Kavoon&display=swap"
rel="stylesheet"
/>
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
href="https://fonts.googleapis.com/css2?family=Kavoon&family=Libre+Franklin&display=swap"
rel="stylesheet"
/>
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#000000" />
<meta
Expand All @@ -24,7 +36,7 @@
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
<title>Rocket Bootcamp Project</title>
<title>React App</title>
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
Expand Down
Binary file modified public/logo192.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified public/logo512.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions public/manifest.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"short_name": "Rocket Project",
"name": "Rocket Bootcamp Project",
"short_name": "React App",
"name": "Create React App Sample",
"icons": [
{
"src": "favicon.ico",
Expand Down
3 changes: 3 additions & 0 deletions public/robots.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# https://www.robotstxt.org/robotstxt.html
User-agent: *
Disallow:
19 changes: 19 additions & 0 deletions src/App.css
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@
pointer-events: none;
}

@media (prefers-reduced-motion: no-preference) {
.App-logo {
animation: App-logo-spin infinite 20s linear;
}
}

.App-header {
background-color: #282c34;
min-height: 100vh;
Expand All @@ -17,3 +23,16 @@
font-size: calc(10px + 2vmin);
color: white;
}

.App-link {
color: #61dafb;
}

@keyframes App-logo-spin {
from {
transform: rotate(0deg);
}
to {
transform: rotate(360deg);
}
}
35 changes: 27 additions & 8 deletions src/App.js
Original file line number Diff line number Diff line change
@@ -1,20 +1,39 @@
import React from "react";
import logo from "./logo.png";
import "./App.css";
import MenuPage from "./Components/Menu-page";
import LearnChords from "./Components/LearnChords";

class App extends React.Component {
constructor(props) {
super(props);
this.state = {
page: "MENU",
};
}

toChordsPage = () => {
this.setState({
page: "LEARNCHORDS",
});
};

toMenuPage = () => {
this.setState({
page: "MENU",
});
};

render() {
return (
<div className="App">
<header className="App-header">
<img src={logo} className="App-logo" alt="logo" />
<p>
Edit <code>src/App.js</code> and save to reload.
</p>
</header>
{this.state.page === "MENU" && (
<MenuPage changeToChordsPage={this.toChordsPage} />
)}
{this.state.page === "LEARNCHORDS" && (
<LearnChords changeToMenuPage={this.toMenuPage} />
)}
</div>
);
}
}

export default App;
8 changes: 8 additions & 0 deletions src/App.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import { render, screen } from '@testing-library/react';
import App from './App';

test('renders learn react link', () => {
render(<App />);
const linkElement = screen.getByText(/learn react/i);
expect(linkElement).toBeInTheDocument();
});
93 changes: 93 additions & 0 deletions src/Components/AG-Buttons.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
.index-AG {
background-color: transparent;
display: flex;
flex-direction: row;
justify-content: center;
width: 100%;
}

.AG-Buttons {
align-items: flex-start;
display: inline-flex;
gap: 25px;
justify-content: center;
position: absolute;
top: 25px;
}

.index-AG .button {
background: none;
border: none;
color: #ffffff;
font-family: "Libre Franklin", Helvetica;
font-size: 30px;
font-weight: 400;
height: 46px;
letter-spacing: 0;
line-height: normal;
margin-top: -1px;
position: relative;
text-align: center;
width: 38px;
}

.index-AG .a-chord {
height: 92px;
left: 402px;
position: absolute;
top: 118px;
width: 61px;
}

.fingering {
position: absolute;
left: -75px;
}

.index-AG .b-chord {
height: 92px;
left: 182px;
position: absolute;
top: 120px;
width: 281px;
}

.index-AG .c-chord {
height: 92px;
left: 251px;
position: absolute;
top: 118px;
width: 281px;
}

.index-AG .d-chord {
height: 92px;
left: 251px;
position: absolute;
top: 118px;
width: 281px;
}

.index-AG .e-chord {
height: 92px;
left: 325px;
position: absolute;
top: 118px;
width: 281px;
}

.index-AG .f-chord {
height: 92px;
left: 251px;
position: absolute;
top: 118px;
width: 281px;
}

.index-AG .g-chord {
height: 92px;
left: 325px;
position: absolute;
top: 118px;
width: 281px;
}
89 changes: 89 additions & 0 deletions src/Components/AG-Buttons.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
import React from "react";
import "./AG-Buttons.css";
import AChord from "./audio/A-Chord.mp3";
import BChord from "./audio/B-Chord.mp3";
import CChord from "./audio/C-Chord.mp3";
import DChord from "./audio/D-Chord.mp3";
import EChord from "./audio/E-Chord.mp3";
import FChord from "./audio/F-Chord.mp3";
import GChord from "./audio/G-Chord.mp3";

class AGButtons extends React.Component {
play = (sound) => {
new Audio(sound).play();
};

render() {
const { changeMajorChord } = this.props;
return (
<div className="index-AG">
<div className="AG-Buttons">
<button
className="button"
onClick={() => {
changeMajorChord("A");
this.play(AChord);
}}
>
A
</button>
<button
className="button"
onClick={() => {
changeMajorChord("B");
this.play(BChord);
}}
>
B
</button>
<button
className="button"
onClick={() => {
changeMajorChord("C");
this.play(CChord);
}}
>
C
</button>
<button
className="button"
onClick={() => {
changeMajorChord("D");
this.play(DChord);
}}
>
D
</button>
<button
className="button"
onClick={() => {
changeMajorChord("E");
this.play(EChord);
}}
>
E
</button>
<button
className="button"
onClick={() => {
changeMajorChord("F");
this.play(FChord);
}}
>
F
</button>
<button
className="button"
onClick={() => {
changeMajorChord("G");
this.play(GChord);
}}
>
G
</button>
</div>
</div>
);
}
}
export default AGButtons;
32 changes: 32 additions & 0 deletions src/Components/AmGm-Buttons.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
.index {
background-color: transparent;
display: flex;
flex-direction: row;
justify-content: center;
width: 100%;
}

.AmGm-Buttons {
align-items: flex-start;
display: inline-flex;
gap: 25px;
position: absolute;
left: 65px;
top: 25px;
}

.index .button {
background: none;
border: none;
color: #ffffff;
font-family: "Libre Franklin", Helvetica;
font-size: 30px;
font-weight: 400;
height: 46px;
letter-spacing: 0;
line-height: normal;
margin-top: -1px;
position: relative;
text-align: center;
width: 38px;
}
Loading