From 9e935389ec6f4d1345c952f294e4be90c46d3db6 Mon Sep 17 00:00:00 2001 From: yangsubinn Date: Fri, 21 Jan 2022 14:27:01 +0900 Subject: [PATCH 1/5] =?UTF-8?q?[Fix]=20#159=20-=20=ED=94=BC=EB=93=9C?= =?UTF-8?q?=EB=B7=B0=20=EC=82=AC=EC=A7=84=20=EB=A0=88=EC=9D=B4=EC=95=84?= =?UTF-8?q?=EC=9B=83=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Spark-iOS/Resource/Storyboards/TabBar/Feed.storyboard | 1 + Spark-iOS/Spark-iOS/Source/Cells/Feed/FeedCVC.swift | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/Spark-iOS/Spark-iOS/Resource/Storyboards/TabBar/Feed.storyboard b/Spark-iOS/Spark-iOS/Resource/Storyboards/TabBar/Feed.storyboard index d84a88b6..cded9d92 100644 --- a/Spark-iOS/Spark-iOS/Resource/Storyboards/TabBar/Feed.storyboard +++ b/Spark-iOS/Spark-iOS/Resource/Storyboards/TabBar/Feed.storyboard @@ -2,6 +2,7 @@ + diff --git a/Spark-iOS/Spark-iOS/Source/Cells/Feed/FeedCVC.swift b/Spark-iOS/Spark-iOS/Source/Cells/Feed/FeedCVC.swift index 5b3a48a5..506b5134 100644 --- a/Spark-iOS/Spark-iOS/Source/Cells/Feed/FeedCVC.swift +++ b/Spark-iOS/Spark-iOS/Source/Cells/Feed/FeedCVC.swift @@ -137,6 +137,7 @@ extension FeedCVC { profileImageView.layer.masksToBounds = true profileImageView.contentMode = .scaleAspectFill feedImageView.contentMode = .scaleAspectFill + feedImageView.layer.masksToBounds = true sparkLabel.text = "받은 스파크" @@ -193,7 +194,7 @@ extension FeedCVC { feedImageView.snp.makeConstraints { make in make.top.leading.trailing.equalToSuperview() - make.height.equalTo(feedImageView.snp.width).multipliedBy(1.0 / 1.0) + make.height.equalTo(self.snp.width).multipliedBy(1.0 / 1.0) } fadeImageView.snp.makeConstraints { make in From 76ca561eb9be8b65ced3334d3ad55f4956a5df4c Mon Sep 17 00:00:00 2001 From: yangsubinn Date: Fri, 21 Jan 2022 14:31:30 +0900 Subject: [PATCH 2/5] =?UTF-8?q?[Chore]=20#159=20-=20=ED=94=BC=EB=93=9C?= =?UTF-8?q?=EB=B7=B0=20API=20=ED=98=B8=EC=B6=9C=20viewWillAppear=EB=A1=9C?= =?UTF-8?q?=20=EB=B3=80=EA=B2=BD,=20=EC=BB=AC=EB=A0=89=EC=85=98=EB=B7=B0?= =?UTF-8?q?=20=EA=B0=80=EC=9E=A5=20=EC=9C=84=EB=A1=9C=20=EC=9D=B4=EB=8F=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Source/ViewControllers/TabBar/FeedVC.swift | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/Spark-iOS/Spark-iOS/Source/ViewControllers/TabBar/FeedVC.swift b/Spark-iOS/Spark-iOS/Source/ViewControllers/TabBar/FeedVC.swift index 678b6fd2..8f143c23 100644 --- a/Spark-iOS/Spark-iOS/Source/ViewControllers/TabBar/FeedVC.swift +++ b/Spark-iOS/Spark-iOS/Source/ViewControllers/TabBar/FeedVC.swift @@ -38,11 +38,11 @@ class FeedVC: UIViewController { setCollectionView() // FIXME: - getFeedListFetchWithAPI 위치 변경 - DispatchQueue.main.async { - self.getFeedListFetchWithAPI(lastID: self.feedLastID) { -// self.collectionView.scrollToItem(at: IndexPath(item: 0, section: 0), at: .bottom, animated: false) - } - } +// DispatchQueue.main.async { +// self.getFeedListFetchWithAPI(lastID: self.feedLastID) { +//// self.collectionView.scrollToItem(at: IndexPath(item: 0, section: 0), at: .bottom, animated: false) +// } +// } } override func viewWillAppear(_ animated: Bool) { @@ -52,6 +52,11 @@ class FeedVC: UIViewController { tabBarController?.tabBar.isHidden = false // FIXME: - getFeedListFetchWithAPI를 여기서 호출하는거로 변경 // collectionView.scrollToItem(at: IndexPath(item: 0, section: 0), at: .bottom, animated: false) + DispatchQueue.main.async { + self.getFeedListFetchWithAPI(lastID: self.feedLastID) { + self.collectionView.scrollToItem(at: IndexPath(item: 0, section: 0), at: .bottom, animated: false) + } + } } // MARK: - Methods From 0bd395dbd9d7510b8a5fdb3a0a69782c3afde206 Mon Sep 17 00:00:00 2001 From: yangsubinn Date: Fri, 21 Jan 2022 14:32:22 +0900 Subject: [PATCH 3/5] =?UTF-8?q?[Del]=20#159=20-=20=EB=B6=88=ED=95=84?= =?UTF-8?q?=EC=9A=94=ED=95=9C=20=EC=BD=94=EB=93=9C=20=EC=82=AD=EC=A0=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Spark-iOS/Spark-iOS/Source/ViewControllers/TabBar/FeedVC.swift | 1 - 1 file changed, 1 deletion(-) diff --git a/Spark-iOS/Spark-iOS/Source/ViewControllers/TabBar/FeedVC.swift b/Spark-iOS/Spark-iOS/Source/ViewControllers/TabBar/FeedVC.swift index 8f143c23..05ca5964 100644 --- a/Spark-iOS/Spark-iOS/Source/ViewControllers/TabBar/FeedVC.swift +++ b/Spark-iOS/Spark-iOS/Source/ViewControllers/TabBar/FeedVC.swift @@ -51,7 +51,6 @@ class FeedVC: UIViewController { NotificationCenter.default.post(name: .disappearFloatingButton, object: nil) tabBarController?.tabBar.isHidden = false // FIXME: - getFeedListFetchWithAPI를 여기서 호출하는거로 변경 -// collectionView.scrollToItem(at: IndexPath(item: 0, section: 0), at: .bottom, animated: false) DispatchQueue.main.async { self.getFeedListFetchWithAPI(lastID: self.feedLastID) { self.collectionView.scrollToItem(at: IndexPath(item: 0, section: 0), at: .bottom, animated: false) From bdb53ef785a62ba53c03a22eaaceb9d9e6d8751e Mon Sep 17 00:00:00 2001 From: yangsubinn Date: Fri, 21 Jan 2022 14:49:53 +0900 Subject: [PATCH 4/5] =?UTF-8?q?[Fix]=20#159=20-=20=EC=9D=B8=EC=A6=9D?= =?UTF-8?q?=ED=95=98=EA=B3=A0=20=ED=94=BC=EB=93=9C=EB=A1=9C=20=EC=99=94?= =?UTF-8?q?=EC=9D=84=20=EB=95=8C=20=ED=99=88=20=ED=83=AD=EC=97=90=EB=8A=94?= =?UTF-8?q?=20=EC=83=81=EC=84=B8=EB=B7=B0=20=EB=96=A0=EC=9E=88=EB=8A=94=20?= =?UTF-8?q?=EB=AC=B8=EC=A0=9C=20=ED=95=B4=EA=B2=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../HabitRoom/CompleteAuthVC.swift | 4 +++- .../ViewControllers/TabBar/FeedVC.swift | 20 +++++++++---------- 2 files changed, 13 insertions(+), 11 deletions(-) diff --git a/Spark-iOS/Spark-iOS/Source/ViewControllers/HabitRoom/CompleteAuthVC.swift b/Spark-iOS/Spark-iOS/Source/ViewControllers/HabitRoom/CompleteAuthVC.swift index 61d3c7de..d1adc64d 100644 --- a/Spark-iOS/Spark-iOS/Source/ViewControllers/HabitRoom/CompleteAuthVC.swift +++ b/Spark-iOS/Spark-iOS/Source/ViewControllers/HabitRoom/CompleteAuthVC.swift @@ -42,8 +42,10 @@ class CompleteAuthVC: UIViewController { // MARK: IBActions @IBAction func goToFeedVC(_ sender: Any) { guard let presentingVC = self.presentingViewController?.presentingViewController as? UITabBarController else { return } + guard let naviVC = presentingVC.viewControllers?[1] as? UINavigationController else { return } - self.presentingViewController?.presentingViewController?.dismiss(animated: false) { + presentingVC.dismiss(animated: false) { + naviVC.popViewController(animated: false) presentingVC.selectedIndex = 0 } } diff --git a/Spark-iOS/Spark-iOS/Source/ViewControllers/TabBar/FeedVC.swift b/Spark-iOS/Spark-iOS/Source/ViewControllers/TabBar/FeedVC.swift index 05ca5964..105fa302 100644 --- a/Spark-iOS/Spark-iOS/Source/ViewControllers/TabBar/FeedVC.swift +++ b/Spark-iOS/Spark-iOS/Source/ViewControllers/TabBar/FeedVC.swift @@ -38,11 +38,11 @@ class FeedVC: UIViewController { setCollectionView() // FIXME: - getFeedListFetchWithAPI 위치 변경 -// DispatchQueue.main.async { -// self.getFeedListFetchWithAPI(lastID: self.feedLastID) { -//// self.collectionView.scrollToItem(at: IndexPath(item: 0, section: 0), at: .bottom, animated: false) -// } -// } + DispatchQueue.main.async { + self.getFeedListFetchWithAPI(lastID: self.feedLastID) { +// self.collectionView.scrollToItem(at: IndexPath(item: 0, section: 0), at: .bottom, animated: false) + } + } } override func viewWillAppear(_ animated: Bool) { @@ -51,11 +51,11 @@ class FeedVC: UIViewController { NotificationCenter.default.post(name: .disappearFloatingButton, object: nil) tabBarController?.tabBar.isHidden = false // FIXME: - getFeedListFetchWithAPI를 여기서 호출하는거로 변경 - DispatchQueue.main.async { - self.getFeedListFetchWithAPI(lastID: self.feedLastID) { - self.collectionView.scrollToItem(at: IndexPath(item: 0, section: 0), at: .bottom, animated: false) - } - } +// DispatchQueue.main.async { +// self.getFeedListFetchWithAPI(lastID: self.feedLastID) { +// self.collectionView.scrollToItem(at: IndexPath(item: 0, section: 0), at: .bottom, animated: false) +// } +// } } // MARK: - Methods From d35c5d613e5ed73a4fc6485fb274a55512bf0baa Mon Sep 17 00:00:00 2001 From: yangsubinn Date: Fri, 21 Jan 2022 14:59:12 +0900 Subject: [PATCH 5/5] =?UTF-8?q?[Feat]=20#159=20-=20=EB=84=A4=EB=B9=84?= =?UTF-8?q?=EB=B0=94=20hidden=EC=9D=BC=EB=95=8C=20swipeBackGesture?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Auth/AuthTimer/AuthTimerVC.swift | 1 + .../ViewControllers/Create/CreateRoomVC.swift | 17 +++++------------ .../ViewControllers/HabitRoom/HabitRoomVC.swift | 1 + 3 files changed, 7 insertions(+), 12 deletions(-) diff --git a/Spark-iOS/Spark-iOS/Source/ViewControllers/Auth/AuthTimer/AuthTimerVC.swift b/Spark-iOS/Spark-iOS/Source/ViewControllers/Auth/AuthTimer/AuthTimerVC.swift index 94b8042c..ea5f17f6 100644 --- a/Spark-iOS/Spark-iOS/Source/ViewControllers/Auth/AuthTimer/AuthTimerVC.swift +++ b/Spark-iOS/Spark-iOS/Source/ViewControllers/Auth/AuthTimer/AuthTimerVC.swift @@ -48,6 +48,7 @@ class AuthTimerVC: UIViewController { super.viewWillAppear(animated) navigationController?.isNavigationBarHidden = true + navigationController?.interactivePopGestureRecognizer?.delegate = nil } // MARK: - Methods diff --git a/Spark-iOS/Spark-iOS/Source/ViewControllers/Create/CreateRoomVC.swift b/Spark-iOS/Spark-iOS/Source/ViewControllers/Create/CreateRoomVC.swift index 647cf5a5..bbfe388b 100644 --- a/Spark-iOS/Spark-iOS/Source/ViewControllers/Create/CreateRoomVC.swift +++ b/Spark-iOS/Spark-iOS/Source/ViewControllers/Create/CreateRoomVC.swift @@ -25,28 +25,22 @@ class CreateRoomVC: UIViewController { // MARK: - View Life Cycles - override func viewWillAppear(_ animated: Bool) { - navigationController?.isNavigationBarHidden = true - } - override func viewDidLoad() { super.viewDidLoad() - setUI() setLayout() setNotification() setAddTarget() } + override func viewWillAppear(_ animated: Bool) { + navigationController?.isNavigationBarHidden = true + navigationController?.interactivePopGestureRecognizer?.delegate = nil + } + // MARK: - Methods private func setUI() { -// navigationController?.initWithLeftButtonTitle(title: "aa", -// tintColor: .sparkBlack, -// backgroundColor: .white, -// image: UIImage(named: "icQuit"), -// selector: #selector(touchCloseButton)) - closeButton.setImage(UIImage(named: "icQuit"), for: .normal) titleLabel.text = "어떤 습관방을 만들건가요?" @@ -213,5 +207,4 @@ extension CreateRoomVC: UITextFieldDelegate { disableButton() } } - } diff --git a/Spark-iOS/Spark-iOS/Source/ViewControllers/HabitRoom/HabitRoomVC.swift b/Spark-iOS/Spark-iOS/Source/ViewControllers/HabitRoom/HabitRoomVC.swift index fbe07bb1..29cf6a65 100644 --- a/Spark-iOS/Spark-iOS/Source/ViewControllers/HabitRoom/HabitRoomVC.swift +++ b/Spark-iOS/Spark-iOS/Source/ViewControllers/HabitRoom/HabitRoomVC.swift @@ -96,6 +96,7 @@ class HabitRoomVC: UIViewController { extension HabitRoomVC { private func setUI() { navigationController?.isNavigationBarHidden = true + navigationController?.interactivePopGestureRecognizer?.delegate = nil tabBarController?.tabBar.isHidden = true NotificationCenter.default.post(name: .disappearFloatingButton, object: nil)