Skip to content

Commit 48d6c50

Browse files
authored
스튜디오 기능을 추가해요 (depromeet#779)
* feat/#add-studio * remove files
1 parent f5e24f1 commit 48d6c50

File tree

66 files changed

+1670
-250
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+1670
-250
lines changed

14th-team5-iOS/Bibbi/Sources/Application/AppDelegate.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,8 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
7272
PrivacyDIContainer(),
7373
PickDICotainer(),
7474
ResignDIContainer(),
75-
NotificationDIContainer()
75+
NotificationDIContainer(),
76+
StudioDIContainer()
7677
]
7778
containers.forEach {
7879
$0.registerDependencies()

14th-team5-iOS/Bibbi/Sources/Application/DIContainer/NavigatorDIContainer.swift

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,14 @@ final class NavigatorDIContainer: BaseContainer {
132132
container.register(type: InputFamilyLinkNavigatorProtocol.self) { _ in
133133
InputFamilyLInkNavigator(navigationController: makeUINavigationController())
134134
}
135+
136+
container.register(type: StudioPageNavigatorProtocol.self) { _ in
137+
StudioPageNavigator(navigationController: makeUINavigationController())
138+
}
139+
140+
container.register(type: StudioNavigatorProtocol.self) { _ in
141+
StudioNavigator(navigationController: makeUINavigationController())
142+
}
135143
}
136144

137145
}
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
//
2+
// StudioDIContainer.swift
3+
// Bibbi
4+
//
5+
// Created by 마경미 on 27.09.25.
6+
//
7+
8+
import Core
9+
import Data
10+
import Domain
11+
import MacrosInterface
12+
13+
14+
15+
final class StudioDIContainer: BaseContainer {
16+
private func makePostRepository() -> StudioRepositoryProtocol {
17+
return PostRepository()
18+
}
19+
20+
private func makeAppRepository() -> AppRepositoryProtocol {
21+
return AppRepository()
22+
}
23+
24+
private func makeFetchStudioCountUseCase() -> FetchStudioCountUseCaseProtocol {
25+
return FetchStudioCountUseCase(studioRepository: makePostRepository())
26+
}
27+
28+
private func makeFetchIsAITermsAgreedUseCase() -> FetchIsAITermsAgreedUseCaseProtocol {
29+
return FetchIsAITermsAgreedUseCase(repository: makeAppRepository())
30+
}
31+
32+
func registerDependencies() {
33+
container.register(type: FetchStudioCountUseCaseProtocol.self) { _ in
34+
makeFetchStudioCountUseCase()
35+
}
36+
37+
container.register(type: FetchIsAITermsAgreedUseCaseProtocol.self) { _ in
38+
makeFetchIsAITermsAgreedUseCase()
39+
}
40+
}
41+
}
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
//
2+
// StudioNavigator.swift
3+
// Bibbi
4+
//
5+
// Created by 마경미 on 27.09.25.
6+
//
7+
8+
import Core
9+
import UIKit
10+
11+
12+
protocol StudioNavigatorProtocol: BaseNavigator {
13+
func showErrorToast(message: String)
14+
func showAITermAlert(saveAction: BBAlertActionHandler)
15+
}
16+
17+
final class StudioNavigator: StudioNavigatorProtocol {
18+
19+
var navigationController: UINavigationController
20+
21+
22+
init(navigationController: UINavigationController) {
23+
self.navigationController = navigationController
24+
}
25+
26+
func showErrorToast(message: String) {
27+
BBToast.text(message).show()
28+
}
29+
30+
func showAITermAlert(saveAction: BBAlertActionHandler) {
31+
BBAlert.style(.AITermAgreement,
32+
primaryAction: saveAction,
33+
secondaryAction: { [weak self] _ in
34+
self?.navigationController.popViewController(animated: true)
35+
}).show()
36+
}
37+
}
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
//
2+
// StuidoPageViewControllerWrapper.swift
3+
// Bibbi
4+
//
5+
// Created by 마경미 on 26.09.25.
6+
//
7+
8+
import Core
9+
import UIKit
10+
11+
12+
protocol StudioPageNavigatorProtocol: BaseNavigator {
13+
func toStudio()
14+
}
15+
16+
final class StudioPageNavigator: StudioPageNavigatorProtocol {
17+
18+
var navigationController: UINavigationController
19+
20+
21+
init(navigationController: UINavigationController) {
22+
self.navigationController = navigationController
23+
}
24+
25+
func toStudio() {
26+
let vc = StudioViewControllerWrapper().viewController
27+
navigationController.pushViewController(vc, animated: true)
28+
}
29+
}

14th-team5-iOS/Bibbi/Sources/Application/Navigator/Wrapper/Camera/CameraDisplayViewControllerWrapper.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@ final class CameraDisplayViewControllerWrapper {
1515

1616
private let displayData: Data
1717
private let missionTitle: String
18-
private let cameraDisplayType: PostType
18+
private let cameraDisplayType: BibbiFeedType
1919

2020
public init(
2121
displayData: Data,
2222
missionTitle: String = "",
23-
cameraDisplayType: PostType = .survival
23+
cameraDisplayType: BibbiFeedType = .survival
2424
) {
2525
self.displayData = displayData
2626
self.missionTitle = missionTitle

14th-team5-iOS/Bibbi/Sources/Application/Navigator/Wrapper/Main/MainPostViewControllerWrapper.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ import MacrosInterface
1313
@Wrapper<MainPostViewReactor, MainPostViewController>
1414
final class MainPostViewControllerWrapper {
1515

16-
private let type: PostType
16+
private let type: BibbiFeedType
1717

18-
init(type: PostType) {
18+
init(type: BibbiFeedType) {
1919
self.type = type
2020
}
2121

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
//
2+
// StudioPageViewControllerWrapper.swift
3+
// Bibbi
4+
//
5+
// Created by 마경미 on 26.09.25.
6+
//
7+
8+
import Core
9+
import Domain
10+
import Foundation
11+
import MacrosInterface
12+
13+
@Wrapper<StudioPageReactor, StudioPageViewController>
14+
final class StudioPageViewControllerWrapper {
15+
16+
init() { }
17+
18+
func makeReactor() -> R {
19+
return StudioPageReactor()
20+
}
21+
22+
}
23+

14th-team5-iOS/Bibbi/Sources/Application/Navigator/Wrapper/Main/StuidoPageViewControllerWrapper.swift

Whitespace-only changes.

14th-team5-iOS/Bibbi/Sources/Application/Navigator/Wrapper/Profile/ProfileFeedViewControllerWrapper.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ import MacrosInterface
1313
@Wrapper<ProfileFeedViewReactor, ProfileFeedViewController>
1414
final class ProfileFeedViewControllerWrapper {
1515

16-
private let postType: PostType
16+
private let postType: BibbiFeedType
1717
private let memberId: String
1818

19-
init(postType: PostType, memberId: String) {
19+
init(postType: BibbiFeedType, memberId: String) {
2020
self.postType = postType
2121
self.memberId = memberId
2222
}

0 commit comments

Comments
 (0)