Skip to content

Commit

Permalink
ready for deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
cyprste2717218 committed Nov 18, 2023
1 parent aed520c commit 7d89c3d
Show file tree
Hide file tree
Showing 23 changed files with 2,543 additions and 1,698 deletions.
Empty file added .xo-config.json
Empty file.
2,805 changes: 1,636 additions & 1,169 deletions package-lock.json

Large diffs are not rendered by default.

12 changes: 9 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,22 @@
"version": "0.1.0",
"private": true,
"dependencies": {
"@emotion/react": "^11.11.1",
"@emotion/styled": "^11.11.0",
"@fortawesome/free-brands-svg-icons": "^6.4.2",
"@fortawesome/free-regular-svg-icons": "^6.4.2",
"@fortawesome/free-solid-svg-icons": "^6.4.2",
"@fortawesome/react-fontawesome": "^0.2.0",
"@mui/icons-material": "^5.11.0",
"@mui/material": "^5.14.15",
"@testing-library/jest-dom": "^5.16.5",
"@testing-library/react": "^13.4.0",
"@testing-library/user-event": "^13.5.0",
"bootstrap": "^5.2.3",
"react": "^18.2.0",
"react-bootstrap": "^2.7.0",
"react-dom": "^18.2.0",
"react-google-material-icons": "^1.0.4",
"react-scripts": "^5.0.1",
"redux": "^4.2.1",
"react-scripts": "5.0.1",
"web-vitals": "^2.1.4"
},
"scripts": {
Expand Down
43 changes: 43 additions & 0 deletions public/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<link rel="icon" href="%PUBLIC_URL%/screwdriver-wrench-solid.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#000000" />
<meta
name="Unit Converter web app built in React"
content="Created using create-react-app"
/>
<link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />
<!--
manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
-->
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
<!--
Notice the use of %PUBLIC_URL% in the tags above.
It will be replaced with the URL of the `public` folder during the build.
Only files inside the `public` folder can be referenced from the HTML.
Unlike "/favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will
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>Unit Converter</title>
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
<!--
This HTML file is a template.
If you open it directly in the browser, you will see an empty page.
You can add webfonts, meta tags, or analytics to this file.
The build step will place the bundled scripts into the <body> tag.
To begin the development, run `npm start` or `yarn start`.
To create a production bundle, use `npm run build` or `yarn build`.
-->
</body>
</html>
Binary file added 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 added 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.
25 changes: 25 additions & 0 deletions public/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"short_name": "React App",
"name": "Create React App Sample",
"icons": [
{
"src": "favicon.ico",
"sizes": "64x64 32x32 24x24 16x16",
"type": "image/x-icon"
},
{
"src": "logo192.png",
"type": "image/png",
"sizes": "192x192"
},
{
"src": "logo512.png",
"type": "image/png",
"sizes": "512x512"
}
],
"start_url": ".",
"display": "standalone",
"theme_color": "#000000",
"background_color": "#ffffff"
}
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:
1 change: 1 addition & 0 deletions public/screwdriver-wrench-solid.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
254 changes: 220 additions & 34 deletions src/App.css
Original file line number Diff line number Diff line change
@@ -1,62 +1,248 @@
.navbar-text {
font-size: 50px !important;
color: #FFFFFF;
}


.unit-category {
width: 110px;
height: 110px;
width: 100px;
height: 100px;
background-color: #FFFFFF;
overflow: visible;


}

.convert-div {
width: 90vw;
background-color: #D9D9D9;
.unit-option {
display: flex;
justify-content: center;
flex-direction: column;
height: 100px;
border: 1px solid #000;
text-align: center;
}

.convert-div {

.app-font {
font-family: 'Work Sans', sans-serif;
background-color: #D9D9D9;
}

.convert-div-title-box {
width: 90%;
height: 80px;
background-color: #346C2A;
font-size: 2.5em;
}

.hide-scroll::-webkit-scrollbar {
display: none;
background-color: #346C2A
}

.switch-units-div {
width: 60px;
height: 60px;
background-color: #D9D9D9;
margin-right: auto;
margin-left: auto;
margin-bottom: auto;
margin-top: auto;
display: flex;
justify-content: center;
flex-direction: column;
font-size: 32px;
}

.dropdown-styling {
height: 80px;
.switch-units-div:hover {
animation: switch-units-scale-up-anim 0.15s ease-in-out forwards, switch-units-colour-focus-anim 0.15s ease-in-out forwards, switch-units-rotate-forward-anim 0.6s ease-in-out forwards;
}

.imperial-metric-unit-options {
display: flex;
flex-direction: column;
align-items: center;
.switch-units-div:not(:hover) {
animation: switch-units-scale-down-anim 0.15s ease-in-out forwards, switch-units-colour-unfocus-anim 0.15s ease-in-out forwards, switch-units-rotate-backward-anim 0.6s ease-in-out forwards;
}

.app-footer {
height: 150px;






.footer {

position: block;
bottom: 0;
left: 0;
right: 0;
height: 200px;
background-color: #D9D9D9;
font-size: 1.5em;
text-align: center;

}

.header-box {
font-size: 35px;
}


@media screen and (min-width: 1024px) {


.navbar-div {
background-color: #3EAD17;
height: 150px;
}

.navbar-text {
font-size: 45px;
color: #FFFFFF !important;
}

.from-to-unit-options {
display: flex;
justify-content: center;
flex-direction: row;
}

.unit-details-div {
width: 100%;
display: flex;
justify-content: center;
}

.mobile-br-elems {
display: none;
}

.dropdown-styling {
width: 20%;
height: 100px;
}

.larger-br-elems {
display: block;
}




}

@media screen and (max-width: 1023px) {

.navbar-text {
font-size: 30px;
color: #FFFFFF !important;
}

.navbar-div {
background-color: #3EAD17;
height: 100px;
font-size: 1px;
}

.from-to-unit-options {
display: flex;
justify-content: center;
flex-direction: column;
}

.unit-details-div {
display: flex;
justify-content: center;

}

.unit-details-span {
display: flex;
justify-content: center;
flex-direction: row;
}

.switch-units-div {
display: flex;
justify-content: center;
}

.mobile-br-elems {
display: block;
}

.dropdown-styling {
width: 100%;
height: 80px;
}

.larger-br-elems {
display: none;
}

}



/* Animations */

@keyframes switch-units-scale-up-anim {
from {
transform: scale(1);
}
to {
transform: scale(1.2);
}
}

@keyframes switch-units-scale-down-anim {
from {
transform: scale(1.2);
}
to {
transform: scale(1);
}
}

@keyframes switch-units-scale-up-down-anim {
from {
transform: scale(1);
}
50% {
transform: scale(1.1);
}
to {
transform: scale(1)
}
}

@keyframes switch-units-colour-focus-anim {
from {
background-color: #D9D9D9;
color: #000;
}
to {
background-color: blue;
color: #fff;

}
}

@keyframes switch-units-colour-unfocus-anim {
from {
background-color: blue;
color: #fff;
}
to {
background-color: #d9d9d9;
color: #000;

}
}

@keyframes switch-units-rotate-forward-anim {
from {
transform: rotate(0deg);
}
to {
transform: rotate(180deg);
}
}

@keyframes switch-units-rotate-backward-anim {
from {
transform: rotate(180deg);
}
to {
transform: rotate(0deg);
}
}

/* @keyframes switch-units-font-anim {
from {
font-size: 32px;
}
}
to {
font-size: 32px;
}
} */
Loading

0 comments on commit 7d89c3d

Please sign in to comment.