diff --git a/src/assets/images/turingcup-winners/TC_Winners2023.jpg b/src/assets/images/turingcup-winners/TC_Winners2023.jpg new file mode 100644 index 0000000..7e37944 Binary files /dev/null and b/src/assets/images/turingcup-winners/TC_Winners2023.jpg differ diff --git a/src/assets/images/turingcup-winners/TC_Winners2024.jpg b/src/assets/images/turingcup-winners/TC_Winners2024.jpg new file mode 100644 index 0000000..3721f42 Binary files /dev/null and b/src/assets/images/turingcup-winners/TC_Winners2024.jpg differ diff --git a/src/components/TuringCup/PastContests.js b/src/components/TuringCup/PastContests.js index 087bed1..b73509a 100644 --- a/src/components/TuringCup/PastContests.js +++ b/src/components/TuringCup/PastContests.js @@ -1,13 +1,15 @@ -import * as React from "react"; -import Accordion from "@mui/material/Accordion"; -import AccordionSummary from "@mui/material/AccordionSummary"; -import AccordionDetails from "@mui/material/AccordionDetails"; -import Typography from "@mui/material/Typography"; import ExpandMoreIcon from "@mui/icons-material/ExpandMore"; +import Looks3OutlinedIcon from "@mui/icons-material/Looks3Outlined"; import LooksOneOutlinedIcon from "@mui/icons-material/LooksOneOutlined"; import LooksTwoOutlinedIcon from "@mui/icons-material/LooksTwoOutlined"; -import Looks3OutlinedIcon from "@mui/icons-material/Looks3Outlined"; -import { Grid } from "@mui/material"; +import { Box, Grid } from "@mui/material"; +import Accordion from "@mui/material/Accordion"; +import AccordionDetails from "@mui/material/AccordionDetails"; +import AccordionSummary from "@mui/material/AccordionSummary"; +import Typography from "@mui/material/Typography"; +import { graphql, useStaticQuery } from "gatsby"; +import { GatsbyImage } from "gatsby-plugin-image"; +import * as React from "react"; const styles = { accordion: { @@ -32,15 +34,43 @@ const styles = { container: { margin: "auto", width: "75vw" - + // height : "10vw" } }; const contestdetails = [ + { + "year": "2024", + "image": "TC_Winners2024.jpg", + "report": "https://drive.google.com/file/d/1SrWLA-6psSmkW8QLzJukpljjif39AqGi/view", + "info": + "Students from all colleges across the nation can participate by forming a team of up to 2 members. The contest has 3 rounds. 1438 teams from 148 different colleges across the nation have registered for the contest. 746 teams have participated in the contest, out of which 60 teams have been invited to the Onsite round, and all the teams have attended the Onsite round, from which top 10 teams qualified for the Final Round.", + "winners": { + "first": { + "mem1": "Kishore Kumar", + "mem2": "Vidit Jain", + "mem3": "", + "college": "Indian Institute of Information Technology, Hyderabad" + }, + "second": { + "mem1": "Shiven Sinha", + "mem2": "", + "mem3": "", + "college": "Indian Institute of Information Technology, Hyderabad" + }, + "third": { + "mem1": "Anant Ojha", + "mem2": "Harsh Kumar", + "mem3": "", + "college": "Indian Institute of Information Technology, Bangalore" + } + } + }, { "year": "2023", - + "image": "TC_Winners2023.jpg", + "report": "https://drive.google.com/file/d/1KiwvD_QynytS_SljFAQGW6uV3pAmD1cp/view", "info": "Students from all colleges across the nation can participate by forming a team of up to 2 members. The contest has 3 rounds. 1078 teams from 190 different colleges across the nation have registered for the contest. 738 teams have participated in the contest, out of which 60 teams have been invited to the Onsite round, and all the teams have attended the Onsite round, from which top 10 teams qualified for the Final Round.", @@ -67,7 +97,8 @@ const contestdetails = [ }, { "year": "2022", - + "image": "NA", + "report": "NA", "info": "Students from all colleges across the nation can participate by forming a team of up to 2 members. The contest has 3 rounds. 753 teams from 50+ different colleges across the nation have registered for the contest. 690 teams have participated in the contest, out of which 80 teams have been invited to the Onsite round, and all the teams have attended the Onsite round, from which top 20 teams qualified for the Final Round.", @@ -94,6 +125,8 @@ const contestdetails = [ }, // { // "year" : "2020", + // "image" : "2020.jpg", + // "report" : "NA", // "info": "Lorem ipsum dolor sit amet consectetur adipisicing elit. Doloribus voluptatem sint quidem corporis consectetur quas. Laboriosam fugit enim veniam neque aliquid accusantium, et dicta impedit, explicabo officiis harum magni odio!", // "winners" : { // "first" : { @@ -112,6 +145,8 @@ const contestdetails = [ // }, { "year": "2019", + "image": "NA", + "report": "NA", "info": "Students from all colleges across the nation can participate by forming a team of up to 3 members. The contest has 2 rounds. 285 teams from both Telangana and Andhra Pradesh states have registered for the contest. 240 teams have participated in the contest, out of which 50 teams have been invited to the Onsite round, 36 teams have attended the Onsite round.", "winners": { @@ -119,20 +154,20 @@ const contestdetails = [ "mem1": "Kug3lBlitzz", "mem2": "", "mem3": "", - college: "VNR Vignana Jyothi Institute of Engineering & Technology" + "college": "VNR Vignana Jyothi Institute of Engineering & Technology" }, "second": { "mem1": "Sage_of_Six_Paths", "mem2": "", "mem3": "", - college: + "college": "Gokaraju Rangaraju Institute of Engineering and Technology, Hyderabad" }, "third": { "mem1": "LogunsPPPPD", "mem2": "", "mem3": "", - college: + "college": "University College of Engineering, Osmania University Hyderabad" } } @@ -140,10 +175,45 @@ const contestdetails = [ ]; function PastContests() { + const data = useStaticQuery(graphql` + query TuringcupWinnersQuery { + allFile(filter: { relativeDirectory: { eq: "turingcup-winners" } }) { + edges { + node { + childImageSharp { + gatsbyImageData( + width: 600 + height: 400 + blurredOptions: { width: 50 } + placeholder: BLURRED + transformOptions: { fit: COVER } + ) + } + name + } + } + } + } + `); + // console.log(data); + + const nodes = data.allFile.edges; + + const getImage = val => { + const result = nodes.filter(item => { + const src = item.node.name; + var filename = val.split('.')[0]; + return filename === src; + }); + return result.length > 0 + ? result[0].node.childImageSharp.gatsbyImageData + : null; + }; + return ( <>