Skip to content

Commit 12c40f0

Browse files
committed
winners
1 parent 25894ec commit 12c40f0

File tree

11 files changed

+59
-16
lines changed

11 files changed

+59
-16
lines changed

package-lock.json

Lines changed: 11 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
"@studio-freight/lenis": "^1.0.42",
2222
"@tsparticles/react": "^3.0.0",
2323
"animejs": "^4.0.2",
24+
"canvas-confetti": "^1.9.3",
2425
"drei": "^2.2.21",
2526
"framer-motion": "^12.4.3",
2627
"gsap": "^3.12.7",
431 KB
Loading
379 KB
Loading
485 KB
Loading

src/app/page.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ export default function Portfolio() {
3131
<main className={inter.className}>
3232
<Navbar />
3333
<Hero />
34-
<LumaEmbed/>
3534
<div className="opacity-0 animate-fadeIn">
3635
<SponsoredBy />
3736
<Projects/>

src/app/projects-carrousel.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ const projectsData: Project[] = [
6464
slidesUrl: "../projects-BSc/henry_miguel.pdf",
6565
repoUrl: "https://github.com/HenryMantilla/Stereo-Lidar-Fusion",
6666
},
67-
// ...more projects
67+
// ...mas proyectos
6868
];
6969

7070
export default function ProjectsCarousel() {

src/app/proyectos/[id]/page.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,10 @@ import { notFound } from "next/navigation";
33
import ProjectPage from "@/components/project-page";
44
import { projects } from "@/components/projects";
55

6-
// ① Le dices a Next qué ids pre-renderizar
76
export async function generateStaticParams() {
87
return projects.map((p) => ({ id: p.id }));
98
}
109

11-
// ② Idéntica firma asíncrona con params: Promise<{id:string}>
1210
export default async function ProjectRoute({
1311
params,
1412
}: {

src/components/navbar.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ const NAV_MENU = [
6363
{ name: "Sesiones", icon: RocketLaunchIcon, href: "/sesiones" },
6464
{ name: "Galería", icon: CameraIcon, href: "/galeria" },
6565
{ name: "Nosotros", icon: UserIcon, href: "/nosotros" },
66-
{ name: "Proyectos Finales", icon: TrophyIcon, href: "https://semillerocv.github.io/sesiones/sesion12" },
66+
{ name: "Proyectos", icon: TrophyIcon, href: "/sesiones/sesion12" },
6767
{
6868
name: "2024",
6969
icon: ArrowRightOnRectangleIcon,

src/components/project-page.tsx

Lines changed: 30 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import { Navbar } from "@/components";
99
import { Project as ProjectData } from "@/components/projects";
1010
import { Container, Engine, InteractivityDetect } from "@tsparticles/engine";
1111
import { FaGithub, FaFilePowerpoint, FaUsers } from "react-icons/fa";
12+
import confetti from 'canvas-confetti';
1213

1314
interface ProjectPageProps {
1415
project: ProjectData;
@@ -95,6 +96,20 @@ export default function ProjectPage({ project }: ProjectPageProps) {
9596
project.photo4,
9697
].filter((p): p is string => Boolean(p));
9798
const isFour = photos.length === 4;
99+
useEffect(() => {
100+
if (project.id === "equipo3" || project.id === "equipo4" || project.id === "equipo9") {
101+
const timer = setTimeout(() => {
102+
confetti({
103+
particleCount: 150,
104+
spread: 70,
105+
origin: { y: 0.6 },
106+
colors: ['#2DD4BF', '#34D399', '#10B981', '#059669']
107+
});
108+
}, 1000);
109+
110+
return () => clearTimeout(timer);
111+
}
112+
}, [project.id]);
98113

99114
const containerVariants = {
100115
hidden: {},
@@ -159,7 +174,7 @@ export default function ProjectPage({ project }: ProjectPageProps) {
159174
variants={itemVariants}
160175
className="flex flex-col space-y-2 sm:space-y-4 xl:mr-36"
161176
>
162-
{/* {project.repoUrl && (
177+
{project.repoUrl && (
163178
<motion.a
164179
href={project.repoUrl}
165180
target="_blank"
@@ -172,7 +187,7 @@ export default function ProjectPage({ project }: ProjectPageProps) {
172187
Ver Código
173188
</span>
174189
</motion.a>
175-
)} */}
190+
)}
176191
{project.slidesUrl && (
177192
<motion.a
178193
href={project.slidesUrl}
@@ -201,6 +216,19 @@ export default function ProjectPage({ project }: ProjectPageProps) {
201216
className="object-cover"
202217
priority
203218
/>
219+
{(project.id === "equipo3" ||
220+
project.id === "equipo4" ||
221+
project.id === "equipo9") && (
222+
<div className="absolute bottom-2 right-2 z-10 w-1/3 sm:w-1/4 md:w-1/5 h-auto">
223+
<Image
224+
src={project.winnerImage!}
225+
alt="Detalle adicional"
226+
width={100}
227+
height={100}
228+
className="object-contain w-full h-auto"
229+
/>
230+
</div>
231+
)}
204232
</motion.div>
205233

206234
<motion.div

0 commit comments

Comments
 (0)