Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
69 commits
Select commit Hold shift + click to select a range
6a4a3aa
ordene las carpetas de componentes y empece a exportar los assets
vivianachoque Mar 13, 2020
b6373d6
cree componente blockimg, que son las imagenes de bloques en el login
vivianachoque Mar 13, 2020
b4c2ec3
exporte bloque
vivianachoque Mar 13, 2020
4af33fd
ordené carpetas
vivianachoque Mar 17, 2020
f09dfa8
corregí ruteos
vivianachoque Mar 17, 2020
c7b9ab5
corregi rutas y carpetas
vivianachoque Mar 17, 2020
e878012
modifique rutas y córregí import de violetbutton
vivianachoque Mar 17, 2020
e12bbb7
acomadamos archivos y funciones
Ezequiiel98 Mar 17, 2020
c48e198
hice formulario de Login
vivianachoque Mar 18, 2020
f29148f
hice carpeta para fonts
vivianachoque Mar 18, 2020
d9a53e5
agregué fuente montserrat
vivianachoque Mar 18, 2020
2cd344f
corregi algunos error en codigo con min y mayus, también estoy estili…
vivianachoque Mar 19, 2020
863315f
arreglé problema con google fonts, junto a tincho
vivianachoque Mar 19, 2020
a0a9024
uní componente Login con componente VioletB
vivianachoque Mar 19, 2020
085825c
agregue divs entre los labels, y separece button con divs
vivianachoque Mar 19, 2020
1249272
mejore algunas cosas del componente form
vivianachoque Mar 20, 2020
7f78f64
Alineé la columna de FormLogin, mejoré en gral. todos los márgenes de…
vivianachoque Mar 20, 2020
fef76a2
agregué style al form y al titulo
vivianachoque Mar 20, 2020
6d5b8dc
hice comments para corregir errores a futuro
vivianachoque Mar 22, 2020
b1b5aab
modifiqué ancho de botones ya que estaba distinto a invision. Mejore …
vivianachoque Mar 22, 2020
a7fd5e6
modificando scroll no deseado de pantalla
vivianachoque Mar 22, 2020
759a73f
mejore ubicación de img y saqué SCROLL no deseado
vivianachoque Mar 22, 2020
e325e4e
corregí margin entre form y blockimg
vivianachoque Mar 22, 2020
976d108
agregué distintos tipos de inputs al form, continuaré con issue
vivianachoque Mar 22, 2020
870c7ef
icon login error hice
vivianachoque Mar 24, 2020
5fb821c
corregi el @import de las clases para la clase .error
vivianachoque Mar 24, 2020
3724cd7
faltaba } en css de formLogin
vivianachoque Mar 24, 2020
1b2b108
cambie clase blockchain por title
vivianachoque Mar 24, 2020
e550c0d
corregí espacios en clases de formlogin
vivianachoque Mar 24, 2020
fb31c1e
agregue img de error a login
vivianachoque Mar 24, 2020
9dcd4e8
corregí errores de anidación en css login form
vivianachoque Mar 24, 2020
e2d62cd
hice cambios en .error
vivianachoque Mar 24, 2020
57b11ba
cree state para formLogn (error)
vivianachoque Mar 25, 2020
f5fb726
arregle Hover de WhiteButton
vivianachoque Mar 25, 2020
57b7c98
agregue state.error a input de NOMBRE
vivianachoque Mar 31, 2020
1ab903b
agregando states a FormLogin para manejo de errores login, corregí al…
vivianachoque Mar 31, 2020
8f8e772
Agregué función a VioletButton (Disabled) y modifiqué algunas cosas d…
vivianachoque Mar 31, 2020
c7667fe
agregué type=submit al componente VioletButton
vivianachoque Apr 1, 2020
d03bda3
agregué state.errorName state.errorCode en caso de que ambas estén va…
vivianachoque Apr 1, 2020
a8762a9
uni api con login, hice manejo de errores de form
vivianachoque Apr 1, 2020
c22b411
hice ruteo de api, modifique ruta
vivianachoque Apr 1, 2020
73bfc84
hice manejo de errores
vivianachoque Apr 2, 2020
2775e66
le di styles a mensajes de error en login y agregué margin-top a cont…
vivianachoque Apr 2, 2020
d302a42
agregué archivos a git ignore link API
vivianachoque Apr 2, 2020
8e922d2
Corregí funciones de login error, ya que tenía algunos problemas a la…
vivianachoque Apr 6, 2020
904354f
agregué una última línea vacía a cada archivo del proyecto
vivianachoque Apr 7, 2020
6c56840
edité readme
vivianachoque Apr 7, 2020
88fa781
agregué una linea a VioletButton (styles)
vivianachoque Apr 7, 2020
ab441cc
cambié ruta de services por Services y nombre de carpeta
vivianachoque Apr 7, 2020
e563bf0
Update src/components/VioletButton/index.js
vivianachoque Apr 7, 2020
b064e2d
Update src/screens/LoginScreen/components/FormLogin/index.module.scss
vivianachoque Apr 7, 2020
3eef62d
cambié nombre función violetbutton por WhiteButton ya que el director…
vivianachoque Apr 7, 2020
ed33651
Apply suggestions from code review
vivianachoque Apr 7, 2020
12ffb34
modifiqué setState en formLogn/index.js simplifiqué todo en una sola …
vivianachoque Apr 7, 2020
0e0b94b
borré lineas en sass con respecto a font:montserrat ya que por defect…
vivianachoque Apr 7, 2020
bcd1d17
agregué & a las propiedades de los estilos de cada clase en sus disti…
vivianachoque Apr 8, 2020
c2beb30
agregué & a las propiedades de los estilos de cada clase en sus disti…
vivianachoque Apr 8, 2020
f35a990
agregué & a las propiedades de los estilos de cada clase en sus disti…
vivianachoque Apr 8, 2020
8a52823
Corregí código para que quede mas prolijo, uni las clases con sus dif…
vivianachoque Apr 8, 2020
43a41dd
Hice cambios en nombre de componente Blockimg a BlockImg
vivianachoque Apr 8, 2020
a2068cd
simplifiqué función handleSubmit
vivianachoque Apr 8, 2020
607e794
modifiqué padre e hijo en los errores de login ya que estaban mal pue…
vivianachoque Apr 8, 2020
168127a
hice cambio en las funciones ya que estaba llamando al evento y era r…
vivianachoque Apr 8, 2020
98aaeff
modifiqué config de identado, y lo apliqué a todos los archivos de sass
vivianachoque Apr 8, 2020
4754498
cambie otra vez el tamaño de ident 2 por defecto
vivianachoque Apr 9, 2020
de69291
Cambie nombre de componente Blockimg a BlockImg
vivianachoque Apr 11, 2020
d3ccbcf
cambié otra vez de Blockimg a BlockImg, los cambios no se estarían ha…
vivianachoque Apr 11, 2020
253bee8
cambie nombre de Services a services para poder mergear
vivianachoque Apr 11, 2020
80857fd
cambie nombre de Services a services para poder mergear
vivianachoque Apr 11, 2020
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
1 change: 1 addition & 0 deletions .env
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
REACT_APP_API_URL=http://woloxblockchain.herokuapp.com
Comment thread
vivianachoque marked this conversation as resolved.
7 changes: 5 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
# See https://healp.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
Expand All @@ -18,6 +18,9 @@
.env.test.local
.env.production.local

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

# env
.env
3 changes: 3 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"files.insertFinalNewline": true
}
69 changes: 1 addition & 68 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,68 +1 @@
This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app).

## Available Scripts

In the project directory, you can run:

### `npm start`

Runs the app in the development mode.<br />
Open [http://localhost:3000](http://localhost:3000) to view it in the browser.

The page will reload if you make edits.<br />
You will also see any lint errors in the console.

### `npm test`

Launches the test runner in the interactive watch mode.<br />
See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.

### `npm run build`

Builds the app for production to the `build` folder.<br />
It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.<br />
Your app is ready to be deployed!

See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.

### `npm run eject`

**Note: this is a one-way operation. Once you `eject`, you can’t go back!**

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.

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.

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.

## Learn More

You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).

To learn React, check out the [React documentation](https://reactjs.org/).

### Code Splitting

This section has moved here: https://facebook.github.io/create-react-app/docs/code-splitting

### Analyzing the Bundle Size

This section has moved here: https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size

### Making a Progressive Web App

This section has moved here: https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app

### Advanced Configuration

This section has moved here: https://facebook.github.io/create-react-app/docs/advanced-configuration

### Deployment

This section has moved here: https://facebook.github.io/create-react-app/docs/deployment

### `npm run build` fails to minify

This section has moved here: https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify
Desarrollo del Login, primer pantalla del proyecto de 'Blockchain'
45 changes: 45 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"@testing-library/jest-dom": "^4.2.4",
"@testing-library/react": "^9.5.0",
"@testing-library/user-event": "^7.2.1",
"apisauce": "^1.1.1",
"node-sass": "^4.13.1",
"react": "^16.13.0",
"react-dom": "^16.13.0",
Expand Down
Binary file removed public/favicon.ico
Binary file not shown.
14 changes: 14 additions & 0 deletions src/Services/api.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import { create } from 'apisauce';

const API_URL = process.env.REACT_APP_API_URL;

const api = create({
baseURL: API_URL,
headers: {
Authorization: 'user_token',
'Content-Type': 'application/json',
Accept: 'application/json'
}
});

export default api;
5 changes: 5 additions & 0 deletions src/Services/gameService.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import api from './api';

export const sendGame = data => api.post('/game/join_game', data);

/* Here I generate the contact with the API */
4 changes: 2 additions & 2 deletions src/components/App/index.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import React from 'react';

import styles from './index.module.scss';
import LoginScreen from '../../screens/LoginScreen';

function App() {
return <h1> Proyecto blockchain </h1>;
return <LoginScreen />;
}

export default App;
Empty file.
42 changes: 42 additions & 0 deletions src/components/VioletButton/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
import React from 'react';
import PropTypes from 'prop-types';

import styles from './index.module.scss';

function VioletButton({ text, typeButton, disable }) {
return (
<div className={disable ? styles.containerBtnDisabled : styles.containerBtnActive}>
{typeButton === 'button' ? (
<button
type="button"
className={disable ? styles.btnDisabled : styles.btnActive}
disabled={disable.toString()}
>
{text}
</button>
) : (
<button
type="submit"
className={disable ? styles.btnDisabled : styles.btnActive}
disable={disable.toString()}
>
{text}
</button>
)}
</div>
);
}

VioletButton.propTypes = {
disable: PropTypes.bool,
text: PropTypes.string,
typeButton: PropTypes.string
};

VioletButton.defaultProps = {
disable: false,
text: 'Text Button',
typeButton: 'button'
};

export default VioletButton;
48 changes: 48 additions & 0 deletions src/components/VioletButton/index.module.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
.containerBtn {
width: 240px;
height: 66px;
border-radius: 5px;
margin: 20px auto 0 auto;
}

.containerBtnActive {
@extend .containerBtn;
background-color: #533D71;
transition: background-color .1s ease, transform .2s ease;

&:hover {
background-color: transparent;
transform: translateY(8px);
}
}

.containerBtnDisabled {
@extend .containerBtn;
background-color: #B5B5B6;
}

.btn {
outline: none;
border: none;
width: 100%;
height: 58px;
font-size: 18px;
font-weight: bold;
border-radius: 5px;
}

.btnActive {
@extend .btn;
background-color: #7758A2;
color: white;

&:hover {
Comment thread
vivianachoque marked this conversation as resolved.
cursor: pointer;
}
}

.btnDisabled {
@extend .btn;
color: #B5B5B6;
background-color: #E8E8E8;
}
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react';
import ReactDOM from 'react-dom';

import './index.css';
import './index.scss';
import App from './components/App';

ReactDOM.render(<App />, document.getElementById('root'));
16 changes: 16 additions & 0 deletions src/index.css → src/index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,19 @@ code {
font-family: source-code-pro, Menlo, Monaco, Consolas, 'Courier New',
monospace;
}

@import url('https://fonts.googleapis.com/css?family=Montserrat:400,700&display=swap');

* {
font-family: 'Montserrat', sans-serif;
}

html {
box-sizing: border-box;
}

*,
*:before,
*:after {
box-sizing: inherit;
}
395 changes: 395 additions & 0 deletions src/screens/LoginScreen/assets/img/Documentacion.md

Large diffs are not rendered by default.

50 changes: 50 additions & 0 deletions src/screens/LoginScreen/assets/img/blockimg.svg
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 src/screens/LoginScreen/assets/img/erroricon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 16 additions & 0 deletions src/screens/LoginScreen/components/Blockimg/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import React from './node_modules/react';

import img from '../../assets/img/blockimg.svg';

import styles from './index.module.scss';

function BlockImg() {
return (
<div className={styles.blockImg}>
<img src={img} className={styles.img} />
</div>
);
}
export default BlockImg;

/*comment*/
Loading