From b0bbddbaca02334b2b1aa9db557e8fc55e912b37 Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Mon, 8 Dec 2025 09:44:14 +0900 Subject: [PATCH 01/18] =?UTF-8?q?fix:=20#346=20=EC=8B=A4=EC=A0=9C=EB=A1=9C?= =?UTF-8?q?=20=EC=8B=9C=EC=8A=A4=ED=85=9C=20=EC=84=A4=EC=A0=95=EC=97=90=20?= =?UTF-8?q?=EB=8B=A4=EB=85=80=EC=98=A8=20=EA=B2=BD=EC=9A=B0=EC=97=90?= =?UTF-8?q?=EB=A7=8C=20checkNotificationAuthorizationWhenBack=20=ED=98=B8?= =?UTF-8?q?=EC=B6=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit didOpenSetting 플래그 변수 추가 --- .../ViewController/MyPageViewController.swift | 28 +++++++++++-------- 1 file changed, 17 insertions(+), 11 deletions(-) diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/MyPage/ViewController/MyPageViewController.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/MyPage/ViewController/MyPageViewController.swift index 60e036db..157ad19d 100644 --- a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/MyPage/ViewController/MyPageViewController.swift +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/MyPage/ViewController/MyPageViewController.swift @@ -16,6 +16,7 @@ final class MyPageViewController: BaseViewController { private var cancellables = Set() private var name: String? private var beforeNotificationStatus = false + private var didOpenSetting = false private let rootView = MyPageView() @@ -204,25 +205,29 @@ extension MyPageViewController { @objc private func checkNoticeAuthorizationWhenBack() { + guard didOpenSetting else { return } + UNUserNotificationCenter.current().getNotificationSettings { [weak self] settings in guard let self else { return } + let isAuthorized: Bool switch settings.authorizationStatus { case .authorized, .provisional, .ephemeral: - if !beforeNotificationStatus { - self.viewModel.action(.notificationSwitchDidTap) - } - beforeNotificationStatus = true + isAuthorized = true default: - if beforeNotificationStatus { - self.viewModel.action(.notificationSwitchDidTap) - } else { - DispatchQueue.main.async { - self.rootView.noticeView.noticeSwitch.setOn(false, animated: false) - } + isAuthorized = false + } + + if beforeNotificationStatus != isAuthorized { + viewModel.action(.notificationSwitchDidTap) + } else if !isAuthorized { + DispatchQueue.main.async { + self.rootView.noticeView.noticeSwitch.setOn(false, animated: false) } - beforeNotificationStatus = false } + + beforeNotificationStatus = isAuthorized + didOpenSetting = false } } @@ -425,6 +430,7 @@ extension MyPageViewController { private func moveSetting() { if let url = URL(string: UIApplication.openSettingsURLString) { UIApplication.shared.open(url) + didOpenSetting = true } } } From 089f3a6b1872775bb3f3659f67cab393d0d3d5c4 Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Mon, 8 Dec 2025 09:59:52 +0900 Subject: [PATCH 02/18] =?UTF-8?q?refactor:=20#346=20=EC=B5=9C=EC=8B=A0=20?= =?UTF-8?q?=ED=86=A0=EA=B8=80=20=EC=83=81=ED=83=9C=20=EB=B3=80=EC=88=98?= =?UTF-8?q?=EB=A5=BC=20=EC=8B=A4=EC=A0=9C=20=ED=86=A0=EA=B8=80=20=EB=B2=84?= =?UTF-8?q?=ED=8A=BC=EC=9D=98=20isOn=20=EC=86=8D=EC=84=B1=EC=9C=BC?= =?UTF-8?q?=EB=A1=9C=20=EC=B4=88=EA=B8=B0=ED=99=94?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Feature/MyPage/ViewController/MyPageViewController.swift | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/MyPage/ViewController/MyPageViewController.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/MyPage/ViewController/MyPageViewController.swift index 157ad19d..df69c7e5 100644 --- a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/MyPage/ViewController/MyPageViewController.swift +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/MyPage/ViewController/MyPageViewController.swift @@ -15,10 +15,10 @@ final class MyPageViewController: BaseViewController { private let viewModel: MyPageViewModel private var cancellables = Set() private var name: String? - private var beforeNotificationStatus = false - private var didOpenSetting = false private let rootView = MyPageView() + private lazy var beforeNotificationStatus = rootView.noticeView.noticeSwitch.isOn + private var didOpenSetting = false init(viewModel: MyPageViewModel) { self.viewModel = viewModel From 4d6be1e9d3e4c526ed212c5a65f81da563b844c0 Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Thu, 12 Feb 2026 15:44:13 +0900 Subject: [PATCH 03/18] =?UTF-8?q?setting:=20=ED=94=84=EB=A1=9C=EB=B9=84?= =?UTF-8?q?=EC=A0=80=EB=8B=9D=20=ED=8C=8C=EC=9D=BC=20=EC=97=85=EB=8D=B0?= =?UTF-8?q?=EC=9D=B4=ED=8A=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ByeBoo-iOS.xcodeproj/project.pbxproj | 22 ++--- .../Quest/CommonQuestViewController.swift | 0 .../Feature/Quest/QuestTabItem.swift | 0 .../Presentation/Feature/Quest/TabItem.swift | 0 .../Feature/Quest/TopTabBar.swift | 33 ++++++++ .../Feature/Quest/TopTabBarItemView.swift | 75 ++++++++++++++++++ .../Quest/TopTabBarViewController.swift | 25 ++++++ .../Feature/QuestTabBarViewController.swift | 0 .../common_journey.imageset/Contents.json | 21 +++++ .../common_journey.png | Bin 0 -> 683 bytes .../my_journey.imageset/Contents.json | 21 +++++ .../my_journey.imageset/my_journey.png | Bin 0 -> 764 bytes 12 files changed, 186 insertions(+), 11 deletions(-) create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/CommonQuestViewController.swift create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/QuestTabItem.swift create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TabItem.swift create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBar.swift create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarItemView.swift create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarViewController.swift create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/QuestTabBarViewController.swift create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/common_journey.imageset/Contents.json create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/common_journey.imageset/common_journey.png create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/my_journey.imageset/Contents.json create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/my_journey.imageset/my_journey.png diff --git a/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj b/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj index 2bb52e97..d7a3f226 100644 --- a/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj +++ b/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj @@ -274,10 +274,10 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-iOS.entitlements"; + CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-Dev.entitlements"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 1; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = Z6682N5G5D; GENERATE_INFOPLIST_FILE = YES; @@ -294,11 +294,11 @@ "$(inherited)", "@executable_path/Frameworks", ); - MARKETING_VERSION = 1.1.0; + MARKETING_VERSION = 1.1.2; PRODUCT_BUNDLE_IDENTIFIER = "com.heartz.ByeBoo-iOS"; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE_SPECIFIER = ""; - "PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = Debug; + "PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = "match Development com.heartz.ByeBoo-iOS"; SUPPORTED_PLATFORMS = "iphoneos iphonesimulator"; SUPPORTS_MACCATALYST = NO; SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO; @@ -316,10 +316,10 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-iOS.entitlements"; - "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; + CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-Prod.entitlements"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 1; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = Z6682N5G5D; GENERATE_INFOPLIST_FILE = YES; @@ -336,11 +336,11 @@ "$(inherited)", "@executable_path/Frameworks", ); - MARKETING_VERSION = 1.1.0; + MARKETING_VERSION = 1.1.2; PRODUCT_BUNDLE_IDENTIFIER = "com.heartz.ByeBoo-iOS"; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE_SPECIFIER = ""; - "PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = Release; + "PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = "match Development com.heartz.ByeBoo-iOS"; SUPPORTED_PLATFORMS = "iphoneos iphonesimulator"; SUPPORTS_MACCATALYST = NO; SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO; @@ -480,7 +480,7 @@ buildSettings = { BUNDLE_LOADER = "$(TEST_HOST)"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 1; + CURRENT_PROJECT_VERSION = 6; GENERATE_INFOPLIST_FILE = YES; IPHONEOS_DEPLOYMENT_TARGET = 18.2; MACOSX_DEPLOYMENT_TARGET = 15.2; @@ -502,7 +502,7 @@ buildSettings = { BUNDLE_LOADER = "$(TEST_HOST)"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 1; + CURRENT_PROJECT_VERSION = 6; GENERATE_INFOPLIST_FILE = YES; IPHONEOS_DEPLOYMENT_TARGET = 18.2; MACOSX_DEPLOYMENT_TARGET = 15.2; diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/CommonQuestViewController.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/CommonQuestViewController.swift new file mode 100644 index 00000000..e69de29b diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/QuestTabItem.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/QuestTabItem.swift new file mode 100644 index 00000000..e69de29b diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TabItem.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TabItem.swift new file mode 100644 index 00000000..e69de29b diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBar.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBar.swift new file mode 100644 index 00000000..dc3beed6 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBar.swift @@ -0,0 +1,33 @@ +// +// QuestTabBar.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/12/26. +// + +import UIKit + +final class QuestTabBar: UIStackView { + + private let itemViews = QuestTabItem.allCases.map { QuestTabBarItemView(item: $0) } + + func setStyle() { + self.do { + $0.axis = .horizontal + $0.spacing = 4 + $0.distribution = .fillEqually + } + } + + func setUI() { + itemViews.forEach { self.addArrangedSubview($0) } + } + + func setLayout() { + self.snp.makeConstraints { + $0.width.equalTo(220.adjustedW) + $0.height.equalTo(28.adjustedH) + $0.edges.equalToSuperview() + } + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarItemView.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarItemView.swift new file mode 100644 index 00000000..7a3013e5 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarItemView.swift @@ -0,0 +1,75 @@ +// +// TopTabBarItemView.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/12/26. +// + +import UIKit + +final class TopTabBarItemView: BaseView { + + private let journeyStackView = UIStackView() + private let journeyImageView = UIImageView() + private let journeyNameLabel = UILabel() + private let underlineLabel = UILabel() + + init(item: any TabItem) { + journeyImageView.image = item.image + journeyNameLabel.text = item.title + + super.init(frame: .zero) + } + + required init?(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + + override func setStyle() { + journeyStackView.do { + $0.axis = .horizontal + $0.spacing = 2 + $0.alignment = .center + } + journeyNameLabel.do { + $0.textColor = .grayscale100 + $0.font = FontManager.body2M16.font + $0.textAlignment = .center + } + underlineLabel.do { + $0.backgroundColor = .grayscale300 + $0.layer.borderWidth = 1 + } + } + + override func setUI() { + addSubviews( + journeyStackView, + underlineLabel + ) + journeyStackView.addArrangedSubviews( + journeyImageView, + journeyNameLabel + ) + } + + override func setLayout() { + journeyStackView.snp.makeConstraints { + $0.width.equalTo(108.adjustedW) + $0.height.equalTo(24.adjustedH) + } + journeyImageView.snp.makeConstraints { + $0.size.equalTo(24.adjustedW) + } + journeyNameLabel.snp.makeConstraints { + $0.centerY.equalToSuperview() + $0.width.equalTo(59.adjustedW) + $0.height.equalTo(21.adjustedH) + } + underlineLabel.snp.makeConstraints { + $0.top.equalTo(journeyStackView.snp.bottom).offset(4.adjustedH) + $0.width.equalTo(108.adjustedW) + $0.height.equalTo(1.adjustedH) + } + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarViewController.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarViewController.swift new file mode 100644 index 00000000..6ff7d2de --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarViewController.swift @@ -0,0 +1,25 @@ +// +// TabBarViewController.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/12/26. +// + +import UIKit + +final class TabBarViewController: UITabBarController { + + private let topTabBar = TopTabBar(items: Array(T.allCases)) + + override func viewDidLoad() { + self.tabBar.isHidden = true + view.addSubview(topTabBar) + + topTabBar.snp.makeConstraints { + $0.edges.equalToSuperview() + } + + let viewControllers = T.allCases.map { $0.viewController } + setViewControllers(viewControllers, animated: false) + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/QuestTabBarViewController.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/QuestTabBarViewController.swift new file mode 100644 index 00000000..e69de29b diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/common_journey.imageset/Contents.json b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/common_journey.imageset/Contents.json new file mode 100644 index 00000000..feb1f516 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/common_journey.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "common_journey.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/common_journey.imageset/common_journey.png b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/common_journey.imageset/common_journey.png new file mode 100644 index 0000000000000000000000000000000000000000..e0f5d2e0387a01290244a1c4af6122e82c885a40 GIT binary patch literal 683 zcmV;c0#yBpP)R6F6k4Pt%90tic$)BgQiblqd{<$M6tSS-k@1Z+yq>? z(O^Ysp&>NwB#xQ;dGDB%>12|$q&s_HnEQLqchC3T3!GsLn7ec5!BU1XJZGRXh?lDG z^JPqkLxH;wm%hng#5LChXyMcPs~RSN?vkp5Tmn*>39kAh1qvB5BuSKPM6GT+E`%Lf zd>x9pXiko|8A?DPPJ{$WazVDS-`PcQDulq)bneLumKi+32)xTs)V7h3&HE0a4MUAf zV(gha==^CR9Ew2K0uUT)?!9c-u{9e>*^Em<^*6k0%->Bk_P3man27dlo8#)a$hyKy)t2s!Wi0Rd^nD%Tu4jzrxR78nCI4?iY@;S{sL7K;+Fp% R4;TOd002ovPDHLkV1m8rIKcn_ literal 0 HcmV?d00001 diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/my_journey.imageset/Contents.json b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/my_journey.imageset/Contents.json new file mode 100644 index 00000000..4229a3ba --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/my_journey.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "my_journey.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/my_journey.imageset/my_journey.png b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/my_journey.imageset/my_journey.png new file mode 100644 index 0000000000000000000000000000000000000000..77373e9ff95d3be9795f05b9868076440e123418 GIT binary patch literal 764 zcmVFZaz|$0*K*c zS}=&;OOPD=FTu*fWEKb8CacEB{n=!(vNz}T_@R$_G|4SPLPRMDqrHTL@7xj?4MPEm zV;d_9&s<6D=1uQ4_*KY(!8~Cpon1-|KIprMD;dYeH34lHPhVtGf{__ydi}MuGJPmA zKq-U3z$gs*f}9ct_~m;EuF>%fmKP?Y2Jy#6*vo+F9RjHY?3cd9gTtW&%9Dp4Ks!07 zhBDh%0&jCD50ol$R41QDFgwXmS9|s{M zSgL)QyE^spHvtl>N_OtehrKkMmVr)PNr-|AnCu4cgOMaC#R-AMZflza)MaoD#tbm& z?BCmjaz3~{o_u13cvk|%b#MuVsSdLFJOMg`n&l`EYrkM;AKtkfJDC7)4Y-7mj_&yS zRwk_cm_L%(ML80~BR ztaq$;?g+c-!yKL+-+-13yRlZ^ky^BI|9ccuilE8iWaK5vvGja20WQ#1>^7_)9EA%r uqGsVp?NK?Q$a|30)KY4!r-FBeuJ{9IY4Ie&$J)LC0000 Date: Sun, 15 Feb 2026 21:43:15 +0900 Subject: [PATCH 04/18] =?UTF-8?q?style:=20#346=20=ED=83=AD=EB=B0=94=20?= =?UTF-8?q?=EA=B5=AC=ED=98=84=EC=97=90=20=ED=95=84=EC=9A=94=ED=95=9C=20?= =?UTF-8?q?=EC=9D=B4=EB=AF=B8=EC=A7=80=20=EC=84=B8=ED=8C=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Assets.xcassets/TabBar/Contents.json | 6 ++++++ .../common_journey.imageset}/Contents.json | 2 +- .../common_journey_sharp.svg | 8 +++++++ .../my_journey.imageset}/Contents.json | 2 +- .../my_journey.imageset/my_journey_sharp.svg | 20 ++++++++++++++++++ .../common_journey.png | Bin 683 -> 0 bytes .../my_journey.imageset/my_journey.png | Bin 764 -> 0 bytes 7 files changed, 36 insertions(+), 2 deletions(-) create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/Contents.json rename ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/{my_journey.imageset => TabBar/common_journey.imageset}/Contents.json (85%) create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/common_journey_sharp.svg rename ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/{common_journey.imageset => TabBar/my_journey.imageset}/Contents.json (86%) create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/my_journey_sharp.svg delete mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/common_journey.imageset/common_journey.png delete mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/my_journey.imageset/my_journey.png diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/Contents.json b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/Contents.json new file mode 100644 index 00000000..73c00596 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/my_journey.imageset/Contents.json b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/Contents.json similarity index 85% rename from ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/my_journey.imageset/Contents.json rename to ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/Contents.json index 4229a3ba..63aded90 100644 --- a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/my_journey.imageset/Contents.json +++ b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/Contents.json @@ -1,7 +1,7 @@ { "images" : [ { - "filename" : "my_journey.png", + "filename" : "common_journey_sharp.svg", "idiom" : "universal", "scale" : "1x" }, diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/common_journey_sharp.svg b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/common_journey_sharp.svg new file mode 100644 index 00000000..61f3b35e --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/common_journey_sharp.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/common_journey.imageset/Contents.json b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/Contents.json similarity index 86% rename from ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/common_journey.imageset/Contents.json rename to ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/Contents.json index feb1f516..4c09197b 100644 --- a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/common_journey.imageset/Contents.json +++ b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/Contents.json @@ -1,7 +1,7 @@ { "images" : [ { - "filename" : "common_journey.png", + "filename" : "my_journey_sharp.svg", "idiom" : "universal", "scale" : "1x" }, diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/my_journey_sharp.svg b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/my_journey_sharp.svg new file mode 100644 index 00000000..9d84a147 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/my_journey_sharp.svg @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/common_journey.imageset/common_journey.png b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/common_journey.imageset/common_journey.png deleted file mode 100644 index e0f5d2e0387a01290244a1c4af6122e82c885a40..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 683 zcmV;c0#yBpP)R6F6k4Pt%90tic$)BgQiblqd{<$M6tSS-k@1Z+yq>? z(O^Ysp&>NwB#xQ;dGDB%>12|$q&s_HnEQLqchC3T3!GsLn7ec5!BU1XJZGRXh?lDG z^JPqkLxH;wm%hng#5LChXyMcPs~RSN?vkp5Tmn*>39kAh1qvB5BuSKPM6GT+E`%Lf zd>x9pXiko|8A?DPPJ{$WazVDS-`PcQDulq)bneLumKi+32)xTs)V7h3&HE0a4MUAf zV(gha==^CR9Ew2K0uUT)?!9c-u{9e>*^Em<^*6k0%->Bk_P3man27dlo8#)a$hyKy)t2s!Wi0Rd^nD%Tu4jzrxR78nCI4?iY@;S{sL7K;+Fp% R4;TOd002ovPDHLkV1m8rIKcn_ diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/my_journey.imageset/my_journey.png b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/my_journey.imageset/my_journey.png deleted file mode 100644 index 77373e9ff95d3be9795f05b9868076440e123418..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 764 zcmVFZaz|$0*K*c zS}=&;OOPD=FTu*fWEKb8CacEB{n=!(vNz}T_@R$_G|4SPLPRMDqrHTL@7xj?4MPEm zV;d_9&s<6D=1uQ4_*KY(!8~Cpon1-|KIprMD;dYeH34lHPhVtGf{__ydi}MuGJPmA zKq-U3z$gs*f}9ct_~m;EuF>%fmKP?Y2Jy#6*vo+F9RjHY?3cd9gTtW&%9Dp4Ks!07 zhBDh%0&jCD50ol$R41QDFgwXmS9|s{M zSgL)QyE^spHvtl>N_OtehrKkMmVr)PNr-|AnCu4cgOMaC#R-AMZflza)MaoD#tbm& z?BCmjaz3~{o_u13cvk|%b#MuVsSdLFJOMg`n&l`EYrkM;AKtkfJDC7)4Y-7mj_&yS zRwk_cm_L%(ML80~BR ztaq$;?g+c-!yKL+-+-13yRlZ^ky^BI|9ccuilE8iWaK5vvGja20WQ#1>^7_)9EA%r uqGsVp?NK?Q$a|30)KY4!r-FBeuJ{9IY4Ie&$J)LC0000 Date: Sun, 15 Feb 2026 21:44:57 +0900 Subject: [PATCH 05/18] =?UTF-8?q?feat:=20#346=20=EC=83=81=EB=8B=A8=20?= =?UTF-8?q?=ED=83=AD=EB=B0=94=20=EC=84=A4=EA=B3=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Common/TopTabBar/TabItem.swift | 14 ++++ .../Common/TopTabBar/TopTabBar.swift | 71 +++++++++++++++++++ .../TopTabBar}/TopTabBarItemView.swift | 25 +++++-- .../Presentation/Feature/Quest/TabItem.swift | 0 .../Feature/Quest/TopTabBar.swift | 33 --------- .../Quest/TopTabBarViewController.swift | 25 ------- 6 files changed, 106 insertions(+), 62 deletions(-) create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TabItem.swift create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBar.swift rename ByeBoo-iOS/ByeBoo-iOS/Presentation/{Feature/Quest => Common/TopTabBar}/TopTabBarItemView.swift (66%) delete mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TabItem.swift delete mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBar.swift delete mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarViewController.swift diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TabItem.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TabItem.swift new file mode 100644 index 00000000..1e35e1f7 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TabItem.swift @@ -0,0 +1,14 @@ +// +// TabItem.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/12/26. +// + +import UIKit + +protocol TabItem: CaseIterable { + var title: String { get } + var image: UIImage { get } + var viewController: UIViewController { get } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBar.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBar.swift new file mode 100644 index 00000000..494b3b24 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBar.swift @@ -0,0 +1,71 @@ +// +// TopTabBar.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/12/26. +// + +import UIKit + +final class TopTabBar: UIStackView { + + private let itemViews: [TopTabBarItemView] + var didTap: ((Int) -> Void)? + + init(items: [any TabItem]) { + self.itemViews = items.map { TopTabBarItemView(item: $0) } + super.init(frame: .zero) + + setStyle() + setUI() + setAction() + } + + required init(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + + private func setStyle() { + self.do { + $0.backgroundColor = .grayscale900 + $0.axis = .horizontal + $0.spacing = 4 + $0.distribution = .fillEqually + } + } + + private func setUI() { + itemViews.forEach { self.addArrangedSubview($0) } + } + + private func setAction() { + itemViews.enumerated().forEach { index, itemView in + let tapGesture = UITapGestureRecognizer( + target: self, action: #selector(barTapped(_:)) + ) + itemView.addGestureRecognizer(tapGesture) + itemView.tag = index + } + + if let firstIndex = itemViews.indices.first { + updateTabBar(tag: firstIndex) + } + } +} + +extension TopTabBar { + + @objc + private func barTapped(_ sender: UITapGestureRecognizer) { + guard let tag = sender.view?.tag else { + return + } + + didTap?(tag) + updateTabBar(tag: tag) + } + + private func updateTabBar(tag: Int) { + itemViews.forEach { $0.updateBarItem(for: tag) } + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarItemView.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBarItemView.swift similarity index 66% rename from ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarItemView.swift rename to ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBarItemView.swift index 7a3013e5..fb76cebd 100644 --- a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarItemView.swift +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBarItemView.swift @@ -37,7 +37,7 @@ final class TopTabBarItemView: BaseView { $0.textAlignment = .center } underlineLabel.do { - $0.backgroundColor = .grayscale300 + $0.layer.borderColor = UIColor.grayscale300.cgColor $0.layer.borderWidth = 1 } } @@ -55,21 +55,38 @@ final class TopTabBarItemView: BaseView { override func setLayout() { journeyStackView.snp.makeConstraints { + $0.top.equalToSuperview() + $0.centerX.equalToSuperview() $0.width.equalTo(108.adjustedW) $0.height.equalTo(24.adjustedH) } journeyImageView.snp.makeConstraints { $0.size.equalTo(24.adjustedW) + $0.verticalEdges.equalToSuperview() + $0.leading.equalToSuperview().inset(9.5.adjustedW) } journeyNameLabel.snp.makeConstraints { + $0.leading.equalTo(journeyImageView.snp.trailing).offset(2.adjustedW) $0.centerY.equalToSuperview() - $0.width.equalTo(59.adjustedW) - $0.height.equalTo(21.adjustedH) + $0.trailing.equalToSuperview().inset(11.5.adjustedW) } underlineLabel.snp.makeConstraints { $0.top.equalTo(journeyStackView.snp.bottom).offset(4.adjustedH) - $0.width.equalTo(108.adjustedW) + $0.horizontalEdges.equalToSuperview() $0.height.equalTo(1.adjustedH) + $0.bottom.equalToSuperview() } } } + +extension TopTabBarItemView { + + func updateBarItem(for tag: Int) { + let condition = (self.tag == tag) + + journeyImageView.layer.opacity = condition ? 1 : 0.44 + journeyNameLabel.textColor = condition ? .grayscale100 : .grayscale600 + underlineLabel.layer.borderColor = condition ? UIColor.grayscale300.cgColor : UIColor.clear.cgColor + underlineLabel.layer.borderWidth = condition ? 1 : 0 + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TabItem.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TabItem.swift deleted file mode 100644 index e69de29b..00000000 diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBar.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBar.swift deleted file mode 100644 index dc3beed6..00000000 --- a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBar.swift +++ /dev/null @@ -1,33 +0,0 @@ -// -// QuestTabBar.swift -// ByeBoo-iOS -// -// Created by APPLE on 2/12/26. -// - -import UIKit - -final class QuestTabBar: UIStackView { - - private let itemViews = QuestTabItem.allCases.map { QuestTabBarItemView(item: $0) } - - func setStyle() { - self.do { - $0.axis = .horizontal - $0.spacing = 4 - $0.distribution = .fillEqually - } - } - - func setUI() { - itemViews.forEach { self.addArrangedSubview($0) } - } - - func setLayout() { - self.snp.makeConstraints { - $0.width.equalTo(220.adjustedW) - $0.height.equalTo(28.adjustedH) - $0.edges.equalToSuperview() - } - } -} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarViewController.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarViewController.swift deleted file mode 100644 index 6ff7d2de..00000000 --- a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/TopTabBarViewController.swift +++ /dev/null @@ -1,25 +0,0 @@ -// -// TabBarViewController.swift -// ByeBoo-iOS -// -// Created by APPLE on 2/12/26. -// - -import UIKit - -final class TabBarViewController: UITabBarController { - - private let topTabBar = TopTabBar(items: Array(T.allCases)) - - override func viewDidLoad() { - self.tabBar.isHidden = true - view.addSubview(topTabBar) - - topTabBar.snp.makeConstraints { - $0.edges.equalToSuperview() - } - - let viewControllers = T.allCases.map { $0.viewController } - setViewControllers(viewControllers, animated: false) - } -} From c165f217c5c50ed7ce790830a487e0d62b587aa8 Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Sun, 15 Feb 2026 21:46:43 +0900 Subject: [PATCH 06/18] =?UTF-8?q?feat:=20#346=20=ED=80=98=EC=8A=A4?= =?UTF-8?q?=ED=8A=B8=20=EC=A0=84=EC=B2=B4=20=EC=A1=B0=ED=9A=8C=20=EB=B7=B0?= =?UTF-8?q?=EC=97=90=20=EC=83=81=EB=8B=A8=20=ED=83=AD=EB=B0=94=20=EC=A0=81?= =?UTF-8?q?=EC=9A=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 전체 관리 : ParentQuestViewController 나의 여정 : QuestCheckViewController 공통 여정 : CommonQuestViewController --- .../Feature/Quest/Common/QuestTabItem.swift | 41 ++++++++ .../Quest/CommonQuestViewController.swift | 0 .../Feature/Quest/QuestTabItem.swift | 0 .../CommonQuestViewController.swift | 19 ++++ .../ParentQuestViewController.swift | 94 +++++++++++++++++++ .../Feature/QuestTabBarViewController.swift | 0 6 files changed, 154 insertions(+) create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/Common/QuestTabItem.swift delete mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/CommonQuestViewController.swift delete mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/QuestTabItem.swift create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/CommonQuestViewController.swift create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/ParentQuestViewController.swift delete mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/QuestTabBarViewController.swift diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/Common/QuestTabItem.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/Common/QuestTabItem.swift new file mode 100644 index 00000000..31d1c67c --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/Common/QuestTabItem.swift @@ -0,0 +1,41 @@ +// +// QuestTabItem.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/12/26. +// + +import UIKit + +enum QuestTabItem: TabItem { + + case myJourney + case commonJourney + + var title: String { + switch self { + case .myJourney: + return "나의 여정" + case .commonJourney: + return "공통 여정" + } + } + + var image: UIImage { + switch self { + case .myJourney: + return .myJourney + case .commonJourney: + return .commonJourney + } + } + + var viewController: UIViewController { + switch self { + case .myJourney: + return ViewControllerFactory.shared.makeQuestViewController() + case .commonJourney: + return ViewControllerFactory.shared.makeCommonQuestViewController() + } + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/CommonQuestViewController.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/CommonQuestViewController.swift deleted file mode 100644 index e69de29b..00000000 diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/QuestTabItem.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/QuestTabItem.swift deleted file mode 100644 index e69de29b..00000000 diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/CommonQuestViewController.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/CommonQuestViewController.swift new file mode 100644 index 00000000..2fefe288 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/CommonQuestViewController.swift @@ -0,0 +1,19 @@ +// +// CommonQuestViewController.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/12/26. +// + +final class CommonQuestViewController: BaseViewController { + + override func viewWillAppear(_ animated: Bool) { + super.viewWillAppear(animated) + self.navigationController?.setNavigationBarHidden(true, animated: false) + } + + override func viewWillDisappear(_ animated: Bool) { + super.viewWillDisappear(animated) + self.navigationController?.setNavigationBarHidden(false, animated: false) + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/ParentQuestViewController.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/ParentQuestViewController.swift new file mode 100644 index 00000000..cdf32179 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/ParentQuestViewController.swift @@ -0,0 +1,94 @@ +// +// ParentQuestViewController.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/14/26. +// + +import UIKit + +final class ParentQuestViewController: BaseViewController { + + private let tabBar: TopTabBar + private let containerView = UIView() + private let controllers: [UIViewController] + private var currentViewController: UIViewController? + + init(items: T.AllCases) { + self.tabBar = TopTabBar(items: Array(items)) + self.controllers = items.map { $0.viewController } + super.init(nibName: nil, bundle: nil) + } + + required init?(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + + override func viewDidLoad() { + super.viewDidLoad() + + setLayout() + bind() + + if let controller = controllers.first { + show(controller) + } + } + + override func setView() { + view.addSubviews( + tabBar, + containerView + ) + } +} + +extension ParentQuestViewController { + + private func setLayout() { + tabBar.snp.makeConstraints { + $0.top.equalTo(view.safeAreaLayoutGuide.snp.top).offset(20.adjustedH) + $0.centerX.equalToSuperview() + $0.width.equalTo(228.adjustedW) + $0.height.equalTo(28.adjustedH) + } + containerView.snp.makeConstraints { + $0.top.equalTo(tabBar.snp.bottom).offset(16.adjustedH) + $0.horizontalEdges.equalToSuperview() + $0.bottom.equalToSuperview() + } + } + + private func bind() { + tabBar.didTap = { [weak self] index in + guard let self, + index >= 0 && index < controllers.count + else { + return + } + show(controllers[index]) + } + } + + private func show(_ target: UIViewController) { + guard currentViewController != target else { return } + + if let currentViewController { + currentViewController.do { + $0.willMove(toParent: nil) + $0.view.removeFromSuperview() + $0.removeFromParent() + } + } + + addChild(target) + containerView.addSubview(target.view) + target.view.snp.makeConstraints { + $0.verticalEdges.equalToSuperview() + $0.horizontalEdges.equalToSuperview() + } + + target.didMove(toParent: self) + currentViewController = target + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/QuestTabBarViewController.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/QuestTabBarViewController.swift deleted file mode 100644 index e69de29b..00000000 From c11f62b930ed572b6b73dafe98e91b8388c7d641 Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Sun, 15 Feb 2026 21:47:18 +0900 Subject: [PATCH 07/18] =?UTF-8?q?refactor:=20#346=20=ED=80=98=EC=8A=A4?= =?UTF-8?q?=ED=8A=B8=20=EB=B7=B0=EB=A1=9C=20=EC=9D=B4=EB=8F=99=ED=95=98?= =?UTF-8?q?=EB=8A=94=20=EB=A9=94=EC=84=9C=EB=93=9C=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Presentation/Common/Navigation/ByeBooTabBar.swift | 2 +- .../ByeBoo-iOS/Presentation/ViewControllerFactory.swift | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/Navigation/ByeBooTabBar.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/Navigation/ByeBooTabBar.swift index fc42776c..a18120c4 100644 --- a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/Navigation/ByeBooTabBar.swift +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/Navigation/ByeBooTabBar.swift @@ -22,7 +22,7 @@ final class ByeBooTabBar: UITabBarController { private func setViewController() { let homeViewController = ViewControllerFactory.shared.makeHomeViewController() - let questViewController = ViewControllerFactory.shared.makeQuestViewController() + let questViewController = ViewControllerFactory.shared.makeParentQuestViewController() let myPageViewController = ViewControllerFactory.shared.makeMyPageViewController() self.viewControllers = [ diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/ViewControllerFactory.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/ViewControllerFactory.swift index 287556ae..2b1e6d38 100644 --- a/ByeBoo-iOS/ByeBoo-iOS/Presentation/ViewControllerFactory.swift +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/ViewControllerFactory.swift @@ -189,6 +189,14 @@ final class ViewControllerFactory: ViewControllerFactoryProtocol { } return CompletedQuestsViewController(viewModel: viewModel) } + + func makeParentQuestViewController() -> ParentQuestViewController { + return ParentQuestViewController(items: QuestTabItem.allCases) + } + + func makeCommonQuestViewController() -> CommonQuestViewController { + return .init() + } } extension ViewControllerFactory { From 3b6eea6dce13b6fc26270f04973384b28f50f61c Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Mon, 16 Feb 2026 14:12:21 +0900 Subject: [PATCH 08/18] =?UTF-8?q?setting:=20#346=20entitlements=20?= =?UTF-8?q?=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj b/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj index d7a3f226..f9e92e02 100644 --- a/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj +++ b/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj @@ -274,7 +274,7 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-Dev.entitlements"; + CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-iOS.entitlements"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 6; @@ -316,7 +316,7 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-Prod.entitlements"; + CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-iOS.entitlements"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 6; From fe06d5f77dc7167a57531be0e5e6e6219105527b Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Mon, 16 Feb 2026 14:14:07 +0900 Subject: [PATCH 09/18] =?UTF-8?q?setting:=20#354=20=ED=94=84=EB=A1=9C?= =?UTF-8?q?=ED=94=BC=EB=B2=84=EC=A7=95=20=ED=8C=8C=EC=9D=BC=20=EC=84=A4?= =?UTF-8?q?=EC=A0=95=20=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj b/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj index 16c57433..f9e92e02 100644 --- a/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj +++ b/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj @@ -274,7 +274,7 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-Dev.entitlements"; + CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-iOS.entitlements"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 6; @@ -298,7 +298,7 @@ PRODUCT_BUNDLE_IDENTIFIER = "com.heartz.ByeBoo-iOS"; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE_SPECIFIER = ""; - "PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = "match AppStore com.heartz.ByeBoo-iOS"; + "PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = "match Development com.heartz.ByeBoo-iOS"; SUPPORTED_PLATFORMS = "iphoneos iphonesimulator"; SUPPORTS_MACCATALYST = NO; SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO; @@ -316,7 +316,7 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-Prod.entitlements"; + CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-iOS.entitlements"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 6; From 74cd809f5a4bc4f25b7bc04654f4482aa640b04f Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Mon, 16 Feb 2026 14:28:10 +0900 Subject: [PATCH 10/18] =?UTF-8?q?feat:=20#354=20=EC=83=81=EB=8B=A8=20?= =?UTF-8?q?=ED=83=AD=EB=B0=94=20=EA=B5=AC=ED=98=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Common/TopTabBar/TabItem.swift | 14 +++ .../Common/TopTabBar/TopTabBar.swift | 71 ++++++++++++++ .../Common/TopTabBar/TopTabBarItemView.swift | 92 ++++++++++++++++++ .../ParentQuestViewController.swift | 94 +++++++++++++++++++ 4 files changed, 271 insertions(+) create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TabItem.swift create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBar.swift create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBarItemView.swift create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/ParentQuestViewController.swift diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TabItem.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TabItem.swift new file mode 100644 index 00000000..1e35e1f7 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TabItem.swift @@ -0,0 +1,14 @@ +// +// TabItem.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/12/26. +// + +import UIKit + +protocol TabItem: CaseIterable { + var title: String { get } + var image: UIImage { get } + var viewController: UIViewController { get } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBar.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBar.swift new file mode 100644 index 00000000..494b3b24 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBar.swift @@ -0,0 +1,71 @@ +// +// TopTabBar.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/12/26. +// + +import UIKit + +final class TopTabBar: UIStackView { + + private let itemViews: [TopTabBarItemView] + var didTap: ((Int) -> Void)? + + init(items: [any TabItem]) { + self.itemViews = items.map { TopTabBarItemView(item: $0) } + super.init(frame: .zero) + + setStyle() + setUI() + setAction() + } + + required init(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + + private func setStyle() { + self.do { + $0.backgroundColor = .grayscale900 + $0.axis = .horizontal + $0.spacing = 4 + $0.distribution = .fillEqually + } + } + + private func setUI() { + itemViews.forEach { self.addArrangedSubview($0) } + } + + private func setAction() { + itemViews.enumerated().forEach { index, itemView in + let tapGesture = UITapGestureRecognizer( + target: self, action: #selector(barTapped(_:)) + ) + itemView.addGestureRecognizer(tapGesture) + itemView.tag = index + } + + if let firstIndex = itemViews.indices.first { + updateTabBar(tag: firstIndex) + } + } +} + +extension TopTabBar { + + @objc + private func barTapped(_ sender: UITapGestureRecognizer) { + guard let tag = sender.view?.tag else { + return + } + + didTap?(tag) + updateTabBar(tag: tag) + } + + private func updateTabBar(tag: Int) { + itemViews.forEach { $0.updateBarItem(for: tag) } + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBarItemView.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBarItemView.swift new file mode 100644 index 00000000..fb76cebd --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBarItemView.swift @@ -0,0 +1,92 @@ +// +// TopTabBarItemView.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/12/26. +// + +import UIKit + +final class TopTabBarItemView: BaseView { + + private let journeyStackView = UIStackView() + private let journeyImageView = UIImageView() + private let journeyNameLabel = UILabel() + private let underlineLabel = UILabel() + + init(item: any TabItem) { + journeyImageView.image = item.image + journeyNameLabel.text = item.title + + super.init(frame: .zero) + } + + required init?(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + + override func setStyle() { + journeyStackView.do { + $0.axis = .horizontal + $0.spacing = 2 + $0.alignment = .center + } + journeyNameLabel.do { + $0.textColor = .grayscale100 + $0.font = FontManager.body2M16.font + $0.textAlignment = .center + } + underlineLabel.do { + $0.layer.borderColor = UIColor.grayscale300.cgColor + $0.layer.borderWidth = 1 + } + } + + override func setUI() { + addSubviews( + journeyStackView, + underlineLabel + ) + journeyStackView.addArrangedSubviews( + journeyImageView, + journeyNameLabel + ) + } + + override func setLayout() { + journeyStackView.snp.makeConstraints { + $0.top.equalToSuperview() + $0.centerX.equalToSuperview() + $0.width.equalTo(108.adjustedW) + $0.height.equalTo(24.adjustedH) + } + journeyImageView.snp.makeConstraints { + $0.size.equalTo(24.adjustedW) + $0.verticalEdges.equalToSuperview() + $0.leading.equalToSuperview().inset(9.5.adjustedW) + } + journeyNameLabel.snp.makeConstraints { + $0.leading.equalTo(journeyImageView.snp.trailing).offset(2.adjustedW) + $0.centerY.equalToSuperview() + $0.trailing.equalToSuperview().inset(11.5.adjustedW) + } + underlineLabel.snp.makeConstraints { + $0.top.equalTo(journeyStackView.snp.bottom).offset(4.adjustedH) + $0.horizontalEdges.equalToSuperview() + $0.height.equalTo(1.adjustedH) + $0.bottom.equalToSuperview() + } + } +} + +extension TopTabBarItemView { + + func updateBarItem(for tag: Int) { + let condition = (self.tag == tag) + + journeyImageView.layer.opacity = condition ? 1 : 0.44 + journeyNameLabel.textColor = condition ? .grayscale100 : .grayscale600 + underlineLabel.layer.borderColor = condition ? UIColor.grayscale300.cgColor : UIColor.clear.cgColor + underlineLabel.layer.borderWidth = condition ? 1 : 0 + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/ParentQuestViewController.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/ParentQuestViewController.swift new file mode 100644 index 00000000..cdf32179 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/ParentQuestViewController.swift @@ -0,0 +1,94 @@ +// +// ParentQuestViewController.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/14/26. +// + +import UIKit + +final class ParentQuestViewController: BaseViewController { + + private let tabBar: TopTabBar + private let containerView = UIView() + private let controllers: [UIViewController] + private var currentViewController: UIViewController? + + init(items: T.AllCases) { + self.tabBar = TopTabBar(items: Array(items)) + self.controllers = items.map { $0.viewController } + super.init(nibName: nil, bundle: nil) + } + + required init?(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + + override func viewDidLoad() { + super.viewDidLoad() + + setLayout() + bind() + + if let controller = controllers.first { + show(controller) + } + } + + override func setView() { + view.addSubviews( + tabBar, + containerView + ) + } +} + +extension ParentQuestViewController { + + private func setLayout() { + tabBar.snp.makeConstraints { + $0.top.equalTo(view.safeAreaLayoutGuide.snp.top).offset(20.adjustedH) + $0.centerX.equalToSuperview() + $0.width.equalTo(228.adjustedW) + $0.height.equalTo(28.adjustedH) + } + containerView.snp.makeConstraints { + $0.top.equalTo(tabBar.snp.bottom).offset(16.adjustedH) + $0.horizontalEdges.equalToSuperview() + $0.bottom.equalToSuperview() + } + } + + private func bind() { + tabBar.didTap = { [weak self] index in + guard let self, + index >= 0 && index < controllers.count + else { + return + } + show(controllers[index]) + } + } + + private func show(_ target: UIViewController) { + guard currentViewController != target else { return } + + if let currentViewController { + currentViewController.do { + $0.willMove(toParent: nil) + $0.view.removeFromSuperview() + $0.removeFromParent() + } + } + + addChild(target) + containerView.addSubview(target.view) + target.view.snp.makeConstraints { + $0.verticalEdges.equalToSuperview() + $0.horizontalEdges.equalToSuperview() + } + + target.didMove(toParent: self) + currentViewController = target + } +} From 4e1e3b21db816441e8d3f48efc21677f222d8ee5 Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Mon, 16 Feb 2026 14:28:27 +0900 Subject: [PATCH 11/18] =?UTF-8?q?feat:=20#354=20=ED=80=98=EC=8A=A4?= =?UTF-8?q?=ED=8A=B8=20=EC=A1=B0=ED=9A=8C=20=ED=99=94=EB=A9=B4=EC=9A=A9=20?= =?UTF-8?q?=ED=83=AD=20=EC=95=84=EC=9D=B4=ED=85=9C=20=EA=B5=AC=ED=98=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Feature/Quest/Common/QuestTabItem.swift | 41 +++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/Common/QuestTabItem.swift diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/Common/QuestTabItem.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/Common/QuestTabItem.swift new file mode 100644 index 00000000..31d1c67c --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/Common/QuestTabItem.swift @@ -0,0 +1,41 @@ +// +// QuestTabItem.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/12/26. +// + +import UIKit + +enum QuestTabItem: TabItem { + + case myJourney + case commonJourney + + var title: String { + switch self { + case .myJourney: + return "나의 여정" + case .commonJourney: + return "공통 여정" + } + } + + var image: UIImage { + switch self { + case .myJourney: + return .myJourney + case .commonJourney: + return .commonJourney + } + } + + var viewController: UIViewController { + switch self { + case .myJourney: + return ViewControllerFactory.shared.makeQuestViewController() + case .commonJourney: + return ViewControllerFactory.shared.makeCommonQuestViewController() + } + } +} From d6d1d6279bcd145487c7adfc670c1196d7195009 Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Mon, 16 Feb 2026 14:28:50 +0900 Subject: [PATCH 12/18] =?UTF-8?q?feat:=20#354=20=EA=B3=B5=ED=86=B5=20?= =?UTF-8?q?=ED=80=98=EC=8A=A4=ED=8A=B8=20=EB=B7=B0=EC=BB=A8=ED=8A=B8?= =?UTF-8?q?=EB=A1=A4=EB=9F=AC=20=EC=83=9D=EC=84=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../CommonQuestViewController.swift | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/CommonQuestViewController.swift diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/CommonQuestViewController.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/CommonQuestViewController.swift new file mode 100644 index 00000000..2fefe288 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/Quest/ViewController/CommonQuestViewController.swift @@ -0,0 +1,19 @@ +// +// CommonQuestViewController.swift +// ByeBoo-iOS +// +// Created by APPLE on 2/12/26. +// + +final class CommonQuestViewController: BaseViewController { + + override func viewWillAppear(_ animated: Bool) { + super.viewWillAppear(animated) + self.navigationController?.setNavigationBarHidden(true, animated: false) + } + + override func viewWillDisappear(_ animated: Bool) { + super.viewWillDisappear(animated) + self.navigationController?.setNavigationBarHidden(false, animated: false) + } +} From df0f8553143d17443a28e4976d340f01b02fe935 Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Mon, 16 Feb 2026 14:29:40 +0900 Subject: [PATCH 13/18] =?UTF-8?q?refactor:=20#354=20=EC=83=88=EB=A1=9C?= =?UTF-8?q?=EC=9A=B4=20=ED=80=98=EC=8A=A4=ED=8A=B8=20=EC=A1=B0=ED=9A=8C=20?= =?UTF-8?q?=EB=B7=B0=EC=BB=A8=ED=8A=B8=EB=A1=A4=EB=9F=AC=EB=A1=9C=20?= =?UTF-8?q?=EC=9D=B4=EB=8F=99=ED=95=98=EB=8A=94=20=EB=A1=9C=EC=A7=81=20?= =?UTF-8?q?=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Presentation/Common/Navigation/ByeBooTabBar.swift | 2 +- .../ByeBoo-iOS/Presentation/ViewControllerFactory.swift | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/Navigation/ByeBooTabBar.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/Navigation/ByeBooTabBar.swift index fc42776c..a18120c4 100644 --- a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/Navigation/ByeBooTabBar.swift +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/Navigation/ByeBooTabBar.swift @@ -22,7 +22,7 @@ final class ByeBooTabBar: UITabBarController { private func setViewController() { let homeViewController = ViewControllerFactory.shared.makeHomeViewController() - let questViewController = ViewControllerFactory.shared.makeQuestViewController() + let questViewController = ViewControllerFactory.shared.makeParentQuestViewController() let myPageViewController = ViewControllerFactory.shared.makeMyPageViewController() self.viewControllers = [ diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/ViewControllerFactory.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/ViewControllerFactory.swift index 287556ae..2b1e6d38 100644 --- a/ByeBoo-iOS/ByeBoo-iOS/Presentation/ViewControllerFactory.swift +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/ViewControllerFactory.swift @@ -189,6 +189,14 @@ final class ViewControllerFactory: ViewControllerFactoryProtocol { } return CompletedQuestsViewController(viewModel: viewModel) } + + func makeParentQuestViewController() -> ParentQuestViewController { + return ParentQuestViewController(items: QuestTabItem.allCases) + } + + func makeCommonQuestViewController() -> CommonQuestViewController { + return .init() + } } extension ViewControllerFactory { From af5cbcebd529e05bef943b6f3b7771997b611a52 Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Mon, 16 Feb 2026 14:30:06 +0900 Subject: [PATCH 14/18] =?UTF-8?q?style:=20#354=20=ED=80=98=EC=8A=A4?= =?UTF-8?q?=ED=8A=B8=20=EC=83=81=EB=8B=A8=20=ED=83=AD=EB=B0=94=EC=97=90=20?= =?UTF-8?q?=ED=95=84=EC=9A=94=ED=95=9C=20=EC=9D=B4=EB=AF=B8=EC=A7=80=20?= =?UTF-8?q?=EC=84=B8=ED=8C=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Assets.xcassets/TabBar/Contents.json | 6 ++++++ .../common_journey.imageset/Contents.json | 21 +++++++++++++++++++ .../common_journey_sharp.svg | 8 +++++++ .../TabBar/my_journey.imageset/Contents.json | 21 +++++++++++++++++++ .../my_journey.imageset/my_journey_sharp.svg | 20 ++++++++++++++++++ 5 files changed, 76 insertions(+) create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/Contents.json create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/Contents.json create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/common_journey_sharp.svg create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/Contents.json create mode 100644 ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/my_journey_sharp.svg diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/Contents.json b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/Contents.json new file mode 100644 index 00000000..73c00596 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/Contents.json b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/Contents.json new file mode 100644 index 00000000..63aded90 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "common_journey_sharp.svg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/common_journey_sharp.svg b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/common_journey_sharp.svg new file mode 100644 index 00000000..61f3b35e --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/common_journey.imageset/common_journey_sharp.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/Contents.json b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/Contents.json new file mode 100644 index 00000000..4c09197b --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "my_journey_sharp.svg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/my_journey_sharp.svg b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/my_journey_sharp.svg new file mode 100644 index 00000000..9d84a147 --- /dev/null +++ b/ByeBoo-iOS/ByeBoo-iOS/Resource/Assets.xcassets/TabBar/my_journey.imageset/my_journey_sharp.svg @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + + + From 8276d475681d26c4d2890d627befc4f80bcffde1 Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Mon, 16 Feb 2026 14:30:15 +0900 Subject: [PATCH 15/18] =?UTF-8?q?fix:=20#354=20=ED=80=98=EC=8A=A4=ED=8A=B8?= =?UTF-8?q?=20=ED=86=A0=EA=B8=80=20=EC=98=A4=EB=A5=98=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ViewController/MyPageViewController.swift | 30 +++++++++++-------- 1 file changed, 18 insertions(+), 12 deletions(-) diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/MyPage/ViewController/MyPageViewController.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/MyPage/ViewController/MyPageViewController.swift index 60e036db..df69c7e5 100644 --- a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/MyPage/ViewController/MyPageViewController.swift +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Feature/MyPage/ViewController/MyPageViewController.swift @@ -15,9 +15,10 @@ final class MyPageViewController: BaseViewController { private let viewModel: MyPageViewModel private var cancellables = Set() private var name: String? - private var beforeNotificationStatus = false private let rootView = MyPageView() + private lazy var beforeNotificationStatus = rootView.noticeView.noticeSwitch.isOn + private var didOpenSetting = false init(viewModel: MyPageViewModel) { self.viewModel = viewModel @@ -204,25 +205,29 @@ extension MyPageViewController { @objc private func checkNoticeAuthorizationWhenBack() { + guard didOpenSetting else { return } + UNUserNotificationCenter.current().getNotificationSettings { [weak self] settings in guard let self else { return } + let isAuthorized: Bool switch settings.authorizationStatus { case .authorized, .provisional, .ephemeral: - if !beforeNotificationStatus { - self.viewModel.action(.notificationSwitchDidTap) - } - beforeNotificationStatus = true + isAuthorized = true default: - if beforeNotificationStatus { - self.viewModel.action(.notificationSwitchDidTap) - } else { - DispatchQueue.main.async { - self.rootView.noticeView.noticeSwitch.setOn(false, animated: false) - } + isAuthorized = false + } + + if beforeNotificationStatus != isAuthorized { + viewModel.action(.notificationSwitchDidTap) + } else if !isAuthorized { + DispatchQueue.main.async { + self.rootView.noticeView.noticeSwitch.setOn(false, animated: false) } - beforeNotificationStatus = false } + + beforeNotificationStatus = isAuthorized + didOpenSetting = false } } @@ -425,6 +430,7 @@ extension MyPageViewController { private func moveSetting() { if let url = URL(string: UIApplication.openSettingsURLString) { UIApplication.shared.open(url) + didOpenSetting = true } } } From c37cee6cb5f80ef22726cb88494fbb6ae9d4cc20 Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Mon, 16 Feb 2026 14:37:42 +0900 Subject: [PATCH 16/18] =?UTF-8?q?setting:=20#354=20entitlements=20?= =?UTF-8?q?=EC=84=A4=EC=A0=95=20=EB=B3=B5=EA=B5=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj b/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj index f9e92e02..d7a3f226 100644 --- a/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj +++ b/ByeBoo-iOS/ByeBoo-iOS.xcodeproj/project.pbxproj @@ -274,7 +274,7 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-iOS.entitlements"; + CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-Dev.entitlements"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 6; @@ -316,7 +316,7 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-iOS.entitlements"; + CODE_SIGN_ENTITLEMENTS = "ByeBoo-iOS/ByeBoo-Prod.entitlements"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 6; From 1af4c50f74d6d810bc3b1a0cd295542eca5ded0c Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Mon, 16 Feb 2026 14:48:42 +0900 Subject: [PATCH 17/18] =?UTF-8?q?refactor:=20#354=20=EB=B3=80=EC=88=98?= =?UTF-8?q?=EB=AA=85=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Common/TopTabBar/TopTabBarItemView.swift | 36 +++++++++---------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBarItemView.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBarItemView.swift index fb76cebd..c9417ab1 100644 --- a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBarItemView.swift +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBarItemView.swift @@ -9,14 +9,14 @@ import UIKit final class TopTabBarItemView: BaseView { - private let journeyStackView = UIStackView() - private let journeyImageView = UIImageView() - private let journeyNameLabel = UILabel() + private let tabStackView = UIStackView() + private let tabImageView = UIImageView() + private let tabNameLabel = UILabel() private let underlineLabel = UILabel() init(item: any TabItem) { - journeyImageView.image = item.image - journeyNameLabel.text = item.title + tabImageView.image = item.image + tabNameLabel.text = item.title super.init(frame: .zero) } @@ -26,12 +26,12 @@ final class TopTabBarItemView: BaseView { } override func setStyle() { - journeyStackView.do { + tabStackView.do { $0.axis = .horizontal $0.spacing = 2 $0.alignment = .center } - journeyNameLabel.do { + tabNameLabel.do { $0.textColor = .grayscale100 $0.font = FontManager.body2M16.font $0.textAlignment = .center @@ -44,34 +44,34 @@ final class TopTabBarItemView: BaseView { override func setUI() { addSubviews( - journeyStackView, + tabStackView, underlineLabel ) - journeyStackView.addArrangedSubviews( - journeyImageView, - journeyNameLabel + tabStackView.addArrangedSubviews( + tabImageView, + tabNameLabel ) } override func setLayout() { - journeyStackView.snp.makeConstraints { + tabStackView.snp.makeConstraints { $0.top.equalToSuperview() $0.centerX.equalToSuperview() $0.width.equalTo(108.adjustedW) $0.height.equalTo(24.adjustedH) } - journeyImageView.snp.makeConstraints { + tabImageView.snp.makeConstraints { $0.size.equalTo(24.adjustedW) $0.verticalEdges.equalToSuperview() $0.leading.equalToSuperview().inset(9.5.adjustedW) } - journeyNameLabel.snp.makeConstraints { - $0.leading.equalTo(journeyImageView.snp.trailing).offset(2.adjustedW) + tabNameLabel.snp.makeConstraints { + $0.leading.equalTo(tabImageView.snp.trailing).offset(2.adjustedW) $0.centerY.equalToSuperview() $0.trailing.equalToSuperview().inset(11.5.adjustedW) } underlineLabel.snp.makeConstraints { - $0.top.equalTo(journeyStackView.snp.bottom).offset(4.adjustedH) + $0.top.equalTo(tabStackView.snp.bottom).offset(4.adjustedH) $0.horizontalEdges.equalToSuperview() $0.height.equalTo(1.adjustedH) $0.bottom.equalToSuperview() @@ -84,8 +84,8 @@ extension TopTabBarItemView { func updateBarItem(for tag: Int) { let condition = (self.tag == tag) - journeyImageView.layer.opacity = condition ? 1 : 0.44 - journeyNameLabel.textColor = condition ? .grayscale100 : .grayscale600 + tabImageView.layer.opacity = condition ? 1 : 0.44 + tabNameLabel.textColor = condition ? .grayscale100 : .grayscale600 underlineLabel.layer.borderColor = condition ? UIColor.grayscale300.cgColor : UIColor.clear.cgColor underlineLabel.layer.borderWidth = condition ? 1 : 0 } From 8aab424da3571fd2d499830f830ccebbd54a2ee9 Mon Sep 17 00:00:00 2001 From: heoseungjun Date: Wed, 18 Feb 2026 08:57:18 +0900 Subject: [PATCH 18/18] =?UTF-8?q?refactor:=20#354=20=EB=A9=94=EC=84=9C?= =?UTF-8?q?=EB=93=9C=EB=AA=85=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit barTapped -> barDidTap --- .../ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBar.swift | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBar.swift b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBar.swift index 494b3b24..c5f696a2 100644 --- a/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBar.swift +++ b/ByeBoo-iOS/ByeBoo-iOS/Presentation/Common/TopTabBar/TopTabBar.swift @@ -41,7 +41,7 @@ final class TopTabBar: UIStackView { private func setAction() { itemViews.enumerated().forEach { index, itemView in let tapGesture = UITapGestureRecognizer( - target: self, action: #selector(barTapped(_:)) + target: self, action: #selector(barDidTap(_:)) ) itemView.addGestureRecognizer(tapGesture) itemView.tag = index @@ -56,7 +56,7 @@ final class TopTabBar: UIStackView { extension TopTabBar { @objc - private func barTapped(_ sender: UITapGestureRecognizer) { + private func barDidTap(_ sender: UITapGestureRecognizer) { guard let tag = sender.view?.tag else { return }