Skip to content
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
12 changes: 12 additions & 0 deletions web/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# EditorConfig is awesome: https://EditorConfig.org

# top-most EditorConfig file
root = true

[*]
indent_style = space
indent_size = 2
end_of_line = crlf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
140 changes: 140 additions & 0 deletions web/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,140 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js

# testing
/coverage

# production
/build

# misc
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.local

npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
lerna-debug.log*

# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage
*.lcov

# nyc test coverage
.nyc_output

# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/
jspm_packages/

# Snowpack dependency directory (https://snowpack.dev/)
web_modules/

# TypeScript cache
*.tsbuildinfo

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Microbundle cache
.rpt2_cache/
.rts2_cache_cjs/
.rts2_cache_es/
.rts2_cache_umd/

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# dotenv environment variables file
.env
.env.test

# parcel-bundler cache (https://parceljs.org/)
.cache
.parcel-cache

# Next.js build output
.next
out

# Nuxt.js build / generate output
.nuxt
dist

# Gatsby files
.cache/
# Comment in the public line in if your project uses Gatsby and not Next.js
# https://nextjs.org/blog/next-9-1#public-directory-support
# public

# vuepress build output
.vuepress/dist

# Serverless directories
.serverless/

# FuseBox cache
.fusebox/

# DynamoDB Local files
.dynamodb/

# TernJS port file
.tern-port

# Stores VSCode versions used for testing VSCode extensions
.vscode-test

# yarn v2
.yarn/cache
.yarn/unplugged
.yarn/build-state.yml
.yarn/install-state.gz
.pnp.*
5 changes: 5 additions & 0 deletions web/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# CRUD - reactJS

- HOME

![manipulando as notas](./assets/notes.png)
Binary file added web/assets/notes.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
40 changes: 40 additions & 0 deletions web/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"name": "web",
"version": "0.1.0",
"private": true,
"dependencies": {
"@testing-library/jest-dom": "^5.11.4",
"@testing-library/react": "^11.1.0",
"@testing-library/user-event": "^12.1.10",
"history": "^5.0.0",
"react": "^17.0.1",
"react-dom": "^17.0.1",
"react-icons": "^4.1.0",
"react-router-dom": "^6.0.0-beta.0",
"react-scripts": "4.0.1",
"styled-components": "^5.2.1",
"web-vitals": "^0.2.4"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
},
"devDependencies": {
"eslint": "^7.16.0",
"prettier": "^2.2.1"
}
}
Binary file added web/public/favicon.ico
Binary file not shown.
21 changes: 21 additions & 0 deletions web/public/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#000000" />
<meta
name="description"
content="Web site created using create-react-app"
/>

<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />

<title>Checkout - eliasallex</title>
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
</body>
</html>
25 changes: 25 additions & 0 deletions web/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 web/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:
25 changes: 25 additions & 0 deletions web/src/App.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import React from 'react';
import { BrowserRouter, Routes, Route } from 'react-router-dom'
// STYLES | STATICs
import GlobalStyles from './styles/GlobalStyles';

// PAGEs
import Home from './pages/Home'
import Auth from './pages/Auth'
// COMPONENTs
import Footer from './components/Footer'

const App = () => (
<BrowserRouter>
<Routes>
<Route path="/" element={<Home />} />
<Route path="/authentication" element={<Auth />} />
</Routes>

<Footer />

<GlobalStyles />
</BrowserRouter>
)

export default App;
14 changes: 14 additions & 0 deletions web/src/components/Footer/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import React from 'react';
// STATICs
import { Container, Line, GithubLogo } from './styles';

const Footer = () => {
return (
<Container>
<Line />
<GithubLogo />
</Container>
);
}

export default Footer;
23 changes: 23 additions & 0 deletions web/src/components/Footer/styles.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import styled from 'styled-components';
import { FaGithub } from 'react-icons/fa';

export const Container = styled.div`
display: flex;
flex-direction: column;
align-items: center;
margin: 25px 32px;
`;

export const Line = styled.div`
max-width: 1100px;
width: 100%;
border-top: 1px solid var(--border);
`;

export const GithubLogo = styled(FaGithub)`
margin-top: 25px;
fill: var(--border);
width: 24px;
height: 24px;
flex-shrink: 0;
`;
19 changes: 19 additions & 0 deletions web/src/components/Header/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import React from 'react';

import { StateBlock, OkIcon } from './styles';

const Header = () => {
return (
<StateBlock>
<span>eliasallex</span>
<strong> - </strong>
<span>CRUD</span>

<strong>
<OkIcon />
</strong>
</StateBlock>
);
}

export default Header;
29 changes: 29 additions & 0 deletions web/src/components/Header/styles.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
import styled from 'styled-components';
import { FiCheck } from 'react-icons/fi'

export const StateBlock = styled.nav`
grid-area: HEADER;

margin: 0 auto;
display: flex;
justify-content: center;
align-items: center;

> span {
font-size: 18px;
}

> strong {
display: flex;
justify-content: center;
align-items: center;

margin: 0 5px;
}
`;

export const OkIcon = styled(FiCheck)`
flex-shrink: 1;
width: 14px;
height: 14px;
`;
Loading