diff --git a/ReaderHive.xcodeproj/project.pbxproj b/ReaderHive.xcodeproj/project.pbxproj index 377bc9d..cabe89d 100644 --- a/ReaderHive.xcodeproj/project.pbxproj +++ b/ReaderHive.xcodeproj/project.pbxproj @@ -102,6 +102,15 @@ 85CF94372EEFE27E006467E3 /* FacebookLogin in Frameworks */ = {isa = PBXBuildFile; productRef = 85CF94362EEFE27E006467E3 /* FacebookLogin */; }; 85CF94392EEFE35A006467E3 /* NRLoginManager+Facebook.swift in Sources */ = {isa = PBXBuildFile; fileRef = 85CF94382EEFE34F006467E3 /* NRLoginManager+Facebook.swift */; }; 85CF943B2EEFE94C006467E3 /* AppDelegate+Open.swift in Sources */ = {isa = PBXBuildFile; fileRef = 85CF943A2EEFE947006467E3 /* AppDelegate+Open.swift */; }; + 85CF943D2EEFEC14006467E3 /* NRSettingViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 85CF943C2EEFEC14006467E3 /* NRSettingViewController.swift */; }; + 85CF943F2EEFF1B2006467E3 /* NRSettingCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 85CF943E2EEFF1B2006467E3 /* NRSettingCell.swift */; }; + 85CF94412EEFF62E006467E3 /* NRSettingFooterView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 85CF94402EEFF62E006467E3 /* NRSettingFooterView.swift */; }; + 85CF94462EF001AD006467E3 /* NRMyUnlocksViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 85CF94452EF001AD006467E3 /* NRMyUnlocksViewController.xib */; }; + 85CF94472EF001AD006467E3 /* NRMyUnlocksViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 85CF94442EF001AD006467E3 /* NRMyUnlocksViewController.swift */; }; + 85CF944A2EF004D3006467E3 /* NRMyUnlocksCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = 85CF94492EF004D3006467E3 /* NRMyUnlocksCell.xib */; }; + 85CF944B2EF004D3006467E3 /* NRMyUnlocksCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 85CF94482EF004D3006467E3 /* NRMyUnlocksCell.swift */; }; + 85CF944D2EF0EC00006467E3 /* NRVersionUpdateModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 85CF944C2EF0EC00006467E3 /* NRVersionUpdateModel.swift */; }; + 85CF944F2EF0F04D006467E3 /* NRUpdatesAlert.swift in Sources */ = {isa = PBXBuildFile; fileRef = 85CF944E2EF0F04D006467E3 /* NRUpdatesAlert.swift */; }; F34348AF2ED5B85300AA7E70 /* NRExploreViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = F34348AE2ED5B85300AA7E70 /* NRExploreViewController.swift */; }; F34348B12ED5B9A400AA7E70 /* NRExploreNovelViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = F34348B02ED5B9A400AA7E70 /* NRExploreNovelViewController.swift */; }; F34348B32ED5BB6100AA7E70 /* NRExploreNovelMenuView.swift in Sources */ = {isa = PBXBuildFile; fileRef = F34348B22ED5BB6100AA7E70 /* NRExploreNovelMenuView.swift */; }; @@ -339,6 +348,15 @@ 85CF94342EEFDFAC006467E3 /* ReaderHive.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = ReaderHive.entitlements; sourceTree = ""; }; 85CF94382EEFE34F006467E3 /* NRLoginManager+Facebook.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "NRLoginManager+Facebook.swift"; sourceTree = ""; }; 85CF943A2EEFE947006467E3 /* AppDelegate+Open.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "AppDelegate+Open.swift"; sourceTree = ""; }; + 85CF943C2EEFEC14006467E3 /* NRSettingViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NRSettingViewController.swift; sourceTree = ""; }; + 85CF943E2EEFF1B2006467E3 /* NRSettingCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NRSettingCell.swift; sourceTree = ""; }; + 85CF94402EEFF62E006467E3 /* NRSettingFooterView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NRSettingFooterView.swift; sourceTree = ""; }; + 85CF94442EF001AD006467E3 /* NRMyUnlocksViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NRMyUnlocksViewController.swift; sourceTree = ""; }; + 85CF94452EF001AD006467E3 /* NRMyUnlocksViewController.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = NRMyUnlocksViewController.xib; sourceTree = ""; }; + 85CF94482EF004D3006467E3 /* NRMyUnlocksCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NRMyUnlocksCell.swift; sourceTree = ""; }; + 85CF94492EF004D3006467E3 /* NRMyUnlocksCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = NRMyUnlocksCell.xib; sourceTree = ""; }; + 85CF944C2EF0EC00006467E3 /* NRVersionUpdateModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NRVersionUpdateModel.swift; sourceTree = ""; }; + 85CF944E2EF0F04D006467E3 /* NRUpdatesAlert.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NRUpdatesAlert.swift; sourceTree = ""; }; C3BEE224CB3F55939653D26D /* Pods-NovelReader.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-NovelReader.debug.xcconfig"; path = "Target Support Files/Pods-NovelReader/Pods-NovelReader.debug.xcconfig"; sourceTree = ""; }; F34348AE2ED5B85300AA7E70 /* NRExploreViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NRExploreViewController.swift; sourceTree = ""; }; F34348B02ED5B9A400AA7E70 /* NRExploreNovelViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NRExploreNovelViewController.swift; sourceTree = ""; }; @@ -1028,6 +1046,7 @@ children = ( F34991042EE165EA0039E939 /* NRMeItem.swift */, F3B8593B2EE677170095A9CC /* NRLanguageModel.swift */, + 85CF944C2EF0EC00006467E3 /* NRVersionUpdateModel.swift */, ); path = M; sourceTree = ""; @@ -1046,6 +1065,8 @@ F34991172EE1780A0039E939 /* NRNovelHistoryCell.swift */, F3B859382EE676610095A9CC /* NRLanguageCell.swift */, 85CF942E2EEFB2CF006467E3 /* NRLoginView.swift */, + 85CF943E2EEFF1B2006467E3 /* NRSettingCell.swift */, + 85CF94402EEFF62E006467E3 /* NRSettingFooterView.swift */, ); path = V; sourceTree = ""; @@ -1059,6 +1080,11 @@ F34991152EE176640039E939 /* NRNovelHistoryViewController.swift */, F3B859362EE6750B0095A9CC /* NRLanguageViewController.swift */, F3B859702EE94A1B0095A9CC /* NRFeedbackViewController.swift */, + 85CF943C2EEFEC14006467E3 /* NRSettingViewController.swift */, + 85CF94442EF001AD006467E3 /* NRMyUnlocksViewController.swift */, + 85CF94452EF001AD006467E3 /* NRMyUnlocksViewController.xib */, + 85CF94482EF004D3006467E3 /* NRMyUnlocksCell.swift */, + 85CF94492EF004D3006467E3 /* NRMyUnlocksCell.xib */, ); path = VC; sourceTree = ""; @@ -1086,6 +1112,7 @@ isa = PBXGroup; children = ( F34991222EE26EAC0039E939 /* NRAlert.swift */, + 85CF944E2EF0F04D006467E3 /* NRUpdatesAlert.swift */, F349911E2EE26C350039E939 /* NRAlertWindowManager.swift */, F34991202EE26C660039E939 /* NRBaseAlert.swift */, ); @@ -1259,10 +1286,12 @@ isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( + 85CF94462EF001AD006467E3 /* NRMyUnlocksViewController.xib in Resources */, 03980F8A2ED009EB0006E317 /* Assets.xcassets in Resources */, 039810732ED053BE0006E317 /* Localizable.strings in Resources */, F3B859872EE972F70095A9CC /* NRConsumptionRecordsCell.xib in Resources */, 03980F8C2ED009EB0006E317 /* LaunchScreen.storyboard in Resources */, + 85CF944A2EF004D3006467E3 /* NRMyUnlocksCell.xib in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -1331,6 +1360,7 @@ F34348FF2ED85BF200AA7E70 /* NRReadBatteryView.swift in Sources */, F3B8593C2EE677170095A9CC /* NRLanguageModel.swift in Sources */, 039810BA2ED4377E0006E317 /* NRHomeNovelReadWhatCell.swift in Sources */, + 85CF94472EF001AD006467E3 /* NRMyUnlocksViewController.swift in Sources */, F3B8596B2EE91C9F0095A9CC /* NRStoreCoinsCell.swift in Sources */, F3B859712EE94A1B0095A9CC /* NRFeedbackViewController.swift in Sources */, 85CF94392EEFE35A006467E3 /* NRLoginManager+Facebook.swift in Sources */, @@ -1351,6 +1381,7 @@ 85CF942B2EED47F2006467E3 /* NRVipRetainItemView.swift in Sources */, 0398107C2ED055260006E317 /* AppDelegate+Config.swift in Sources */, F34348B52ED5C6F800AA7E70 /* NRTableView.swift in Sources */, + 85CF944B2EF004D3006467E3 /* NRMyUnlocksCell.swift in Sources */, F34348DB2ED6F80A00AA7E70 /* NRNovelReaderViewController.swift in Sources */, F34990B92EDEB1620039E939 /* NRHomeNovelModuleItem.swift in Sources */, F34349032ED943C300AA7E70 /* NRReadParser.swift in Sources */, @@ -1408,6 +1439,7 @@ 85CF94252EEC09AE006467E3 /* NRCoinsPackClaimCell.swift in Sources */, 0373D94D2ED583A80017DCC7 /* NRNovelModel.swift in Sources */, F34348AF2ED5B85300AA7E70 /* NRExploreViewController.swift in Sources */, + 85CF944D2EF0EC00006467E3 /* NRVersionUpdateModel.swift in Sources */, F3B859732EE94A760095A9CC /* NRAppWebViewController.swift in Sources */, 0373D9602ED59DA10017DCC7 /* NRSearchResultCell.swift in Sources */, 039810952ED066710006E317 /* UIScreen+NRAdd.swift in Sources */, @@ -1436,6 +1468,7 @@ 0398106D2ED053000006E317 /* NRDefine.swift in Sources */, F34349282EDD815D00AA7E70 /* NRNovelCatalogCell.swift in Sources */, 039810D22ED54F190006E317 /* NRHomeNovelListTextCell.swift in Sources */, + 85CF943D2EEFEC14006467E3 /* NRSettingViewController.swift in Sources */, F343492C2EDE72F300AA7E70 /* NRHomeAPI.swift in Sources */, F3B859372EE6750B0095A9CC /* NRLanguageViewController.swift in Sources */, F34348E12ED70A2700AA7E70 /* NRNovelDetailHeaderView+NovelCoverInfo.swift in Sources */, @@ -1496,6 +1529,7 @@ F34991092EE169C60039E939 /* NRAboutHeaderView.swift in Sources */, 039810AE2ED3F3400006E317 /* NRHomeNovelMustReadTodayView.swift in Sources */, F34348E92ED7FA9100AA7E70 /* NRNovelDetailRecommandViewController.swift in Sources */, + 85CF944F2EF0F04D006467E3 /* NRUpdatesAlert.swift in Sources */, 0373D95C2ED598890017DCC7 /* UIStackView+NRAdd.swift in Sources */, 0398107A2ED054E40006E317 /* NRToast.swift in Sources */, 039810A82ED3E7DB0006E317 /* NRHomeNovelListCell.swift in Sources */, @@ -1505,6 +1539,7 @@ F34991182EE1780A0039E939 /* NRNovelHistoryCell.swift in Sources */, F34990F12EE00F5A0039E939 /* NRKeyedArchiver.swift in Sources */, F34349162EDA9FC700AA7E70 /* NRReadSettingBrightnessView.swift in Sources */, + 85CF943F2EEFF1B2006467E3 /* NRSettingCell.swift in Sources */, F3B8598D2EEA51FE0095A9CC /* NRRewardCoinsCell.swift in Sources */, F34990F52EE0346B0039E939 /* NRNovelReadBaseViewController.swift in Sources */, 039810642ED04F480006E317 /* NRTargetType.swift in Sources */, @@ -1537,6 +1572,7 @@ F34348D72ED6E7C600AA7E70 /* NRMyListNovelCell.swift in Sources */, F34349052ED9442300AA7E70 /* NRReadPageModel.swift in Sources */, F34990F92EE118FC0039E939 /* NRNovelReadFinishHeaderView.swift in Sources */, + 85CF94412EEFF62E006467E3 /* NRSettingFooterView.swift in Sources */, F3B8596F2EE9456E0095A9CC /* NRStoreVipCell.swift in Sources */, F34990C52EDFCD4A0039E939 /* NRMeViewController.swift in Sources */, F349911C2EE190590039E939 /* NRNovelDetailCatalogViewController.swift in Sources */, diff --git a/ReaderHive/Base/Define/NRUserDefaultsKey.swift b/ReaderHive/Base/Define/NRUserDefaultsKey.swift index 66cbc14..f2239e0 100644 --- a/ReaderHive/Base/Define/NRUserDefaultsKey.swift +++ b/ReaderHive/Base/Define/NRUserDefaultsKey.swift @@ -13,3 +13,5 @@ let kNRUserInfoDefaultsKey = "kNRUserInfoDefaultsKey" let kNRNovelReadSetDefaultsKey = "kNRNovelReadSetDefaultsKey" let kNRWaitRestoreIAPDefaultsKey = "kNRWaitRestoreIAPDefaultsKey" + +let kNRVersionUpdateAlertDefaultsKey = "kNRVersionUpdateAlertDefaultsKey" diff --git a/ReaderHive/Base/Networking/API/NRSettingAPI.swift b/ReaderHive/Base/Networking/API/NRSettingAPI.swift index 551efc2..7e893cf 100644 --- a/ReaderHive/Base/Networking/API/NRSettingAPI.swift +++ b/ReaderHive/Base/Networking/API/NRSettingAPI.swift @@ -44,4 +44,21 @@ struct NRSettingAPI { } } + static func requestVersionUpdateData() async -> NRVersionUpdateModel? { + + await withCheckedContinuation { continuation in + var param = NRNetwork.Parameters(path: "/customer/versionControl") + param.method = .get + param.isToast = false + + NRNetwork.request(parameters: param) { (response: NRNetwork.Response) in + if response.isSuccess { + continuation.resume(returning: response.data) + } else { + continuation.resume(returning: nil) + } + } + } + } + } diff --git a/ReaderHive/Base/VC/NRTabBarController.swift b/ReaderHive/Base/VC/NRTabBarController.swift index 7466f7e..12db17f 100644 --- a/ReaderHive/Base/VC/NRTabBarController.swift +++ b/ReaderHive/Base/VC/NRTabBarController.swift @@ -38,6 +38,8 @@ class NRTabBarController: UITabBarController { self.tabBar.isTranslucent = false self.selectedIndex = 1 + + NRTool.checkUpdates() } diff --git a/ReaderHive/Base/View/NRTableView.swift b/ReaderHive/Base/View/NRTableView.swift index 7efcd17..6a02165 100644 --- a/ReaderHive/Base/View/NRTableView.swift +++ b/ReaderHive/Base/View/NRTableView.swift @@ -17,6 +17,15 @@ class NRTableView: UITableView, UIGestureRecognizerDelegate { override init(frame: CGRect, style: UITableView.Style) { super.init(frame: frame, style: style) + _init() + } + + required init?(coder: NSCoder) { + super.init(coder: coder) + _init() + } + + private func _init() { separatorInset = .init(top: 0, left: 16, bottom: 0, right: 16) self.backgroundColor = .clear self.contentInsetAdjustmentBehavior = .never @@ -31,10 +40,6 @@ class NRTableView: UITableView, UIGestureRecognizerDelegate { } } - required init?(coder: NSCoder) { - fatalError("init(coder:) has not been implemented") - } - override var layoutMargins: UIEdgeInsets { set { super.layoutMargins = newValue diff --git a/ReaderHive/Base/WebView/NRAppWebViewController.swift b/ReaderHive/Base/WebView/NRAppWebViewController.swift index 4714865..49d14ad 100644 --- a/ReaderHive/Base/WebView/NRAppWebViewController.swift +++ b/ReaderHive/Base/WebView/NRAppWebViewController.swift @@ -34,7 +34,10 @@ class NRAppWebViewController: NRWebViewController { override func nr_webViewDidFinishLoad(_ webView: NRWebView) { super.nr_webViewDidFinishLoad(webView) receiveDataCount = 0 - receiveDataFromNative() + DispatchQueue.main.asyncAfter(deadline: .now() + 0.5) { [weak self] in + guard let self = self else { return } + self.receiveDataFromNative() + } } } @@ -45,7 +48,6 @@ extension NRAppWebViewController { receiveDataCount += 1 if receiveDataCount > 10 { return } - var dic = [ "token" : NRLoginManager.manager.token?.token ?? "", "time_zone" : NRTargetType.timeZone(), diff --git a/ReaderHive/Class/Me/M/NRMeItem.swift b/ReaderHive/Class/Me/M/NRMeItem.swift index 73a6446..e2f43ef 100644 --- a/ReaderHive/Class/Me/M/NRMeItem.swift +++ b/ReaderHive/Class/Me/M/NRMeItem.swift @@ -16,9 +16,12 @@ struct NRMeItem { case settings case web case feedback + case wallet case consumptionRecords case purchaseRecords case rewardCoins + case accountDeletion + case myUnlocks } var type: ItemType diff --git a/ReaderHive/Class/Me/M/NRVersionUpdateModel.swift b/ReaderHive/Class/Me/M/NRVersionUpdateModel.swift new file mode 100644 index 0000000..49fe110 --- /dev/null +++ b/ReaderHive/Class/Me/M/NRVersionUpdateModel.swift @@ -0,0 +1,39 @@ +// +// NRVersionUpdateModel.swift +// ReaderHive +// +// Created by 澜声世纪 on 2025/12/16. +// + +import UIKit +import SmartCodable + +class NRVersionUpdateModel: NSObject, SmartCodable { + + required override init() { } + + var des: String? + var version_name: String? + var version_code: String? + + var force: Bool? + + + func canUpdate() -> Bool { + guard let version = version_code else { return false } + + let result = kNRAPPVersion.compare(version, options: .numeric) + if result == .orderedAscending { + return true + } else { + return false + } + } + + + static func mappingForKey() -> [SmartKeyTransformer]? { + return [ + CodingKeys.des <--- ["description"] + ] + } +} diff --git a/ReaderHive/Class/Me/V/NRAboutCell.swift b/ReaderHive/Class/Me/V/NRAboutCell.swift index 8071753..88a029c 100644 --- a/ReaderHive/Class/Me/V/NRAboutCell.swift +++ b/ReaderHive/Class/Me/V/NRAboutCell.swift @@ -23,6 +23,13 @@ class NRAboutCell: NRTableViewCell { return label }() + private lazy var lineView: NRDashedLineView = { + let view = NRDashedLineView() + view.direction = .horizontal + view.lineColor = UIColor.black.withAlphaComponent(0.15) + return view + }() + override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) { super.init(style: style, reuseIdentifier: reuseIdentifier) @@ -30,15 +37,22 @@ class NRAboutCell: NRTableViewCell { contentView.addSubview(titleLabel) contentView.addSubview(nr_indicatorImageView) + contentView.addSubview(lineView) titleLabel.snp.makeConstraints { make in make.centerY.equalToSuperview() - make.left.equalToSuperview().offset(16) + make.left.equalToSuperview().offset(28) } nr_indicatorImageView.snp.makeConstraints { make in make.centerY.equalToSuperview() - make.right.equalToSuperview().offset(-16) + make.right.equalToSuperview().offset(-28) + } + + lineView.snp.makeConstraints { make in + make.left.equalToSuperview().offset(28) + make.centerX.equalToSuperview() + make.bottom.equalToSuperview() } } diff --git a/ReaderHive/Class/Me/V/NRSettingCell.swift b/ReaderHive/Class/Me/V/NRSettingCell.swift new file mode 100644 index 0000000..509913e --- /dev/null +++ b/ReaderHive/Class/Me/V/NRSettingCell.swift @@ -0,0 +1,60 @@ +// +// NRSettingCell.swift +// ReaderHive +// +// Created by 澜声世纪 on 2025/12/15. +// + +import UIKit +import SnapKit + +class NRSettingCell: UICollectionViewCell { + + var model: NRMeItem? { + didSet { + titleLabel.text = model?.title + } + } + + private lazy var titleLabel: UILabel = { + let label = UILabel() + label.font = .font(ofSize: 14, weight: .medium) + label.textColor = .black + return label + }() + + private lazy var indicatorImageView = UIImageView(image: UIImage(named: "arrow_right_icon_06")) + + override init(frame: CGRect) { + super.init(frame: frame) + contentView.backgroundColor = .F_2_EFEE + contentView.layer.cornerRadius = 8 + contentView.layer.masksToBounds = true + + nr_setupUI() + } + + required init?(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + +} + +extension NRSettingCell { + + private func nr_setupUI() { + contentView.addSubview(titleLabel) + contentView.addSubview(indicatorImageView) + + titleLabel.snp.makeConstraints { make in + make.centerY.equalToSuperview() + make.left.equalToSuperview().offset(12) + } + + indicatorImageView.snp.makeConstraints { make in + make.centerY.equalToSuperview() + make.right.equalToSuperview().offset(-12) + } + } + +} diff --git a/ReaderHive/Class/Me/V/NRSettingFooterView.swift b/ReaderHive/Class/Me/V/NRSettingFooterView.swift new file mode 100644 index 0000000..1e80bc1 --- /dev/null +++ b/ReaderHive/Class/Me/V/NRSettingFooterView.swift @@ -0,0 +1,77 @@ +// +// NRSettingFooterView.swift +// ReaderHive +// +// Created by 澜声世纪 on 2025/12/15. +// + +import UIKit +import SnapKit +import HWPanModal + +class NRSettingFooterView: UICollectionReusableView { + + var userInfo: NRUserInfo? { + didSet { + loginButton.setNeedsUpdateConfiguration() + } + } + + private lazy var loginButton: UIButton = { + var configuration = UIButton.Configuration.plain() + configuration.background.image = UIImage(named: "gradient_color_01") + configuration.background.cornerRadius = 24 + + let button = UIButton(configuration: configuration, primaryAction: UIAction(handler: { [weak self] _ in + guard let self = self else { return } + self.loginButtonHandle() + })) + button.configurationUpdateHandler = { [weak self] button in + guard let self = self else { return } + var title = "Login".localized + if userInfo?.is_tourist == false { + title = "Log Out".localized + } + button.configuration?.attributedTitle = AttributedString(title, attributes: AttributeContainer([ + .font : UIFont.font(ofSize: 14, weight: .medium), + .foregroundColor : UIColor.white + ])) + } + return button + }() + + override init(frame: CGRect) { + super.init(frame: frame) + + addSubview(loginButton) + + loginButton.snp.makeConstraints { make in + make.left.equalToSuperview().offset(16) + make.centerX.equalToSuperview() + make.bottom.equalToSuperview() + make.height.equalTo(48) + } + } + + required init?(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + + private func loginButtonHandle() { + guard let userInfo = userInfo else { return } + + if userInfo.is_tourist == false { + let alert = NRAlert(title: "Log Out".localized, detail: "logout_alert_text".localized, topIconImage: UIImage(named: "alert_top_icon_02"), highlightButtonText: "Confirm".localized) + alert.highlightHandle = { + NRLoginManager.manager.logout(completer: nil) + } + alert.show() + + } else { + let view = NRLoginView() + view.present(in: nil) + } + + } + +} diff --git a/ReaderHive/Class/Me/VC/NRMeViewController.swift b/ReaderHive/Class/Me/VC/NRMeViewController.swift index bcf9c7e..f562813 100644 --- a/ReaderHive/Class/Me/VC/NRMeViewController.swift +++ b/ReaderHive/Class/Me/VC/NRMeViewController.swift @@ -13,9 +13,11 @@ class NRMeViewController: NRViewController { private lazy var dataArr: [NRMeItem] = { let arr = [ NRMeItem(type: .history, icon: UIImage(named: "history_icon_01"), title: "History".localized), + NRMeItem(type: .wallet, icon: UIImage(named: "wallet_icon_01"), title: "My Wallet".localized), // NRMeItem(type: .language, icon: UIImage(named: "language_icon_01"), title: "Language".localized), + NRMeItem(type: .feedback, icon: UIImage(named: "feedback_icon_01"), title: "Feedback".localized), + NRMeItem(type: .settings, icon: UIImage(named: "settings_icon_02"), title: "Settings".localized), NRMeItem(type: .about, icon: UIImage(named: "about_icon_01"), title: "About".localized), - NRMeItem(type: .feedback, icon: UIImage(named: "feedback_icon_01"), title: "Feedback".localized) ] return arr }() @@ -115,6 +117,14 @@ extension NRMeViewController: UITableViewDelegate, UITableViewDataSource { let vc = NRFeedbackViewController() self.navigationController?.pushViewController(vc, animated: true) + case .wallet: + let vc = NRWalletViewController() + self.navigationController?.pushViewController(vc, animated: true) + + case .settings: + let vc = NRSettingViewController() + self.navigationController?.pushViewController(vc, animated: true) + default: break } diff --git a/ReaderHive/Class/Me/VC/NRMyUnlocksCell.swift b/ReaderHive/Class/Me/VC/NRMyUnlocksCell.swift new file mode 100644 index 0000000..fc50026 --- /dev/null +++ b/ReaderHive/Class/Me/VC/NRMyUnlocksCell.swift @@ -0,0 +1,40 @@ +// +// NRMyUnlocksCell.swift +// ReaderHive +// +// Created by 澜声世纪 on 2025/12/15. +// + +import UIKit + +class NRMyUnlocksCell: NRTableViewCell { + + + @IBOutlet weak var bgView: UIView! + + @IBOutlet weak var coverImageView: NRImageView! + + @IBOutlet weak var titleLabel: UILabel! + + @IBOutlet weak var chLabel: UILabel! + + @IBOutlet weak var countLabel: UILabel! + + @IBOutlet weak var countTextLabel: UILabel! + + override func awakeFromNib() { + super.awakeFromNib() + + bgView.layer.borderColor = UIColor.F_2_EFEE.cgColor + + countTextLabel.text = "Unlocked Chapters".localized + + } + + override func setSelected(_ selected: Bool, animated: Bool) { + super.setSelected(selected, animated: animated) + + // Configure the view for the selected state + } + +} diff --git a/ReaderHive/Class/Me/VC/NRMyUnlocksCell.xib b/ReaderHive/Class/Me/VC/NRMyUnlocksCell.xib new file mode 100644 index 0000000..23a83eb --- /dev/null +++ b/ReaderHive/Class/Me/VC/NRMyUnlocksCell.xib @@ -0,0 +1,125 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/ReaderHive/Class/Me/VC/NRMyUnlocksViewController.swift b/ReaderHive/Class/Me/VC/NRMyUnlocksViewController.swift new file mode 100644 index 0000000..011352f --- /dev/null +++ b/ReaderHive/Class/Me/VC/NRMyUnlocksViewController.swift @@ -0,0 +1,50 @@ +// +// NRMyUnlocksViewController.swift +// ReaderHive +// +// Created by 澜声世纪 on 2025/12/15. +// + +import UIKit + +class NRMyUnlocksViewController: NRViewController { + + @IBOutlet weak var tableView: NRTableView! + + override func viewDidLoad() { + super.viewDidLoad() + self.title = "My Unlocks".localized + self.backgroundImageView.isHidden = true + configNavigationBack("arrow_left_icon_05") + + tableView.contentInset = .init(top: 24, left: 0, bottom: UIScreen.safeBottom, right: 0) + tableView.register(UINib(nibName: "NRMyUnlocksCell", bundle: nil), forCellReuseIdentifier: "cell") + } + + override func viewWillAppear(_ animated: Bool) { + super.viewWillAppear(animated) + self.navigationController?.setNavigationBarHidden(false, animated: true) + self.nr_setNavigationStyle(titleColor: UINavigationBar.titleBlackColor) + } + +} + +//MARK: UITableViewDelegate UITableViewDataSource +extension NRMyUnlocksViewController: UITableViewDelegate, UITableViewDataSource { + + func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "cell", for: indexPath) as! NRMyUnlocksCell + return cell + } + + func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + return 10 + } + + func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) { + + } + + + +} diff --git a/ReaderHive/Class/Me/VC/NRMyUnlocksViewController.xib b/ReaderHive/Class/Me/VC/NRMyUnlocksViewController.xib new file mode 100644 index 0000000..ef6f957 --- /dev/null +++ b/ReaderHive/Class/Me/VC/NRMyUnlocksViewController.xib @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/ReaderHive/Class/Me/VC/NRSettingViewController.swift b/ReaderHive/Class/Me/VC/NRSettingViewController.swift new file mode 100644 index 0000000..4d9a618 --- /dev/null +++ b/ReaderHive/Class/Me/VC/NRSettingViewController.swift @@ -0,0 +1,131 @@ +// +// NRSettingViewController.swift +// ReaderHive +// +// Created by 澜声世纪 on 2025/12/15. +// + +import UIKit +import SnapKit + +class NRSettingViewController: NRViewController { + + private lazy var dataArr: [NRMeItem] = getDataArr() + + private lazy var collectionViewLayout: UICollectionViewFlowLayout = { + let layout = UICollectionViewFlowLayout() + layout.itemSize = .init(width: UIScreen.width - 32, height: 60) + layout.footerReferenceSize = .init(width: UIScreen.width, height: 72) + layout.minimumLineSpacing = 12 + return layout + }() + + private lazy var collectionView: NRCollectionView = { + let collectionView = NRCollectionView(frame: .zero, collectionViewLayout: collectionViewLayout) + collectionView.delegate = self + collectionView.dataSource = self + collectionView.contentInset = .init(top: 24, left: 0, bottom: UIScreen.safeBottom + 10, right: 0) + collectionView.register(NRSettingCell.self, forCellWithReuseIdentifier: "cell") + collectionView.register(NRSettingFooterView.self, forSupplementaryViewOfKind: UICollectionView.elementKindSectionFooter, withReuseIdentifier: "footer") + return collectionView + }() + + @MainActor deinit { + NotificationCenter.default.removeObserver(self) + } + + override func viewDidLoad() { + super.viewDidLoad() + self.title = "Settings".localized + self.backgroundImageView.isHidden = true + configNavigationBack("arrow_left_icon_05") + + NotificationCenter.default.addObserver(self, selector: #selector(userInfoUpdateNotification), name: NRLoginManager.userInfoUpdateNotification, object: nil) + + nr_setupUI() + } + + + override func viewWillAppear(_ animated: Bool) { + super.viewWillAppear(animated) + self.navigationController?.setNavigationBarHidden(false, animated: true) + self.nr_setNavigationStyle(titleColor: UINavigationBar.titleBlackColor) + } + + @objc private func userInfoUpdateNotification() { + dataArr = getDataArr() + self.collectionView.reloadData() + } +} + +extension NRSettingViewController { + + private func nr_setupUI() { + view.addSubview(collectionView) + + collectionView.snp.makeConstraints { make in + make.left.right.bottom.equalToSuperview() + make.top.equalToSuperview().offset(UIScreen.navBarHeight) + } + } + +} + +//MARK: UICollectionViewDelegate UICollectionViewDataSource +extension NRSettingViewController: UICollectionViewDelegate, UICollectionViewDataSource { + + func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell { + let cell = collectionView.dequeueReusableCell(withReuseIdentifier: "cell", for: indexPath) as! NRSettingCell + cell.model = dataArr[indexPath.row] + return cell + } + + func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int { + return self.dataArr.count + } + + func collectionView(_ collectionView: UICollectionView, viewForSupplementaryElementOfKind kind: String, at indexPath: IndexPath) -> UICollectionReusableView { + if kind == UICollectionView.elementKindSectionFooter { + let view = collectionView.dequeueReusableSupplementaryView(ofKind: kind, withReuseIdentifier: "footer", for: indexPath) as! NRSettingFooterView + view.userInfo = NRLoginManager.manager.userInfo + return view + } + return UICollectionReusableView() + } + + func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) { + let model = dataArr[indexPath.row] + + switch model.type { + case .accountDeletion: + let vc = NRAppWebViewController() + vc.webUrl = kNRLogoutWebUrl + self.navigationController?.pushViewController(vc, animated: true) + + case .myUnlocks: + let vc = NRMyUnlocksViewController() + self.navigationController?.pushViewController(vc, animated: true) + + default: + break + } + } +} + +extension NRSettingViewController { + + private func getDataArr() -> [NRMeItem] { + if NRLoginManager.manager.userInfo?.is_tourist == true { + return [ + NRMeItem(type: .myUnlocks, title: "My Unlocks".localized), + ] + } else { + return [ + NRMeItem(type: .accountDeletion, title: "Account Deletion".localized), + NRMeItem(type: .myUnlocks, title: "My Unlocks".localized), + ] + } + } + + +} diff --git a/ReaderHive/Class/Store/V/NRWalletCell.swift b/ReaderHive/Class/Store/V/NRWalletCell.swift index 852e1fe..c6fdfac 100644 --- a/ReaderHive/Class/Store/V/NRWalletCell.swift +++ b/ReaderHive/Class/Store/V/NRWalletCell.swift @@ -23,6 +23,13 @@ class NRWalletCell: NRTableViewCell { return label }() + private lazy var lineView: NRDashedLineView = { + let view = NRDashedLineView() + view.direction = .horizontal + view.lineColor = UIColor.black.withAlphaComponent(0.15) + return view + }() + override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) { super.init(style: style, reuseIdentifier: reuseIdentifier) @@ -30,15 +37,22 @@ class NRWalletCell: NRTableViewCell { contentView.addSubview(titleLabel) contentView.addSubview(nr_indicatorImageView) + contentView.addSubview(lineView) titleLabel.snp.makeConstraints { make in make.centerY.equalToSuperview() - make.left.equalToSuperview().offset(16) + make.left.equalToSuperview().offset(28) } nr_indicatorImageView.snp.makeConstraints { make in make.centerY.equalToSuperview() - make.right.equalToSuperview().offset(-16) + make.right.equalToSuperview().offset(-28) + } + + lineView.snp.makeConstraints { make in + make.left.equalToSuperview().offset(28) + make.centerX.equalToSuperview() + make.bottom.equalToSuperview() } } diff --git a/ReaderHive/Class/Store/V/NRWalletHeaderView.swift b/ReaderHive/Class/Store/V/NRWalletHeaderView.swift index ac85a66..084b1e8 100644 --- a/ReaderHive/Class/Store/V/NRWalletHeaderView.swift +++ b/ReaderHive/Class/Store/V/NRWalletHeaderView.swift @@ -55,6 +55,12 @@ class NRWalletHeaderView: UITableViewHeaderFooterView { return view }() + private lazy var lineView: UIView = { + let view = UIView() + view.backgroundColor = .black.withAlphaComponent(0.15) + return view + }() + override init(reuseIdentifier: String?) { super.init(reuseIdentifier: reuseIdentifier) @@ -74,6 +80,7 @@ extension NRWalletHeaderView { bgView.addSubview(storeButton) bgView.addSubview(coinsView) bgView.addSubview(bonusCoinsView) + bgView.addSubview(lineView) bgView.snp.makeConstraints { make in make.left.equalToSuperview().offset(16) @@ -101,6 +108,13 @@ extension NRWalletHeaderView { make.width.equalTo(coinsView) make.left.equalTo(coinsView.snp.right).offset(0) } + + lineView.snp.makeConstraints { make in + make.centerX.equalToSuperview() + make.centerY.equalTo(coinsView) + make.width.equalTo(1) + make.height.equalTo(36) + } } } diff --git a/ReaderHive/Libs/Alert/NRAlert.swift b/ReaderHive/Libs/Alert/NRAlert.swift index 1666953..598ea82 100644 --- a/ReaderHive/Libs/Alert/NRAlert.swift +++ b/ReaderHive/Libs/Alert/NRAlert.swift @@ -13,27 +13,46 @@ class NRAlert: NRBaseAlert { var closeHandle: (() -> Void)? var highlightHandle: (() -> Void)? - private lazy var bgView: UIImageView = { + private(set) lazy var bgView: UIImageView = { let view = UIImageView(image: UIImage(named: "alert_bg_image_01")) view.isUserInteractionEnabled = true + view.setContentHuggingPriority(.required, for: .horizontal) + view.setContentCompressionResistancePriority(.required, for: .horizontal) return view }() - private lazy var topIconImageView: UIImageView = { + private(set) lazy var topIconImageView: UIImageView = { let imageView = UIImageView() return imageView }() - private lazy var closeButton: UIButton = { + private(set) lazy var closeButton: UIButton = { let button = UIButton(type: .custom, primaryAction: UIAction(handler: { [weak self] _ in - self?.closeHandle?() - self?.dismiss() + self?.handleCloseButton() })) button.setImage(UIImage(named: "close_icon_01"), for: .normal) return button }() + private(set) lazy var highlightButton: UIButton = { + let button = NRGradientButton(type: .custom, primaryAction: UIAction(handler: { [weak self] _ in + guard let self = self else { return } + self.handleHighlightButton() + })) + button.setTitleColor(.white, for: .normal) + button.titleLabel?.font = .font(ofSize: 14, weight: .medium) + button.colors = [UIColor.F_3912_F.cgColor, UIColor.FF_4_A_4_A.cgColor, UIColor.FA_9_B_1_F.cgColor] + button.startPoint = .init(x: 0, y: 0.5) + button.endPoint = .init(x: 1, y: 0.5) + button.layer.cornerRadius = 24 + button.layer.masksToBounds = true + return button + }() + override init(frame: CGRect) { + super.init(frame: frame) + nr_setupUI() + } init(title: String?, detail: String?, topIconImage: UIImage?, highlightButtonText: String?) { super.init(frame: .zero) @@ -74,20 +93,8 @@ class NRAlert: NRBaseAlert { if let text = highlightButtonText { - let button = NRGradientButton(type: .custom, primaryAction: UIAction(handler: { [weak self] _ in - guard let self = self else { return } - self.highlightHandle?() - self.dismiss() - })) - button.setTitle(text, for: .normal) - button.setTitleColor(.white, for: .normal) - button.titleLabel?.font = .font(ofSize: 14, weight: .medium) - button.colors = [UIColor.F_3912_F.cgColor, UIColor.FF_4_A_4_A.cgColor, UIColor.FA_9_B_1_F.cgColor] - button.startPoint = .init(x: 0, y: 0.5) - button.endPoint = .init(x: 1, y: 0.5) - button.layer.cornerRadius = 24 - button.layer.masksToBounds = true - buttonStackView.addArrangedSubview(button) + highlightButton.setTitle(text, for: .normal) + buttonStackView.addArrangedSubview(highlightButton) } bgView.addSubview(stackView) @@ -106,11 +113,21 @@ class NRAlert: NRBaseAlert { make.bottom.equalToSuperview().offset(-16) make.height.equalTo(48) } - } + @MainActor required init?(coder: NSCoder) { - fatalError("init(coder:) has not been implemented") + super.init(coder: coder) + } + + func handleHighlightButton() { + self.highlightHandle?() + self.dismiss() + } + + func handleCloseButton() { + self.closeHandle?() + self.dismiss() } } diff --git a/ReaderHive/Libs/Alert/NRUpdatesAlert.swift b/ReaderHive/Libs/Alert/NRUpdatesAlert.swift new file mode 100644 index 0000000..dac8090 --- /dev/null +++ b/ReaderHive/Libs/Alert/NRUpdatesAlert.swift @@ -0,0 +1,126 @@ +// +// NRUpdatesAlert.swift +// ReaderHive +// +// Created by 澜声世纪 on 2025/12/16. +// + +import UIKit +import SnapKit + +class NRUpdatesAlert: NRAlert { + + + + + init(model: NRVersionUpdateModel) { + super.init(frame: .zero) + closeButton.isHidden = model.force ?? false + + topIconImageView.image = UIImage(named: "alert_top_icon_03") + + let stackView = UIStackView() + stackView.axis = .vertical + stackView.alignment = .center + stackView.spacing = 12 + + let titleView = UIView() + + let titleLabel = UILabel() + titleLabel.textAlignment = .center + titleLabel.numberOfLines = 0 + titleLabel.font = .font(ofSize: 20, weight: .medium) + titleLabel.textColor = .F_9710_D + titleLabel.text = "New Version".localized + + let versionView = UIView() + versionView.backgroundColor = .F_9710_D + versionView.layer.cornerRadius = 9 + versionView.layer.masksToBounds = true + + let versionLabel = UILabel() + versionLabel.font = .font(ofSize: 12, weight: .bold) + versionLabel.textColor = .FFEFD_4 + versionLabel.text = "v\(model.version_name ?? "")" + + titleView.addSubview(titleLabel) + titleView.addSubview(versionView) + versionView.addSubview(versionLabel) + + titleLabel.snp.makeConstraints { make in + make.left.top.bottom.equalToSuperview() + } + + versionView.snp.makeConstraints { make in + make.centerY.equalToSuperview() + make.height.equalTo(18) + make.left.equalTo(titleLabel.snp.right).offset(8) + make.right.equalToSuperview() + } + + versionLabel.snp.makeConstraints { make in + make.center.equalToSuperview() + make.left.equalToSuperview().offset(7) + } + + stackView.addArrangedSubview(titleView) + + + if let detail = model.des { + let label = UILabel() + label.textAlignment = .center + label.numberOfLines = 0 + label.font = .font(ofSize: 14, weight: .regular) + label.textColor = .black.withAlphaComponent(0.5) + label.text = detail.localized + stackView.addArrangedSubview(label) + } + + let buttonStackView = UIStackView() + buttonStackView.axis = .horizontal + buttonStackView.spacing = 19 + buttonStackView.distribution = .fillEqually + + + + highlightButton.setTitle("Update Now".localized, for: .normal) + buttonStackView.addArrangedSubview(highlightButton) + + bgView.addSubview(stackView) + bgView.addSubview(buttonStackView) + + stackView.snp.makeConstraints { make in + make.centerX.equalToSuperview() + make.right.lessThanOrEqualToSuperview().offset(-16) + make.top.equalToSuperview().offset(100) + } + + buttonStackView.snp.makeConstraints { make in + make.left.equalToSuperview().offset(16) + make.centerX.equalToSuperview() + make.top.equalTo(stackView.snp.bottom).offset(36) + make.bottom.equalToSuperview().offset(-16) + make.height.equalTo(48) + } + + } + + @MainActor required init?(coder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + + override func handleHighlightButton() { +// super.handleHighlightButton() + + guard let url = URL(string: "https://apps.apple.com/app/id6756297764") else { return } + let application = UIApplication.shared + if application.canOpenURL(url) { + application.open(url) + } + } + + override func handleCloseButton() { + super.handleCloseButton() + } + +} diff --git a/ReaderHive/Libs/Tool/NRTool.swift b/ReaderHive/Libs/Tool/NRTool.swift index f2882aa..248498c 100644 --- a/ReaderHive/Libs/Tool/NRTool.swift +++ b/ReaderHive/Libs/Tool/NRTool.swift @@ -54,3 +54,55 @@ class NRTool { } } + +extension NRTool { + + static weak var updateAlert: UIView? + + static func checkUpdates() { + guard self.self.updateAlert == nil else { return } + + + Task { + guard let model = await NRSettingAPI.requestVersionUpdateData() else { +// FAAdjustStateManager.manager.upgradeAlertFinish = true +// FATool.sceneDelegate?.retryHandleOpenAppMessage() + return + } + + self.showUpdatesAlert(model) + + + } + } + + static func showUpdatesAlert(_ model: NRVersionUpdateModel) { + guard self.self.updateAlert == nil else { return } +#if !DEBUG + if model.force != true { + if let date = UserDefaults.standard.object(forKey: kNRVersionUpdateAlertDefaultsKey) as? Date { + if date.nr_isToday { +// FAAdjustStateManager.manager.upgradeAlertFinish = true +// FATool.sceneDelegate?.retryHandleOpenAppMessage() + return + } + } + UserDefaults.standard.set(Date(), forKey: kNRVersionUpdateAlertDefaultsKey) + } +#endif // !DEBUG + + + if model.canUpdate() { +// FAStatAPI.requestEventStat(orderCode: nil, shortPlayId: nil, videoId: nil, eventKey: .forceUpdate, errorMsg: nil, otherParamenters: [ +// "is_force" : model.force == true ? "true" : "false" +// ]) + + let view = NRUpdatesAlert(model: model) + view.show() + self.updateAlert = view + } else { +// FAAdjustStateManager.manager.upgradeAlertFinish = true +// FATool.sceneDelegate?.retryHandleOpenAppMessage() + } + } +} diff --git a/ReaderHive/Source/Assets.xcassets/Color/black_0.25.colorset/Contents.json b/ReaderHive/Source/Assets.xcassets/Color/black_0.25.colorset/Contents.json new file mode 100644 index 0000000..d1dbdaa --- /dev/null +++ b/ReaderHive/Source/Assets.xcassets/Color/black_0.25.colorset/Contents.json @@ -0,0 +1,20 @@ +{ + "colors" : [ + { + "color" : { + "color-space" : "srgb", + "components" : { + "alpha" : "0.250", + "blue" : "0x00", + "green" : "0x00", + "red" : "0x00" + } + }, + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_02.imageset/Contents.json b/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_02.imageset/Contents.json new file mode 100644 index 0000000..602d2a0 --- /dev/null +++ b/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_02.imageset/Contents.json @@ -0,0 +1,22 @@ +{ + "images" : [ + { + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "logout@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "logout@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_02.imageset/logout@2x.png b/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_02.imageset/logout@2x.png new file mode 100644 index 0000000..c2cfebc Binary files /dev/null and b/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_02.imageset/logout@2x.png differ diff --git a/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_02.imageset/logout@3x.png b/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_02.imageset/logout@3x.png new file mode 100644 index 0000000..2b3ac86 Binary files /dev/null and b/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_02.imageset/logout@3x.png differ diff --git a/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_03.imageset/Contents.json b/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_03.imageset/Contents.json new file mode 100644 index 0000000..512decf --- /dev/null +++ b/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_03.imageset/Contents.json @@ -0,0 +1,22 @@ +{ + "images" : [ + { + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "new version@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "new version@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_03.imageset/new version@2x.png b/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_03.imageset/new version@2x.png new file mode 100644 index 0000000..fc983af Binary files /dev/null and b/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_03.imageset/new version@2x.png differ diff --git a/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_03.imageset/new version@3x.png b/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_03.imageset/new version@3x.png new file mode 100644 index 0000000..f766787 Binary files /dev/null and b/ReaderHive/Source/Assets.xcassets/Image/alert_top_icon_03.imageset/new version@3x.png differ diff --git a/ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/Contents.json b/ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/Contents.json index 414422f..3e2a3f9 100644 --- a/ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/Contents.json +++ b/ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/Contents.json @@ -5,12 +5,12 @@ "scale" : "1x" }, { - "filename" : "My Wallet@2x.png", + "filename" : "Feedback@2x.png", "idiom" : "universal", "scale" : "2x" }, { - "filename" : "My Wallet@3x.png", + "filename" : "Feedback@3x.png", "idiom" : "universal", "scale" : "3x" } diff --git a/ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/Feedback@2x.png b/ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/Feedback@2x.png new file mode 100644 index 0000000..12341fa Binary files /dev/null and b/ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/Feedback@2x.png differ diff --git a/ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/Feedback@3x.png b/ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/Feedback@3x.png new file mode 100644 index 0000000..eb799cb Binary files /dev/null and b/ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/Feedback@3x.png differ diff --git a/ReaderHive/Source/Assets.xcassets/Image/settings_icon_02.imageset/Contents.json b/ReaderHive/Source/Assets.xcassets/Image/settings_icon_02.imageset/Contents.json new file mode 100644 index 0000000..2ea1fc8 --- /dev/null +++ b/ReaderHive/Source/Assets.xcassets/Image/settings_icon_02.imageset/Contents.json @@ -0,0 +1,22 @@ +{ + "images" : [ + { + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "Settings@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "Settings@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ReaderHive/Source/Assets.xcassets/Image/settings_icon_02.imageset/Settings@2x.png b/ReaderHive/Source/Assets.xcassets/Image/settings_icon_02.imageset/Settings@2x.png new file mode 100644 index 0000000..d999e50 Binary files /dev/null and b/ReaderHive/Source/Assets.xcassets/Image/settings_icon_02.imageset/Settings@2x.png differ diff --git a/ReaderHive/Source/Assets.xcassets/Image/settings_icon_02.imageset/Settings@3x.png b/ReaderHive/Source/Assets.xcassets/Image/settings_icon_02.imageset/Settings@3x.png new file mode 100644 index 0000000..f700e4b Binary files /dev/null and b/ReaderHive/Source/Assets.xcassets/Image/settings_icon_02.imageset/Settings@3x.png differ diff --git a/ReaderHive/Source/Assets.xcassets/Image/wallet_icon_01.imageset/Contents.json b/ReaderHive/Source/Assets.xcassets/Image/wallet_icon_01.imageset/Contents.json new file mode 100644 index 0000000..414422f --- /dev/null +++ b/ReaderHive/Source/Assets.xcassets/Image/wallet_icon_01.imageset/Contents.json @@ -0,0 +1,22 @@ +{ + "images" : [ + { + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "My Wallet@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "My Wallet@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/My Wallet@2x.png b/ReaderHive/Source/Assets.xcassets/Image/wallet_icon_01.imageset/My Wallet@2x.png similarity index 100% rename from ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/My Wallet@2x.png rename to ReaderHive/Source/Assets.xcassets/Image/wallet_icon_01.imageset/My Wallet@2x.png diff --git a/ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/My Wallet@3x.png b/ReaderHive/Source/Assets.xcassets/Image/wallet_icon_01.imageset/My Wallet@3x.png similarity index 100% rename from ReaderHive/Source/Assets.xcassets/Image/feedback_icon_01.imageset/My Wallet@3x.png rename to ReaderHive/Source/Assets.xcassets/Image/wallet_icon_01.imageset/My Wallet@3x.png diff --git a/ReaderHive/Source/en.lproj/Localizable.strings b/ReaderHive/Source/en.lproj/Localizable.strings index 024d87d..55b5c53 100644 --- a/ReaderHive/Source/en.lproj/Localizable.strings +++ b/ReaderHive/Source/en.lproj/Localizable.strings @@ -131,8 +131,18 @@ "Buy Now" = "Buy Now"; "Login with Apple" = "Login with Apple"; "Login with Facebook" = "Login with Facebook"; +"My Wallet" = "My Wallet"; +"Account Deletion" = "Account Deletion"; +"My Unlocks" = "My Unlocks"; +"Login" = "Login"; +"Log Out" = "Log Out"; +"Confirm" = "Confirm"; +"Unlocked Chapters" = "Unlocked Chapters"; +"Update Now" = "Update Now"; +"New Version" = "New Version"; "retain_alert_text" = "Unlock every show you love!"; +"logout_alert_text" = "Are you sure you want to log out?"; "vip_tip_01" = "Unlimited access to all series";