From c051c45e9f96db7ad5a8537aa7a911841a22c46b Mon Sep 17 00:00:00 2001 From: jnkeniaem Date: Tue, 13 Aug 2024 16:09:06 +0900 Subject: [PATCH 01/11] =?UTF-8?q?[FE]=20FIX:=20debounce=20=EC=A0=81?= =?UTF-8?q?=EC=9A=A9=ED=95=B4=20=EC=BD=94=EC=9D=B8=20=EB=82=B4=EC=97=AD=20?= =?UTF-8?q?=ED=8E=98=EC=9D=B4=EC=A7=80=20=ED=95=84=ED=84=B0=20=EB=B3=80?= =?UTF-8?q?=EA=B2=BD=EC=8B=9C=20=EB=B6=88=ED=95=84=EC=9A=94=ED=95=9C=20api?= =?UTF-8?q?=20=EC=9A=94=EC=B2=AD=20=EB=B3=B4=EB=82=B4=EC=A7=80=20=EC=95=8A?= =?UTF-8?q?=EA=B2=8C=20=EC=88=98=EC=A0=95=20#1677?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/Cabinet/components/Store/CoinLog/CoinLog.tsx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/frontend/src/Cabinet/components/Store/CoinLog/CoinLog.tsx b/frontend/src/Cabinet/components/Store/CoinLog/CoinLog.tsx index b6d867c8c..425692936 100644 --- a/frontend/src/Cabinet/components/Store/CoinLog/CoinLog.tsx +++ b/frontend/src/Cabinet/components/Store/CoinLog/CoinLog.tsx @@ -11,6 +11,7 @@ import { ReactComponent as CoinIcon } from "@/Cabinet/assets/images/coinIcon.svg import { ReactComponent as Select } from "@/Cabinet/assets/images/selectMaincolor.svg"; import { CoinLogToggleType } from "@/Cabinet/types/enum/store.enum"; import { axiosCoinLog } from "@/Cabinet/api/axios/axios.custom"; +import useDebounce from "@/Cabinet/hooks/useDebounce"; import { formatDate } from "@/Cabinet/utils/dateUtils"; const toggleList: toggleItem[] = [ @@ -44,10 +45,11 @@ const CoinLog = () => { const [userInfo] = useRecoilState(userState); const size = 5; // NOTE : size 만큼 데이터 불러옴 + const { debounce } = useDebounce(); - const getCoinLog = async (type: CoinLogToggleType) => { + const getCoinLog = async () => { try { - const response = await axiosCoinLog(type, page, size); + const response = await axiosCoinLog(toggleType, page, size); if (page === 0) { setCoinLogs(response.data.result); } else { @@ -71,9 +73,7 @@ const CoinLog = () => { }; useEffect(() => { - setTimeout(() => { - getCoinLog(toggleType); - }, 333); + debounce("coinLog", getCoinLog, 100); }, [page, toggleType]); useEffect(() => { From ac7b11eec89df03c409bc7c2873cb2a06ad60b28 Mon Sep 17 00:00:00 2001 From: jnkeniaem Date: Tue, 13 Aug 2024 18:31:23 +0900 Subject: [PATCH 02/11] =?UTF-8?q?[FE]=20FIX:=20=EA=B3=B5=EC=9C=A0=EC=82=AC?= =?UTF-8?q?=EB=AC=BC=ED=95=A8=20=EC=BD=94=EB=93=9C=20=EB=B3=B5=EC=82=AC,?= =?UTF-8?q?=20=ED=81=B4=EB=9F=BD=20=EB=A9=A4=EB=B2=84=EB=A6=AC=EC=8A=A4?= =?UTF-8?q?=ED=8A=B8=EC=99=80=20=EC=95=84=EC=9D=B4=ED=85=9C=20=EC=82=AC?= =?UTF-8?q?=EC=9A=A9=20=EB=82=B4=EC=97=AD=20=EB=B6=88=EB=9F=AC=EC=98=A4?= =?UTF-8?q?=EA=B8=B0=EC=97=90=EC=84=9C=20debouncing=20=EC=A0=81=EC=9A=A9#1?= =?UTF-8?q?677?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../CabinetInfoArea/CountTime/CodeAndTime.tsx | 12 +++++++++--- .../ClubMemberList/ClubMemberList.container.tsx | 16 +++++++++++----- frontend/src/Cabinet/pages/ItemUsageLogPage.tsx | 15 +++++++++++---- frontend/src/Cabinet/pages/PostLogin.tsx | 1 + 4 files changed, 32 insertions(+), 12 deletions(-) diff --git a/frontend/src/Cabinet/components/CabinetInfoArea/CountTime/CodeAndTime.tsx b/frontend/src/Cabinet/components/CabinetInfoArea/CountTime/CodeAndTime.tsx index c3c013be9..1984630d3 100644 --- a/frontend/src/Cabinet/components/CabinetInfoArea/CountTime/CodeAndTime.tsx +++ b/frontend/src/Cabinet/components/CabinetInfoArea/CountTime/CodeAndTime.tsx @@ -5,6 +5,7 @@ import { myCabinetInfoState } from "@/Cabinet/recoil/atoms"; import alertImg from "@/Cabinet/assets/images/cautionSign.svg"; import { ReactComponent as ClockImg } from "@/Cabinet/assets/images/clock.svg"; import { MyCabinetInfoResponseDto } from "@/Cabinet/types/dto/cabinet.dto"; +import useDebounce from "@/Cabinet/hooks/useDebounce"; interface CountTimeProps { minutes: string; @@ -17,13 +18,18 @@ const CodeAndTime = ({ minutes, seconds, isTimeOver }: CountTimeProps) => { useRecoilValue(myCabinetInfoState); const code = myCabinetInfo.shareCode + ""; const [copySuccess, setCopySuccess] = useState(false); + const { debounce } = useDebounce(); const handleCopyClick = () => { navigator.clipboard.writeText(code).then(() => { setCopySuccess(true); - setTimeout(() => { - setCopySuccess(false); - }, 2000); + debounce( + "codeAndTimeCopyClick", + () => { + setCopySuccess(false); + }, + 2000 + ); }); }; diff --git a/frontend/src/Cabinet/components/Club/ClubMemberList/ClubMemberList.container.tsx b/frontend/src/Cabinet/components/Club/ClubMemberList/ClubMemberList.container.tsx index 0df8e737c..aa08a10c2 100644 --- a/frontend/src/Cabinet/components/Club/ClubMemberList/ClubMemberList.container.tsx +++ b/frontend/src/Cabinet/components/Club/ClubMemberList/ClubMemberList.container.tsx @@ -1,11 +1,12 @@ import { useEffect, useState } from "react"; -import { useRecoilState, useRecoilValue } from "recoil"; -import { targetClubUserInfoState, userState } from "@/Cabinet/recoil/atoms"; +import { useRecoilState } from "recoil"; +import { targetClubUserInfoState } from "@/Cabinet/recoil/atoms"; import ClubMemberList from "@/Cabinet/components/Club/ClubMemberList/ClubMemberList"; import { ClubInfoResponseDto, ClubUserResponseDto, } from "@/Cabinet/types/dto/club.dto"; +import useDebounce from "@/Cabinet/hooks/useDebounce"; import useMenu from "@/Cabinet/hooks/useMenu"; export type TClubMemberModalState = "addModal"; @@ -36,12 +37,17 @@ const ClubMemberListContainer = ({ const [targetClubUser, setTargetClubUser] = useRecoilState( targetClubUserInfoState ); + const { debounce } = useDebounce(); const clickMoreButton = () => { setIsLoading(true); - setTimeout(() => { - setPage(page + 1); - }, 100); + debounce( + "clubMemberList", + () => { + setPage(page + 1); + }, + 100 + ); }; const selectClubMemberOnClick = (member: ClubUserResponseDto) => { diff --git a/frontend/src/Cabinet/pages/ItemUsageLogPage.tsx b/frontend/src/Cabinet/pages/ItemUsageLogPage.tsx index f34eb2c90..455e6d119 100644 --- a/frontend/src/Cabinet/pages/ItemUsageLogPage.tsx +++ b/frontend/src/Cabinet/pages/ItemUsageLogPage.tsx @@ -7,6 +7,7 @@ import { ItemIconMap } from "@/Cabinet/assets/data/maps"; import { ReactComponent as DropdownChevron } from "@/Cabinet/assets/images/dropdownChevron.svg"; import { StoreItemType } from "@/Cabinet/types/enum/store.enum"; import { axiosGetItemUsageHistory } from "@/Cabinet/api/axios/axios.custom"; +import useDebounce from "@/Cabinet/hooks/useDebounce"; const mapItemNameToType = (itemName: string): StoreItemType => { switch (itemName) { @@ -55,8 +56,9 @@ const ItemUsageLogPage = () => { const [isMoreBtnLoading, setIsMoreBtnLoading] = useState(true); const [isLoading, setIsLoading] = useState(true); const size = 5; + const { debounce } = useDebounce(); - const getItemUsageLog = async (page: number, size: number) => { + const getItemUsageLog = async () => { try { const data = await axiosGetItemUsageHistory(page, size); const newLogs = createLogEntries(data); @@ -72,13 +74,19 @@ const ItemUsageLogPage = () => { useEffect(() => { setTimeout(() => { - getItemUsageLog(page, size); + getItemUsageLog(); }, 333); }, [page]); const handleMoreClick = () => { - setPage((prev) => prev + 1); setIsMoreBtnLoading(true); + debounce( + "itemUsageLog", + () => { + setPage((prev) => prev + 1); + }, + 333 + ); }; return ( @@ -111,7 +119,6 @@ const ItemUsageLogPage = () => { {isMoreBtnLoading ? ( diff --git a/frontend/src/Cabinet/pages/PostLogin.tsx b/frontend/src/Cabinet/pages/PostLogin.tsx index c840badad..ef31dbbd8 100644 --- a/frontend/src/Cabinet/pages/PostLogin.tsx +++ b/frontend/src/Cabinet/pages/PostLogin.tsx @@ -46,6 +46,7 @@ const PostLogin = (): JSX.Element => { let time = setTimeout(() => { navigate("/home"); }, 600); + return () => { clearTimeout(time); }; From e9da7497a3e8e9a3b02d9e5d97f9466827e94738 Mon Sep 17 00:00:00 2001 From: jnkeniaem Date: Tue, 13 Aug 2024 21:30:06 +0900 Subject: [PATCH 03/11] =?UTF-8?q?[FE]=20FIX:=20AvailablePage=EC=97=90?= =?UTF-8?q?=EC=84=9C=20=ED=95=84=EC=9A=94=EC=97=86=EB=8A=94=20=EC=BD=94?= =?UTF-8?q?=EB=93=9C=20=EC=82=AD=EC=A0=9C#1677?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/Cabinet/components/Search/SearchCabinetDetails.tsx | 6 +----- .../Cabinet/components/Search/SearchNoCabinetDetails.tsx | 1 - frontend/src/Cabinet/pages/AvailablePage.tsx | 6 +----- 3 files changed, 2 insertions(+), 11 deletions(-) diff --git a/frontend/src/Cabinet/components/Search/SearchCabinetDetails.tsx b/frontend/src/Cabinet/components/Search/SearchCabinetDetails.tsx index 8861c7450..b092bb807 100644 --- a/frontend/src/Cabinet/components/Search/SearchCabinetDetails.tsx +++ b/frontend/src/Cabinet/components/Search/SearchCabinetDetails.tsx @@ -49,9 +49,7 @@ const SearchCabinetDetails = (props: ISearchDetail) => { ); const { openCabinet, closeCabinet } = useMenu(); const CabinetIcon = - cabinetIconComponentMap[ - cabinetInfo?.lentType || CabinetType.PRIVATE - ]; + cabinetIconComponentMap[cabinetInfo?.lentType || CabinetType.PRIVATE]; const clickSearchItem = () => { if ( @@ -150,7 +148,6 @@ const SearchCabinetDetails = (props: ISearchDetail) => { ); }; - const WrapperStyled = styled.div` width: 350px; height: 110px; @@ -252,4 +249,3 @@ const ButtonWrapper = styled.div` `; export default SearchCabinetDetails; - diff --git a/frontend/src/Cabinet/components/Search/SearchNoCabinetDetails.tsx b/frontend/src/Cabinet/components/Search/SearchNoCabinetDetails.tsx index 455a58aed..6456dfc49 100644 --- a/frontend/src/Cabinet/components/Search/SearchNoCabinetDetails.tsx +++ b/frontend/src/Cabinet/components/Search/SearchNoCabinetDetails.tsx @@ -145,7 +145,6 @@ const SearchNoCabinetDetails = (props: ISearchDetail) => { ); }; - const WrapperStyled = styled.div` width: 350px; height: 110px; diff --git a/frontend/src/Cabinet/pages/AvailablePage.tsx b/frontend/src/Cabinet/pages/AvailablePage.tsx index 9cd4291a4..82ebd53ff 100644 --- a/frontend/src/Cabinet/pages/AvailablePage.tsx +++ b/frontend/src/Cabinet/pages/AvailablePage.tsx @@ -98,10 +98,6 @@ const AvailablePage = () => { useEffect(() => { deleteRecoilPersistFloorSection(); - setTimeout(() => { - // 새로고침 광클 방지를 위한 초기 로딩 딜레이 - setIsLoaded(true); - }, 500); }, []); useEffect(() => { @@ -156,7 +152,7 @@ const AvailablePage = () => { /> - {isLoaded && cabinets ? ( + {Object.keys(cabinets).length ? ( Object.entries(cabinets).map(([key, value]) => ( Date: Tue, 20 Aug 2024 15:22:51 +0900 Subject: [PATCH 04/11] =?UTF-8?q?[FE]=20FIX:=20UserCabinetInfoArea.tsx?= =?UTF-8?q?=EC=97=90=EC=84=9C=20font=20color=20=EA=B0=92=20=EB=AC=B8?= =?UTF-8?q?=EB=B2=95=EC=A0=81=20=EC=97=90=EB=9F=AC=20=ED=95=B4=EA=B2=B0=20?= =?UTF-8?q?#1677?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config | 2 +- .../components/UserCabinetInfoArea/UserCabinetInfoArea.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/config b/config index d72c8b1fb..f185aa6c7 160000 --- a/config +++ b/config @@ -1 +1 @@ -Subproject commit d72c8b1fb948031bd8084f72dc42c713f16d2152 +Subproject commit f185aa6c734e4c7f8dd672610802e25c5c4f8d3e diff --git a/frontend/src/Cabinet/components/UserCabinetInfoArea/UserCabinetInfoArea.tsx b/frontend/src/Cabinet/components/UserCabinetInfoArea/UserCabinetInfoArea.tsx index 67840970f..10071a05d 100644 --- a/frontend/src/Cabinet/components/UserCabinetInfoArea/UserCabinetInfoArea.tsx +++ b/frontend/src/Cabinet/components/UserCabinetInfoArea/UserCabinetInfoArea.tsx @@ -59,7 +59,7 @@ const UserCabinetInfoArea: React.FC<{ - + {selectedUserInfo.name} From fb876b19eae8d01ab2fe13de03f2bb82c7174b9e Mon Sep 17 00:00:00 2001 From: jnkeniaem Date: Tue, 20 Aug 2024 15:41:57 +0900 Subject: [PATCH 05/11] =?UTF-8?q?[FE]=20FIX:=20z-index=20=EC=82=AD?= =?UTF-8?q?=EC=A0=9C=ED=95=B4=EC=84=9C=20=ED=8F=AC=EC=9D=B8=ED=8A=B8=20?= =?UTF-8?q?=EC=BB=AC=EB=9F=AC=20=EC=B9=B4=EB=93=9C=EC=97=90=EC=84=9C=20?= =?UTF-8?q?=EC=83=89=20=EC=84=A0=ED=83=9D=ED=96=88=EC=9D=84=EB=95=8C=20?= =?UTF-8?q?=ED=99=94=EB=A9=B4=20=EC=8A=A4=ED=83=80=EC=9D=BC=20=EC=B9=B4?= =?UTF-8?q?=EB=93=9C=EB=8F=84=20=EA=B7=B8=EB=A6=BC=EC=9E=90=20=EC=A0=81?= =?UTF-8?q?=EC=9A=A9#1682?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/Card/DisplayStyleCard/DisplayStyleCard.tsx | 1 - 1 file changed, 1 deletion(-) diff --git a/frontend/src/Cabinet/components/Card/DisplayStyleCard/DisplayStyleCard.tsx b/frontend/src/Cabinet/components/Card/DisplayStyleCard/DisplayStyleCard.tsx index f24601027..59685d886 100644 --- a/frontend/src/Cabinet/components/Card/DisplayStyleCard/DisplayStyleCard.tsx +++ b/frontend/src/Cabinet/components/Card/DisplayStyleCard/DisplayStyleCard.tsx @@ -75,7 +75,6 @@ const DisplayStyleCard = ({ }; const DisplayStyleCardWrapper = styled.div` - z-index: 1; align-self: start; `; From 4b6ddf458861cdb2bbaf2c0440015adbecd30633 Mon Sep 17 00:00:00 2001 From: jnkeniaem Date: Tue, 20 Aug 2024 15:49:24 +0900 Subject: [PATCH 06/11] =?UTF-8?q?[FE]=20REMOVE:=20=ED=94=84=EB=A1=9C?= =?UTF-8?q?=ED=95=84=20=EC=97=B0=EC=9E=A5=EA=B6=8C=20=EC=B9=B4=EB=93=9C=20?= =?UTF-8?q?=EA=B4=80=EB=A0=A8=20=ED=8C=8C=EC=9D=BC=20=EC=82=AD=EC=A0=9C#16?= =?UTF-8?q?82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ExtensionCard/ExtensionCard.container.tsx | 76 ------------------- .../Card/ExtensionCard/ExtensionCard.tsx | 63 --------------- 2 files changed, 139 deletions(-) delete mode 100644 frontend/src/Cabinet/components/Card/ExtensionCard/ExtensionCard.container.tsx delete mode 100644 frontend/src/Cabinet/components/Card/ExtensionCard/ExtensionCard.tsx diff --git a/frontend/src/Cabinet/components/Card/ExtensionCard/ExtensionCard.container.tsx b/frontend/src/Cabinet/components/Card/ExtensionCard/ExtensionCard.container.tsx deleted file mode 100644 index 18958f830..000000000 --- a/frontend/src/Cabinet/components/Card/ExtensionCard/ExtensionCard.container.tsx +++ /dev/null @@ -1,76 +0,0 @@ -import { useRecoilState, useSetRecoilState } from "recoil"; -import { - currentCabinetIdState, - myCabinetInfoState, - targetCabinetInfoState, - userState, -} from "@/Cabinet/recoil/atoms"; -import ExtensionCard from "@/Cabinet/components/Card/ExtensionCard/ExtensionCard"; -import { CabinetInfo } from "@/Cabinet/types/dto/cabinet.dto"; -import { LentDto, LentExtensionDto } from "@/Cabinet/types/dto/lent.dto"; -import { axiosCabinetById } from "@/Cabinet/api/axios/axios.custom"; -import useMenu from "@/Cabinet/hooks/useMenu"; - -const ExtensionCardContainer = ({ - extensionInfo, -}: { - extensionInfo: LentExtensionDto | null; -}) => { - const { toggleCabinet, openCabinet, closeAll } = useMenu(); - const [myInfo, setMyInfo] = useRecoilState(userState); - const [currentCabinetId, setCurrentCabinetId] = useRecoilState( - currentCabinetIdState - ); - const [myCabinetInfo, setMyCabinetInfo] = useRecoilState(myCabinetInfoState); - const setTargetCabinetInfo = useSetRecoilState( - targetCabinetInfoState - ); - async function setTargetCabinetInfoToMyCabinet() { - setCurrentCabinetId(myInfo.cabinetId); - setMyInfo((prev) => ({ ...prev, cabinetId: null })); - try { - if (!myCabinetInfo?.cabinetId) return; - const { data } = await axiosCabinetById(myCabinetInfo.cabinetId); - if (data.lents.length === 0 && myInfo.cabinetId !== null) { - setMyInfo((prev) => ({ ...prev, cabinetId: null })); - } else { - const doesNameExist = data.lents.some( - (lent: LentDto) => lent.name === myInfo.name - ); - if (doesNameExist) { - setTargetCabinetInfo(data); - setCurrentCabinetId(data.cabinetId); - setMyInfo((prev) => ({ ...prev, cabinetId: data.cabinetId })); - } - } - } catch (error) { - console.log(error); - } - } - const clickMyCabinet = () => { - if (!!extensionInfo && !!myInfo.cabinetId) { - if (myInfo.cabinetId === null && !myCabinetInfo?.cabinetId) { - setTargetCabinetInfoToMyCabinet(); - toggleCabinet(); - } else if (currentCabinetId !== myInfo.cabinetId) { - setTargetCabinetInfoToMyCabinet(); - openCabinet(); - } else { - toggleCabinet(); - } - } - }; - return ( - clickMyCabinet(), - isClickable: !!extensionInfo && !!myInfo.cabinetId, - isExtensible: !!extensionInfo, - }} - /> - ); -}; - -export default ExtensionCardContainer; diff --git a/frontend/src/Cabinet/components/Card/ExtensionCard/ExtensionCard.tsx b/frontend/src/Cabinet/components/Card/ExtensionCard/ExtensionCard.tsx deleted file mode 100644 index e35446a69..000000000 --- a/frontend/src/Cabinet/components/Card/ExtensionCard/ExtensionCard.tsx +++ /dev/null @@ -1,63 +0,0 @@ -import { useState } from "react"; -import Card, { IButtonProps } from "@/Cabinet/components/Card/Card"; -import { - CardContentStyled, - CardContentWrapper, - ContentDetailStyled, - ContentInfoStyled, -} from "@/Cabinet/components/Card/CardStyles"; -import { NotificationModal } from "@/Cabinet/components/Modals/NotificationModal/NotificationModal"; -import { LentExtensionDto } from "@/Cabinet/types/dto/lent.dto"; -import { formatDate } from "@/Cabinet/utils/dateUtils"; - -interface ExtensionProps { - extensionInfo: LentExtensionDto | null; - button: IButtonProps; -} - -const NotificationModalDetail = `연장권은 매월 2일 제공되며,
이전에 받은 연장권은 사용이 불가능 합니다.
24HANE 기준 160시간을 출석한 경우,
연장권이 부여됩니다.`; - -const ExtensionCard = ({ extensionInfo, button }: ExtensionProps) => { - const [showNotificationModal, setShowNotificationModal] = - useState(false); - return ( - <> - { - setShowNotificationModal(true); - }} - gridArea={"extension"} - width={"350px"} - height={"183px"} - buttons={[button]} - > - - - 사용 기한 - - {!!extensionInfo - ? formatDate(new Date(extensionInfo.expiredAt), ".", 4, 2, 2) - : "-"} - - - - 연장 기간 - - {!!extensionInfo ? extensionInfo.extensionPeriod + "일" : "-"} - - - - - {showNotificationModal && ( - setShowNotificationModal(false)} - /> - )} - - ); -}; - -export default ExtensionCard; From 92a5c3110d85f168a02b3a6995107d13885b581e Mon Sep 17 00:00:00 2001 From: jnkeniaem Date: Tue, 20 Aug 2024 16:04:18 +0900 Subject: [PATCH 07/11] =?UTF-8?q?[FE]=20FIX:=20=EA=B3=B5=EC=9C=A0=EC=BD=94?= =?UTF-8?q?=EB=93=9C=20=ED=81=B4=EB=A6=AD=ED=96=88=EC=9D=84=EB=95=8C=20deb?= =?UTF-8?q?ounce=20=ED=95=A8=EC=88=98=20=ED=98=B8=EC=B6=9C=EC=8B=9C=20key?= =?UTF-8?q?=20=EC=9D=B4=EB=A6=84=EC=97=90=EC=84=9C=20time=20=EB=82=B4?= =?UTF-8?q?=EC=9A=A9=20=EC=82=AD=EC=A0=9C#1677?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/CabinetInfoArea/CountTime/CodeAndTime.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/Cabinet/components/CabinetInfoArea/CountTime/CodeAndTime.tsx b/frontend/src/Cabinet/components/CabinetInfoArea/CountTime/CodeAndTime.tsx index 1984630d3..5535b3852 100644 --- a/frontend/src/Cabinet/components/CabinetInfoArea/CountTime/CodeAndTime.tsx +++ b/frontend/src/Cabinet/components/CabinetInfoArea/CountTime/CodeAndTime.tsx @@ -24,7 +24,7 @@ const CodeAndTime = ({ minutes, seconds, isTimeOver }: CountTimeProps) => { navigator.clipboard.writeText(code).then(() => { setCopySuccess(true); debounce( - "codeAndTimeCopyClick", + "codeCopyClick", () => { setCopySuccess(false); }, From 048e6c9454963b9e3d97fc9fa24c0e8b9b989349 Mon Sep 17 00:00:00 2001 From: jnkeniaem Date: Wed, 4 Sep 2024 15:00:05 +0900 Subject: [PATCH 08/11] =?UTF-8?q?[FE]=20REFACT:=20getClubInfo=EC=99=80=20c?= =?UTF-8?q?lickMoreButton=EC=9D=98=20=EC=A4=91=EB=B3=B5=EB=90=9C=20setTime?= =?UTF-8?q?out=20clickMoreButton=EC=97=90=EC=84=9C=20=EC=A0=9C=EA=B1=B0#16?= =?UTF-8?q?77?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config | 2 +- .../Club/ClubMemberList/ClubMemberList.container.tsx | 10 +--------- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/config b/config index f185aa6c7..dd72d80cc 160000 --- a/config +++ b/config @@ -1 +1 @@ -Subproject commit f185aa6c734e4c7f8dd672610802e25c5c4f8d3e +Subproject commit dd72d80cce8800e34f3938f3da0dfeb4ef9eb8eb diff --git a/frontend/src/Cabinet/components/Club/ClubMemberList/ClubMemberList.container.tsx b/frontend/src/Cabinet/components/Club/ClubMemberList/ClubMemberList.container.tsx index aa08a10c2..1e5e24317 100644 --- a/frontend/src/Cabinet/components/Club/ClubMemberList/ClubMemberList.container.tsx +++ b/frontend/src/Cabinet/components/Club/ClubMemberList/ClubMemberList.container.tsx @@ -6,7 +6,6 @@ import { ClubInfoResponseDto, ClubUserResponseDto, } from "@/Cabinet/types/dto/club.dto"; -import useDebounce from "@/Cabinet/hooks/useDebounce"; import useMenu from "@/Cabinet/hooks/useMenu"; export type TClubMemberModalState = "addModal"; @@ -37,17 +36,10 @@ const ClubMemberListContainer = ({ const [targetClubUser, setTargetClubUser] = useRecoilState( targetClubUserInfoState ); - const { debounce } = useDebounce(); const clickMoreButton = () => { setIsLoading(true); - debounce( - "clubMemberList", - () => { - setPage(page + 1); - }, - 100 - ); + setPage(page + 1); }; const selectClubMemberOnClick = (member: ClubUserResponseDto) => { From 9027033d841617c68de8ed50589923e48926edef Mon Sep 17 00:00:00 2001 From: jnkeniaem Date: Fri, 6 Sep 2024 09:26:53 +0900 Subject: [PATCH 09/11] =?UTF-8?q?[FE]=20FIX:=20=EB=A9=A4=EB=B2=84=20?= =?UTF-8?q?=EB=8D=94=EB=B3=B4=EA=B8=B0=20=EB=B2=84=ED=8A=BC=20=ED=81=B4?= =?UTF-8?q?=EB=A6=AD=EC=8B=9C=20page=20=EB=B3=80=EA=B2=BD=ED=95=98?= =?UTF-8?q?=EB=8A=94=20=EB=B6=80=EB=B6=84=EC=97=90=20debounce=20=EC=A0=81?= =?UTF-8?q?=EC=9A=A9#1677?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Club/ClubMemberList/ClubMemberList.container.tsx | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/frontend/src/Cabinet/components/Club/ClubMemberList/ClubMemberList.container.tsx b/frontend/src/Cabinet/components/Club/ClubMemberList/ClubMemberList.container.tsx index 1e5e24317..44c6344cd 100644 --- a/frontend/src/Cabinet/components/Club/ClubMemberList/ClubMemberList.container.tsx +++ b/frontend/src/Cabinet/components/Club/ClubMemberList/ClubMemberList.container.tsx @@ -6,6 +6,7 @@ import { ClubInfoResponseDto, ClubUserResponseDto, } from "@/Cabinet/types/dto/club.dto"; +import useDebounce from "@/Cabinet/hooks/useDebounce"; import useMenu from "@/Cabinet/hooks/useMenu"; export type TClubMemberModalState = "addModal"; @@ -27,7 +28,6 @@ const ClubMemberListContainer = ({ }: ClubMemberListContainerProps) => { const [moreButton, setMoreButton] = useState(true); const [members, setMembers] = useState([]); - // const [sortMembers, setSortMembers] = useState([]); const [clubModal, setClubModal] = useState({ addModal: false, }); @@ -36,10 +36,16 @@ const ClubMemberListContainer = ({ const [targetClubUser, setTargetClubUser] = useRecoilState( targetClubUserInfoState ); - + const { debounce } = useDebounce(); const clickMoreButton = () => { setIsLoading(true); - setPage(page + 1); + debounce( + "clubMemberList", + () => { + setPage(page + 1); + }, + 300 + ); }; const selectClubMemberOnClick = (member: ClubUserResponseDto) => { From 43debf7ed2cc53f7ad426041d2e2c49e67aae8ef Mon Sep 17 00:00:00 2001 From: chyo1 Date: Fri, 13 Sep 2024 15:04:43 +0900 Subject: [PATCH 10/11] =?UTF-8?q?[BE]=20fcm=20=ED=85=8C=EC=8A=A4=ED=8A=B8?= =?UTF-8?q?=EB=A5=BC=20=EC=9C=84=ED=95=9C=20dev=20=ED=99=98=EA=B2=BD=20?= =?UTF-8?q?=EC=84=A4=EC=A0=95=20=EC=9E=84=EC=8B=9C=20=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/org/ftclub/cabinet/alarm/config/AlarmProperties.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/src/main/java/org/ftclub/cabinet/alarm/config/AlarmProperties.java b/backend/src/main/java/org/ftclub/cabinet/alarm/config/AlarmProperties.java index 556f30571..60bbc6692 100644 --- a/backend/src/main/java/org/ftclub/cabinet/alarm/config/AlarmProperties.java +++ b/backend/src/main/java/org/ftclub/cabinet/alarm/config/AlarmProperties.java @@ -8,8 +8,8 @@ @Getter public class AlarmProperties { - @Value("${cabinet.production}") - private Boolean isProduction; +// @Value("${cabinet.production}") + private Boolean isProduction = true; /*===================== lentSuccess =========================*/ @Value("${cabinet.alarm.mail.lentSuccess.subject}") From 5c6848138a664c7bbb92f2ad6d72c4c8f2e26b4e Mon Sep 17 00:00:00 2001 From: chyo1 Date: Fri, 13 Sep 2024 16:00:07 +0900 Subject: [PATCH 11/11] =?UTF-8?q?[BE]=20fcm=20=ED=85=8C=EC=8A=A4=ED=8A=B8?= =?UTF-8?q?=EB=A5=BC=20=EC=9C=84=ED=95=9C=20dev=20=ED=99=98=EA=B2=BD=20?= =?UTF-8?q?=EC=84=A4=EC=A0=95=20=EB=B3=80=EA=B2=BD=20=ED=9B=84=20=EC=9B=90?= =?UTF-8?q?=EC=83=81=EB=B3=B5=EA=B5=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/org/ftclub/cabinet/alarm/config/AlarmProperties.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/src/main/java/org/ftclub/cabinet/alarm/config/AlarmProperties.java b/backend/src/main/java/org/ftclub/cabinet/alarm/config/AlarmProperties.java index 60bbc6692..556f30571 100644 --- a/backend/src/main/java/org/ftclub/cabinet/alarm/config/AlarmProperties.java +++ b/backend/src/main/java/org/ftclub/cabinet/alarm/config/AlarmProperties.java @@ -8,8 +8,8 @@ @Getter public class AlarmProperties { -// @Value("${cabinet.production}") - private Boolean isProduction = true; + @Value("${cabinet.production}") + private Boolean isProduction; /*===================== lentSuccess =========================*/ @Value("${cabinet.alarm.mail.lentSuccess.subject}")