Skip to content

Commit

Permalink
move cp images to /public
Browse files Browse the repository at this point in the history
  • Loading branch information
bhaskar1001101 committed Jul 11, 2024
1 parent c3051b9 commit 549ed04
Show file tree
Hide file tree
Showing 13 changed files with 24 additions and 23 deletions.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
47 changes: 24 additions & 23 deletions src/components/Cp/Cp.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,35 +2,35 @@ import React, { useState, useEffect } from 'react';
import './Cp.css';

const topImages = [
{ src: "src/assets/images/cp/cj.svg", alt: "cj" },
{ src: "src/assets/images/cp/cnhooghly.svg", alt: "cnhooghly" },
{ src: "src/assets/images/cp/dev.svg", alt: "dev" },
{ src: "src/assets/images/cp/ieee.svg", alt: "ieee" },
{ src: "src/assets/images/cp/gdsc.svg", alt: "gdsc" },
{ src: "/images/cj.svg", alt: "cj" },
{ src: "/images/cnhooghly.svg", alt: "cnhooghly" },
{ src: "/images/dev.svg", alt: "dev" },
{ src: "/images/ieee.svg", alt: "ieee" },
{ src: "/images/gdsc.svg", alt: "gdsc" },

// double for infinite loop
{ src: "src/assets/images/cp/cj.svg", alt: "cj" },
{ src: "src/assets/images/cp/cnhooghly.svg", alt: "cnhooghly" },
{ src: "src/assets/images/cp/dev.svg", alt: "dev" },
{ src: "src/assets/images/cp/ieee.svg", alt: "ieee" },
{ src: "src/assets/images/cp/gdsc.svg", alt: "gdsc" },
{ src: "/images/cj.svg", alt: "cj" },
{ src: "/images/cnhooghly.svg", alt: "cnhooghly" },
{ src: "/images/dev.svg", alt: "dev" },
{ src: "/images/ieee.svg", alt: "ieee" },
{ src: "/images/gdsc.svg", alt: "gdsc" },
];

const bottomImages = [
{ src: "src/assets/images/cp/iei.svg", alt: "iei" },
{ src: "src/assets/images/cp/iiitians.svg", alt: "iiitians" },
{ src: "src/assets/images/cp/rc.svg", alt: "rc" },
{ src: "src/assets/images/cp/thc.svg", alt: "thc" },
{ src: "src/assets/images/cp/gdscm.svg", alt: "gdscm" },
{ src: "src/assets/images/cp/vuchvilla.svg", alt: "vv" },
{ src: "/images/iei.svg", alt: "iei" },
{ src: "/images/iiitians.svg", alt: "iiitians" },
{ src: "/images/rc.svg", alt: "rc" },
{ src: "/images/thc.svg", alt: "thc" },
{ src: "/images/gdscm.svg", alt: "gdscm" },
{ src: "/images/vuchvilla.svg", alt: "vv" },

// double for infinite loop
{ src: "src/assets/images/cp/iei.svg", alt: "iei" },
{ src: "src/assets/images/cp/iiitians.svg", alt: "iiitians" },
{ src: "src/assets/images/cp/rc.svg", alt: "rc" },
{ src: "src/assets/images/cp/thc.svg", alt: "thc" },
{ src: "src/assets/images/cp/gdscm.svg", alt: "gdscm" },
{ src: "src/assets/images/cp/vuchvilla.svg", alt: "vv" },
{ src: "/images/iei.svg", alt: "iei" },
{ src: "/images/iiitians.svg", alt: "iiitians" },
{ src: "/images/rc.svg", alt: "rc" },
{ src: "/images/thc.svg", alt: "thc" },
{ src: "/images/gdscm.svg", alt: "gdscm" },
{ src: "/images/vuchvilla.svg", alt: "vv" },
];

const SimpleSlider = ({ images, direction }) => {
Expand Down Expand Up @@ -64,7 +64,8 @@ const SimpleSlider = ({ images, direction }) => {
{images.map((image, index) => (
<div key={index} className="slide my-3 sm:my-6 mx-4 sm:mx-10 w-[200px] sm:w-[30vw] md:w-[25vw] xl:w-[20vw]">
<img
src={image.src}
// adding the extra text to get it to display on github pages (only for dev) (remove before deploy)
src={(window.location.href == "https://iiitkalyanifosc.github.io/Hackathon-website-2024/" ? "/Hackathon-website-2024" : "") + image.src}
alt={image.alt}
className="slide-image"
style={{
Expand Down

0 comments on commit 549ed04

Please sign in to comment.