From fbc5ee8e681702f0eea57ef4b5197d4c309a8d6c Mon Sep 17 00:00:00 2001 From: hooni Date: Thu, 23 Jan 2025 06:07:18 +0900 Subject: [PATCH] =?UTF-8?q?feat:=20#140=20=EC=9D=B8=EB=94=94=EC=BC=80?= =?UTF-8?q?=EC=9D=B4=ED=84=B0=20=EA=B0=84=EA=B2=A9=EC=A1=B0=EC=A0=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../PlaceHolderCardView/PlaceCard.swift | 41 ++++++++++--------- 1 file changed, 21 insertions(+), 20 deletions(-) diff --git a/Spoony-iOS/Spoony-iOS/Source/Feature/Home/Components/PlaceHolderCardView/PlaceCard.swift b/Spoony-iOS/Spoony-iOS/Source/Feature/Home/Components/PlaceHolderCardView/PlaceCard.swift index 0470ccac..2a07d158 100644 --- a/Spoony-iOS/Spoony-iOS/Source/Feature/Home/Components/PlaceHolderCardView/PlaceCard.swift +++ b/Spoony-iOS/Spoony-iOS/Source/Feature/Home/Components/PlaceHolderCardView/PlaceCard.swift @@ -12,30 +12,31 @@ struct PlaceCard: View { @Binding var currentPage: Int var body: some View { - VStack(spacing: 0) { - TabView(selection: $currentPage) { - ForEach(places.indices, id: \.self) { index in - PlaceCardItem(place: places[index]) - .tag(index) + VStack(spacing: 0) { + TabView(selection: $currentPage) { + ForEach(places.indices, id: \.self) { index in + PlaceCardItem(place: places[index]) + .tag(index) + .padding(.horizontal, 26) + } } - } - .padding(.horizontal, 26) - .frame(height: 264.adjusted) - .tabViewStyle(.page(indexDisplayMode: .never)) - .background(.clear) - - ZStack { - if places.count > 1 { - PageIndicator( - currentPage: currentPage, - pageCount: places.count - ) - .padding(.vertical, 4.adjustedH) + .frame(maxWidth: .infinity) + .frame(height: 264.adjusted) + .tabViewStyle(.page(indexDisplayMode: .never)) + .background(.clear) + + ZStack { + if places.count > 1 { + PageIndicator( + currentPage: currentPage, + pageCount: places.count + ) + .padding(.vertical, 4) + } } + .frame(height: 8) } - .frame(height: 8.adjustedH) } - } } private struct PlaceCardItem: View {