From f1cda0f60aedde4f6bb9ecbc8975107207228b57 Mon Sep 17 00:00:00 2001 From: JAESEON PARK Date: Mon, 16 Feb 2026 22:49:19 +0900 Subject: [PATCH 1/6] =?UTF-8?q?feat:=20RestaurantListSkeleton=20=EC=B6=94?= =?UTF-8?q?=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../restaurant/RestaurantCardSkeleton.tsx | 3 +++ .../restaurant/RestaurantListSkeleton.tsx | 18 ++++++++++++++++++ 2 files changed, 21 insertions(+) create mode 100644 src/components/restaurant/RestaurantCardSkeleton.tsx create mode 100644 src/components/restaurant/RestaurantListSkeleton.tsx diff --git a/src/components/restaurant/RestaurantCardSkeleton.tsx b/src/components/restaurant/RestaurantCardSkeleton.tsx new file mode 100644 index 0000000..a1fb232 --- /dev/null +++ b/src/components/restaurant/RestaurantCardSkeleton.tsx @@ -0,0 +1,3 @@ +export default function RestaurantCardSkeleton() { + return
리스트카드 스켈레톤
; +} diff --git a/src/components/restaurant/RestaurantListSkeleton.tsx b/src/components/restaurant/RestaurantListSkeleton.tsx new file mode 100644 index 0000000..c9c0569 --- /dev/null +++ b/src/components/restaurant/RestaurantListSkeleton.tsx @@ -0,0 +1,18 @@ +import RestaurantCardSkeleton from "./RestaurantCardSkeleton"; + +export default function RestaurantListSkeleton({ + count = 8, +}: { + count?: number; +}) { + return ( +
+ {Array.from({ length: count }).map((_, idx) => ( +
+ + {idx !== count - 1 ?
: null} +
+ ))} +
+ ); +} From 6c10da5cc7d591268347b75a3c1af215cc61608a Mon Sep 17 00:00:00 2001 From: JAESEON PARK Date: Mon, 16 Feb 2026 22:52:54 +0900 Subject: [PATCH 2/6] =?UTF-8?q?feat:=20RestaurantCard=20=EC=8A=A4=EC=BC=88?= =?UTF-8?q?=EB=A0=88=ED=86=A4=20UI=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/restaurant/RestaurantCardSkeleton.tsx | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/components/restaurant/RestaurantCardSkeleton.tsx b/src/components/restaurant/RestaurantCardSkeleton.tsx index a1fb232..92f71ad 100644 --- a/src/components/restaurant/RestaurantCardSkeleton.tsx +++ b/src/components/restaurant/RestaurantCardSkeleton.tsx @@ -1,3 +1,12 @@ export default function RestaurantCardSkeleton() { - return
리스트카드 스켈레톤
; + return ( +
+
+
+
+
+
+
+
+ ); } From 40cca7103a43c453f98365b2bd31c01180d66b16 Mon Sep 17 00:00:00 2001 From: JAESEON PARK Date: Mon, 16 Feb 2026 23:21:56 +0900 Subject: [PATCH 3/6] =?UTF-8?q?feat:=20SearchPage=20=EB=A1=9C=EB=94=A9=20?= =?UTF-8?q?=EC=8A=A4=EC=BC=88=EB=A0=88=ED=86=A4=20UI=EC=B6=94=EA=B0=80,=20?= =?UTF-8?q?isFetching=20=EA=B8=B0=EB=B0=98=20=EC=83=81=ED=83=9C=20?= =?UTF-8?q?=EB=B6=84=EA=B8=B0=20=EC=A0=95=EB=A6=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/restaurant/RestaurantList.tsx | 8 ------ src/pages/SearchPage.tsx | 27 +++++++++++++++++--- 2 files changed, 23 insertions(+), 12 deletions(-) diff --git a/src/components/restaurant/RestaurantList.tsx b/src/components/restaurant/RestaurantList.tsx index 2b17303..bdf2d73 100644 --- a/src/components/restaurant/RestaurantList.tsx +++ b/src/components/restaurant/RestaurantList.tsx @@ -7,14 +7,6 @@ type Props = { }; export default function RestaurantList({ restaurants, onSelect }: Props) { - if (restaurants.length === 0) { - return ( -
- 검색 결과가 없어요. -
- ); - } - return (
{restaurants.map((r, idx) => ( diff --git a/src/pages/SearchPage.tsx b/src/pages/SearchPage.tsx index 789c4d7..0f687f0 100644 --- a/src/pages/SearchPage.tsx +++ b/src/pages/SearchPage.tsx @@ -13,6 +13,7 @@ import { useRestaurantDetail } from "@/hooks/store/useRestaurantDetail"; import { useSearchStores } from "@/hooks/store/useSearchStores"; import type { CreateBookingResult } from "@/api/endpoints/reservations"; import { toHHmm } from "@/utils/time"; +import RestaurantListSkeleton from "@/components/restaurant/RestaurantListSkeleton"; export default function SearchPage() { const [query, setQuery] = useState(""); @@ -269,11 +270,29 @@ export default function SearchPage() { />
- {searchError ? ( -

{searchError}

- ) : null} {hasSearched ? ( - + <> + {searchError ? ( +

{searchError}

+ ) : searchQuery.isFetching ? ( + <> +
+ + 검색 중... +
+ + + ) : results.length === 0 ? ( +
+ 검색 결과가 없어요. +
+ ) : ( + + )} + ) : null}
From 61b81f2b9c46a9bd593c744ec5173c536885658d Mon Sep 17 00:00:00 2001 From: JAESEON PARK Date: Mon, 16 Feb 2026 23:34:35 +0900 Subject: [PATCH 4/6] =?UTF-8?q?feat:=20=EA=B2=80=EC=83=89=20=EA=B2=B0?= =?UTF-8?q?=EA=B3=BC=20=EB=A1=9C=EB=94=A9=20UX=20=EA=B0=9C=EC=84=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/SearchPage.tsx | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/src/pages/SearchPage.tsx b/src/pages/SearchPage.tsx index 0f687f0..699385f 100644 --- a/src/pages/SearchPage.tsx +++ b/src/pages/SearchPage.tsx @@ -35,6 +35,8 @@ export default function SearchPage() { const detailQuery = useRestaurantDetail(selectedStoreId); + const [isSearchingUI, setIsSearchingUI] = useState(false); + const [searchParams, setSearchParams] = useState<{ keyword: string; lat: number; @@ -226,8 +228,10 @@ export default function SearchPage() { if (!keyword) { setSearchParams(null); + setIsSearchingUI(false); return; } + setIsSearchingUI(true); const c = coords ?? (await getCoords()); setCoords(c); @@ -235,6 +239,15 @@ export default function SearchPage() { setSearchParams({ keyword, lat: c.lat, lng: c.lng }); }; + useEffect(() => { + if (!hasSearched) return; + if (!isSearchingUI) return; + + if (searchQuery.isSuccess || searchQuery.isError) { + setIsSearchingUI(false); + } + }, [hasSearched, isSearchingUI, searchQuery.isSuccess, searchQuery.isError]); + return ( <>
@@ -274,7 +287,7 @@ export default function SearchPage() { <> {searchError ? (

{searchError}

- ) : searchQuery.isFetching ? ( + ) : isSearchingUI || searchQuery.isFetching ? ( <>
From 67bc3be2c6aa105017654717332e7bb1c2b7d65e Mon Sep 17 00:00:00 2001 From: JAESEON PARK Date: Mon, 16 Feb 2026 23:39:45 +0900 Subject: [PATCH 5/6] =?UTF-8?q?fix:=20=EB=B3=84=EC=A0=90=20=EA=B4=80?= =?UTF-8?q?=EB=A0=A8=20=EB=82=B4=EC=9A=A9=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/restaurant/RestaurantCard.tsx | 6 ------ src/components/restaurant/RestaurantDetailModal.tsx | 11 +---------- 2 files changed, 1 insertion(+), 16 deletions(-) diff --git a/src/components/restaurant/RestaurantCard.tsx b/src/components/restaurant/RestaurantCard.tsx index f6035c4..7662162 100644 --- a/src/components/restaurant/RestaurantCard.tsx +++ b/src/components/restaurant/RestaurantCard.tsx @@ -1,5 +1,4 @@ import { categoryLabel, type RestaurantSummary } from "@/types/store"; -import { Star } from "lucide-react"; type Props = { restaurant: RestaurantSummary; @@ -22,11 +21,6 @@ export default function RestaurantCard({ restaurant, onClick }: Props) { {categoryLabel[restaurant.category]} • {restaurant.address}

- - - - {restaurant.rating.toFixed(1)} -
); diff --git a/src/components/restaurant/RestaurantDetailModal.tsx b/src/components/restaurant/RestaurantDetailModal.tsx index 163c474..af0ac16 100644 --- a/src/components/restaurant/RestaurantDetailModal.tsx +++ b/src/components/restaurant/RestaurantDetailModal.tsx @@ -1,5 +1,5 @@ import type { Day, RestaurantDetail } from "@/types/store"; -import { Clock, Star, X } from "lucide-react"; +import { Clock, X } from "lucide-react"; import { Button } from "../ui/button"; import { useNavigate } from "react-router-dom"; import { useAuthStore } from "@/stores/useAuthStore"; @@ -165,9 +165,6 @@ export default function RestaurantDetailModal({ if (status !== "success") return null; if (!restaurant) return null; - const rating = typeof restaurant.rating === "number" ? restaurant.rating : 0; - const reviewCount = - typeof restaurant.reviewCount === "number" ? restaurant.reviewCount : 0; const tableImageUrls = Array.isArray(restaurant.tableImageUrls) ? restaurant.tableImageUrls : []; @@ -213,12 +210,6 @@ export default function RestaurantDetailModal({
) : null}
-
- - {rating.toFixed(1)} - ({reviewCount}개 리뷰) -
-
From deb63f454d54d09eff67bf0ca9431e079a3215c5 Mon Sep 17 00:00:00 2001 From: JAESEON PARK Date: Tue, 17 Feb 2026 00:07:22 +0900 Subject: [PATCH 6/6] =?UTF-8?q?chore:=20=EC=BD=94=EB=93=9C=EB=9E=98?= =?UTF-8?q?=EB=B9=97=20=EC=88=98=EC=A0=95=EC=82=AC=ED=95=AD=20=EB=B0=98?= =?UTF-8?q?=EC=98=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/restaurant/RestaurantCardSkeleton.tsx | 2 +- src/components/restaurant/RestaurantDetailModal.tsx | 1 + src/components/restaurant/RestaurantListSkeleton.tsx | 6 +++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/components/restaurant/RestaurantCardSkeleton.tsx b/src/components/restaurant/RestaurantCardSkeleton.tsx index 92f71ad..770f0aa 100644 --- a/src/components/restaurant/RestaurantCardSkeleton.tsx +++ b/src/components/restaurant/RestaurantCardSkeleton.tsx @@ -1,6 +1,6 @@ export default function RestaurantCardSkeleton() { return ( -
+