diff --git a/design-system/ui/textFields/SearchTextField.tsx b/design-system/ui/textFields/SearchTextField.tsx index 82f7682..091619f 100644 --- a/design-system/ui/textFields/SearchTextField.tsx +++ b/design-system/ui/textFields/SearchTextField.tsx @@ -20,7 +20,7 @@ const SearchTextField = forwardRef( onChange={onChange} placeholder={placeholder} {...rest} - className="w-full sm:h-6 md:h-7 border-[0.3px] border-black rounded-[3px] px-2 outline-none placeholder:text-placeholderText text-xs font-light" + className="w-full h-7 md:h-8 border-[0.3px] border-black rounded-[3px] px-2 outline-none placeholder:text-placeholderText text-xs font-light" />
{iconPath}
diff --git a/src/pages/home/ui/MainPage.tsx b/src/pages/home/ui/MainPage.tsx index c05789d..a6405ce 100644 --- a/src/pages/home/ui/MainPage.tsx +++ b/src/pages/home/ui/MainPage.tsx @@ -17,6 +17,7 @@ import rightButton from '../../../../public/assets/main/RightButton.svg'; import leftButton from '../../../../public/assets/main/LeftButton.svg'; import { AnimatePresence } from 'framer-motion'; import LoginModal from '../../../widgets/main/ui/LoginModal'; +import { cardButtons } from '../../../shared/types/mainCardButtonType'; const MainPage = () => { const images = [ @@ -25,29 +26,6 @@ const MainPage = () => { { img: thirdPage, link: 'https://example.com/page3' }, ]; - // 버튼 데이터 - const cardButtons = [ - { - iconPath: '/assets/main/DevStudy.svg', - label: '개발/스터디', - onClick: () => console.log('DevStudy clicked'), - }, - { - iconPath: '/assets/main/Networking.svg', - label: '네트워킹', - onClick: () => console.log('Networking clicked'), - }, - { - iconPath: '/assets/main/Hackathon.svg', - label: '해커톤', - onClick: () => console.log('Hackathon clicked'), - }, - { - iconPath: '/assets/main/Conference.svg', - label: '컨퍼런스', - onClick: () => console.log('Conference clicked'), - }, - ]; const [modalOpen, setModalOpen] = useState(false); const [latestStartIndex, setLatestStartIndex] = useState(0); const [trendingStartIndex, setTrendingStartIndex] = useState(0); @@ -64,16 +42,6 @@ const MainPage = () => { const handlePrev = (setStartIndex: SetStartIndex, currentIndex: number, eventsLength: number): void => { setStartIndex((currentIndex - 1 + eventsLength) % eventsLength); }; - const handleEventCardClick = () => { - navigate('/event-details'); - }; - const handleAllEventsButtonClick = () => { - navigate('/all-events'); - }; - - const handleSearchButtonClick = () => { - navigate('/search'); - }; return (
@@ -81,7 +49,7 @@ const MainPage = () => { centerContent={ } - onClick={handleSearchButtonClick} + onClick={() => navigate('/search')} onChange={() => {}} placeholder="입력해주세요" /> @@ -130,7 +98,7 @@ const MainPage = () => { eventDate={event.eventDate} location={event.location} hashtags={event.hashtags} - onClick={handleEventCardClick} + onClick={() => navigate('/event-details')} /> ))}
@@ -219,7 +187,7 @@ const MainPage = () => { />