Skip to content

Commit

Permalink
✨ :: [#1199] 플로팅 버튼 위치 조정
Browse files Browse the repository at this point in the history
  • Loading branch information
KangTaeHoon committed Aug 19, 2024
1 parent 938b081 commit e2c3142
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,14 @@ private extension MainTabBarViewController {
let viewController = playlistDetailFactory.makeView(key: key)
navigationController?.pushViewController(viewController, animated: true)

// 보관함에서 플리상세 접근 시 플로팅버튼 내림
if selectedIndex == 3 {
NotificationCenter.default.post(
name: .shouldMovePositionPlaylistFloatingButton,
object: PlaylistFloatingButtonPosition.default
)
}

case "songDetail":
let id = params["id"] as? String ?? ""
songDetailPresenter.present(id: id)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,12 @@ final class ListStorageViewController: BaseReactorViewController<ListStorageReac
super.viewDidAppear(animated)
LogManager.analytics(CommonAnalyticsLog.viewPage(pageName: .storagePlaylist))
listStorageView.resetParticeAnimation()

// 플리 상세에서 내 리스트로 돌아오는 경우, 플로팅 버튼 올림
NotificationCenter.default.post(
name: .shouldMovePositionPlaylistFloatingButton,
object: PlaylistFloatingButtonPosition.top
)
}

override func configureUI() {
Expand Down Expand Up @@ -91,6 +97,7 @@ final class ListStorageViewController: BaseReactorViewController<ListStorageReac
reactor.pulse(\.$showDetail)
.compactMap { $0 }
.bind(with: self, onNext: { owner, key in
// 플리 상세 진입 시, 플로팅 버튼 내림
NotificationCenter.default.post(
name: .shouldMovePositionPlaylistFloatingButton,
object: PlaylistFloatingButtonPosition.default
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ final class StorageViewController: TabmanViewController, View {
animated: Bool
) {
self.reactor?.action.onNext(.switchTab(index))
// 탭 이동 간 플로팅 버튼 위치 조정
NotificationCenter.default.post(
name: .shouldMovePositionPlaylistFloatingButton,
object: index == 0 ?
Expand Down

0 comments on commit e2c3142

Please sign in to comment.