Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
78 commits
Select commit Hold shift + click to select a range
356cca5
agrego parrafo
LindaRobles May 22, 2023
461de74
comentario
SofSaules May 22, 2023
e27518a
Merge pull request #1 from SofSaules/feature/maquetacion-modulo
SofSaules May 22, 2023
d20ba6a
Merge branch 'main' of https://github.com/SofSaules/DEV008-data-lover…
SofSaules May 22, 2023
a6b016a
Merge branch 'main' of https://github.com/SofSaules/DEV008-data-lover…
SofSaules May 22, 2023
5b04492
cambios
SofSaules May 22, 2023
9e89a37
encabezado
LindaRobles May 22, 2023
14b95d9
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 22, 2023
01c79f0
Merge branch 'develop' of https://github.com/SofSaules/DEV008-data-lo…
LindaRobles May 22, 2023
6bdbaa1
Merge branch 'develop' of https://github.com/SofSaules/DEV008-data-lo…
LindaRobles May 22, 2023
834435f
mas pruebas
SofSaules May 22, 2023
7cf752d
dosparrafos
LindaRobles May 22, 2023
33d60f4
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 22, 2023
9645f12
Merge branch 'feature/maquetacion-modulo' of https://github.com/SofSa…
LindaRobles May 22, 2023
1e204a9
comentarios
SofSaules May 22, 2023
14b3320
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 22, 2023
b17a787
chec
SofSaules May 22, 2023
f8aa43a
Merge branch 'develop' of https://github.com/SofSaules/DEV008-data-lo…
SofSaules May 22, 2023
302fd52
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
LindaRobles May 22, 2023
9d9d10c
Merge branch 'develop' of https://github.com/SofSaules/DEV008-data-lo…
LindaRobles May 22, 2023
1fe3e63
1
SofSaules May 22, 2023
2f4a2f9
cambios1
SofSaules May 22, 2023
6785152
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 22, 2023
a537d69
Merge branch 'develop' of https://github.com/SofSaules/DEV008-data-lo…
SofSaules May 22, 2023
b460d29
eliminamos lineas de prueba y X-UA compatible
LindaRobles May 23, 2023
5317c26
borramos lineas ejemplo
LindaRobles May 23, 2023
d36b621
UX compatible para html
LindaRobles May 23, 2023
70292f6
cambio
SofSaules May 23, 2023
f88b1cd
Merge branch 'feature/maquetacion-modulo' of https://github.com/SofSa…
LindaRobles May 23, 2023
f6241a7
Merge branch 'feature/maquetacion-modulo' of https://github.com/SofSa…
SofSaules May 23, 2023
8b62c41
bocetoHTML y bocetoCSS
LindaRobles May 23, 2023
86a5cb1
Merge branch 'feature/maquetacion-modulo' of https://github.com/SofSa…
LindaRobles May 23, 2023
165533e
Merge branch 'feature/maquetacion-modulo' of https://github.com/SofSa…
SofSaules May 23, 2023
763324e
Merge branch 'feature/maquetacion-modulo' of https://github.com/SofSa…
SofSaules May 23, 2023
1d4d402
Merge branch 'develop' of https://github.com/SofSaules/DEV008-data-lo…
SofSaules May 23, 2023
338b3e4
desplegableTipos
SofSaules May 23, 2023
164004a
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 23, 2023
af3adf7
cambios nav
SofSaules May 24, 2023
2fe5d2b
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 24, 2023
788764b
cambios css
SofSaules May 24, 2023
17a9244
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 24, 2023
c38b1d3
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
LindaRobles May 24, 2023
156b03c
Merge branch 'develop' of https://github.com/SofSaules/DEV008-data-lo…
LindaRobles May 24, 2023
17f5e0a
Importar data en main js
SofSaules May 25, 2023
9118f8b
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 25, 2023
b4c5bbc
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
LindaRobles May 25, 2023
91ac145
creacion tarjeta pokemon
SofSaules May 26, 2023
2591909
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 26, 2023
0e60f5c
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
LindaRobles May 26, 2023
ecdd9b0
Filtrado por tipo
SofSaules May 29, 2023
0d0b048
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 29, 2023
bd08fb1
Merge branch 'develop' of https://github.com/SofSaules/DEV008-data-lo…
SofSaules May 29, 2023
d38e021
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
LindaRobles May 29, 2023
bf823b5
búsqueda por nombre o número
SofSaules May 29, 2023
c79a0ad
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 29, 2023
3e0d768
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
LindaRobles May 29, 2023
5028bba
cambio de la barra de navegación
SofSaules May 29, 2023
71ad7f7
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 29, 2023
6528463
orden por número y nombre alfabético
SofSaules May 31, 2023
b31219b
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 31, 2023
6ec924e
modal de cada pokémon
SofSaules May 31, 2023
0a2d07e
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules May 31, 2023
ab25cd3
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
LindaRobles May 31, 2023
463917c
Merge branch 'develop' of https://github.com/SofSaules/DEV008-data-lo…
LindaRobles May 31, 2023
26d849e
modal en la pantalla
SofSaules Jun 1, 2023
72dc245
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules Jun 1, 2023
bc26a7c
comentario
SofSaules Jun 1, 2023
d271246
Merge branch 'develop' of https://github.com/SofSaules/DEV008-data-lo…
SofSaules Jun 1, 2023
4ae3eb6
Merge branch 'feature/maquetacion-pag-principal' of https://github.co…
SofSaules Jun 1, 2023
1d8c4f7
modal flex
SofSaules Jun 2, 2023
9efd00e
color en tipos
SofSaules Jun 2, 2023
41ef6f6
ajustes css, reset, desplegables
LindaRobles Jun 2, 2023
865df07
cambio en modulo
SofSaules Jun 2, 2023
de8b70f
pruebas unitarias
SofSaules Jun 6, 2023
d1cddd4
Responsivo
SofSaules Jun 8, 2023
0239b8a
charts
SofSaules Jun 14, 2023
a6612a8
proyecto final
SofSaules Jun 14, 2023
ae72a29
responsive modal
SofSaules Jun 14, 2023
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
650 changes: 93 additions & 557 deletions README.md

Large diffs are not rendered by default.

13,151 changes: 13,151 additions & 0 deletions package-lock.json

Large diffs are not rendered by default.

5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,8 @@
"createdAt": "2023-05-09T14:49:00.455Z",
"version": "6.2.0",
"commit": "da890e27d7d1949d74bbea9f12216b48ff8185e9"
},
"dependencies": {
"chart.js": "^4.3.0"
}
}
}
57 changes: 51 additions & 6 deletions src/data.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,54 @@
// estas funciones son de ejemplo

export const example = () => {
return 'example';
/*funcion generica que puede filtrar lo que quiera
* la función recibe dos parametros, el primero es un array de objetos(data) y
* el segundo un tipo de elemento (condicion)
*/
export function filterByType(arrayObj, elementTypeDelObj) {
//filter() regresa un arreglo y recibe una función. Antes de la flechita es el parametro recibido, después es el cuerpo de mi función
// el parametro es un elemento de mi arrayObjeto
const pokemon = arrayObj.filter((obj) =>
obj.type.includes(elementTypeDelObj)
);
return pokemon;
}
//se utilizó el método startsWith() y un or.
export const searchPokemonByName = (arrayObj, input) => {
const pokemon = arrayObj.filter(
(obj) =>
obj.name.startsWith(input.toLowerCase().trim()) || obj.num.includes(input.trim())
);
return pokemon;
};

export const anotherExample = () => {
return 'OMG';
//Sort
/**
* Función para ordenar el arrayObj por diferentes criterios.
* La función recibe dos parámetros: arrayObj (array de objetos) y orderBy (tipo de ordenamiento).
* Retorna el arrayObj ordenado según el criterio especificado.
*/
export const sortData = (data, options) => {
/*console.log("--->", data.map((e) => e.num));*/
let newPokemons;
switch (options) {
case "asc":
newPokemons = data.sort((a, b) => a.name.localeCompare(b.name));
return newPokemons;
case "desc":
newPokemons = data.sort((a, b) => b.name.localeCompare(a.name));
/*console.log("alafebetico descendente", newPokemons);*/
return newPokemons;
case "numAsc":
newPokemons = data.sort((a, b) => Number(a.num) - Number(b.num));
return newPokemons;
case "numDesc":
newPokemons = data.sort((a, b) => Number(b.num) - Number(a.num));
/*console.log("num descendente", newPokemons);*/
return newPokemons;
default:
return data;
}
};
export function computeTypePercentage(pokemonList, type) {
const filteredPokemon = pokemonList.filter(p => p.type.includes(type));
const percentage = (filteredPokemon.length / pokemonList.length * 100).toFixed(2);
return percentage;
}
28 changes: 0 additions & 28 deletions src/data/athletes/README.md

This file was deleted.

27 changes: 0 additions & 27 deletions src/data/athletes/README.pt.md

This file was deleted.

Loading