Skip to content

Commit b1ee9a7

Browse files
committed
style:se agrego la seccion de resena
1 parent cccb4b8 commit b1ee9a7

File tree

6 files changed

+480
-522
lines changed

6 files changed

+480
-522
lines changed

asset/data/project.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"titulo": "ia-assistant",
1414
"autora": "Carlos López",
1515
"descripcion": "Un asistente basado en inteligencia artificial para mejorar la productividad.",
16-
"img": "asset/img/proyecto2.jpg",
16+
"img": "asset/img/IMG_20221001_175958.jpg",
1717
"redes": {
1818
"github": "https://github.com/carlos/ia-assistant",
1919
"demo": "https://demo.ia-assistant.com"
@@ -23,7 +23,7 @@
2323
"titulo": "seguro-max",
2424
"autora": "Luishiño Pericena",
2525
"descripcion": "Un sistema seguro para gestionar información confidencial.",
26-
"img": "asset/img/proyecto3.jpg",
26+
"img": "asset/img/IMG_20221001_175958.jpg",
2727
"redes": {
2828
"github": "https://github.com/luishino/seguro-max",
2929
"demo": "https://demo.seguro-max.com"

asset/data/review.json

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
[
2+
{
3+
"nombre": "Carlos Mendoza",
4+
"curso": "Desarrollo Web",
5+
"comentario": "Astro ha sido increíble para sitios rápidos y dinámicos.",
6+
"imagen": "asset/img/mentor/Luishiño.png"
7+
},
8+
{
9+
"nombre": "María López",
10+
"curso": "Desarrollo Móvil",
11+
"comentario": "Flutter es genial para apps móviles.",
12+
"imagen": "asset/img/mentor/Luishiño.png"
13+
},
14+
{
15+
"nombre": "Juan Pérez",
16+
"curso": "Inteligencia Artificial",
17+
"comentario": "Aprender IA me ha abierto muchas oportunidades.",
18+
"imagen": "asset/img/mentor/Luishiño.png"
19+
},
20+
{
21+
"nombre": "Ana Silva",
22+
"curso": "Inteligencia de Negocios",
23+
"comentario": "El análisis de datos es clave para negocios.",
24+
"imagen": "asset/img/mentor/Luishiño.png"
25+
},
26+
{
27+
"nombre": "Roberto Castillo",
28+
"curso": "Ciberseguridad",
29+
"comentario": "Ciberseguridad me ha ayudado a proteger sistemas.",
30+
"imagen": "asset/img/mentor/Luishiño.png"
31+
}
32+
]

asset/data/teachers.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
{
1414
"nombre": "María García",
1515
"especialidad": "Inteligencia Artificial",
16-
"img": "asset/img/mentor/Maria.png",
16+
"img": "asset/img/mentor/Luishiño.png",
1717
"redes": {
1818
"facebook": "https://facebook.com/maria",
1919
"instagram": "https://instagram.com/maria",
@@ -23,7 +23,7 @@
2323
{
2424
"nombre": "Carlos López",
2525
"especialidad": "Seguridad Informática",
26-
"img": "asset/img/mentor/Carlos.png",
26+
"img": "asset/img/mentor/Luishiño.png",
2727
"redes": {
2828
"facebook": "https://facebook.com/carlos",
2929
"instagram": "https://instagram.com/carlos",

asset/js/review.js

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
2+
document.addEventListener("DOMContentLoaded", async function () {
3+
const reviewContainer = document.getElementById("review-container");
4+
5+
try {
6+
const response = await fetch("/asset/data/review.json"); // Cambia esto a la URL de tu API si es necesario
7+
const data = await response.json();
8+
9+
data.forEach(resena => {
10+
const slide = document.createElement("div");
11+
slide.classList.add("swiper-slide", "flex", "justify-center");
12+
13+
slide.innerHTML = `
14+
<div class="p-6 text-center">
15+
<img src="${resena.imagen}" class="w-30 h-5 mx-auto" alt="${resena.nombre}">
16+
<p class="text-lg italic text-gray-700 dark:text-gray-300">"${resena.comentario}"</p>
17+
<h4 class="font-bold mt-4 text-gray-900 dark:text-white">${resena.nombre}</h4>
18+
<span class="text-sm text-gray-500 dark:text-gray-400">${resena.curso}</span>
19+
</div>
20+
`;
21+
22+
reviewContainer.appendChild(slide);
23+
});
24+
25+
// Inicializar Swiper después de cargar las review
26+
new Swiper('.swiper-container', {
27+
loop: true,
28+
autoplay: { delay: 4000 },
29+
slidesPerView: 1,
30+
breakpoints: {
31+
640: { slidesPerView: 2 },
32+
1024: { slidesPerView: 3 }
33+
},
34+
pagination: { el: '.swiper-pagination', clickable: true }
35+
});
36+
37+
} catch (error) {
38+
console.error("Error cargando las reseñas:", error);
39+
}
40+
});

asset/js/sponsors.js

+48
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
2+
3+
document.addEventListener("DOMContentLoaded", async function () {
4+
const sponsorsWrapper = document.getElementById("sponsors-wrapper");
5+
6+
async function fetchSponsors() {
7+
try {
8+
const response = await fetch("/asset/data/sponsors.json");
9+
if (!response.ok) throw new Error("Error al cargar los sponsors.");
10+
const sponsors = await response.json();
11+
renderSponsors(sponsors);
12+
} catch (error) {
13+
console.error("Error:", error);
14+
sponsorsWrapper.innerHTML = `<p class="text-red-500 text-center">No se pudieron cargar los sponsors.</p>`;
15+
}
16+
}
17+
18+
function renderSponsors(sponsors) {
19+
sponsorsWrapper.innerHTML = ""; // Limpiar contenido previo
20+
21+
sponsors.forEach(sponsor => {
22+
const slide = document.createElement("div");
23+
slide.className = "swiper-slide flex justify-center";
24+
slide.innerHTML = `
25+
<div class="bg-white dark:bg-gray-800 shadow-lg rounded-xl p-4 flex justify-center items-center w-40 h-24">
26+
<img src="${sponsor.image}" alt="${sponsor.name}" class="h-16 object-contain">
27+
</div>
28+
`;
29+
sponsorsWrapper.appendChild(slide);
30+
});
31+
32+
// Inicializar Swiper después de renderizar los slides
33+
setTimeout(() => {
34+
new Swiper('.swiper-container', {
35+
loop: true,
36+
autoplay: { delay: 2500 },
37+
slidesPerView: 1,
38+
breakpoints: {
39+
640: { slidesPerView: 2 },
40+
1024: { slidesPerView: 3 }
41+
},
42+
pagination: { el: '.swiper-pagination', clickable: true }
43+
});
44+
}, 100);
45+
}
46+
47+
fetchSponsors();
48+
});

0 commit comments

Comments
 (0)