Skip to content

Commit

Permalink
Merge pull request #1514 from GeorgeET15/old-dev
Browse files Browse the repository at this point in the history
fix: fixed infinite API calls
  • Loading branch information
viraka authored May 19, 2024
2 parents ab75c1d + 1ba10ae commit d55d12f
Show file tree
Hide file tree
Showing 14 changed files with 5,801 additions and 2,570 deletions.
7,885 changes: 5,539 additions & 2,346 deletions package-lock.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/Components/Footer/Footer.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ const Footer = () => {
</a>

<a
href="https://www.youtube.com/c/mulearn"
href="https://www.youtube-nocookie.com/c/mulearn"
target="_blank"
rel="noopener noreferrer"
>
Expand Down
1 change: 1 addition & 0 deletions src/Components/Testimonials/Card.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ const Card = ({ person }) => {
frameborder="0"
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
allowfullscreen
loading="lazy"
></iframe>
</div>
</>
Expand Down
82 changes: 41 additions & 41 deletions src/Components/Testimonials/testimonials-data.json
Original file line number Diff line number Diff line change
@@ -1,42 +1,42 @@
[
{
"name": "Dr Saji Gopinath",
"video": "https://www.youtube.com/embed/LgDKzzz8xp4"
},
{
"name": "Dr Pv Unnikrishnan",
"video": "https://www.youtube.com/embed/Rn2v9mkar4Q"
},
{
"name": "K. N. Balagopal",
"video": "https://www.youtube.com/embed/XoybSPRL3pw"
},
{
"name": "Anoop P Ambika",
"video": "https://www.youtube.com/embed/UcAM0_Kgbn0"
},
{
"name": "Dr P. K. Biju",
"video": "https://www.youtube.com/embed/tvmqUINECCI"
},
{
"name": "Dr RAJASREE M S",
"video": "https://www.youtube.com/embed/Kx2lRDjzMMk"
},
{
"name": "Google",
"video": "https://www.youtube.com/embed/b7u86JWH6ww"
},
{
"name": "Rajeev",
"video": "https://www.youtube.com/embed/duM15-tOwFo"
},
{
"name": "Sangeetha ",
"video": "https://www.youtube.com/embed/SyxOSPx4b5o"
},
{
"name": "Joy sebastian",
"video": "https://www.youtube.com/embed/X79zbLQufl0"
}
]
{
"name": "Dr Saji Gopinath",
"video": "https://www.youtube-nocookie.com/embed/LgDKzzz8xp4"
},
{
"name": "Dr Pv Unnikrishnan",
"video": "https://www.youtube-nocookie.com/embed/Rn2v9mkar4Q"
},
{
"name": "K. N. Balagopal",
"video": "https://www.youtube-nocookie.com/embed/XoybSPRL3pw"
},
{
"name": "Anoop P Ambika",
"video": "https://www.youtube-nocookie.com/embed/UcAM0_Kgbn0"
},
{
"name": "Dr P. K. Biju",
"video": "https://www.youtube-nocookie.com/embed/tvmqUINECCI"
},
{
"name": "Dr RAJASREE M S",
"video": "https://www.youtube-nocookie.com/embed/Kx2lRDjzMMk"
},
{
"name": "Google",
"video": "https://www.youtube-nocookie.com/embed/b7u86JWH6ww"
},
{
"name": "Rajeev",
"video": "https://www.youtube-nocookie.com/embed/duM15-tOwFo"
},
{
"name": "Sangeetha ",
"video": "https://www.youtube-nocookie.com/embed/SyxOSPx4b5o"
},
{
"name": "Joy sebastian",
"video": "https://www.youtube-nocookie.com/embed/X79zbLQufl0"
}
]
51 changes: 28 additions & 23 deletions src/Pages/ArtOfTeaching/ArtOfTeaching.jsx
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
import React from "react"
import Navbar from "../../Components/Navbar/Navbar"
import Footer from "../../Components/Footer/Footer"
import React from "react";
import Navbar from "../../Components/Navbar/Navbar";
import Footer from "../../Components/Footer/Footer";

import styles from "./ArtOfTeaching.module.css"
import "./ArtOfTeaching.scss"
import styles from "./ArtOfTeaching.module.css";
import "./ArtOfTeaching.scss";

import Faq from "react-faq-component"
import Faq from "react-faq-component";

import fvimg from "./assets/fvimg.gif"
import fvimg from "./assets/fvimg.gif";

import MentorCard from "../../Components/MentorCard/MentorCard"
import MentorCard from "../../Components/MentorCard/MentorCard";

import { Swiper, SwiperSlide } from "swiper/react"
import { Swiper, SwiperSlide } from "swiper/react";

// Import Swiper styles
import "swiper/css"
import "swiper/css/pagination"
import "swiper/css/navigation"
import "swiper/css";
import "swiper/css/pagination";
import "swiper/css/navigation";

// import { Pagination, Navigation } from "swiper"

Expand Down Expand Up @@ -50,15 +50,15 @@ const ArtOfTeaching = () => {
"Yes, you can resubmit your entry if you think your previous submission lacked a certain element that you aimed for.",
},
],
}
};

const fstyles = {
// bgColor: 'white',
titleTextColor: "#f78c40",
rowTitleColor: "#404040",
rowContentColor: "#373737",
arrowColor: "#f78c40",
}
};
return (
<>
<Navbar />
Expand All @@ -72,8 +72,9 @@ const ArtOfTeaching = () => {

<p className={styles.fv_tagline}>
µLearn is back with Art of Teaching to honor teachers who mould
our future generation. µLearn Foundation is partnering with Google
developers, KTU and Kerala University for Art of Teaching 2.0.
our future generation. µLearn Foundation is partnering with
Google developers, KTU and Kerala University for Art of Teaching
2.0.
</p>
<div className={styles.event_partners}>
<div className={styles.partners}>
Expand Down Expand Up @@ -292,11 +293,12 @@ const ArtOfTeaching = () => {
<div className={styles.ytplayer}>
<iframe
className={styles.yt_video}
src="https://www.youtube.com/embed/vPLuA5kXoBI"
src="https://www.youtube-nocookie.com/embed/vPLuA5kXoBI"
title="YouTube video player"
frameborder="0"
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
allowfullscreen
loading="lazy"
></iframe>
</div>
</div>
Expand Down Expand Up @@ -366,31 +368,34 @@ const ArtOfTeaching = () => {
<div className={styles.video}>
<iframe
className={styles.ytvideo}
src="https://www.youtube.com/embed/Wmo0StqW9Kc"
src="https://www.youtube-nocookie.com/embed/Wmo0StqW9Kc"
title="YouTube video player"
frameborder="0"
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
allowfullscreen
loading="lazy"
></iframe>
</div>
<div className={styles.video}>
<iframe
className={styles.ytvideo}
src="https://www.youtube.com/embed/TEylubYDzhQ"
src="https://www.youtube-nocookie.com/embed/TEylubYDzhQ"
title="YouTube video player"
frameborder="0"
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
allowfullscreen
loading="lazy"
></iframe>
</div>
<div className={styles.video}>
<iframe
className={styles.ytvideo}
src="https://www.youtube.com/embed/jRcseEVk2sk"
src="https://www.youtube-nocookie.com/embed/jRcseEVk2sk"
title="YouTube video player"
frameborder="0"
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
allowfullscreen
loading="lazy"
></iframe>
</div>
</div>
Expand All @@ -405,7 +410,7 @@ const ArtOfTeaching = () => {
</div>
<Footer />
</>
)
}
);
};

export default ArtOfTeaching
export default ArtOfTeaching;
43 changes: 25 additions & 18 deletions src/Pages/CampusChapters/CampusChapters.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,18 @@ const CampusChapters = () => {
const [districts, setDistricts] = useState([]);
const [selectedDistrict, setSelectedDistrict] = useState("all");
const [campusData, setCampusData] = useState([]);
const districtZone={
'South':['Pathanamthitta','Trivandrum','Kollam'],
'Central':['Alappuzha','Ernakulam','Kottayam','Idukki'],
'North':['Palakkad','Thrissur','Kasaragod','Malappuram','Kozhikode','Kannur']
}
const districtZone = {
South: ["Pathanamthitta", "Trivandrum", "Kollam"],
Central: ["Alappuzha", "Ernakulam", "Kottayam", "Idukki"],
North: [
"Palakkad",
"Thrissur",
"Kasaragod",
"Malappuram",
"Kozhikode",
"Kannur",
],
};

useEffect(() => {
axios
Expand Down Expand Up @@ -167,13 +174,13 @@ const CampusChapters = () => {
{
//iterate through the districts array and return the option element
districts
.filter((district) => {
if (selectedZone === 'all') return true
return ( districtZone[selectedZone].includes(district) )
})
.map((district) => {
return <option value={district}>{district}</option>
})
.filter((district) => {
if (selectedZone === "all") return true;
return districtZone[selectedZone].includes(district);
})
.map((district) => {
return <option value={district}>{district}</option>;
})
}
</select>
</div>
Expand All @@ -184,11 +191,11 @@ const CampusChapters = () => {
// return the campuses that match the selected zone
if (
(campus.zone === selectedZone &&
selectedDistrict === "all") |
selectedDistrict === "all") |
(campus.zone === selectedZone &&
campus.district === selectedDistrict) |
(selectedZone === 'all' &&
campus.district === selectedDistrict)
campus.district === selectedDistrict) |
(selectedZone === "all" &&
campus.district === selectedDistrict)
) {
return (
<div className={styles.college}>
Expand Down Expand Up @@ -317,13 +324,13 @@ const CampusChapters = () => {
<div className={styles.d_video_container}>
<div className={styles.d_video}>
<iframe
src="https://www.youtube.com/embed/3sycnoFCeaM?si=a0t4z26fI-BaO5C_"
src="https://www.youtube-nocookie.com/embed/3sycnoFCeaM?si=a0t4z26fI-BaO5C_"
title="YouTube video player"
frameborder="0"
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
allowfullscreen
loading="lazy"
></iframe>

</div>

<div className={styles.d_main_container}>
Expand Down
2 changes: 1 addition & 1 deletion src/Pages/CapTF/Level1.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ const Level1 = () => {
+ Muhammad Kutty Panaparambil Ismai's Son
</p>
<a
href="https://www.youtube.com/watch?v=dQw4w9WgXcQ"
href="https://www.youtube-nocookie.com/watch?v=dQw4w9WgXcQ"
target="_blank"
rel="noopener noreferrer"
>
Expand Down
2 changes: 1 addition & 1 deletion src/Pages/CapTF/Submission.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ const Submission = () => {
<a
href={
showParam === "true" || name !== "Secret Key"
? "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
? "https://www.youtube-nocookie.com/watch?v=dQw4w9WgXcQ"
: process.env.REACT_APP_CTF_SUMISSION_LINK
}
target="_blank"
Expand Down
Loading

0 comments on commit d55d12f

Please sign in to comment.