From 055b1deb4f46ffe1eb1cf885a74b204e1bc7ebff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=EB=8F=84=ED=98=95?= <108233361+ShapeKim98@users.noreply.github.com> Date: Sun, 8 Sep 2024 19:54:51 +0900 Subject: [PATCH] =?UTF-8?q?[fix]=20#111=20=ED=94=BC=EB=93=9C=EB=B0=B1=20?= =?UTF-8?q?=EB=B0=98=EC=98=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Projects/DSKit/Sources/Components/PokitShareSheet.swift | 8 ++++---- .../Sources/CategoryDetailFeature.swift | 4 ++-- .../Sources/CategoryDetailView.swift | 2 +- .../Sources/ContentDetail/ContentDetailFeature.swift | 4 ++-- .../Sources/ContentDetail/ContentDetailView.swift | 2 +- .../Sources/ContentList/ContentListFeature.swift | 4 ++-- .../Sources/ContentList/ContentListView.swift | 2 +- .../Feature/FeaturePokit/Sources/PokitRootFeature.swift | 4 ++-- Projects/Feature/FeaturePokit/Sources/PokitRootView.swift | 2 +- .../FeatureRemind/Sources/Remind/RemindFeature.swift | 4 ++-- .../Feature/FeatureRemind/Sources/Remind/RemindView.swift | 2 +- .../Sources/Search/PokitSearchFeature.swift | 4 ++-- .../FeatureSetting/Sources/Search/PokitSearchView.swift | 2 +- 13 files changed, 22 insertions(+), 22 deletions(-) diff --git a/Projects/DSKit/Sources/Components/PokitShareSheet.swift b/Projects/DSKit/Sources/Components/PokitShareSheet.swift index cecf15d9..aa82cd8c 100644 --- a/Projects/DSKit/Sources/Components/PokitShareSheet.swift +++ b/Projects/DSKit/Sources/Components/PokitShareSheet.swift @@ -9,11 +9,11 @@ import SwiftUI public struct PokitShareSheet: UIViewControllerRepresentable { private var items: [Any] - private var completion: ((_ completed: Bool) -> Void)? + private var completion: (() -> Void)? public init( items: [Any], - completion: ((_: Bool) -> Void)? + completion: (() -> Void)? ) { self.items = items self.completion = completion @@ -24,8 +24,8 @@ public struct PokitShareSheet: UIViewControllerRepresentable { activityItems: items, applicationActivities: nil ) - controller.completionWithItemsHandler = { _, completed, _, _ in - completion?(completed) + controller.completionWithItemsHandler = { _, _, _, _ in + completion?() } return controller } diff --git a/Projects/Feature/FeatureCategoryDetail/Sources/CategoryDetailFeature.swift b/Projects/Feature/FeatureCategoryDetail/Sources/CategoryDetailFeature.swift index 7b8b8296..e50dc251 100644 --- a/Projects/Feature/FeatureCategoryDetail/Sources/CategoryDetailFeature.swift +++ b/Projects/Feature/FeatureCategoryDetail/Sources/CategoryDetailFeature.swift @@ -100,7 +100,7 @@ public struct CategoryDetailFeature { case dismiss case onAppear case pagenation - case 링크_공유_완료(completed: Bool) + case 링크_공유_완료 } public enum InnerAction: Equatable { @@ -219,7 +219,7 @@ private extension CategoryDetailFeature { } case .pagenation: return .run { send in await send(.async(.pagenation_네트워크)) } - case .링크_공유_완료(completed: let completed): + case .링크_공유_완료: state.shareSheetItem = nil return .none } diff --git a/Projects/Feature/FeatureCategoryDetail/Sources/CategoryDetailView.swift b/Projects/Feature/FeatureCategoryDetail/Sources/CategoryDetailView.swift index 8dfc9ab4..655b1ff7 100644 --- a/Projects/Feature/FeatureCategoryDetail/Sources/CategoryDetailView.swift +++ b/Projects/Feature/FeatureCategoryDetail/Sources/CategoryDetailView.swift @@ -45,7 +45,7 @@ public extension CategoryDetailView { if let shareURL = URL(string: content.data) { PokitShareSheet( items: [shareURL], - completion: { send(.링크_공유_완료(completed: $0)) } + completion: { send(.링크_공유_완료) } ) .presentationDetents([.medium, .large]) } diff --git a/Projects/Feature/FeatureContentDetail/Sources/ContentDetail/ContentDetailFeature.swift b/Projects/Feature/FeatureContentDetail/Sources/ContentDetail/ContentDetailFeature.swift index a01b9194..55b59c6e 100644 --- a/Projects/Feature/FeatureContentDetail/Sources/ContentDetail/ContentDetailFeature.swift +++ b/Projects/Feature/FeatureContentDetail/Sources/ContentDetail/ContentDetailFeature.swift @@ -70,7 +70,7 @@ public struct ContentDetailFeature { case favoriteButtonTapped case alertCancelButtonTapped - case 링크_공유_완료(completed: Bool) + case 링크_공유_완료 } public enum InnerAction: Equatable { @@ -176,7 +176,7 @@ private extension ContentDetailFeature { await send(.async(.즐겨찾기(id: content.id))) } } - case .링크_공유_완료(completed: let completed): + case .링크_공유_완료: state.showShareSheet = false return .none case .alertCancelButtonTapped: diff --git a/Projects/Feature/FeatureContentDetail/Sources/ContentDetail/ContentDetailView.swift b/Projects/Feature/FeatureContentDetail/Sources/ContentDetail/ContentDetailView.swift index 3244e187..dabd2a2e 100644 --- a/Projects/Feature/FeatureContentDetail/Sources/ContentDetail/ContentDetailView.swift +++ b/Projects/Feature/FeatureContentDetail/Sources/ContentDetail/ContentDetailView.swift @@ -62,7 +62,7 @@ public extension ContentDetailView { let shareURL = URL(string: content.data) { PokitShareSheet( items: [shareURL], - completion: { send(.링크_공유_완료(completed: $0)) } + completion: { send(.링크_공유_완료) } ) .presentationDetents([.medium, .large]) } diff --git a/Projects/Feature/FeatureContentList/Sources/ContentList/ContentListFeature.swift b/Projects/Feature/FeatureContentList/Sources/ContentList/ContentListFeature.swift index 7c33719e..0e64afaf 100644 --- a/Projects/Feature/FeatureContentList/Sources/ContentList/ContentListFeature.swift +++ b/Projects/Feature/FeatureContentList/Sources/ContentList/ContentListFeature.swift @@ -77,7 +77,7 @@ public struct ContentListFeature { case contentListViewOnAppeared case pagenation - case 링크_공유_완료(completed: Bool) + case 링크_공유_완료 } public enum InnerAction: Equatable { @@ -193,7 +193,7 @@ private extension ContentListFeature { case .pagenation: return .run { send in await send(.async(.pagenation_네트워크)) } - case .링크_공유_완료(completed: let completed): + case .링크_공유_완료: state.shareSheetItem = nil return .none } diff --git a/Projects/Feature/FeatureContentList/Sources/ContentList/ContentListView.swift b/Projects/Feature/FeatureContentList/Sources/ContentList/ContentListView.swift index b3e52957..8415f497 100644 --- a/Projects/Feature/FeatureContentList/Sources/ContentList/ContentListView.swift +++ b/Projects/Feature/FeatureContentList/Sources/ContentList/ContentListView.swift @@ -46,7 +46,7 @@ public extension ContentListView { if let shareURL = URL(string: content.data) { PokitShareSheet( items: [shareURL], - completion: { send(.링크_공유_완료(completed: $0)) } + completion: { send(.링크_공유_완료) } ) .presentationDetents([.medium, .large]) } diff --git a/Projects/Feature/FeaturePokit/Sources/PokitRootFeature.swift b/Projects/Feature/FeaturePokit/Sources/PokitRootFeature.swift index cf71ef7e..b71e45a2 100644 --- a/Projects/Feature/FeaturePokit/Sources/PokitRootFeature.swift +++ b/Projects/Feature/FeaturePokit/Sources/PokitRootFeature.swift @@ -92,7 +92,7 @@ public struct PokitRootFeature { case categoryTapped(BaseCategoryItem) case contentItemTapped(BaseContentItem) - case 링크_공유_완료(completed: Bool) + case 링크_공유_완료 case pokitRootViewOnAppeared @@ -244,7 +244,7 @@ private extension PokitRootFeature { return .send(.async(.미분류_카테고리_컨텐츠_페이징_조회)) default: return .none } - case .링크_공유_완료(completed: let completed): + case .링크_공유_완료: state.shareSheetItem = nil return .none } diff --git a/Projects/Feature/FeaturePokit/Sources/PokitRootView.swift b/Projects/Feature/FeaturePokit/Sources/PokitRootView.swift index f407e45f..b8525b4d 100644 --- a/Projects/Feature/FeaturePokit/Sources/PokitRootView.swift +++ b/Projects/Feature/FeaturePokit/Sources/PokitRootView.swift @@ -49,7 +49,7 @@ public extension PokitRootView { if let shareURL = URL(string: content.data) { PokitShareSheet( items: [shareURL], - completion: { send(.링크_공유_완료(completed: $0)) } + completion: { send(.링크_공유_완료) } ) .presentationDetents([.medium, .large]) } diff --git a/Projects/Feature/FeatureRemind/Sources/Remind/RemindFeature.swift b/Projects/Feature/FeatureRemind/Sources/Remind/RemindFeature.swift index f138c4eb..72f34f6f 100644 --- a/Projects/Feature/FeatureRemind/Sources/Remind/RemindFeature.swift +++ b/Projects/Feature/FeatureRemind/Sources/Remind/RemindFeature.swift @@ -78,7 +78,7 @@ public struct RemindFeature { ) case deleteAlertConfirmTapped(content: BaseContentItem) - case 링크_공유_완료(completed: Bool) + case 링크_공유_완료 case remindViewOnAppeared } @@ -175,7 +175,7 @@ private extension RemindFeature { await send(.async(.읽지않음_컨텐츠_조회), animation: .pokitDissolve) await send(.async(.즐겨찾기_링크모음_조회), animation: .pokitDissolve) } - case .링크_공유_완료(completed: let completed): + case .링크_공유_완료: state.shareSheetItem = nil return .none } diff --git a/Projects/Feature/FeatureRemind/Sources/Remind/RemindView.swift b/Projects/Feature/FeatureRemind/Sources/Remind/RemindView.swift index f8318e73..c2e2756d 100644 --- a/Projects/Feature/FeatureRemind/Sources/Remind/RemindView.swift +++ b/Projects/Feature/FeatureRemind/Sources/Remind/RemindView.swift @@ -42,7 +42,7 @@ public extension RemindView { if let shareURL = URL(string: content.data) { PokitShareSheet( items: [shareURL], - completion: { send(.링크_공유_완료(completed: $0)) } + completion: { send(.링크_공유_완료) } ) .presentationDetents([.medium, .large]) } diff --git a/Projects/Feature/FeatureSetting/Sources/Search/PokitSearchFeature.swift b/Projects/Feature/FeatureSetting/Sources/Search/PokitSearchFeature.swift index e7e44bef..33b5cf9b 100644 --- a/Projects/Feature/FeatureSetting/Sources/Search/PokitSearchFeature.swift +++ b/Projects/Feature/FeatureSetting/Sources/Search/PokitSearchFeature.swift @@ -126,7 +126,7 @@ public struct PokitSearchFeature { /// - TextInput OnSubmitted case searchTextInputOnSubmitted - case 링크_공유_완료(completed: Bool) + case 링크_공유_완료 case onAppear case 로딩_isPresented @@ -331,7 +331,7 @@ private extension PokitSearchFeature { case .unreadChipTapped: state.domain.condition.isRead = false return .send(.inner(.페이징_초기화)) - case .링크_공유_완료(completed: let completed): + case .링크_공유_완료: state.shareSheetItem = nil return .none case .로딩_isPresented: diff --git a/Projects/Feature/FeatureSetting/Sources/Search/PokitSearchView.swift b/Projects/Feature/FeatureSetting/Sources/Search/PokitSearchView.swift index 7f451021..72080288 100644 --- a/Projects/Feature/FeatureSetting/Sources/Search/PokitSearchView.swift +++ b/Projects/Feature/FeatureSetting/Sources/Search/PokitSearchView.swift @@ -60,7 +60,7 @@ public extension PokitSearchView { if let shareURL = URL(string: content.data) { PokitShareSheet( items: [shareURL], - completion: { send(.링크_공유_완료(completed: $0)) } + completion: { send(.링크_공유_완료) } ) .presentationDetents([.medium, .large]) }