From fbca33360455da35f3c8a0480b086fa01a72a6c6 Mon Sep 17 00:00:00 2001 From: Esenbek Date: Tue, 14 Nov 2023 16:57:15 +0600 Subject: [PATCH] Add separate Blockchair restore modes --- .../project.pbxproj | 6 ++-- .../API_Hybrid@2x.png | Bin 0 -> 1166 bytes .../API_Hybrid@3x.png | Bin 0 -> 1720 bytes .../APIplaceHolder@2x.png | Bin 1484 -> 0 bytes .../APIplaceHolder@3x.png | Bin 1983 -> 0 bytes .../api_placeholder_32.imageset/Contents.json | 4 +-- .../Core/Managers/BtcBlockchainManager.swift | 26 ++++++++---------- .../Extensions/BlockchainType.swift | 11 ++++++++ .../Models/BtcRestoreMode.swift | 3 +- .../BtcBlockchainSettingsService.swift | 12 +++----- .../BtcBlockchainSettingsViewModel.swift | 15 +++++----- .../BlockchainSettingsViewModel.swift | 14 ++++------ .../en.lproj/Localizable.strings | 6 ++-- 13 files changed, 52 insertions(+), 45 deletions(-) create mode 100644 UnstoppableWallet/UnstoppableWallet/Assets.xcassets/Icons/api_placeholder_32.imageset/API_Hybrid@2x.png create mode 100644 UnstoppableWallet/UnstoppableWallet/Assets.xcassets/Icons/api_placeholder_32.imageset/API_Hybrid@3x.png delete mode 100644 UnstoppableWallet/UnstoppableWallet/Assets.xcassets/Icons/api_placeholder_32.imageset/APIplaceHolder@2x.png delete mode 100644 UnstoppableWallet/UnstoppableWallet/Assets.xcassets/Icons/api_placeholder_32.imageset/APIplaceHolder@3x.png diff --git a/UnstoppableWallet/UnstoppableWallet.xcodeproj/project.pbxproj b/UnstoppableWallet/UnstoppableWallet.xcodeproj/project.pbxproj index b8d13a7f1d..44daa04cfd 100644 --- a/UnstoppableWallet/UnstoppableWallet.xcodeproj/project.pbxproj +++ b/UnstoppableWallet/UnstoppableWallet.xcodeproj/project.pbxproj @@ -12436,7 +12436,7 @@ repositoryURL = "https://github.com/horizontalsystems/BitcoinCore.Swift"; requirement = { kind = exactVersion; - version = 2.1.1; + version = 2.1.3; }; }; 6B55461F2A6E73190054B524 /* XCRemoteSwiftPackageReference "UIExtensions.Swift" */ = { @@ -12548,7 +12548,7 @@ repositoryURL = "https://github.com/horizontalsystems/BitcoinKit.Swift"; requirement = { kind = exactVersion; - version = 2.1.2; + version = 2.1.3; }; }; D3604E6728F02DF30066C366 /* XCRemoteSwiftPackageReference "BitcoinCashKit.Swift" */ = { @@ -12556,7 +12556,7 @@ repositoryURL = "https://github.com/horizontalsystems/BitcoinCashKit.Swift"; requirement = { kind = exactVersion; - version = 2.1.1; + version = 2.1.2; }; }; D3604E6A28F02E3F0066C366 /* XCRemoteSwiftPackageReference "LitecoinKit.Swift" */ = { diff --git a/UnstoppableWallet/UnstoppableWallet/Assets.xcassets/Icons/api_placeholder_32.imageset/API_Hybrid@2x.png b/UnstoppableWallet/UnstoppableWallet/Assets.xcassets/Icons/api_placeholder_32.imageset/API_Hybrid@2x.png new file mode 100644 index 0000000000000000000000000000000000000000..553e3fe1bb00a7e0a47c43dff0a61a370db920f4 GIT binary patch literal 1166 zcmV;91abR`P)`~B|B_`TVE1TM(h+72t<;mx!7KB#f|cC#`##t-Zkvp(C8gK1gi{!r){u;jNYpcyy4 z7iHWs91jbn=nh;lj(PNX!E!fk!~4P@-A>5ueYipx7xwKBziv_tZ($0UEUwCp10X6U zOTL3EhRdiHwbO(%2d2ZVH@jjg*I-KRlnTQJU6I-;$gB=@MQW$Bl;Noc=K%_ulNkV- zlNkV-qrCwJD8^)glQ+CC2}$nDAmjc;e^<&i{v7q40J0w^Y}<`We}H0?_5h2y6~}z} z8zXUb9P#HtK-`nL!;ht0^LLB+N;6lb1{6$x6HdhVsu7if+4&WF87M-T0Y$653KJFI zM^tc#fg+U60S1k}N*^bJ?0NCx<0vs)xCGecZKG3VM6CAP2;s_xm&zekynv)p-nv)p-nv)p-6GCOYj!70w2xSIv zAWzfBdBgo)MdpS^+D1@Kw+TU%Jw{WO3kboU0*MD9D#q>w(_IBqeGnIOwhf9<)&smC zj~De1OdL{IxiF&40F2i=k@Em1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ig!epyQk= zuag4m$?)vTo~2hceEv_93SA8{wn6t+l()}W=7jh(XzJS?v9bPLo9{DA2K$d(k=wH9 z`yEhVQ3caJo}fqlZO-``5_;~M)<+~wnqiv6T>d=4t9X0&jL+wV+QrLj`P(^;w#rlB zg+%0B9xGa%89tyh0{_vwqKBviuRO{B@}c9C^`AZf@!<5+Mh32k+aWx~)86Q1<>lF4 zUw)q;&=`TZJFIq9=Voww-?hKaSK_UPnEzrAV;1QnqUsK~ZnlFHB%PwccWWcal;8(^ qLMt3&kvj(dXsWp<#C~@Y`n#NS7(MFPB(G?vXaH|_yj#;za{AvBl@=cW literal 0 HcmV?d00001 diff --git a/UnstoppableWallet/UnstoppableWallet/Assets.xcassets/Icons/api_placeholder_32.imageset/APIplaceHolder@2x.png b/UnstoppableWallet/UnstoppableWallet/Assets.xcassets/Icons/api_placeholder_32.imageset/APIplaceHolder@2x.png deleted file mode 100644 index 8696462a94bb89da0d9867a1047bbcd47680737a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1484 zcmV;-1vC1IP)0K|$BO-%(B(4UP}XDi(h-^BuOYNz!k=}tlY!ZFZWt~-_!uu>I=s4dz4TO zh5(Oy)^mO4uV%gB6$9MAzoFaO@r_|oz6u(_I)+!V7Ew`C+~vDzb4rB(I-*01}9Ya@ayi=qn^!u%n;ZZm0k~K!x|XzZ-i-(Y*x; zOlil9(0An#p28spJ>m(k7Ijx#k42fUL+p=2?N95UT~4-2&ddYbReEYE?DD!&Of$k4 zt7U|EQihi*bf=UnI>_N>{e$5|)_PSQv0Ob{GNTXb%P7b(00`a1T*W7#58#V~By1Au z*^o^Uy3?z)!;=lp0~AJ_u>oMj85;mboUs9*PvEW)B!QbO=o8Wm-~oAB{~T5d-^$pz zp&@m}OxKrjPPRc33P^%;_7sRyb5YTEkEn%3P~|&uj>pzP64H7=$qeI59YEi~?XbLq z5orcMf4yi&??PXVK(a+Uat|aTZ3rN^0XlN^I}vdWI^$KkJ{5%*2O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s{dEqq*1_hbB@eK^<#wQ-D z#3}fI*aEZ?h{5ejj#_4x;pT7yutQ%`;2lnx@PuR3TyMQWEm6flR@_2w BtcRestoreMode { + blockchainType.supports(restoreMode: .blockchair) ? .blockchair : .hybrid + } } extension BtcBlockchainManager { @@ -46,23 +50,17 @@ extension BtcBlockchainManager { } func restoreMode(blockchainType: BlockchainType) -> BtcRestoreMode { - storage.btcRestoreMode(blockchainType: blockchainType) ?? .api - } - - func apiSyncMode(blockchainType: BlockchainType) -> BitcoinCore.SyncMode { - switch blockchainType { - case .bitcoin, .bitcoinCash: return .blockchair(key: AppConfig.blockchairApiKey) - default: return .api - } + storage.btcRestoreMode(blockchainType: blockchainType) ?? fastestSyncMode(blockchainType: blockchainType) } func syncMode(blockchainType: BlockchainType, accountOrigin: AccountOrigin) -> BitcoinCore.SyncMode { - if accountOrigin == .created { - return apiSyncMode(blockchainType: blockchainType) - } + let _restoreMode = accountOrigin == .created + ? fastestSyncMode(blockchainType: blockchainType) + : restoreMode(blockchainType: blockchainType) - switch restoreMode(blockchainType: blockchainType) { - case .api: return apiSyncMode(blockchainType: blockchainType) + switch _restoreMode { + case .blockchair: return .blockchair(key: AppConfig.blockchairApiKey) + case .hybrid: return .api case .blockchain: return .full } } diff --git a/UnstoppableWallet/UnstoppableWallet/Extensions/BlockchainType.swift b/UnstoppableWallet/UnstoppableWallet/Extensions/BlockchainType.swift index c9ed07083d..aba3f3f26c 100644 --- a/UnstoppableWallet/UnstoppableWallet/Extensions/BlockchainType.swift +++ b/UnstoppableWallet/UnstoppableWallet/Extensions/BlockchainType.swift @@ -186,6 +186,17 @@ extension BlockchainType { } } + func supports(restoreMode: BtcRestoreMode) -> Bool { + guard case .blockchair = restoreMode else { + return true + } + + switch self { + case .bitcoin, .bitcoinCash: return true + default: return false + } + } + } extension BlockchainType: Comparable { diff --git a/UnstoppableWallet/UnstoppableWallet/Models/BtcRestoreMode.swift b/UnstoppableWallet/UnstoppableWallet/Models/BtcRestoreMode.swift index 7e802d7632..9d042cb24a 100644 --- a/UnstoppableWallet/UnstoppableWallet/Models/BtcRestoreMode.swift +++ b/UnstoppableWallet/UnstoppableWallet/Models/BtcRestoreMode.swift @@ -1,5 +1,6 @@ enum BtcRestoreMode: String, CaseIterable, Identifiable, Codable { - case api + case blockchair + case hybrid case blockchain var id: Self { diff --git a/UnstoppableWallet/UnstoppableWallet/Modules/BtcBlockchainSettings/BtcBlockchainSettingsService.swift b/UnstoppableWallet/UnstoppableWallet/Modules/BtcBlockchainSettings/BtcBlockchainSettingsService.swift index 1822586874..32d4268922 100644 --- a/UnstoppableWallet/UnstoppableWallet/Modules/BtcBlockchainSettings/BtcBlockchainSettingsService.swift +++ b/UnstoppableWallet/UnstoppableWallet/Modules/BtcBlockchainSettings/BtcBlockchainSettingsService.swift @@ -1,5 +1,5 @@ -import MarketKit import BitcoinCore +import MarketKit class BtcBlockchainSettingsService { let blockchain: Blockchain @@ -12,19 +12,15 @@ class BtcBlockchainSettingsService { self.blockchain = blockchain self.btcBlockchainManager = btcBlockchainManager - restoreModes = BtcRestoreMode.allCases.map { restoreMode in - let syncMode = btcBlockchainManager.apiSyncMode(blockchainType: blockchain.type) - return BtcSyncModeItem(blockchain: blockchain, restoreMode: restoreMode, syncMode: syncMode) - } + restoreModes = BtcRestoreMode.allCases + .filter { blockchain.type.supports(restoreMode: $0) } + .map { BtcSyncModeItem(blockchain: blockchain, restoreMode: $0) } currentRestoreMode = btcBlockchainManager.restoreMode(blockchainType: blockchain.type) } - } extension BtcBlockchainSettingsService { - func save(restoreMode: BtcRestoreMode) { btcBlockchainManager.save(restoreMode: restoreMode, blockchainType: blockchain.type) } - } diff --git a/UnstoppableWallet/UnstoppableWallet/Modules/BtcBlockchainSettings/BtcBlockchainSettingsViewModel.swift b/UnstoppableWallet/UnstoppableWallet/Modules/BtcBlockchainSettings/BtcBlockchainSettingsViewModel.swift index b601aaa971..70c784ac33 100644 --- a/UnstoppableWallet/UnstoppableWallet/Modules/BtcBlockchainSettings/BtcBlockchainSettingsViewModel.swift +++ b/UnstoppableWallet/UnstoppableWallet/Modules/BtcBlockchainSettings/BtcBlockchainSettingsViewModel.swift @@ -19,19 +19,20 @@ class BtcBlockchainSettingsViewModel: ObservableObject { selectedRestoreMode = service.currentRestoreMode restoreModes = service.restoreModes.map { restoreMode in let image: BtcRestoreModeViewItem.Image - switch (restoreMode.restoreMode, restoreMode.syncMode) { - case (.api, .api): - image = .local(name: "api_placeholder_32") - case (.api, .blockchair): + switch restoreMode.restoreMode { + case .blockchair: image = .local(name: "blockchair_32") - default: + case .hybrid: + image = .local(name: "api_placeholder_32") + case .blockchain: image = .remote(url: service.blockchain.type.imageUrl) } let description: String switch restoreMode.restoreMode { - case .api: description = "btc_restore_mode.fast".localized - case .blockchain: description = "btc_restore_mode.slow".localized + case .blockchair: description = "btc_restore_mode.blockchair".localized + case .hybrid: description = "btc_restore_mode.hybrid".localized + case .blockchain: description = "btc_restore_mode.blockchain".localized } return BtcRestoreModeViewItem( diff --git a/UnstoppableWallet/UnstoppableWallet/Modules/Settings/BlockchainSettings/BlockchainSettingsViewModel.swift b/UnstoppableWallet/UnstoppableWallet/Modules/Settings/BlockchainSettings/BlockchainSettingsViewModel.swift index ff01f6c4f5..773a346b35 100644 --- a/UnstoppableWallet/UnstoppableWallet/Modules/Settings/BlockchainSettings/BlockchainSettingsViewModel.swift +++ b/UnstoppableWallet/UnstoppableWallet/Modules/Settings/BlockchainSettings/BlockchainSettingsViewModel.swift @@ -1,8 +1,8 @@ +import BitcoinCore import Combine import MarketKit import RxRelay import RxSwift -import BitcoinCore class BlockchainSettingsViewModel: ObservableObject { private let btcBlockchainManager: BtcBlockchainManager @@ -29,8 +29,7 @@ class BlockchainSettingsViewModel: ObservableObject { btcItems = btcBlockchainManager.allBlockchains .map { blockchain in let restoreMode = btcBlockchainManager.restoreMode(blockchainType: blockchain.type) - let syncMode = btcBlockchainManager.apiSyncMode(blockchainType: blockchain.type) - return BtcSyncModeItem(blockchain: blockchain, restoreMode: restoreMode, syncMode: syncMode) + return BtcSyncModeItem(blockchain: blockchain, restoreMode: restoreMode) } .sorted { $0.blockchain.type.order < $1.blockchain.type.order } } @@ -55,13 +54,12 @@ extension BlockchainSettingsViewModel { struct BtcSyncModeItem { let blockchain: Blockchain let restoreMode: BtcRestoreMode - let syncMode: BitcoinCore.SyncMode var title: String { - switch (restoreMode, syncMode) { - case (.api, .api): return "API" - case (.api, .blockchair): return "Blockchair API" - default: return "sync_mode.from_blockchain".localized(blockchain.name) + switch restoreMode { + case .blockchair: return "Blockchair API" + case .hybrid: return "sync_mode.hybrid".localized + case .blockchain: return "sync_mode.from_blockchain".localized(blockchain.name) } } } diff --git a/UnstoppableWallet/UnstoppableWallet/en.lproj/Localizable.strings b/UnstoppableWallet/UnstoppableWallet/en.lproj/Localizable.strings index 0bff3f9511..5f39240520 100644 --- a/UnstoppableWallet/UnstoppableWallet/en.lproj/Localizable.strings +++ b/UnstoppableWallet/UnstoppableWallet/en.lproj/Localizable.strings @@ -181,6 +181,7 @@ "coin_settings.title" = "Blockchain Settings"; "coin_settings.bitcoin_cash_coin_type.title.type0" = "Legacy"; "coin_settings.bitcoin_cash_coin_type.title.type145" = "CashAddress"; +"sync_mode.hybrid" = "Hybrid"; "sync_mode.from_blockchain" = "%@ Blockchain"; "blockchain_settings.description" = "Select the address format for receiving payments. A correct format should be chosen when restoring an existing wallet."; @@ -1215,8 +1216,9 @@ "btc_blockchain_settings.restore_source.description" = "Choose the source Unstoppable app should use for synchronizing wallet(s)."; "btc_blockchain_settings.restore_source.alert" = "After changing Restore Source the wallet will have to resync itself with the %@ blockchain."; -"btc_restore_mode.fast" = "Fast, Private, Centralized"; -"btc_restore_mode.slow" = "Slow, Private, Decentralized"; +"btc_restore_mode.blockchair" = "Fast, Private, Centralized"; +"btc_restore_mode.hybrid" = "API + Blockchain"; +"btc_restore_mode.blockchain" = "Slow, Private, Decentralized"; "btc_transaction_sort_mode.shuffle" = "Shuffle"; "btc_transaction_sort_mode.shuffle.description" = "Random Indexing";