From 9608460e7818419c70f116dff6086f8f353f543c Mon Sep 17 00:00:00 2001 From: imi21123 Date: Thu, 7 Mar 2024 20:53:02 +0900 Subject: [PATCH 1/2] =?UTF-8?q?Feat:=20Banner=20onClick=20=EC=82=AD?= =?UTF-8?q?=EC=A0=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/views/Home/Banner/Banner.jsx | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/components/views/Home/Banner/Banner.jsx b/src/components/views/Home/Banner/Banner.jsx index ec182fc..5ab0158 100644 --- a/src/components/views/Home/Banner/Banner.jsx +++ b/src/components/views/Home/Banner/Banner.jsx @@ -26,12 +26,7 @@ const Banner = () => { {eventBanners.map((item) => { return ( -
navigate(item.redirectUrl)} - key={item} - > +
{`Banner
); From 499673c8c080117d1238ebd6bce5bfe5bea4f5e3 Mon Sep 17 00:00:00 2001 From: imi21123 Date: Thu, 7 Mar 2024 20:55:59 +0900 Subject: [PATCH 2/2] =?UTF-8?q?Fix:=20=EC=95=88=EC=93=B0=EB=8A=94=20?= =?UTF-8?q?=EC=BD=94=EB=93=9C=20=EC=82=AD=EC=A0=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/views/Home/Banner/Banner.jsx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/components/views/Home/Banner/Banner.jsx b/src/components/views/Home/Banner/Banner.jsx index 5ab0158..94e2c9a 100644 --- a/src/components/views/Home/Banner/Banner.jsx +++ b/src/components/views/Home/Banner/Banner.jsx @@ -1,5 +1,4 @@ import React, { useState } from "react"; -import { useNavigate } from "react-router-dom"; import Slider from "react-slick"; import "slick-carousel/slick/slick-theme.css"; import "slick-carousel/slick/slick.css"; @@ -9,7 +8,6 @@ import "./Banner.css"; const Banner = () => { const eventBanners = useFetchEventBanners(); //이벤트 배너를 서버에서 받아옴 const [currentIndex, setCurrentIndex] = useState(0); - const navigate = useNavigate(); const settings = { slidesToShow: 1, @@ -20,6 +18,7 @@ const Banner = () => { autoplaySpeed: 1800, //1.8s afterChange: (currentSlide) => setCurrentIndex(currentSlide), //이게 인덱스값 업데이트용 }; + return (