Compare commits

...

381 Commits

Author SHA1 Message Date
Lukas Korba 4046b6c059
Merge pull request #1282 from LukasKorba/1279-Release-1-1-1
[#1279] Release 1.1.1
2024-05-23 15:38:46 +02:00
Lukas Korba dab345be26 [#1279] Release 1.1.1
- changelog updatd
- version set to 1.1.1-1

[#1279] Release 1.1.1

- Cleanup and fixes
2024-05-22 11:26:14 +02:00
Andrea Kobrlova 6da9845dec
Merge pull request #1280 from Electric-Coin-Company/true-jared-patch-1
Update whatsNew.json
2024-05-22 10:45:06 +02:00
Andrea Kobrlova e5bdf8aaaf
Merge pull request #1281 from Electric-Coin-Company/true-jared-patch-2
Update whatsNew.json
2024-05-22 10:43:56 +02:00
Andrea Kobrlova 4bb15d5977
Update whatsNew.json
Updated .json with a fixed header release information
2024-05-22 10:33:09 +02:00
Andrea Kobrlova 9723a811ef
Update whatsNew.json
.json file updated with release notes for 1.1.1 release
2024-05-21 16:06:59 +02:00
Lukas Korba b2911ff134
Merge pull request #1278 from LukasKorba/1277-Send-failed-authentication-minor-bugs
[#1277] Send failed authentication minor bugs
2024-05-21 10:41:30 +02:00
Lukas Korba 3fb36406a3 [#1277] Send failed authentication minor bugs
- The reset form of send calls the right actions for the input fields to reset their local values as well
- When the biometric authentication fails the sending progress of buttons is reseted
2024-05-20 10:57:16 +02:00
Lukas Korba b1d6ecf695
Merge pull request #1273 from LukasKorba/1233-changelog-screen-to-inform-users-about-changes-implemented-in-an-update
[#1233] Changelog screen to inform users about changes implemented in an update
2024-05-17 13:17:20 +02:00
Lukas Korba 8af0d785c7
Merge pull request #1271 from LukasKorba/1270-Synchronizer-error-in-the-alert-view
[#1270] Synchronizer error in the alert view
2024-05-17 13:17:08 +02:00
Lukas Korba 2e928e6ae5
Merge pull request #1269 from LukasKorba/1267--Adopt-sdk-with-shielding-crash-fix
[#1267] Adopt sdk with shielding crash fix
2024-05-17 13:16:57 +02:00
Lukas Korba 7a307bf592 1233-changelog screen to inform users about changes implemented in an update
- WIP

[#1233] changelog screen to inform users about changes implemented in an update

- About screen is now an independent feature with standalone reducer
- What's new feature implemented
- JSON structure defined for the what's new
- What's new provider implemented to read the json file
- Custom styling via attributed strings implemented

[#1233] changelog screen to inform users about changes implemented in an update

- Localization support implemented

[#1233] changelog screen to inform users about changes implemented in an update

- About view final design
- What's new final design
- JSON extended to cover all production version releases

[#1233] changelog screen to inform users about changes implemented in an update

- Code cleanup
2024-05-16 13:04:56 +02:00
Lukas Korba 0ad73b905d [#1270] Synchronizer error in the alert view
- Changelog updated
- SyncProgress reducer has been refactored to the latest TCA
- Progress label is tappable when an error occurs and shows an alert view with the details
2024-05-16 08:55:00 +02:00
Lukas Korba 6d8096c20e
Merge pull request #1268 from LukasKorba/1234-improve-security-and-authentication-requirements
[#1234] improve security and authentication requirements
2024-05-16 08:08:07 +02:00
Lukas Korba d54675069b [#1234] improve security and authentication requirements
- Biometric lock if available is used to protect seed, delete zashi and export private data
- Also protecting Send at the very last step, when tapping the send button

[#1234] improve security and authentication requirements (#1268)

- Changelog updated
2024-05-16 08:05:12 +02:00
Lukas Korba c1b373dcec [#1267] Adopt sdk with shielding crash fix
- Fixed the crash of shielding, the error message is presented instead
2024-05-15 10:18:05 +02:00
Lukas Korba 4145b5eb8f
Merge pull request #1266 from LukasKorba/1235-When-receiving-a-multi-output-transaction,-all-memos-must-be-displayed
[#1235] When receiving a multi-output transaction all memos must be displayed
2024-05-15 10:07:07 +02:00
Lukas Korba ccf15f4c9f [#1235] When receiving a multi-output transaction all memos must be displayed
- Multi-text memos implemented
- changelog updated
2024-05-14 10:01:14 +02:00
Lukas Korba 1d821455c8
Merge pull request #1265 from LukasKorba/biometric--send
biometric--send
2024-05-13 19:29:32 +02:00
Lukas Korba 766213023a biometric--send
- WIP

biometric--send

- WIP

biometric--send

- The logic for navigation has been redesigned so confirmation screen is taken out of the tab-view navigation. That allowed to use iOS 15 and biometric lock and avoid SwiftUI navigation bug

biometric--send

- cleanup

biometric--send

- review comment resolved
2024-05-13 19:29:20 +02:00
Lukas Korba 0337b1b1e9
Merge pull request #1263 from LukasKorba/1262-Release-1-1---6
[#1262] Release 1.1-6
2024-05-09 13:36:06 +02:00
Lukas Korba a5bb3af11e [#1262] Release 1.1-6
- Changelog updated
- Version updated to 1.1 build 6
2024-05-09 13:00:21 +02:00
Lukas Korba a49a5d7ca8
Merge pull request #1261 from LukasKorba/1260-Tweak-hide-balances
[#1260] Tweak hide balances
2024-05-09 12:56:45 +02:00
Lukas Korba 0c4ab9ae56 [#1260] Tweak hide balances
- addressed comments and feedback, the send balances are hidden but not amounts
- the hide balances button is accessible on send screen
- shielding is disabled when balances are hidden
2024-05-09 09:07:29 +02:00
Lukas Korba cd71176185
Merge pull request #1259 from LukasKorba/1258-Share-QR-code-lacks-background
[#1258] Share QR code lacks background
2024-05-08 12:23:25 +02:00
Lukas Korba ad523860ca [#1258] Share QR code lacks background
- Due to inconsistencies of different QR readers we revert the QR code to standardised coluors
2024-05-08 11:42:25 +02:00
Lukas Korba 00b9e5903b
Merge pull request #1257 from LukasKorba/1256-Release-1-1---3
[#1256] Release 1.1-3
2024-05-07 16:51:40 +02:00
Lukas Korba 4f037aaa6b [#1256] Release 1.1-3
- Changelog updated
- Version updated to 1.1 build 3
2024-05-07 15:45:55 +02:00
Lukas Korba 95f4b3ba94
Merge pull request #1255 from LukasKorba/1254-Refresh-balances-immediately-after-send
[#1254] Refresh balances immediately after send
2024-05-07 15:43:15 +02:00
Lukas Korba 1d7d5426d4 [#1254] Refresh balances immediately after send
- The balances are proactively refreshed immediately after send or shield proposals are processed
- I also noticed wrong color of disabled message box when sending to transparent address so it's been fixed in this PR as well

[#1254] Refresh balances immediately after send

- unit tests fixed
2024-05-07 13:52:27 +02:00
Lukas Korba 5ac25b2bbb
Merge pull request #1251 from LukasKorba/1250-Restrict-Hide-balances-to-Account-and-Balances-tabs-only
[#1250] Restrict Hide balances to Account and Balances tabs only
2024-05-07 07:54:29 +02:00
Lukas Korba 633aed4b4a
Merge pull request #1253 from LukasKorba/1252-Some-views-hide-balances-that-is-supposed-to-be-visible
[#1252] Some views hide balances that is supposed to be visible
2024-05-06 20:42:02 +02:00
Lukas Korba 89e5afc30e [#1252] Some views hide balances that is supposed to be visible
- fixes for some Balances (views) that must stay always visible even though the hide balances is turned on
2024-05-06 20:03:39 +02:00
Lukas Korba 8a2694ed41 [#1250] Restrict Hide balances to Account and Balances tabs only
- The hide balances feature is supposed to be on Account and Balances tabs only so I removed it from Send and Receive
2024-05-06 19:09:28 +02:00
Lukas Korba 120479a3ea
Merge pull request #1249 from LukasKorba/hide-balances
[#1232] Be able to hide my balances
2024-05-06 19:02:24 +02:00
Lukas Korba eaf0a6322c hide-balances
- New dependency broadcasting value of hide balances flag implemented
- Every Zatoshi representation decides whether is rendered as number value or hidden, respects the font size and colour
- Flag value is persisted for next app start

hide-balances

- localization added

hide-balances

- changes according to the final design

[#1232] Be able to hide my balances

- finalized

[#1232] Be able to hide my balances

- changelog updated

[#1232] Be able to hide my balances

- regenerated strings
2024-05-06 19:02:05 +02:00
Lukas Korba 98f79f17f3
Merge pull request #1248 from LukasKorba/receive-tab-tweaks
[#1230] Improve Receive screen UI by adding a toggle for addresses
2024-05-06 18:56:48 +02:00
Lukas Korba b776a51802
Merge pull request #1247 from LukasKorba/read-qr-code-from-image
[#1231] QR code from a photo saved in my library
2024-05-06 18:56:34 +02:00
Lukas Korba 55283ffa1a receive-tab-tweaks
- The selection of the address has been added to the reducer
- UI renders only selected address in a scroll view
- AddressDetails Reducer has been refactored to the latest TCA

receive-tab-tweaks

- design finalized

receive-tab-tweaks

- colors finalized for dark mode

[#1230] improve Receive screen UI by adding a toggle for addresses

- receive tab finalized

[#1230] improve Receive screen UI by adding a toggle for addresses

- removed the forced dark mode

[#1230] improve Receive screen UI by adding a toggle for addresses

- changelog updated
2024-05-06 09:47:54 +02:00
Lukas Korba 02b479826e read-qr-code-from-image
- The ZashiImagePicker implemented that opens a library and reads an image from it
- QR code image detector implemented

read-qr-code-from-image

- QRImageDetector dependency implemented

read-qr-code-from-image

- Multiple codes detection + handling. For it's an error because more codes could result in wrong pick from user's point of view.

read-qr-code-from-image

- final design
2024-05-06 09:47:54 +02:00
Lukas Korba 156dde9678 hide-balances
- New dependency broadcasting value of hide balances flag implemented
- Every Zatoshi representation decides whether is rendered as number value or hidden, respects the font size and colour
- Flag value is persisted for next app start

hide-balances

- localization added

hide-balances

- changes according to the final design
2024-05-06 09:47:54 +02:00
Lukas Korba 1cb9ad1465 read-qr-code-from-image
- The ZashiImagePicker implemented that opens a library and reads an image from it
- QR code image detector implemented

read-qr-code-from-image

- QRImageDetector dependency implemented

read-qr-code-from-image

- Multiple codes detection + handling. For it's an error because more codes could result in wrong pick from user's point of view.

read-qr-code-from-image

- final design

[#1231] QR code from a photo saved in my library

- changelog updated
2024-05-06 09:45:14 +02:00
Lukas Korba aa024e95f6
Merge pull request #1245 from LukasKorba/dark-mode
[#1054] Enable Dark Mode
2024-05-06 09:41:11 +02:00
Lukas Korba 8e26014364 dark-mode
- WIP

dark-mode

- inverted QR code colours support

dark-mode

- Custom background color for TextEditor

dark-mode

- Buttons resolved

dark-mode

- Buttons consolidated with the Figma design
- Scan view fix for the back button
- Placeholders for the inputs custom color solution implemented

dark-mode

- Dark mode enabled, controlled by the system settings

dark-mode

- last few fixes, feature is ready

dark-mode

- finished buttons and all answered questions

dark-mode

- fixed issue with QR code being black in dark mode
- caching generated QR code

dark-mode

- fix for the message box shape

dark-mode

- changelog updated

[#1054] Enable dark mode

- dark mode finalized

[#1054] Enable dark mode

- commented code cleaned up
2024-05-04 07:54:52 +02:00
Lukas Korba 3f679d1aba
Merge pull request #1229 from LukasKorba/1228-I-have-saved-it-button-title-refactor
[#1228] I have saved it button title refactor
2024-04-30 10:44:16 +02:00
Lukas Korba 534d246006 [#1228] I have saved it button title refactor
- changelog updated
- the button's title has been refactored

[#1228] I have saved it button title refactor (#1229)

- exclamation mark removed
2024-04-30 10:38:41 +02:00
Lukas Korba bedf46bb61
Merge pull request #1227 from LukasKorba/1216-Release-1-0-6-4
[#1216] Release 1.0.6-4
2024-04-30 10:16:19 +02:00
Lukas Korba e0b371d947 [#1216] Release 1.0.6-4
- Changelog updated
- version bumped to 1.0.6 build 4
2024-04-30 10:07:29 +02:00
Lukas Korba 5deec082b9
Merge pull request #1226 from LukasKorba/1223-Fallback-missing-server-to-custom-field
[#1223] Fallback missing server to custom field
2024-04-30 10:04:11 +02:00
Lukas Korba eb83de4d8d [#1223] Fallback missing server to custom field
- The version1 has been completely refactored and redesigned
- The custom server and term now supports localisation
- The list of servers is now network dependent, different for testnet vs. mainnet
- The selected server is now represented as Hashable and Codable struct ServerConfig that holds the host, port and isCustom flag
- Migration of version1 implemented that ensures to persist previous choice of a user and fills it in a custom field
- The UI dynamically ensured the host & port are at one line, not split to multiline label
- The persistency of a choice is now handled by UserPreferencesStorage, a dependency designed for user settings
- Tests fixed

[#1223] Fallback missing server to custom field (#1226)

- Servers are newly represented as enums allowing customization of naming and localization
2024-04-30 10:03:50 +02:00
Lukas Korba e5f5cbf31f [#1221] Scroll to selected server
- Automatically scroll to the selected server so even the one at the bottom of the list that is not visible will be scrolled to the visual area.
2024-04-30 10:03:50 +02:00
Lukas Korba d43990a7b1
Merge pull request #1222 from LukasKorba/1221-Scroll-to-selected-server
[#1221] Scroll to selected server
2024-04-30 10:02:34 +02:00
Lukas Korba 3c6ca1bde2 [#1221] Scroll to selected server
- Automatically scroll to the selected server so even the one at the bottom of the list that is not visible will be scrolled to the visual area.

[#1221] Scroll to selected server (#1222)

- named constant
2024-04-30 10:02:18 +02:00
Lukas Korba 6e8db9feb8
Merge pull request #1225 from LukasKorba/1224-Bug-in-Create-a-New-Wallet-flow
[#1224] Bug in Create a New Wallet flow
2024-04-28 10:42:28 +02:00
Lukas Korba 2280e15a04 [#1224] Bug in Create a New Wallet flow
- The detection of pressed button needed to be extended to cover the case with SecurityWarning screen. I got it button is pressed in one of two possible scenarios and only one was handled.
2024-04-26 21:06:28 +02:00
Lukas Korba 17e5721ddc
Merge pull request #1219 from LukasKorba/1218-Add-zec-rocks-servers
[#1218] Add zec rocks servers
2024-04-26 13:25:28 +02:00
Lukas Korba 55efc372dc [#1218] Add zec rocks servers
- WIP

[#1218] Add zec rocks servers

- UI tweaked, servers tested
2024-04-26 13:17:59 +02:00
Lukas Korba e2ea411b2c [#1216] Release 1.0.6
- changelog updated
- version bumped to 1.0.6-1
2024-04-24 17:48:15 +02:00
Lukas Korba 9efb5ecd6d
Merge pull request #1215 from LukasKorba/1214-Add-more-servers-to-the-list
[#1214] Add more servers to the list
2024-04-24 17:45:26 +02:00
Lukas Korba 6abf3bac93 [#1214] Add more servers to the list
- 8 more servers added to the list
- order of servers changed to show default as 1st, custom as 2nd
2024-04-24 17:42:57 +02:00
Lukas Korba 5f08313c4b
Merge pull request #1212 from Chlup/1166_fix_archive_in_xcode_15_3
Fix Archive in Xcode 15.3
2024-04-22 14:37:12 +02:00
Lukas Korba e776584575
Merge pull request #1206 from LukasKorba/1205-Release-1-0-5-3
[#1205] Release 1.0.5-3
2024-04-22 14:26:10 +02:00
Lukas Korba c662157034
Merge branch 'main' into 1205-Release-1-0-5-3 2024-04-22 14:25:40 +02:00
Lukas Korba 7fbee0082b
Merge pull request #1211 from Electric-Coin-Company/true-jared-patch-1
Update to README.md
2024-04-22 08:33:26 +02:00
Michal Fousek ca35256417 Fix Archive in Xcode 15.3
Problem was in swift-custom-dump package. And it was fixed in this PR:
https://github.com/pointfreeco/swift-custom-dump/pull/108.
2024-04-20 10:03:51 +02:00
Andrea Kobrlova f77d154c08
Update README.md
Proposed update to the Zashi iOS repo description.
2024-04-19 16:21:01 +02:00
Lukas Korba 1645d00aad
Merge pull request #1210 from LukasKorba/1208-Release-1.0.5-4
[#1208] Release 1.0.5-4
2024-04-19 08:31:27 +02:00
Lukas Korba e4ec0ad6f5 [#1208] Release 1.0.5-4
- Changelog updated
2024-04-19 08:21:56 +02:00
Lukas Korba fd589ea959
Merge pull request #1209 from LukasKorba/1207-Pending-changes-are-broken
[#1207] Pending changes are broken
2024-04-19 08:20:10 +02:00
Lukas Korba 3b41b52dc1 [#1207] Pending changes are broken
- Pending values were removed with new WalletBalances component, I needed to restore those in order to work again.
2024-04-19 07:29:17 +02:00
Lukas Korba 9a3f7a4756 [#1205] Release 1.0.5-3
- Changelog updated
- SDK version bumped up
- Project settings for build 3 updated
2024-04-18 15:46:10 +02:00
Lukas Korba 0892676253
Merge pull request #1204 from LukasKorba/1199--Release-1-0-5
[#1199] Release 1.0.5
2024-04-17 15:49:56 +02:00
Lukas Korba 34db837127 [#1199] Release 1.0.5
- Changelog updated
- SDK version bumped to the latest version
2024-04-17 14:50:10 +02:00
Lukas Korba 52017ab435
Merge pull request #1203 from LukasKorba/1202-View-for-covering-Zashi-prevents-from-seeing-the-seed
[#1202] View for covering Zashi prevents from seeing the seed
2024-04-17 14:32:33 +02:00
Lukas Korba 6a8b0d5b50 [#1202] View for covering Zashi prevents from seeing the seed
- The cover view is now an overlay instead of a switch to a different view
- The animation of the overlay needed to be removed so it's processed until the app is suspended
- The cover is now processed for background notification only, inactive has been removed to never show during system overlays like face ID, etc.
2024-04-17 14:16:29 +02:00
Lukas Korba e5ec490421
Merge pull request #1198 from LukasKorba/1195-Transaction-History-remove-No-message-included-in-transaction-copy-from-expanded-transparent-
[#1195] Transaction History: remove No message included in transaction copy from expanded transparent
2024-04-16 16:38:32 +02:00
Lukas Korba 7bbfde8133 [#1195] Transaction History: remove No message included in transaction copy from expanded transparent
- The "no message in the transaction" is no longer rendered for transparent Recipients
2024-04-16 16:38:11 +02:00
Lukas Korba e883749f50
Merge pull request #1197 from LukasKorba/1193-Restore-update-the-copy-inside-the-input-field
[#1193] Restore: update the copy inside the input field
2024-04-16 16:36:37 +02:00
Lukas Korba e7bd2fd458
Merge pull request #1196 from LukasKorba/1194-Security-Warning-make-the-text-clickable-as-well-to-improve-usability
[#1194] Security warning make the text clickable as well to improve usability
2024-04-16 16:36:27 +02:00
Lukas Korba 16d3499c30 [#1193] Restore: update the copy inside the input field
- The input field for the recovery phrase now shows the expected format in the placeholder.
2024-04-16 08:57:45 +02:00
Lukas Korba cd0fba7665 [#1194] Security Warning: make the text clickable as well to improve usability
- New ZashiToggle created to handle tap on the label as well
- All 3 system Toggles replaced with new one
2024-04-16 08:51:43 +02:00
Lukas Korba c64e1ef21b
Merge pull request #1192 from LukasKorba/1191-Refactor-AdvancedSettingsReducer-to-latest-TCA
[#1191] Refactor AdvancedSettingsReducer to latest TCA
2024-04-16 08:50:40 +02:00
Lukas Korba d46d0a4f94 [#1191] Refactor AdvancedSettingsReducer to latest TCA
- The reducer has been refactored
- The Bindings have been refactored to not use deprecated API
- View has been refactored to not rely on ViewStore
- Dependency version have been bumped up in order to use latest TCA
2024-04-15 16:09:39 +02:00
Lukas Korba ecad037103
Merge pull request #1190 from LukasKorba/1189-Cleanup-of-unused-translations
[#1189] Cleanup of unused translations
2024-04-15 16:07:32 +02:00
Lukas Korba 3d6ed24dd4 [#1189] Cleanup of unused translations
- All unused texts have been removed from the project
- Tests checked and fixed (missing dependencies)
2024-04-15 14:00:39 +02:00
Lukas Korba 375def846b
Merge pull request #1188 from LukasKorba/1185-Syncing-frame-in-progress-view
[#1185] Syncing frame in progress view
2024-04-12 15:40:55 +02:00
Lukas Korba d295e10bb9
Merge pull request #1187 from LukasKorba/1186-Resolve-AppStore-warnings
[#1186] Resolve AppStore warnings
2024-04-12 15:40:26 +02:00
Lukas Korba 7b3d214531 [#1185] Syncing frame in progress view
- The syncing label's height has been unified so whatever state we render, the progress bar stays on the same position.
2024-04-12 15:33:15 +02:00
Lukas Korba c8454ccd9c [#1186] Resolve AppStore warnings
- One of the keys (for user defaults) has been wrongly named - fixed.

[#1186] Resolve AppStore warnings

- Fixed AppStore profile build-ability, the dependency in modules was missing
2024-04-12 15:16:16 +02:00
Lukas Korba 2ebf9fb9d7
Merge pull request #1183 from LukasKorba/1173--Persist-info-about-restore-until-it-is-done
[#1173] Persist info about restore until it is done
2024-04-09 12:35:51 +02:00
Lukas Korba efb05a5913
Merge pull request #1182 from LukasKorba/1181-No-and-some-transactions-at-the-same-time
[#1181] No and some transactions at the same time
2024-04-09 12:23:15 +02:00
Lukas Korba 52a2f6b0a9 [#1173] Persist info about restore until it is done
- The restoration of the wallet is persisted until it's done (up-to date/synced) at some point in the future
2024-04-09 12:22:18 +02:00
Lukas Korba ad1ba0f98f [#1181] No and some transactions at the same time
- The no transaction Text as well as ForEach are connected to the same property and view should re-render accordingly. On a theoretical level it might be possible the view re-rendered only a portion of itself. Adding else should hopefully cover even the theoretical/swiftui potential bug.
2024-04-09 12:21:01 +02:00
Lukas Korba ff5b6ce0ef
Merge pull request #1180 from LukasKorba/1179-Bold-token-name-in-available-balance
[#1179] Bold token name in available balance
2024-04-09 09:46:45 +02:00
Lukas Korba 1bc5d70e36 [#1179] Bold token name in available balance
- The ZEC token name is now aligned with the value (both bold)
2024-04-08 12:24:53 +02:00
Lukas Korba d8f70a64ee
Merge pull request #1176 from LukasKorba/1087--Total-and-available-balances-component
[#1087] Total and available balances component
2024-04-05 12:18:20 +02:00
Lukas Korba 6e054f5b52 [#1087] Total and available balances component
- The total and available balances have been extracted into separate and fully autonomous component used in 3 independent places (Account, Send and Balances)
- Code massively cleaned up
- Available balance underline logic + redirect to Balances

[#1087] Total and available balances component

- Unit tests fixes

[#1087] Total and available balances component

- tests fixed

[#1087] Total and available balances component

- small fixes and tweaks
2024-04-05 11:52:44 +02:00
Lukas Korba 3e68ed8e33
Merge pull request #1175 from LukasKorba/1174-Final-not-enough-free-space-UI
[#1174] Final not enough free space UI
2024-04-04 13:33:08 +02:00
Lukas Korba f73b6dc9e1 [#1174] Final not enough free space UI
- The UI has been updated according to the latest design

[#1174] Final not enough free space UI (#1175)

- tweaks

[#1174] Final not enough free space UI (#1175)

- removed mocked state of disk
2024-04-04 13:13:22 +02:00
Lukas Korba 215e745522
Merge pull request #1170 from LukasKorba/1029--Not-enough-free-space-UI
[#1029] Not enough free space UI
2024-04-04 10:16:14 +02:00
Lukas Korba ccb5b2936c
Merge pull request #1172 from LukasKorba/1171-Hide-content-in-the-app-switcher
[#1171] Hide content in the app switcher
2024-04-04 10:15:53 +02:00
Lukas Korba 9e4b27e585
Merge pull request #1169 from LukasKorba/1108-Enhance-scan-UI
[#1108] Enhance scan UI
2024-04-04 10:15:42 +02:00
Lukas Korba e235a84528 [#1171] Hide content in the app switcher
- The Zashi hides its content when it's going to the background and reveals it when it's going to the foreground

[#1171] Hide content in the app switcher (#1172)

- changelog update
2024-04-04 10:13:09 +02:00
Lukas Korba 88f91380eb [#1029] Not enough free space UI
- The UI has been updated to the latest design
- The values of disc space are provided
- The business logic has changed to react to check every app start or app foreground
- Test has been fixed

[#1029] Not enough free space UI

- Final copy

[#1029] Not enough free space UI (#1170)

- changelog updated
2024-04-04 07:54:57 +02:00
Lukas Korba 23379c069c [#1108] Enhance scan UI
- The open settings button added and regular back button used in such case
2024-04-03 15:04:43 +02:00
Lukas Korba 9decc16ffa
Merge pull request #1168 from LukasKorba/1167-Autofocus-birthday-field-in-restore-flow
[#1167] Autofocus birthday field in restore flow
2024-04-03 13:09:21 +02:00
Lukas Korba 2755f3c2c0 [#1167] Autofocus birthday field in restore flow
- the BD field is automatically focused
2024-04-03 08:15:53 +02:00
Lukas Korba 93b44b0b7f
Merge pull request #1163 from LukasKorba/1162--Release-1-0-4-2
[#1162] Release 1.0.4-2
2024-03-29 12:54:35 +01:00
Lukas Korba 936f461740 [#1162] Release 1.0.4-2
- Build number bumped
2024-03-29 12:33:03 +01:00
Lukas Korba cbb842c6f3
Merge pull request #1161 from LukasKorba/1160-Tweaks-and-fixes-for-Zashi-1-0-3
[#1160] Tweaks and fixes for zashi 1.0.3
2024-03-29 12:30:08 +01:00
Lukas Korba a8847abae6 [#1160] Tweaks and fixes for Zashi 1.0.3
- Fixes for the transparent funds

[#1160] Tweaks and fixes for Zashi 1.0.3

- Changelog updated
- Tests fixed

[#1160] Tweaks and fixes for Zashi 1.0.3

- shielded + pending balance
2024-03-29 12:27:43 +01:00
Lukas Korba be00165d3b [#1160] Tweaks and fixes for Zashi 1.0.3
- Fix for the #1119
2024-03-29 11:49:27 +01:00
Lukas Korba d50a576f82 [#1160] Tweaks and fixes for Zashi 1.0.3
- Tap to Copy memo added
2024-03-29 11:43:09 +01:00
Lukas Korba 31db61df25
Merge pull request #1159 from LukasKorba/1158-Release-1-0-4
[#1158] Release 1.0.4
2024-03-28 16:20:01 +01:00
Lukas Korba 10399c9c6c [#1158] Release 1.0.4
- Changelog updated
- SDK version bump
2024-03-28 16:17:42 +01:00
Lukas Korba 5b45efa0fd
Merge pull request #1157 from LukasKorba/1156-Release-1-0-3
[#1156] Release 1.0.3
2024-03-27 23:30:20 +01:00
Lukas Korba eeb9a57254 [#1156] Release 1.0.3
- fix for a bug in note selection when sending to a transparent recipient
2024-03-27 23:24:54 +01:00
Lukas Korba cdca45f10c
Merge pull request #1155 from LukasKorba/1154-Release-1.0.2
[#1154] Release 1.0.2
2024-03-27 17:02:58 +01:00
Lukas Korba 0bb356f6b3 [#1154] Release 1.0.2
- SDK version bump
- Changelog updated
2024-03-27 16:52:02 +01:00
Lukas Korba a1fd4097c7
Merge pull request #1153 from LukasKorba/1036-Wipe-wallet-in-advanced-settings
[#1036] Wipe wallet in advanced settings
2024-03-27 16:32:03 +01:00
Lukas Korba da3687b9d1 [#1036] Wipe wallet in advanced settings
- Wipe wallet feature integrated into advanced settings
2024-03-27 16:20:56 +01:00
Lukas Korba ecc65f9a83
Merge pull request #1152 from LukasKorba/986-Release-Zashi-iOS-version-1-0
[#986] Release Zashi iOS version 1.0
2024-03-26 18:50:42 +01:00
Lukas Korba 6e6245dd64 [#986] Release Zashi iOS version 1.0
- changelog updated
- code cleanup
2024-03-26 18:44:32 +01:00
Lukas Korba 98ff1d4043
Merge pull request #1151 from LukasKorba/1024--KeysMissing-when-restored-to-a-new-iPhone
[#1024] KeysMissing when restored to a new iPhone
2024-03-26 18:38:59 +01:00
Lukas Korba 3e6afc69a8 [#1024] KeysMissing when restored to a new iPhone
- validation flow done for the 2 out of 3 flows
- 1. when the restore path is selected and the seed doesn't match the DB
- 2. when create new wallet is selected
- (missing) 3. seed is validated (waiting on API)

[#1024] KeysMissing when restored to a new iPhone

- preparations for SDK 2.1.0

[#1024] KeysMissing when restored to a new iPhone

- Seed validation API used and integrated
- There's an error in rust that must be resolved first

[#1024] KeysMissing when restored to a new iPhone

- rebased

[#1024] KeysMissing when restored to a new iPhone

- updated to use latest SDK's isSeedRelevantToAnyDerivedAccount

[#1024] KeysMissing when restored to a new iPhone

- unstable SDK branch test

[#1024] KeysMissing when restored to a new iPhone

- version bump

[#1024] KeysMissing when restored to a new iPhone

- bugfix
- packae redirected to ECCs repo

[#1024] KeysMissing when restored to a new iPhone

- tests fixed
2024-03-26 18:24:49 +01:00
Lukas Korba 2e51a9d839
Merge pull request #1150 from LukasKorba/1149--Include-rust-error-desc-in-the-alert-view
[#1149] Include rust error desc in the alert view
2024-03-26 08:29:02 +01:00
Lukas Korba 5d3fcdd094 [#1149] Include rust error desc in the alert view
- The alert views now show more detailed info about the error. Code + message + rust/service error info
- Unit tests fixed
2024-03-24 11:20:54 +01:00
Lukas Korba b269c9210e
Merge pull request #1148 from LukasKorba/1147-Handle-nil-transaction-fees
[#1147] Handle nil transaction fees
2024-03-23 14:16:57 +01:00
Lukas Korba 31d455f0ac [#1147] Handle nil transaction fees
- The transactions with nil fees show Typical Fee < 0.001
- When the fee is available, the value is used
- Tests fixed
2024-03-22 14:50:19 +01:00
Lukas Korba e20038c573
Merge pull request #1145 from LukasKorba/ProposalAPI-comments
ProposalAPI-comments
2024-03-20 13:10:52 +01:00
Lukas Korba bcca5eff08 ProposalAPI-comments
- comments addressed
2024-03-20 13:06:32 +01:00
Lukas Korba 66a8e670cd
Merge pull request #1117 from LukasKorba/1092-Adopt-proposal-API
[#1092] Adopt proposal API
2024-03-20 13:04:33 +01:00
Lukas Korba 28a88a9a1e [#1092] Adopt proposal API
- TCA sdkSYnchronizer dependency extended with 3 new Proposal APIs
- proposeTransfer tested, works as expected

[#1092] Adopt proposal API

- send transaction via new proposal API implemented

[#1092] Adopt proposal API

- code cleaned up and finished

[#1092] Adopt proposal API

- unit tests fixed

[#1092] Adopt proposal API

- Typical Fee < 0.001 localized and updated in the UI

[#1092] Adopt proposal API

- awaiting all transaction results with use of new proposal.transactionCount() method

[#1092] Adopt proposal API

- Implemented new PartialProposalError reducer and view
- Contact support mail with transaction IDs logic implemented
- Fallback to share logic implemented
- PPE integrated into SendFlow
- PPE integrated into Shielding

[#1092] Adopt proposal API

- Changelog updated

[#1092] Adopt proposal API

- SDK's fee constant removed

[#1092] Adopt proposal API (#1117)

- debug code reverted

[#1092] Adopt proposal API (#1117)

- copy change

[#1092] Adopt proposal API (#1117)

- code cleanup

[#1092] Adopt proposal API (#1117)

- proposed total fee

[#1092] Adopt proposal API (#1117)

- Final copy

[#1092] Adopt proposal API (#1117)

- Transaction statuses added

[#1092] Adopt proposal API (#1117)

- tests fixed
2024-03-20 09:51:29 +01:00
Lukas Korba d3adf88b3f
Merge pull request #1144 from LukasKorba/1140-Disable-send-and-back-buttons
[#1140] Disable send and back buttons
2024-03-18 16:32:12 +01:00
Lukas Korba 0bfc256488
Merge pull request #1143 from LukasKorba/1141-Empty-list-of-transactions
[#1141] Bugfix batch
2024-03-18 16:22:39 +01:00
Lukas Korba ad05fdb17e [#1140] Disable send and back buttons
- send & back buttons disabled when request is in progress
2024-03-18 14:25:04 +01:00
Lukas Korba 5948947288 [#1141] Bugfix batch
- The no transactions list has been disabled to not scroll
- The sync bar % was canceled on Balanced before it could gather data, the problem is about cancelation IDs not being unique, I updated all effect handles to be UUIDs
- Balances tab was rendering spendable balance instead of total balance
2024-03-18 14:02:02 +01:00
Lukas Korba 1a6f458834
Merge pull request #1138 from LukasKorba/1135-Keyboard-toolbars
[#1135] Keyboard toolbars
2024-03-18 12:28:42 +01:00
Lukas Korba 14920b0ea9 [#1135] Keyboard toolbars
- The white blank area above the keyboard has been fixed

[#1135] Keyboard toolbars

- Changelog updated
2024-03-18 12:28:17 +01:00
Lukas Korba 111e16fe31
Merge pull request #1130 from LukasKorba/1129-Call-configureCrashReporter-only-when-didFinishLaunching
[#1129] Call configureCrashReporter only when didFinishLaunching
2024-03-18 08:17:13 +01:00
Lukas Korba f7b6d78d42
Merge pull request #1134 from LukasKorba/1133-Define-NSPrivacyAccessedAPITypes
[#1133] Define NSPrivacyAccessedAPITypes
2024-03-15 12:45:47 +01:00
Lukas Korba 7939015132
Merge pull request #1137 from LukasKorba/1136-Fix-flaky-tests
[#1136] Fix flaky tests
2024-03-14 12:55:59 +01:00
Lukas Korba c525105f59 [#1136] Fix flaky tests
- All false positive tests have been resolved. Flakiness of the tests has been fixed by providing unimplemented dependencies to the right Stores.
2024-03-14 12:52:58 +01:00
Lukas Korba 36013ce69b [#1133] Define NSPrivacyAccessedAPITypes
- I set the required keys & hopefully the right values according to doc (https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_use_of_required_reason_api#4278401)

[#1133] Define NSPrivacyAccessedAPITypes

- Changelog updated
2024-03-14 08:15:59 +01:00
Lukas Korba 1886b5fc47
Merge pull request #1132 from LukasKorba/1131-Remove-swipe-gesture-between-tabs
[#1131] Remove swipe gesture between tabs
2024-03-14 08:09:03 +01:00
Lukas Korba ee83a5afe9 [#1131] Remove swipe gesture between tabs
- The page style of the tab view removed, this way the gesture is no longer available.
2024-03-13 18:47:39 +01:00
Lukas Korba 1bc7f3ca59 [#1129] Call configureCrashReporter only when didFinishLaunching
- I moved the configuration of Firebase to the didFinishLaunching, this way the FB is configured only once at the start of the app, not causing crashes or issues of type 'FB is already configured'
- tests fixed
2024-03-13 18:39:48 +01:00
Lukas Korba 749dd7f5a8
Merge pull request #1128 from LukasKorba/1126-Release-0-3-0
[#1126] Release 1.0-3
2024-03-13 18:35:38 +01:00
Lukas Korba 22153c97a1 [#1126] Release 0.3.0
- Changelog updated

[#1126] Release 0.3.0

- Version updated to 0.3.0 build 1

[#1126] Release 0.3.0

- The release needed to be increased to 1.0 build 3 because we already uploaded 1.0 build 2 in the past

Update CHANGELOG.md

Co-Authored-By: Honza Rychnovský <rychnovsky.honza@gmail.com>
2024-03-13 18:35:14 +01:00
Lukas Korba c848e5f48c
Merge pull request #1127 from LukasKorba/1111-Automatic-dSYM-upload
[#1111] Automatic dSYM upload
2024-03-13 13:03:46 +01:00
Lukas Korba 14093cd3ea [#1111] Automatic dSYM upload
- New target for Testflight & AppStore builds has been created
- Automatic dSYM upload run script added to the configuration of the target
- DebugMenu is no longer accessible in production builds, only Testflight builds
2024-03-13 12:19:52 +01:00
Lukas Korba 0819cb6f92
Merge pull request #1114 from LukasKorba/1097-Zashi-iOS-audit-Issue-E
[#1097] Zashi-iOS audit Issue E
2024-03-13 11:35:15 +01:00
Lukas Korba 5260ac7809
Merge pull request #1107 from LukasKorba/1106-Zashi-iOS-audit-Issue-G
[#1106] Zashi-iOS audit Issue G
2024-03-13 11:35:05 +01:00
Lukas Korba 9961058da4
Merge pull request #1112 from LukasKorba/940--Set-final-privacy-policy-URL-for-iOS
[#940] Set final privacy policy URL for iOS
2024-03-13 11:34:54 +01:00
Lukas Korba 42a8cd8184
Merge pull request #1115 from LukasKorba/1103-Remove-pull-to-refresh
[#1103] Remove pull to refresh
2024-03-13 11:34:43 +01:00
Lukas Korba b1b3619db6
Merge pull request #1116 from LukasKorba/863-Phrase-screen-trails-seed-on-iPhone-SE
[#863] Phrase screen trails seed on iPhone SE
2024-03-13 11:34:32 +01:00
Lukas Korba b3c0198d28
Merge pull request #1118 from LukasKorba/1100-Insufficient-funds-when-syncing-and-enabled-Review-button
[#1100] Insufficient funds when syncing and enabled Review button
2024-03-13 11:34:20 +01:00
Lukas Korba 4a634dec7e
Merge pull request #1122 from LukasKorba/1121-Hint-box-text-update
[#1121] Hint box text update
2024-03-13 11:34:08 +01:00
Lukas Korba e1125cf29b
Merge pull request #1123 from LukasKorba/1110-No-transactions-fetched-at-start
[#1110] No transactions fetched at start
2024-03-13 11:33:54 +01:00
Lukas Korba dd51b758a8
Merge pull request #1125 from LukasKorba/1124-Line-above-tab-bar
[#1124] Line above tab bar
2024-03-13 11:33:40 +01:00
Lukas Korba a25bdbb55c [#1124] Line above tab bar
- The line has been added to all tabs excluding Account
2024-03-13 07:59:14 +01:00
Lukas Korba ef460b7b42 [#1110] No transactions fetched at start
- UI updated to handle case when no transactions are available
2024-03-13 07:43:05 +01:00
Lukas Korba 55950c07e5 [#1121] Hint box text update
- text updated

[#1121] Hint box text update

- generated file updated
2024-03-13 07:25:15 +01:00
Lukas Korba 2632c8aad4 [#1100] Insufficient funds when syncing and enabled Review button
- the boolean helpers updated to address some specific states
2024-03-12 08:36:05 +01:00
Lukas Korba 9b08395bf8 [#863] Phrase screen trails seed on iPhone SE
- The issue has been solved with setting the fixedSize() modifier. That one ensures the word is never truncated. I tested the seed words on iPhone SE and it fits the screen even when I repeat the words three times, e.g. "humanhumanhuman". It works well.
2024-03-08 14:09:41 +01:00
Lukas Korba 609158023e [#1103] Remove pull to refresh
- Pull to refresh feature has never been required or designed by Product or Leadership, it was a temporary thing that helped during the development but has been completely replaced with reactive approach over the time.
2024-03-08 13:43:25 +01:00
Lukas Korba e8822d21c9
Merge pull request #1105 from LukasKorba/1093-Zashi-iOS-audit-Issue-B
[#1093] Zashi-iOS audit Issue B
2024-03-08 13:37:28 +01:00
Lukas Korba abb8dcea29 [#1093] Zashi-iOS audit Issue B
- The URL scheme has been removed entirely from the project

[#1093] Zashi-iOS audit Issue B (#1105)

- removed from testnet target
2024-03-08 13:37:16 +01:00
Lukas Korba 746b6859a7 [#1097] Zashi-iOS audit Issue E
- copy with expiry time set draft

[#1097] Zashi-iOS audit Issue E

- copy to pasteboard has been removed from recovery phrase seed completely
- copy seed to pasteboard added to the debug menu, please note, the debug menu will not be in production build, issue #1113
2024-03-08 13:31:55 +01:00
Lukas Korba 22fab58852 [#940] Set final privacy policy URL for iOS
- new URL used
2024-03-08 13:09:55 +01:00
Lukas Korba b5a71c7bed [#1106] Zashi-iOS audit Issue G
- storedWallet is no longer held in memory
- unit tests fixed
2024-03-06 16:12:23 +01:00
Lukas Korba 6970b6ff60
Merge pull request #1091 from LukasKorba/1086-Resolve-interaction-with-the-keychain-for-both-fore-and-background-app-states
[#1086] Resolve interaction with the keychain for both fore and background app states
2024-03-04 13:42:19 +01:00
Lukas Korba 557cae3552 [#1086] Resolve interaction with the keychain for both fore and background app states
- draft

[#1086] Resolve interaction with the keychain for both fore and background app states

- revert

[#1086] Resolve interaction with the keychain for both fore and background app states

- initialization pipeline updated to handle state when BGTask runs with fresh app start, in such case Zashi wait and doesn't try to initialize SDK -> no keychain error is triggered

[#1086] Resolve interaction with the keychain for both fore and background app states

- code cleaned up
- finished the state handling
- closing the BGTask asap for state that is supposed to just wait

[#1086] Resolve interaction with the keychain for both fore and background app states

- unit tests fixed

[#1086] Resolve interaction with the keychain for both fore and background app states (#1091)

- Comments addressed

[#1086] Resolve interaction with the keychain for both fore and background app states (#1091)

- Unit tests fixed
- Block time of didFinishLaunching increased to 0.5s (from 0.02)
2024-03-03 10:09:16 +01:00
Lukas Korba 487abbd9bf
Merge pull request #1089 from LukasKorba/931-Statuses-of-the-sync-process-dependency
[#931] Statuses of the sync process dependency
2024-03-02 18:03:00 +01:00
Lukas Korba 2ba8f26d0a
Merge pull request #1088 from LukasKorba/1055-Handle-unavailable-AccountBalance
[#1055] Handle unavailable AccountBalance
2024-02-29 08:11:53 +01:00
Lukas Korba 99e1b12e7d [#931] Statuses of the sync process dependency
- Statuses updated according to the product/design requirements.
2024-02-27 12:56:06 +01:00
Lukas Korba 21b01fca7d [#1055] Handle unavailable AccountBalance
- The available balance 0 scenario is now handled on a product/design level and the 0 is replaced with a progress view.
- There is some redundancy in the code that is going to be resolved in #1087 because it will require to implement a brand new reducer and stream subscriber, out of the scope of this issue.

[#1055] Handle unavailable AccountBalance

- Changelog updated.

[#1055] Handle unavailable AccountBalance (#1088)

- rebased
2024-02-27 12:54:39 +01:00
Lukas Korba ecc8ec9c1d
Merge pull request #1078 from LukasKorba/1051-Crashlytics-acknowledge
[#1051] Crashlytics acknowledge
2024-02-27 12:52:38 +01:00
Lukas Korba 6b94e1a8f6 [#1051] Crashlytics acknowledge (#1078)
- comments addressed

[#1051] Crashlytics acknowledge (#1078)

- documented what boolean values represents
2024-02-27 12:52:11 +01:00
Lukas Korba 45d7241d33
Merge pull request #1085 from LukasKorba/1082-New-shielding-explanation-copy
[#1082] New shielding explanation copy
2024-02-27 12:48:57 +01:00
Lukas Korba f1c7df7768 [#1082] New shielding explanation copy (#1085)
- generated file updated
2024-02-27 12:46:40 +01:00
Lukas Korba 6c83487da4
Update modules/Sources/Generated/Resources/Localizable.strings
Co-authored-by: Kris Nuttycombe <kris@nutty.land>
2024-02-27 12:43:42 +01:00
Lukas Korba 97dc8eea80
Merge pull request #1083 from LukasKorba/1080-Send-amount-enhancements
[#1080] Send amount enhancements
2024-02-25 09:23:20 +01:00
Lukas Korba 18ee995a42
Merge pull request #1084 from LukasKorba/940-Set-final-privacy-policy-URL-for-iOS
[#940] Set final privacy policy URL for iOS
2024-02-23 12:31:31 +01:00
Lukas Korba a83dfa73f7 [#1082] New shielding explanation copy
- Message for the transparent hint box updated
2024-02-22 14:05:22 +01:00
Lukas Korba ab10520492 [#940] Set final privacy policy URL for iOS
- link updated
2024-02-22 13:58:05 +01:00
Lukas Korba a0a17c6d49 [#1080] Send fields enhancements
- All bullet points from the parent ticket have been resolved
- The keyboard is not decimal one so users don't need to switch to numbers + it reduces cases when users fill in some alphabetical letters + it improved the UX with floating point comma vs. point
- Error handling fixed
- Max amount fix and rely on spendable balance
- Unit tests fixed
2024-02-22 13:47:15 +01:00
Lukas Korba c9f1e85c1f [#1060] Memo field behaviours for transparent address
- MessageEditor updated to present disabled state in a different way
- Text in the memo is not persisted when the transparent address is used and MessageBox disabled
- New unit tests implemented and many more updated

[#1060] Memo field behaviours for transparent address (#1075)

- comments addressed

[#1060] Memo field behaviours for transparent address (#1075)

- debug code removed

[#1060] Memo field behaviours for transparent address (#1075)

- code revert
2024-02-22 13:46:23 +01:00
Lukas Korba 25197b1dc6 Update modules/Sources/Generated/L10n.swift
Co-authored-by: str4d <thestr4d@gmail.com>
2024-02-22 10:04:57 +01:00
Lukas Korba ff5cc09941 [#1051] Crashlytics acknowledge
- Layout changes for the Security warning consent
- The screen has also been refactored to the latest TCA
- Unit tests fixed
2024-02-22 10:04:57 +01:00
Lukas Korba 039af8c863
Merge pull request #1069 from LukasKorba/988-Scan-UI
[#988] Scan UI
2024-02-22 09:04:10 +01:00
Lukas Korba 6b6c586f01 [#988] Scan UI (#1069)
- comments addressed
2024-02-22 09:03:42 +01:00
Lukas Korba 774f5d294d Update modules/Sources/Features/Scan/ScanStore.swift
Co-authored-by: Daira-Emma Hopwood <daira@jacaranda.org>
2024-02-22 09:03:42 +01:00
Lukas Korba 5a96727b01 [#988] Scan UI
- new layout for the scan screen

[#988] Scan UI

- new layout and design for scan
- camera not authorized case + UI
- scan store refactored to the latest TCA
- unit test fixed

[#988] Scan UI (#1069)

- changelog update
2024-02-22 09:03:42 +01:00
Lukas Korba 32b7afb867
Merge pull request #1077 from LukasKorba/1037-Consolidate-back-button-on-the-phrase-display-screen
[#1037] Consolidate back button on the phrase display screen
2024-02-22 08:53:51 +01:00
Lukas Korba ef64496739 [#1037] Consolidate back button on the phrase display screen
- ZashiBackModifier updated with a new hidden param. This way it can be controlled by views for dynamic scenarios.
- Reducer updated to latest TCA.
- Unit tests refactored and fixed.

[#1037] Consolidate back button on the phrase display screen

- updated test
2024-02-20 15:25:03 +01:00
Lukas Korba 21cb72dfc9
Merge pull request #1065 from LukasKorba/1056-Redactable-AccountBalance
[#1056] Redactable AccountBalance
2024-02-20 12:10:51 +01:00
Lukas Korba e494744fcc
Merge pull request #1072 from LukasKorba/1067-Disable-logging-for-production
[#1067] Disable logging for production
2024-02-20 12:08:52 +01:00
Lukas Korba 3460cf6f58 [#1067] Disable logging for production
- There are 3 different and independent loggers that have been disabled for production (release configuration builds)
- The TCA logger doesn't call os_log()
- The SDK is instantiated with .noLogging policy
- The Wallet logger is never set so it's nil
- With no logs the export logs button in Export Private Data screen no longer makes sense so I removed it from the UI

[#1067] Disable logging for production (#1072)

- project reverted back
2024-02-20 12:06:30 +01:00
Lukas Korba 06cc8ed1c1
Merge pull request #1073 from LukasKorba/1068--False-positive-keysMissing-detection
[#1068] False positive keysMissing detection
2024-02-20 12:03:31 +01:00
Lukas Korba 6b783cbbe5
Merge pull request #1074 from LukasKorba/1070-No-email-account-in-iPhone-error-handling
[#1070] No email account in iPhone error handling
2024-02-20 12:03:07 +01:00
Lukas Korba 5afe5fb1dd [#1070] No email account in iPhone error handling
- Alert view message updated
- Copy support email button added to the alert view
- Unit test for the new functionality added

[#1070] No email account in iPhone error handling (#1074)

- empty row comment addressed
2024-02-20 12:02:38 +01:00
Lukas Korba 9d7d9badb6 [#1068] False positive keysMissing detection
- Change of the setup of the keychain massively reduces the probability and frequency of cases when the keychain is required to provide data. Background task for the sync was the main producer of these attempts to read the data, the new flag allows BGTask to operate freely with no errors related to the keychain. Ultimate solution how to make it even better is covered in #1071, TODO added to the code.
2024-02-19 14:04:42 +01:00
Lukas Korba 33b94b517d
Merge pull request #1066 from LukasKorba/1053-Improve-successful-restore-message
[#1053] Improve successful restore message
2024-02-16 08:49:39 +01:00
Lukas Korba 4639e4fc84 [#1053] Improve successful restore message
- text has been updated
2024-02-15 13:13:29 +01:00
Lukas Korba 21412a356b [#1056] Redactable AccountBalance
- AccountBalance has been wrapped into RedactableAccountBalance
- SynchronizerState has been wrapped into RedactableSynchronizerState
- Code updated to use these new redactable structs instead of direct use of unredacted ones
- tests fixed
2024-02-15 12:42:11 +01:00
Lukas Korba 10eb66f1a2
Merge pull request #1061 from LukasKorba/1058-Cleanup-dependency-injection-in-reducers
[#1058] Cleanup dependency injection in reducers
2024-02-14 19:33:20 +01:00
Lukas Korba 9b683651cf [#1058] Cleanup dependency injection in reducers
- All work here is just cleanup of obsolete dependency injection. #981 introduced a brand new approach of DI for token name and SDK constants. That allowed me to deliver expected values directly in the TCA fashion so all reducers no longer needed those values to be passed via initializers.
2024-02-14 14:42:01 +01:00
Lukas Korba 48536e5fa0
Merge pull request #1059 from LukasKorba/981--Send-button-disable-check-must-include-the-fee
[#981] Send button disable check must include the fee
2024-02-14 14:39:27 +01:00
Lukas Korba 0faa37c243 [#981] Send button disable check must include the fee
- the fee is now checked and it's coming from the SDK
- unit test checking validity of the form when not enough Zatoshi for the fee has been implemented
- brand new concept of handling the SDK constants inside the TCA has been implemented, will greatly simplify cleanup of all reducers (see #1058)
2024-02-14 12:44:42 +01:00
Lukas Korba b668b15f04
Merge pull request #1048 from LukasKorba/975-Localize-the-balances
[#975] Localize the balances
2024-02-14 12:02:24 +01:00
Lukas Korba 783ed20c20 [#975] Localize the balances
- The Zatoshi decimals have been localized with respect to floating point style
- unit tests fixed + new set of comma tests implemented

[#975] Localize the balances (#1048)

- pre-rebase

[#975] Localize the balances (#1048)

- "<" localized

[#975] Localize the balances (#1048)

- rebased
2024-02-14 11:30:47 +01:00
Lukas Korba 82fd0e043f
Merge pull request #1047 from LukasKorba/1032-Advanced-settings
[#1032] Advanced settings
2024-02-14 11:16:20 +01:00
Lukas Korba 8498cff744 [#1032] Advanced settings
- all buttons moved to appropriate positions and screens
- business logic rewired
- all new texts localized
- changelog updated

[#1032] Advanced settings

- unit tests fixed

[#1032] Advanced settings (#1047)

- separate reducer for advanced settings
2024-02-14 11:12:51 +01:00
Lukas Korba 5d078035f4 [#1028] Runtime switch of lightwalletd servers
- prototype of the solution implemented

[#1028] Runtime switch of lightwalletd servers

- error handling done
- localized all new texts
- custom server resolved with all possible parsing states
- persistency of selected server done

[#1028] Runtime switch of lightwalletd servers (#1044)

- changelog update

[#1028] Runtime switch of lightwalletd servers (#1044)

- Unfortunately the compiler has a bug so Circular reference error is not possible to solve, Apple fixed reported issue from October 2023 last week so we should expect fix in Xcode 15.3, beta is released but still no fix. Until that moment I moved placeholders to the view and will move it back to the stores once the issue is resolved
2024-02-14 11:12:51 +01:00
Lukas Korba 8372df6f1e [#1028] Runtime switch of lightwalletd servers
- prototype of the solution implemented

[#1028] Runtime switch of lightwalletd servers

- error handling done
- localized all new texts
- custom server resolved with all possible parsing states
- persistency of selected server done

[#1028] Runtime switch of lightwalletd servers (#1044)

- changelog update

[#1028] Runtime switch of lightwalletd servers (#1044)

- Unfortunately the compiler has a bug so Circular reference error is not possible to solve, Apple fixed reported issue from October 2023 last week so we should expect fix in Xcode 15.3, beta is released but still no fix. Until that moment I moved placeholders to the view and will move it back to the stores once the issue is resolved

[#1028] Runtime switch of lightwalletd servers (#1044)

- adoption of SDK 2.0.10
2024-02-14 11:12:51 +01:00
Lukas Korba 924e318be3
Merge pull request #1044 from LukasKorba/1028-Runtime-switch-of-lightwalletd-servers
[#1028] Runtime switch of lightwalletd servers
2024-02-14 11:11:00 +01:00
Lukas Korba ec6e082938 [#1028] Runtime switch of lightwalletd servers
- prototype of the solution implemented

[#1028] Runtime switch of lightwalletd servers

- error handling done
- localized all new texts
- custom server resolved with all possible parsing states
- persistency of selected server done

[#1028] Runtime switch of lightwalletd servers (#1044)

- changelog update

[#1028] Runtime switch of lightwalletd servers (#1044)

- Unfortunately the compiler has a bug so Circular reference error is not possible to solve, Apple fixed reported issue from October 2023 last week so we should expect fix in Xcode 15.3, beta is released but still no fix. Until that moment I moved placeholders to the view and will move it back to the stores once the issue is resolved

[#1028] Runtime switch of lightwalletd servers (#1044)

- adoption of SDK 2.0.10

[#1028] Runtime switch of lightwalletd servers (#1044)

- comments addressed
2024-02-14 11:10:31 +01:00
Lukas Korba f7f5bcfedd
Merge pull request #1041 from LukasKorba/1035-Align-balances-vertically-on-Balances-tab
[#1035] Align balances vertically on Balances tab
2024-02-10 09:09:20 +01:00
Lukas Korba 0919584b81 [#1035] Align balances vertically on Balances tab
- balances aligned for all formats possible
2024-02-08 14:38:40 +01:00
Lukas Korba 9aa28d39b8
Merge pull request #1026 from LukasKorba/1007-Missing-seed-screen-lacks-any-back-button
[#1007] Missing seed screen lacks any back button
2024-02-08 10:30:36 +01:00
Lukas Korba 70631cc995 [#1007] Missing seed screen lacks any back button
- Exit button from the screen moved one layer up to show even when no words are stored

[#1007] Missing seed screen lacks any back button

- changelog updated
2024-02-06 08:57:02 +01:00
Lukas Korba 79648f59af
Merge pull request #1025 from LukasKorba/1022-Restore-UI-not-activated-when-app-is-deleted-and-reinstalled
[#1022] Restore UI not activated when app is deleted and reinstalled
2024-02-06 08:47:48 +01:00
Lukas Korba 1f39ce2423 [#1022] Restore UI not activated when app is deleted and reinstalled
- Restore mode in the UI was missing when Zashi was deleted from an iPhone and reinstalled again.
- Syncing bar in the restore mode bottom padding.
2024-02-05 17:02:26 +01:00
Lukas Korba a64815c178
Merge pull request #1020 from LukasKorba/1019-Extract-sort-logic-into-a-function
[#1019] Extract sort logic into a function
2024-02-02 06:04:25 -08:00
Lukas Korba 05364dc3c3 [#1019] Extract sort logic into a function
- reduced duplication of the code by extracting the logic into the transaction itself
2024-02-02 14:57:51 +01:00
Lukas Korba 760243581f
Merge pull request #1018 from LukasKorba/932-Pending-balances
[#932] Pending balances
2024-02-01 18:05:13 -08:00
Lukas Korba f546c9d8f5 [#932] Pending balances
- adopted new SDK with the AccountBalance values
- unit tests refactored
- use of SynchronizerState refactored
- failed transactions sort changed to put failed around the timestamp it failed (expiredHeight used)

[#932] Pending balances

- SDK version bump

[#932] Pending balances

- changelog updated

[#932] Pending balances

- addressed comments for the sort

[#932] Pending balances (#1018)

- unit tests fixed
- sort updated
2024-02-01 17:50:54 -08:00
Lukas Korba f0c4759e0c
Merge pull request #1016 from Electric-Coin-Company/release-0.2.0-15
Release version 0.2.0 build 15
2024-01-31 17:31:58 -08:00
Kris Nuttycombe 06355da1b4 Release version 0.2.0 build 15 2024-01-31 09:05:12 -08:00
Lukas Korba cef25b79cf
[#1014] Adopt SDK 2.0.8 (#1015)
- changelog updated
- SDK version bumped with shielding fix
2024-01-31 08:56:48 -08:00
Kris Nuttycombe 54fdc0cd9e
Release version 0.2.0 build 14 (#1011) 2024-01-30 11:46:28 -08:00
Lukas Korba 4231fd321a
[#1005] Adopt SDK 2.0.7 (#1010)
- SDK version bumped up, 2.0.7 has brought some rust performance optimizations
- changelog updated
2024-01-30 09:57:19 -08:00
Kris Nuttycombe f1a63e37f1
Update dependencies for release 0.2.0 build 13 (#1004)
Zashi bumped to build 13
2024-01-28 20:46:09 -08:00
Lukas Korba 6f03d91bc3
[#1002] Adopt SDK 2.0.6 (#1003)
- SDK updated to the 2.0.6
2024-01-28 19:56:10 -08:00
Lukas Korba 8ebd310798
[#999] Update support mail metadata (#1001)
- Subject in the mail composer/generator fixed
- unit tests checking the subject + mailto implemented
2024-01-28 19:29:07 -08:00
Lukas Korba 79ab841f75
[#997] Keys missing handling (#1000)
- changelog update
- the keys missing error state has been tweaked to try 3 retry attempts because of unresponsiveness keychain API
- in case of true missing keys, the user is no longer locked on a splash screen but rather let land to the Account tab so the rest of the Zashi can be used
- unit tests fixed + implemented new ones for the 3-attempt retry logic
2024-01-28 19:28:18 -08:00
Lukas Korba b6248fdd3c
[#971] Share QR code (#996)
- UI modified to offer both copy & share in the Balance tab
- share of the QR implemented
- unit tests added
- code cleanup
- changelog update
2024-01-23 20:13:46 +01:00
Kris Nuttycombe 96292825bf
Version updates for release 0.2.0 build 12 (#995) 2024-01-20 16:30:13 +01:00
Lukas Korba a4fc0743c6
[#933] Shielding hint box (#994)
- The hint box implemented
- Snapshot tests extended to cover the hint box case
- Unit tests for show/hide of the hint box implemented
- Code cleanup of the previous design for the hint box
- typeface fix
2024-01-14 17:35:47 +01:00
Lukas Korba 777aab54d5
[#991] Send failed alert not localized (#993)
- The alert metadata fixed
- changelog updated
- new test case for send failure implemented
2024-01-10 13:28:32 +01:00
Lukas Korba b801ac72d7
[#974] Restore of the wallet UI (#989)
The broadcasting technology done, the views can subscribe to the restoring wallet state dependency
The restoring wallet badge implemented + handling of different backgrounds underneath it
Progress of the sync implemented on the Account screen
SyncProgress feature implemented, this new component is used 2 times already in Zashi so it's been separated into its own module (used in balances screen and at home screen when restoring the wallet)
Unit tests fixed + implemented new ones for the restore wallet flag
2024-01-09 19:36:42 +01:00
Lukas Korba 1d60dd3275
[#982] Background syncing (#985)
Background processing task implemented
Doc for the Background Synchronization added
changelog update
custom wifi check
2024-01-08 14:14:48 +01:00
Lukas Korba 79205018a5
[#979] Export private data UX tweaks (#980)
- is acknowledge flag is reseted with every private data screen access
- the export buttons are disabled throughout the whole export + share phase
- the spinner is attached to the button that's exporting
- unit tests for all this new functionality added
- sdk 2.0.5 adopted
- changelog updated
2023-12-15 09:28:05 +01:00
Lukas Korba 9ed49c9a29
[#852] Persistency in onboarding flows (#977)
- check for the confirmed phrase backup implemented, when not confirmed, the phrase is displayed and awaiting user's confirmation
- unit tests added + modified
2023-12-15 09:26:04 +01:00
Kris Nuttycombe 076d445597
Version updates for release 0.2.0 build 11 (#978) 2023-12-14 19:24:00 +01:00
Lukas Korba 88715ded04
[#968] Share logs in private data sector (#973)
export of logs from the sdk implemented
the logs have been split into 2 files - verbose and sync specific logs + metrics
changelog updated
SDK dependency adopted
unit tests fixed + added new ones
2023-12-13 11:17:13 +01:00
Lukas Korba bc3db29ee0
[#965] Changelog update for the fixes (#966)
- entries for user facing changes/fixes/updates
- comments resolved
2023-12-12 20:30:02 +01:00
Lukas Korba 5c1898f5a7
[#963] Sending gets stuck (#964)
- Fixed alert appearance in the view
- Fixed missing memo UI in the confirmation screen
- Created a few more tests to cover new cases
2023-12-04 16:24:47 +01:00
Lukas Korba eb36c6db3e
[#961] Grid pattern in the background (#962)
- screen background extended to render either solid background or with grid pattern
- all screens that are designed with pattern have been updated
- recovery phrase screen has been updated to be scrollable because it couldn't fit the smallest iPhone's screen
- changelog updated
2023-12-04 16:23:33 +01:00
Lukas Korba ad4ac13e86
[#950] Sapling address when testnet build (#959)
- the sapling address and its QR code are present only for the testnet builds
- unit tests resolved and tweaked a bit - TCA actions have been merged into 1 copyToPasteboard
- snapshot tests for both mainnet and testnet version to prove sapling is missing on mainnet
2023-12-04 16:20:51 +01:00
Kris Nuttycombe e27e4ed34d Version updates for release 0.2.0 build 10 2023-11-30 09:23:58 -07:00
Lukas Korba 8b53ebfc34
[#936] Send confirmation screen UI (#957)
- confirmation screen implemented
- navigation flow implemented instead of just 1 pushed view
- unit tests fixed + added new ones that handles new actions and states
- zashi button modifier extended to offer new options for new states
- changelog update
- snapshot tests
2023-11-30 15:11:58 +01:00
Lukas Korba 26de9e250b
[#930] Newly created transaction (#944)
- the UX of the newly created transaction is improved by inserting the returned transaction immediately to the array of transactions, that way when the account page is accessed, the sending transaction is presented
- unit tests fixed + added new ones
- sending title for the button implemented alongside with the spinner
- changelog updated
2023-11-27 10:26:03 +01:00
Lukas Korba 4f3a5f7270
[#928] Balances screen UI (#942)
- the new layout implemented
- some of the functionality is not done yet because it's not supported in the SDK or some design is still WIP - TODOs added at related places
- result of shielding (the transaction) is automatically added to the list of transactions so the UX is seamless
- localized texts refactored
- unit tests done
2023-11-27 10:04:51 +01:00
Lukas Korba 4f06f83274
[#919] Update TODO to link ECC repo instead of secant (#927)
- the links haven been updated to point to the ECC repo
2023-11-22 10:07:48 +01:00
Lukas Korba 1d8ceb138b
[#918] Omit sapling address (#926)
- the sapling address is no longer on the receive screen
- code cleaned up
- changelog updated
2023-11-22 10:03:00 +01:00
Lukas Korba f7c4a83d72
[#923] Changelog update (#925)
- changelog updated to cover all new Zashi changes
2023-11-22 10:01:17 +01:00
Kris Nuttycombe 26d6be7773
Update the README for the Zashi iOS repository. (#914)
* Update the README for the Zashi IOS repository.
2023-11-21 09:58:33 +01:00
Lukas Korba c76322c0fb
[#922] Batch of ux feedback tweaks (#924)
message (memo) text regular weight, black color
change the color or received message bubble background
no message included... title regular + black
transaction ID (expanded one) regular font + black
expanded address regular font + black
2023-11-21 09:58:00 +01:00
Lukas Korba 4ab2ca0e7c
[#879] BalanceFormatter dependency (#921)
- BalanceFormatter dependency implemented
- ZatoshiRepresantationView implemented, all balances and zatoshi amounts supposed to be rendered should be done via this view
- zatoshi string representation struct implemented, holds all possible states
- unit tests + celanup
2023-11-20 15:07:24 +01:00
Lukas Korba a8a68852d3
[#902] Adopt TCA version 1 (#920)
- Reducers refactored
- EffectTasks refactored
- WithViewStores refactored
- all side effects refactored to the newest API
- tests refactored to MainActor async ones
- hosting application bypassed so the tests are passing and not flaky
- code cleanup
- snapshot tests with ViewStore bindings work again
- Confirmation dialog refactored, used brand new navigation TCA pattern
- unit tests fixed
2023-11-16 16:10:24 +01:00
Lukas Korba 14c5057eff
[#900] Reset states after wipe of the wallet (#901)
- concept of placeholder states removed finally, replaced with initial states that are production ready
- this change allowed the TCA roto state to simply clear out to initial after nuke/wipe
- code + tests refactored and fixed
- unit tests implemented
2023-11-14 15:33:07 +01:00
Kris Nuttycombe 29835e085b Version update for release 0.2.0 build 9 2023-11-13 17:08:37 -07:00
Lukas Korba aa726aa9e3
[#898] Feature timestamp is broken in unread logic (#899)
- fixed unread timestamp logic, old transactions are marked as read
- the BUG itself was in the unit test, that's why it got through the testing unnoticed

[#898] Feature timestamp is broken in unread logic (#899)

- reverted the names of the assets
2023-11-13 14:40:09 -07:00
Kris Nuttycombe 23ee03c208 Version and asset updates for release 0.2.0 build 8. 2023-11-13 10:00:59 -07:00
Kris Nuttycombe 028af83616 Version and dependency updates for release 0.2.0 build 7 2023-11-13 08:40:16 -07:00
Lukas Korba 50c603278a
[#888] Read and Unread state persistency for transactions (#896)
- implemented CoreData dependency as this is the best choice for the persistency in the end
- update the list only if there's anything new
- fixes + code cleanup
- unit tests & fixes
2023-11-13 11:34:46 +01:00
Lukas Korba e9d8e0fbbb
[#892] Add floating points to the balances (#895)
- the utility that splits the balance into 2 parts: main + rest so it can be rendered separately with different font sizes
- unit tests implemented
- code refactored
- Available balance view helper implemented
- spaces unified for the Home & Send
2023-11-13 11:31:34 +01:00
Lukas Korba 49de5f2e3e
[#891] Tap to copy for the transaction details (#893)
- Tap to copy of transaction address and ID implemented
2023-11-13 11:30:10 +01:00
Lukas Korba 34f0077604
[#887] UI tweaks for transactions on Home (#890)
- Concept of WalletEvents removed and replaced with TransactionState and TransactionList
- UI updated to enable list of transactions and expansion with the details
- Color naming cleanups and refactors
- Conditional font modifier implemented
- Conditional strikethrough modifier implemented
- Title + tests of the title for the transaction implemented
- Color + tests for the title of the transaction implemented
- All texts localized
- tests fot the TCA TransactionList implemented
2023-11-13 11:28:43 +01:00
Lukas Korba 3fa10e5147
[#881] UI tweaks for the latest Zashi (#883)
- Balances tab name (from Details)
- Restore flow - birthday header + optional
- Swipe across tabs to change it
- Splash screen with bigger steps
- Restore flow seed screen, scrollable + nav bar fixes + scroll to see the seed field
- Restore seed box to have a placeholder
- Fix the suggestions for the restore seed editor
- Rectangle around recovery phrase editor is now a shape instead of a full background with padding 1
2023-11-02 10:43:08 +01:00
Lukas Korba 74a2936b26
[#875] Send Screen UI (#882)
- message box (memo) reworked to properly handle text with system suggestions
- cleaned up the focused state
- cleaned up the screen background
- finalized the work on Zashi UI for Send
- unit tests fixed + added new ones that cover updated logic
- fixed next next return logic when transparent address is used and message (memo) box disabled
- scrollable content in the message (memo) box instead of dynamically expanding box
2023-11-02 10:37:38 +01:00
Kris Nuttycombe 38720c54d1 Version and dependency updates for release 0.2.0 build 6 2023-11-01 12:43:57 -06:00
Lukas Korba c15b9558b8
[#885] Export of private data (#886)
- PrivateDataConsent screen implemented where is possible to share the dataDb
- tests fixed + added
2023-11-01 19:38:41 +01:00
Kris Nuttycombe a2d3246a24 Updates for release version 0.2.0 build 5 2023-10-25 17:30:15 -06:00
Lukas Korba b4dc72d511
[#873] Start of the app shows pending state for the transaction (#874)
- The TransactionState always require a BlockHeight to be given, no more optional
- This ensures transactions are properly evaluated for the state (pending vs. non-pending)
2023-10-25 12:43:54 +02:00
Lukas Korba c0d34224c4
[#864] Restore from seed UI (#872)
- fixes for the birthday screen
- layout updated to be scrollable for the seed screen
- code cleanup
- SDK 2.0.3 adopted
- optional placeholder for the birthday
- fixes for the restore flow after a wipe
- clean up of TCA warnings, EffectTask refactored to Effect
2023-10-24 10:38:19 +02:00
Lukas Korba 3689e461cd
[#870] balance truncation to 3 floating points (#871)
- BalanceTitle view created for the bigger balance + zcash icon
- balance formatter with 3 floating points created and used everywhere in the views
- tests for this formatted added to check bank rounding
2023-10-20 15:03:13 +02:00
Lukas Korba 72c34db59d
[#868] tap to copy seed (#869)
- tap to copy phrase action added to the phrase screen
2023-10-20 15:01:20 +02:00
Lukas Korba 44510ac88d
[#865] Settings UI (#867)
- Settings UI according to the Zashi UI
- cleanup of unused code
- fixed tests
2023-10-20 15:00:52 +02:00
Kris Nuttycombe e7db6a9050 ZcashLightClientKit release 0.2.0 build 4 2023-10-13 08:39:25 -06:00
Lukas Korba 9f4243b475
[#861] Remove lightwalletd related error dialogs (#862)
- error dialogs removed
- cleanup of the code

[#861] Remove lightwalletd related error dialogs

- sdk 2.0.2 adopted, version bumped
- error dialogs removed
- a few bugfixes:
- phrase display can handle longer words and still render it fully with no truncation
- tabs tap area increased
- receive screen with addresses now uses the wallet's UA
2023-10-13 08:36:50 -06:00
Lukas Korba 2d4ddd72c6
[#858] About screen UI (#859)
- About screen updated to the Zashi UI
- back button finalised according to the Zashi UI
2023-10-13 08:25:35 +02:00
Lukas Korba 86007d449a
[#856] Opening screen UI (#857)
- Opening Screen UI has been redesigned according to the new Zashi UI
2023-10-13 08:16:11 +02:00
Lukas Korba 9827e9aff9
[#853] open privacy policy from the security screen (#854)
- here in the texts works as a hyperlink now and redirects a user to the system browser with the PP
2023-10-13 07:53:04 +02:00
Lukas Korba c1190c782e
[#851] Tab bar layout for the home screen (#855)
- concept of tabs implemented, it's the main navigation hub
- home reducer simplified because it no longer plays a role of a navigation hub
- navigation bar titles implemented
- hamburger menu for the settings screen
- balances screen tweaked
- wallet events on home screen instead of a separate screen
- tests fixed
- feature flags removed from the debug menu, no longer used
- semitransparent nav bar implemented
2023-10-13 07:47:04 +02:00
Lukas Korba fc4f6ad7f9
[#849] Receive screen (#850)
- Profile screen removed completely, no longer in the designs
- AddressScreen is now directly connected to the receive ZEC button
- redesigned according to new Zashi UI
- localized texts
2023-10-10 13:51:06 +02:00
Lukas Korba 1e0c82e15d
[#845] Recovery screen (#848)
- redesigned according to new Zashi UI
- modified grouping or phrase words, halves instead of quarters
- snapshot tests updated
- code cleanup - recovery phrase screen loads the stored wallet instead of being injected into it
2023-10-10 13:47:52 +02:00
Kris Nuttycombe 3fcdbd4a2e Bump project version to (3) to agree with TestFlight's view. 2023-10-05 13:08:33 -06:00
Kris Nuttycombe e8a5d02395 Update dependencies & build version for 0.2.0-2 release. 2023-10-05 12:42:59 -06:00
Lukas Korba 5ad02e0c6b
[#842] Move state and progress of the synchronizer to the balance breakdown screen (#844)
- Home screen updated to show total + spendable balances
- BalanceBreakdown screen updated to show status of the synchronizer
- Zashi BACK button applied to all screens
- tests fixed
2023-10-05 11:31:12 +02:00
Lukas Korba 4fb80ed89f
[#841] Warning screen (#843)
- custom toggle
- security screen UI and logic finished
- splash screen extended to report completion, this way I can assure it never shows again
- dynamic Zashi version + build implemented into the warning message
2023-10-05 11:30:04 +02:00
Lukas Korba 7c5022a5df
[#828] Splash masking effect (#836)
- Splash screen accessible from a view modifier
- landing through it to the Home and Restore wallet screens
- final effect after round of feedback from Richard
2023-10-04 15:04:08 +02:00
Lukas Korba e33ee405ee
[#830] Zashi design buttons (#837)
- all features of the button done
- cleanup of everything that is not part of the design anymore, needed for the colors for the buttons
- zcashStyle used for the buttons
2023-10-04 11:04:22 +02:00
Lukas Korba e1a5fa9778
[#839] Show total balance on Home screen (#840)
- balance on the home screen is not a total instead of verified one
2023-10-04 11:03:47 +02:00
Kris Nuttycombe c98ec53940 Update dependencies & version for 0.2.0 release. 2023-10-03 08:38:31 -06:00
Lukas Korba 83e5f4fb11
[#833] Ensure that the Send ZEC button is enabled whenever the wallet reports a spendable balance (#835)
- button is enabled when verified shielded balance > 0
2023-10-03 14:05:55 +02:00
Lukas Korba ebbf2520ad
[#832] Replace user-facing Secant strings with Zashi (#834)
- localized files updated, secant -> Zashi
2023-10-03 14:05:44 +02:00
Lukas Korba bbd8da45d6
[#826] proper handling of apps lifecycle (#827)
- SDK version updated
- handling of stopped state added
- swiftgen plugin removed until it's supported by xcode 15 again
2023-09-29 10:23:17 +02:00
Kris Nuttycombe 9586bcbb60 Update Zashi wallet to ZcashLightClientKit 2.0.0-rc.4 2023-09-22 22:05:17 -06:00
Kris Nuttycombe 30eabdf589 Update Zashi wallet to ZcashLightClientKit 2.0.0-rc.3 2023-09-20 15:21:04 -06:00
Lukas Korba feb4ab4eaf
[#820] Adopt SDK sbs-rc1 (#821)
- adopted SDK 2.0.0 RC1 with the Spend-before-Sync
- fixed how memo is selected out of the array of memos (.text is picked, .empty ignored)
2023-09-14 17:10:46 +02:00
Lukas Korba 78f230a768
[#816] Adopt TCA 0.59.0 (#818)
- TCA updated to the latest supported version, there's a 1.0 release already but handled in a different ticket
2023-09-01 08:43:07 +02:00
Lukas Korba 9839f3e34e
[#812] Add Archivo font (#813)
- Archivo font added to the project
- info file indentation fixed
2023-08-29 10:35:44 +02:00
Lukas Korba a73a57aee2
[#814] Server update (#815)
- endpoint updated to the latest and workable server
2023-08-29 10:25:19 +02:00
Lukas Korba 9b2463a370
[#810] Bitrise fails to build (#811)
- hotfix for the CI to work again
2023-08-23 18:16:46 +02:00
Lukas Korba faec526e15
[#804] Update FFI dependency (#805)
- SDK version updated so the FFI is updated as well
- log levels changed so uni tests fixed
2023-08-23 17:06:34 +02:00
Lukas Korba 59e0a68da5
[#747] CrashReporterClient as isolated package (#799)
- CrashReporter is now an independent module
- all crash reporter TODOs removed
- the crash reporter code commented out is now back in action
- package.resolved file updated
- adopted latest SDK
- test crash reporter added back to debug menu
- typo in comments fixed
2023-08-10 08:20:31 +02:00
Lukas Korba 0330f0e7e9
[#789] Use Inter font in Zashi (#797)
- Inter fonts added and registered for use
- all Texts in the Zashi use Inter as a default font
- some texts have custom sizes
- cleanup of fonts in the project
2023-08-10 08:18:19 +02:00
Lukas Korba 4913c60741
[#796] Update App icon (#798)
- mainnet app icon updated
- testnet app icon updated
2023-08-07 14:55:39 +02:00
Lukas Korba 1de13698d8
[#793] Polish debug menu and fix dark mode (#794)
- fixed alerts in debug menu
- fixed confirmation dialog in for rescan action
- fixed dark mode colors
- updated texts
- simplified texteditor UI so it's more consistent with the other components
- reduced debug menu items
- tests fixed
2023-08-07 08:33:33 +02:00
Lukas Korba 0206641fc6
[#790] Adopt latest SDK (#791)
- The SDK updated to the latest main (commit hash)
- Fixes for a few texts
- UX improvement: Upgrading databases... label for cases when it takes a few seconds, most of the times it is so quick that the label is even not visible to the user. It simple dismisses before user lands on a home page from the welcome screen
- fixed tests after adding the flag for migration
2023-07-31 18:07:44 +02:00
Lukas Korba ae2c18006d
[#786] Errors for input fields (#787)
- Send flow updated so both input field show an error
- texts for the errors start with capital letters
2023-07-21 09:23:22 +02:00
Lukas Korba de0c954dd7
[#785] Dark mode (#788)
- dark mode support integrated (colors)
- branding updated (name of the app + logo)
2023-07-20 13:21:37 +02:00
Lukas Korba 5fe923f91d
[#783] Set the swift tool version to 5-6 (#784)
- the version has been downgraded to 5.6 from 5.8
2023-07-17 15:11:59 +02:00
Matthew Watt 9fc08a221e
Use SwiftGen plugin (#782)
SwiftGen plugin
2023-07-17 12:12:32 +02:00
Lukas Korba 60f8c6ae5d
[#779] Release configuration not compiling (#780)
- script for crashlytics symbols upload removed for now
2023-06-27 13:39:44 +02:00
Lukas Korba d972a7834b
[#776] Alerts do not work as expected (#777)
- actions from alerts are now properly propagated
- dismissal of an alert is not clearing out the state
- qrcode icon is now a system one
- swiftgen paths updated
2023-06-22 08:12:33 +02:00
Lukas Korba 2aadd2870a
[#772] Cleanup app dependencies (#775)
- dependencies cleaned up
- _unmodularized folder cleared as well
2023-06-22 08:05:22 +02:00
Lukas Korba f1de69f10e
[#767] Modularize batch of features Vol IV (#770)
Following features have been modularized:
- Home
- Root
2023-06-09 10:29:01 +02:00
Lukas Korba 896f4532a1
[#766] Modularize batch of leaf features Vol III (#768)
Following features have been modularized:
- OnboardingFlow
- ImportWallet
- SendFlow
- Sandbox
- crashReporter TODO added
2023-06-08 14:13:36 +02:00
Lukas Korba 0d5904e30c
[#764] Modularize batch of leaf features Vol II (#765)
Following features have been modularized:
- BalanceBreakdown
- WalletEventsFlow
- Scan
- ExportLogs
- Settings
- AlertState generic type cleanup
- crashReported TODO added
2023-06-08 09:37:05 +02:00
Lukas Korba e3a312ee1a
[#761] AlertReducer and RootReducer needs to be decoupled (#763)
- AlertRequest + Reducer + States removed
- Alerts decoupled and living within the features
- tests fixed
2023-06-06 11:30:58 +02:00
Lukas Korba 9b77a57a5f
[#757] Modularize batch of leaf features Vol I (#760)
Following features have been modularized:
- AddressDetails
- RecoveryPhraseDisplay
- Welcome
- Profile
2023-06-01 10:11:37 -04:00
Matthew Watt 2e4c526272
Register custom fonts (#759)
Missing registration of custom fonts
2023-06-01 16:09:55 +02:00
Lukas Korba 561ccc0689
[#750] Batch of Dependency Packages Vol IV (#756)
Last 4 dependencies modularized

- URIParser
- UserPreferencesStorage
- WalletConfigProvider
- WalletStorage
2023-06-01 16:05:35 +02:00
Lukas Korba e2502075e0
[#754] Structure for modules (#755)
- the modules are now in folders
2023-05-31 09:49:37 +02:00
Lukas Korba dbc6316766
[#749] Batch of Dependency Packages Vol III (#751)
Finished modules for:

RecoveryPhraseRandomizer
RecoveryPhraseValidationFlow
ReviewRequest
SDKSynchronizer
SecItem
SupportDataGenerator
ZcashSDKEnvironment
UserDefaults
2023-05-31 08:29:32 +02:00
Lukas Korba 7e9f8c3170
[#746] Batch of Dependency Packages Vol II (#748)
Finished modules for:
- DiskSpaceChecker
- FeedbackGenerator
- LocalAuthentication
- LogsHandler
- Mnemonic
- NumberFormatter
- Pasteboard
2023-05-30 22:33:56 +02:00
Lukas Korba c8546376db
[#744] Batch of Dependency Packages Vol I (#745)
Finished modules for:
- AudioServices
- Capturedevice
- DatabaseFiles + FileManager
- Deeplink
- DerivationTool
- Utils: NumberFormatter+zcash, String, URL+Empty
2023-05-29 14:38:53 +02:00
Lukas Korba 7ed4d1bfcf
[#739] AppVersion Dependency Package (#742)
- AppVersion dependency moved to a separate package
2023-05-29 08:28:36 +02:00
Lukas Korba 7b7ef3b087
[#738] Date Dependency Package (#741)
- Date dependency moved to a separate package
2023-05-26 13:30:01 +02:00
Lukas Korba 04d4c363d4
[#735] Setup swift package (#740)
- project updated to hold package for future modularization
2023-05-26 12:59:36 +02:00
Lukas Korba 49f7afd56a
[#730] Fix warnings with TCA 0-53 (#733)
- timer instead of self
- TCA updated to 0.53.2
- store.score warnings fixed
2023-05-24 15:44:34 +02:00
Lukas Korba 3cfba64f2a
[#731] Update Swiftlint section (#732)
- Swiftlint section updated to 0.50.3 version
2023-05-24 15:42:52 +02:00
Francisco Gindre 31d05d914b
Release/0.0.1-53 (#729)
* fix compiler issues

* bump build number
2023-05-23 20:22:21 -03:00
Francisco Gindre d10f594782
update ZcashLightClientKit to commit `ee3d082155bf542aa3580c84e6140a329633319a` (#728) 2023-05-23 15:25:23 -03:00
Lukas Korba 403d60bf9f
[#724] Adopt TCA 0.53.0 (#725)
- in general, cleanup of warnings:
- unused code in the tests
- cancellable ids updated
- fulfillment instead of wait
- library updated to 0.53.0
2023-05-23 17:57:43 +02:00
Lukas Korba b142609af9
[#720] User can proceed to send flow without funds (#723)
- the send button is enabled only when some funds are available
- the verified balance used for sufficiency of funds instead of total
- changed the pending transaction logic and split into sending/receiving instead
- code cleanup of unused CancelId
- UI cleanup, detail of receiving transaction rendered "to" prefix with no address

[#720] User can proceed to send flow without funds (#723)

- totalBalance -> totalSpendableBalance
- improved code syntax for the conditions in TransactionState deciding the status
2023-05-17 11:31:08 -03:00
Francisco Gindre b204c42a13
[#717] import birthday does not work as expected (#718)
This corrects the case for which the user does not input a birthday
to restore the wallet and it needs to fall back to sapling activation
2023-05-12 08:38:20 +02:00
Francisco Gindre 44039f7648
Add changelog and bump build number for 52 (#716) 2023-05-10 17:57:05 -03:00
Francisco Gindre a4e377e0d1
[#711] Transaction History not shown (#715)
Closes #711

also uses SDK commit that fixes this issue
https://github.com/zcash/ZcashLightClientKit/issues/1037

Point to commit `cf53edb3b82c9d7998043d6ff7a663ec8fd87b95`

Add resolved file

point to latest SDK commit
2023-05-10 17:52:13 -03:00
Lukas Korba c143f4b31d
[#709] Better error handling in tests (#713)
- Strings replaced with ZcashError
- unit test don't depend on error descriptions anymore

[#709] Better error handling in tests (#713)

- cleanup

[#709] Better error handling in tests (#713)

- alerts now show error message + code
2023-05-10 13:52:56 -03:00
Francisco Gindre 647eeea7aa
release 0.0.1-50 to testflight (#710) 2023-05-09 07:28:08 -03:00
Lukas Korba 041a630412
[#707] Adopt latest SDK (#708)
- TransactionState simplified and adopted to the latest ZcashTransaction
- WalletEvent simplified
- sendTransaction updated to the async/await
- unit tests fixed
2023-05-09 07:20:33 -03:00
Lukas Korba fe1e7b758c
[#705] Transaction detail lacks memo and addresses (#706)
- synchronizer's protocol cleaned up
- latest SDK adopted
- memos back toincleared transactions
- recipient back in cleared transactions
- unit tets fixed
- pending transaction memos are back
- recieved recipients no longer available, removed from the UI
2023-04-27 19:27:58 +02:00
Lukas Korba a727f49817
[#265] Integrate App Rating Alert (#703)
- async adaptations of the latest sdk
- review request TCA dependency added
- set of rules for the triggering the app rating dialog
- unit tests fixed
- unit tests for the review request client
- app review request logic disconnected from the production for now (added the TODO for the triggering)
2023-04-06 08:06:49 +02:00
Lukas Korba 36d2090654
[#698] RootView to use SwitchStore (#699)
- all alerts refactored and connected
- unit tests fixed
2023-03-31 07:25:13 +02:00
Michal Fousek c61b406372 Install ZcashLightClientKit from commit instead of feature branch 2023-03-24 12:51:30 +01:00
Lukas Korba ef26c835c2
[#691] Adopt sync/async synchronizer changes (#696)
- async APIs called instead of a sync one
- tests fixed
2023-03-23 16:10:18 +01:00
Lukas Korba 8294415a69
[#683] Zip log files into one (#692)
- files stored temporarily and then zipped
- the dependency API changed so it handles the temporary files and folders and returns the final logs.zip URL
- test fixed
2023-03-22 14:38:10 +01:00
Lukas Korba 4a3be9ac0b
[#684] Improvements for the derivation tool dependency (#689)
- dependency updated and simplified
- tests fixed
2023-03-21 11:09:26 +01:00
Lukas Korba 28e95efca9
[#678] Adopt TCA 0.52.0 (#688)
- updated, build & tests ok, no code changes needed
2023-03-21 11:03:56 +01:00
Lukas Korba 702b71103b
[#682] Adopt removal of the Notification center on the SDK side (#687)
- secant is buildable again, notifications replaced by publishers
- tests WIP
- all unit tests fixed
- syntax of dependencies consolidated
- syntax of .send and .receive states consolidated
2023-03-21 11:03:42 +01:00
Francisco Gindre c1847d4216
[#685] release 0.0.1 Build 49 (#686)
closes #685
2023-03-17 18:46:25 -03:00
Lukas Korba 59ad8f4c7b
[#673] End to end bugfix (#679)
- memo is nil for send transaction and transparent address
- memo is hidden from the UI when transparent address is used
- derivation tool respect the network set in the target
- unit tests fixed
- memo logic related to the address added
2023-03-17 18:46:41 +01:00
Francisco Gindre b55de57a9a
[#680] Add CHANGELOG entry and build bump for 0.0.1-48 (#681) 2023-03-15 12:47:29 -03:00
Francisco Gindre 604a840517
[#676] fix About.swift not being present on mainnet target (#677)
"SettingsView.swift:70:21: error: cannot find 'About' in scope (exit code: 1)"

Closes #676
2023-03-15 12:09:46 -03:00
Michal Fousek 5ce87b18a9
[#654] Convert SDKSynchronizerDependency to regular TCA dependency (#672)
Closes #654

- `SDKSynchronizerClient` is now regular TCA dependency like any other
  dependency that we have in the app.
2023-03-15 09:53:16 +01:00
Francisco Gindre 69c1aa12a3
[#674] release 0.0.1-47 (#675)
closes #674
2023-03-14 16:01:19 -03:00
Michal Fousek f46eaf69c5
[#653] Adopt SDK initialisation changes (#671)
Closes #653
2023-03-14 09:14:52 -03:00
Lukas Korba 88f81e774a
[#668] Balance Breakdown design enhancements (#669)
- layout & colors changed so it's not a modal semi-transparent view anymore
2023-03-14 09:10:08 -03:00
Michal Fousek 39d1472c45
Fix missing percentage on homepage while syncing (#670) 2023-03-14 12:31:53 +01:00
Francisco Gindre a74dfa03ae
[#663] Shield Funds button is enabled when there are no funds to shield (#665)
- This adds new logic for disabling the shield funds button and tests that
check that the state is consistent with the intended behaviour.
- handling button opacity is left for another PR
- one more condition to disable shield button
2023-03-14 10:04:49 +01:00
Francisco Gindre d5b92c32c5
[#666] Remove Graphics from "create new wallet" screen (#667)
Also removes padding from '.activeButtonStyle' and changes
padding throughout the app where it's needed
2023-03-14 09:54:04 +01:00
Francisco Gindre 72324f2a94
[#661] Send Button works even if it's apparently disabled (#664)
- This creates a view modifier that disables and dims the view in a
single line of code
- Also moves every button that can be disabled to use the ViewModifier
2023-03-14 09:50:31 +01:00
Francisco Gindre fe09ae7aef
[#660] Settings button is not part of a navigation bar (#662)
This deletes the HStack on the HomeView and adds the settings view into
the navigation bar trailing item
2023-03-14 09:42:34 +01:00
Lukas Korba c8037f714b
[#658] About Screen with version (#659)
- about screen implemented with version only for now but place for licences, etc.
2023-03-14 09:41:39 +01:00
Lukas Korba 37af62201d
[#652] Each logged TCA actions appears twice in the log (#657)
- the logging infrastructure is doing exactly the same as the pointfree's  _printChanges() so there has been a duplication of logs
2023-03-14 09:41:13 +01:00
Francisco Gindre 1c1eed592d
[#655] Release testflight 0.0.1-46 (#656)
closes #655
2023-03-13 11:53:25 -03:00
Lukas Korba f8191e33ac
[#626] Small UI-UX fixes for 0.0.1-45 (#649)
- all resolved except nav bar issue (separate ticket)
2023-03-13 08:53:21 +01:00
Lukas Korba 09380a169d
[#650] Layout changes for the send screen (#651)
- adding/editing memo proposed to be in a sheet popover
2023-03-13 08:50:32 +01:00
Francisco Gindre bae3ec974b
[#647] Adopt 0.19.1-beta (#648) 2023-03-12 10:14:37 -03:00
Francisco Gindre bb5af14f4a
[#597] Sync cannot be retried after a failure (#646) 2023-03-12 10:12:24 -03:00
Lukas Korba 1d86157198
[#631] Make Send Form fields avoid being blocked by keyboard (#645)
- hiding the keyboard on tap
- adapting the layout on the keyboard appearance
2023-03-09 16:40:03 +01:00
Michal Fousek 3de41fe289
[#599] Add ability to shield funds (#641)
Closes #599
2023-03-09 08:35:23 +01:00
Michal Fousek 3071652a65
[#632] Show error message for failed transaction (#642)
Closes #632
2023-03-08 15:56:17 -03:00
Lukas Korba dea5b19621
[#628] TAZ vs ZEC builds (#637)
- all instances of hardcoded ZEC are now dynamic depending on a target
- debug menu fixed
2023-03-08 19:50:09 +01:00
Michal Fousek ff58ae718c
[#639] Show valid balance after app start (#640)
Closes #639.

- The Secant app read `SynchronizerState` only from
  `SDKSyncronizerSynced` notification. So when app started and there was
  some latency between sync start and sync finish the Secant app didn't
  show valid balance.
- Now the Secant app reads `SynchronizerState` also from `SDKSyncronizerStarted`
  notification. So it shows valid balance right on the app start.
2023-03-08 15:14:01 +01:00
Michal Fousek ddc6bb7d86
[#618] Require specific version of SwiftGen (#638)
- We need to require specific version of SwiftGen because each version
  may generate different file. Which causes then problems with git.
- Convert build phase shell scripts to zsh.
2023-03-08 12:40:21 +01:00
749 changed files with 26370 additions and 21416 deletions

70
BACKGROUND_SYNCING.md Normal file
View File

@ -0,0 +1,70 @@
# Background Syncing
## Sources
We encourange you to watch WWDC videos:
- [Advances in App Background Execution]: https://developer.apple.com/videos/play/wwdc2019/707
- [Background execution demystified]: https://developer.apple.com/videos/play/wwdc2020/10063
## Implementation details
There are 4 different APIs and types of background tasks. Each one is specific and can be used for different scenarios. Synchronization of the blockchain data is time and memory consuming operation. Therefore the `BGProcessingTask` has been used. This type of task is designed to run for a longer time when certain conditions are met (watch Background execution demystified).
### Steps to make it work
1. Add a capability of `background modes` in the settings of the xcode project.
2. Turn the `Background Processing` mode on in the new capability.
3. Add `Permitted background task scheduler identifiers` to the info.plist.
4. Create the ID for the background task in the newly created array.
5. Register the BGTask in `application.didFinishLaunchingWithOptions`
```Swift
BGTaskScheduler.shared.register(
forTaskWithIdentifier: <ID>,
using: DispatchQueue.main
) { task in
// see the next steps
}
```
Note: The queue is an optional and most tutorials leave the parameter `nil` but Zashi requires main thread processing due to UI layer - therefore we pass `DispatchQueue.main`.
6. Call a method that schedules the task execution.
7. Start the synchronizer.
8. Set the expiration closure and stop the synchronizer inside it
```swift
task.expirationHandler = {
synchronizer.stop()
}
```
9. The body of the registered task summarized:
```swift
BGTaskScheduler.shared.register(...) { task in
scheduleTask() // 6
synchronizer.start() // 7
task.expirationHandler = {
synchronizer.stop() // 8
}
}
```
10. Call `scheduleTask()` when app goes to the background so there is the initial scheduling done, the next one will be handled by the closure of the registered task. The method usually consists of:
```Swift
let request = BGProcessingTaskRequest(identifier: <ID>)
request.earliestBeginDate = <scheduledTime>
request.requiresExternalPower = true // optional, we require the iPhone to be connected to the power
request.requiresNetworkConnectivity = true // required
do {
try BGTaskScheduler.shared.submit(request)
} catch { // handle error }
```
11. Last step is to call `.setTaskCompleted(success: <bool>)` on the BGTask when the work is done. This is required by the system no matter what. We call it with `true` when the synchronizer finishes the work (up-to-date state) and with `false` for other or failed reasons (stopped state, error state, etc.).
You can see specific details of the Zashi implementation in:
- Xcode project settings, steps 1-4.
- AppDelegate.swift file, steps 5-9.
- SecantApp.swift file, step 10.
- RootInitialization.swift, step 11.
## Gotchas
- The `requiresNetworkConnectivity` flag doesn't specify or deal with the type of connectivity. It simply allows scheduling when the iPhone is connected to the internet. We deal with it when the task is triggered. The custom check wheather the wifi is or is not connected preceeds the start of the synchronizer.
- When the app is killed by a user in the app switcher, the scheduled BGTask is deleted. So the BGTask is triggered at the scheduled time only when the app is suspended or killed by the system. Explicit termination of the app by a user leads to termination of any background processing.

View File

@ -1,4 +1,293 @@
# Changelog
All notable changes to this application will be documented in this file.
Please be aware that this changelog primarily focuses on user-related modifications, emphasizing changes that can
directly impact users rather than highlighting other crucial architectural updates.
## [Unreleased]
## 1.1.1 build 1 (2024-05-22)
### Added
- Expanded transaction lists all text memos.
- Biometric lock is used to protect Delete Zashi, Export Private Data and Send features.
- Tapping on the error message label in the sync progress shows an alert view with the details of the error.
- What's new screen accessible from Settings -> About.
### Fixed
- Sometimes, Zashi crashed when the shield button was tapped. We fixed the crash, but shielding won't be possible due to funds being below the threshold.
## 1.1 build 6 (2024-05-09)
### Changed
- Hide balances logic has been tweaked for better security. Shileding is not possible when balances are hidden. Send tab balances are also hidden.
## 1.1 build 3 (2024-05-07)
### Added
- Dark mode.
- Scan QR code from an image stored in the library.
- Hide the balances with an eye icon on the Account or Balances tabs.
### Changed
- The confirmation button at recovery phrase screen changed its name from "I got it" to "I've saved it".
- Receive tab shows 1 QR code at a time with ability to switch between them.
### Fixed
- Balances are refreshed right after the send or shielding transaction are processed.
## 1.0.6 build 4 (2024-04-30)
### Changed
- We have added one more group of server options (zec.rocks) for increased coverage and reliability.
- zec.rocks:443 is now default wallet option.
### Fixed
- We fixed a bug issue with displaying the recovery seed phrase twice after creating a new wallet.
## 1.0.5 build 4 (2024-04-19)
### Fixed
- Migration of DB ensures that the default Unified Address for existing wallets now contains an Orchard receiver.
## 1.0.5 build 2 (2024-04-17)
### Added
- Open settings button added to the scan screen for a case when the camera is disabled.
- Content of Zashi is hidden in system's app switcher.
- Birthday field is auto-focused in the restore flow.
- Information about restore is persisted until fully synced wallet.
### Changed
- Zashi requires 1 GB of free space to operate. We have updated the user experience to display a message when this requirement is not met, indicating the actual amount of free space available. From this screen, you can access the settings to obtain the recovery phrase if needed.
- The height of syncing label has been unified to never change the overall component's' height based on different states.
- The input field for the recovery phrase now shows the expected format in the placeholder.
- "No message included in transaction" has been removed from expanded transparent transaction view.
### Fixed
- General clean up and bugfix.
- Delete Zashi resets local in memory values.
## 1.0.4 build 2 (2024-03-29)
### Added
- Tap to Copy memo.
### Fixed
- Tap to Copy transaction ID button animation.
- Transparent balance added up to the total balance.
- Tap to transparent funds hint box area.
## 1.0.4 build 1 (2024-03-28)
### Fixed
- Orchard subtree roots are now fetched alongside Sapling subtree roots.
## 1.0.3 build 1 (2024-03-27)
### Fixed
- Bug in note selection when sending to a transparent recipient.
## 1.0.2 build 1 (2024-03-27)
### Fixed
- Bug in an SQL query that prevented shielding of transparent funds.
## 1.0.1 build 3 (2024-03-26)
### Added
- Proposal API integrated with error handling for multi-transaction Proposals.
- Privacy info manifest.
- Orchard support.
- Seed validation for case when Zashi is migrated to another device.
### Fixed
- White area above the keyboard has been removed.
## 1.0 build 3 (2024-03-13)
### Changed
- Settings screen options have been reduced and some were moved to the new Advanced Settings screen.
- Scan of QR codes has been re-worked with new design and behaviours.
- Security warning consent extended with crash reports.
- Available balance component shows a spinner instead of zero value when processing spendable balance.
### Added
- Pending values (changes) at the Balances tab.
- Choose a Server feature: available at settings, pre-defined servers + custom server setup.
- Account tab UI tweaks for no transactions available.
### Fixed
- Restore mode in the UI was missing when Zashi was deleted from an iPhone and reinstalled again.
- Syncing bar in the restore mode bottom padding.
- Missing exit button at backup phrase screen when no words are stored in the keychain.
- Failed transactions are no longer at the top of the transaction history but mixed with the transactions around the time it failed.
- Synchronization progress bar starts at the expected percentage as oposed to previous behaviour when it started with 0% and jumped to the expected one in a few seconds.
- iPhone SE recovery phrase screen is not trailing words anymore.
- Security audit issues has been resolved.
### Removed
- Pull to refresh the transaction history.
## 0.2.0 build 15 (2024-01-31)
### Fixed
- Shileding of transparent funds.
## 0.2.0 build 14 (2024-01-30)
### Updated
- SDK 2.0.7 adopted with the performance optimizations on the rust side.
## 0.2.0 build 13 (2024-01-28)
### Added
- Share QR code of addresses via system share dialog.
### Fixed
- `Keys Missing` error dialog was sometimes triggered as a false positive due to system overload and keychain API unresponsivity in expected time. Retry logic was implemented to pass this state. Also the app always lands users to the Account tab instead of lock them on a splash screen with no options to solve this state.
## 0.2.0 build 12 (2024-01-20)
### Added
- The exported logs also show the shielded balances (total & verified) for every finished sync metric.
- Synchronization in the background. When the iPhone is connected to the power and wifi, the background task will try to synchronize randomly between 3-4am.
- Restore of the wallet is now indiated in the UI throughout the application.
- A hint box that elucidates transparent funds and shielding on the Balances tab.
### Fixed
- The export buttons are disabled when exporting of the private data is in progress.
- The alert message and title for the failed transaction send.
## 0.2.0 build 11 (2023-12-13)
### Added
- Option to export SDK and wallet logs in `Export private data` screen.
### Changed
- The background of Onboarding and some of the Settings screen has been updated to show a subtle texture of a grid pattern.
- The sapling address + QR code has been restored on the Receive tab (for testnet only.)
### Fixed
- Fixed a bug that caused spends to appear to be stuck.
- The confirmation screen has been altered such that the message bubble is rendered only when the message is non-empty.
## 0.2.0 build 10 (2023-11-30)
### Changed
- The way how the balances (zatoshi amounts/values) are represented has been updated accoridng to the latest requirements. In general any zatoshi value has 2 major states, expanded or abbreviated. Trailing zeroes are trimmed when expanded.
- The `Balances` screen has been redesigned: new progress bar with the status of the synchronization, all balances available. Penging fields are disabled for now and show only zeroes until support from the SDK is implemented.
- When the send button is tapped, the sending title + spinner is shown instead of just the spinner. Also, when the send is done, and redirect to the Account page is done, the sending transaction is already populated in the list. The lag between it was presented has been fixed.
### Removed
- [testnet only] The sapling address and the QR of it has been removed from the receive screen. The only meaningful options are the UA and the transparent addresses.
### Added
- Confirmation screen when sending funds. The initial screen is about filling in the address, amount and message (optional). The butoon `review` leads to a brand new screen where the summary of the transaction is presented. The send is confirmed by tapping the send button. Going back to update send data is possible via `go back` button.
## 0.2.0 build 9 (2023-11-14)
### Changed
- Send (tab) redesigned: All the input fields are at the same screen. The screen is scrollable so it's usable on every possible iPhone.
- Complete redesign of transactions on the Account tab. Expandable transactions show details of it, including options to copy transaction IDs as well as addresses.
### Added
- The concept of read/unread transactions with the message (memo) implemented. The color of the icon of received transaction that holds message and hasn't been read yet is yellow. Once the transaction is expanded, the icon's color flips to the black and the state is persisted.
## 0.2.0 build 6 (2023-11-01)
### Added
- Option to export private data: brand new screen accessible via Settings, where once consent acknowledged, a user can export a database of data. Important note: the data are sensitive because it holds some information about user's transactions and history but spending keys are not exported so lost of funds is not possible.
## 0.2.0 build 5 (2023-10-26)
### Changed
- Settings screen has been redesigned and options on the screen changed.
- Truncation of the balances changed from 8 floating points to the 3 only.
- Restore from the seed flow and UI updated.
### Added
- Option to copy the seed to the pasteboard when a new wallet is created and the seed presented.
## 0.2.0 build 4 (2023-10-13)
### Changed
- About screen UI updated.
- The main navigation of the Zashi changed, now the wallet is tab based with Account, Send, Receive and Balances tabs.
- Home screen is now called Account.
- Receive screen UI updated.
- Recovery screen UI updated (the screen with the seed presented).
### Added
- The security warning screen with that is presented when the new wallet is created now holds a link in the text that takes a user to the privacy policy.
## 0.2.0 build 3 (2023-10-05)
### Changed
- Zashi design buttons
- Splash screen: new animated screen with the logo + HI text.
- Security warning screen UI updated.
- State and progress of the synchronizer moved from the Home screen to the balance breakdown screen.
## 0.2.0 build 1 (2023-10-03)
### Changed
- The send button is disabled until the spendable balance is not a zero.
### Added
- The wallet now handles lifecycle events: when the app goes to the background and back to the foreground. That fixed lightwalletd errors.
# Previous Changelog records before we rethink the idea of the changelog and before Zashi design
## 0.0.1 build 52
- [#709] Better error handling in tests (#713)
## 0.0.1 build 51
- [#711] Transaction History not shown (#715)
## 0.0.1 build 50
- [#707] Adopt latest SDK (#708)
- [#705] Transaction detail lacks memo and addresses (#706)
- [#265] Integrate App Rating Alert (#703)
- [#698] RootView to use SwitchStore (#699)
- [#691] Adopt sync/async synchronizer changes (#696)
- [#683] Zip log files into one (#692)
- [#684] Improvements for the derivation tool dependency (#689)
- [#678] Adopt TCA 0.52.0 (#688)
- [#682] Adopt removal of the Notification center on the SDK side (#687)
## 0.0.1 build 49
- [#673] End to end bugfix (#679)
Bugs fixed:
- derivation tool live key has hardcoded mainnet so it doesn't recognise and validate zcash testnet addresses
- send to transparent address fails because of Memo("") provided instead of nil
- when transparent address is filled in a send form, the memo input is still present in the UI, memo is not supported by transparent addresses so it should be removed
## 0.0.1 build 48
- [#676] fix About.swift not being present on mainnet target (#677)
- [#654] Convert SDKSynchronizerDependency to regular TCA dependency (#672)
# 0.0.1 build 47
- [#653] Adopt SDK initialisation changes (#671)
- [#668] Balance Breakdown design enhancements (#669)
- [#660] Fix missing percentage on homepage while syncing (#670)
- [#663] Shield Funds button is enabled when there are no funds to shield (#665)
- [#666] Remove Graphics from "create new wallet" screen (#667)
- [#661] Send Button works even if it's apparently disabled (#664)
- [#660] Settings button is not part of a navigation bar (#662)
- [#658] About Screen with version (#659)
- [#652] Each logged TCA actions appears twice in the log (#657)
## 0.0.1 build 46
- [#626] Small UI-UX fixes for 0.0.1-45 (#649)
- [#650] Layout changes for the send screen (#651)
- [#647] Adopt 0.19.1-beta (#648)
- [#597] Sync cannot be retried after a failure (#646)
- [#631] Make Send Form fields avoid being blocked by keyboard (#645)
- [#599] Add ability to shield funds (#641)
- [#632] Show error message for failed transaction (#642)
- [#628] TAZ vs ZEC builds (#637)
- [#639] Show valid balance after app start (#640)
- [#618] Require specific version of SwiftGen (#638)
# 0.0.1 build 45
- [#635] Fix HomeTests
- [#633] build and release from tag 0.0.1-45

View File

@ -1,40 +1,50 @@
# secant-ios-wallet
# Zashi iOS Wallet
This wallet is a Dogfooding effort towards Zcash Halo Arc / NU5 efforts.
This is the official home of the Zashi Zcash wallet for Wallet, a no-frills
Zcash mobile wallet leveraging the [Zcash Swift SDK](https://github.com/Electric-Coin-Company/zcash-swift-wallet-sdk).
# Motivation
Dogfooding - _transitive verb_ - is the practice of an organization using its own product. This app was created to help us learn.
# Production
Please take note: the wallet is not an official product by ECC, but rather a tool for learning about our libraries that it is built on. This means that we do not have robust infrastructure or user support for this application. We open sourced it as a resource to make wallet development easier for the Zcash ecosystem.
The Zashi IOS wallet is publicly available for download in the [AppStore](https://apps.apple.com/cz/app/zashi-zcash-wallet/id1672392439).
# Disclaimers
There are some known areas for improvement:
# Zashi Discord
- This app is mainly intended for learning and improving the related libraries that it uses. There may be bugs.
- Traffic analysis, like in other cryptocurrency wallets, can leak some privacy of the user.
- The wallet requires a trust in the server to display accurate transaction information.
Join the Zashi community on ECC Discord server, report bugs, share ideas, request new features, and help shape Zashi's journey!
See the [Wallet App Threat Model](https://zcash.readthedocs.io/en/latest/rtd_pages/wallet_threat_model.html)
# Reporting an issue
If you'd like to report a technical issue or feature request for the IOS
Wallet, please file a GitHub issue [here](https://github.com/Electric-Coin-Company/zashi-ios/issues/new/choose).
For feature requests and issues related to the Zashi user interface that are
not iOS-specific, please file a GitHub issue [here](https://github.com/Electric-Coin-Company/zashi/issues/new/choose).
If you wish to report a security issue, please follow our
[Responsible Disclosure guidelines](https://github.com/Electric-Coin-Company/zashi/blob/master/responsible_disclosure.md).
See the [Wallet App Threat Model](https://github.com/Electric-Coin-Company/zashi/blob/master/wallet_threat_model.md)
for more information about the security and privacy limitations of the wallet.
If you'd like to sign up to help us test, reach out on discord and let us know! We're always happy to get feedback!
General Zcash questions and/or support requests may also be directed to either:
* [Zcash Forum](https://forum.zcashcommunity.com/)
* [Discord Community](https://discord.io/zcash-community)
# Description
# Contributing
iOS wallet using the Zcash iOS SDK that is maintained by core developers.
Contributions are very much welcomed! Please read our [Contributing Guidelines](/CONTRIBUTING.md)
and [Code of Conduct](/CONDUCT.md). Our backlog has many Issues tagged with the
`good first issue` label. Please fork the repo and make a pull request for us
to review.
This a reference wallet for the following set of features:
- z2z transactions w/ encrypted memos
- reply-to formatted memos
- z2t transactions
- transparent receive-only
- autoshielding on threshold from receive only t-address
Zashi Wallet uses [SwiftLint](https://github.com/realm/SwiftLint) and
[SwiftGen](https://github.com/SwiftGen/SwiftGen) to conform to our coding
guidelines for source code and generate accessors for assets. Please install
these locally when contributing to the project, they are run automatically when
you build.
note: z means sapling shielded addresses.
## Installation of Swiftgen & Swiftlint on Apple Silicon-based hardware
# Installation of Swiftgen & Swiftlint on Apple Silicon chip
### Swiftgen
## Swiftgen
Install it using homebrew
```
$ brew install swiftgen
@ -43,26 +53,14 @@ and create a symbolic link
```
ln -s /opt/homebrew/bin/swiftgen /usr/local/bin
```
## Swiftlint
The project is setup to work with `0.47.0` version. We recommend to install it directly using [the official 0.47.0 package](https://github.com/realm/SwiftLint/releases/download/0.47.0/SwiftLint.pkg). If you follow this step there is no symbolic link needed.
In case you already have swiftlint 0.47.0 ready on your machine and installed via homebrew, create a symbolic link
### Swiftlint
The project is setup to work with `0.50.3` version. We recommend to install it
directly using [the official 0.50.3 package](https://github.com/realm/SwiftLint/releases/download/0.50.3/SwiftLint.pkg).
If you follow this step there is no symbolic link needed.
In case you already have swiftlint 0.50.3 ready on your machine and installed via homebrew, create a symbolic link
```
ln -s /opt/homebrew/bin/swiftlint /usr/local/bin
```
# Contributing
Contributions are very much welcomed! Please read our [Contributing Guidelines](/CONTRIBUTING.md) and [Code of Conduct](/CONDUCT.md). Our backlog has many Issues tagged with the `good first issue` label. Please fork the repo and make a pull request for us to review.
Secant Wallet uses [SwiftLint](https://github.com/realm/SwiftLint) and [SwiftGen](https://github.com/SwiftGen/SwiftGen) to conform to our coding guidelines for source code and generate accessors for assets. Please install these locally when contributing to the project, they are run automatically when you build.
# Reporting an issue
If you wish to report a security issue, please follow our [Responsible Disclosure guidelines](https://github.com/zcash/ZcashLightClientKit/blob/master/responsible_disclosure.md).
For other kind of inquiries, feel welcome to open an Issue if you encounter a bug or would like to request a feature.
# License
MIT

9
modules/.gitignore vendored Normal file
View File

@ -0,0 +1,9 @@
.DS_Store
/.build
/Packages
/*.xcodeproj
xcuserdata/
DerivedData/
.swiftpm/config/registries.json
.swiftpm/xcode/package.xcworkspace/contents.xcworkspacedata
.netrc

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "AddressDetails"
BuildableName = "AddressDetails"
BlueprintName = "AddressDetails"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "AddressDetails"
BuildableName = "AddressDetails"
BlueprintName = "AddressDetails"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "AppVersion"
BuildableName = "AppVersion"
BlueprintName = "AppVersion"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "AppVersion"
BuildableName = "AppVersion"
BlueprintName = "AppVersion"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "AudioServices"
BuildableName = "AudioServices"
BlueprintName = "AudioServices"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "AudioServices"
BuildableName = "AudioServices"
BlueprintName = "AudioServices"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "BalanceBreakdown"
BuildableName = "BalanceBreakdown"
BlueprintName = "BalanceBreakdown"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "BalanceBreakdown"
BuildableName = "BalanceBreakdown"
BlueprintName = "BalanceBreakdown"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "Home"
BuildableName = "Home"
BlueprintName = "Home"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "Home"
BuildableName = "Home"
BlueprintName = "Home"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "ImportWallet"
BuildableName = "ImportWallet"
BlueprintName = "ImportWallet"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "ImportWallet"
BuildableName = "ImportWallet"
BlueprintName = "ImportWallet"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "ImportWallet"
BuildableName = "ImportWallet"
BlueprintName = "ImportWallet"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "ImportWallet"
BuildableName = "ImportWallet"
BlueprintName = "ImportWallet"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "OnboardingFlow"
BuildableName = "OnboardingFlow"
BlueprintName = "OnboardingFlow"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "OnboardingFlow"
BuildableName = "OnboardingFlow"
BlueprintName = "OnboardingFlow"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "Profile"
BuildableName = "Profile"
BlueprintName = "Profile"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "Profile"
BuildableName = "Profile"
BlueprintName = "Profile"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "RecoveryPhraseDisplay"
BuildableName = "RecoveryPhraseDisplay"
BlueprintName = "RecoveryPhraseDisplay"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "RecoveryPhraseDisplay"
BuildableName = "RecoveryPhraseDisplay"
BlueprintName = "RecoveryPhraseDisplay"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "Scan"
BuildableName = "Scan"
BlueprintName = "Scan"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "Scan"
BuildableName = "Scan"
BlueprintName = "Scan"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "SecurityWarning"
BuildableName = "SecurityWarning"
BlueprintName = "SecurityWarning"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "SecurityWarning"
BuildableName = "SecurityWarning"
BlueprintName = "SecurityWarning"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "SendFlow"
BuildableName = "SendFlow"
BlueprintName = "SendFlow"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "SendFlow"
BuildableName = "SendFlow"
BlueprintName = "SendFlow"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "Settings"
BuildableName = "Settings"
BlueprintName = "Settings"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "Settings"
BuildableName = "Settings"
BlueprintName = "Settings"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "TransactionList"
BuildableName = "TransactionList"
BlueprintName = "TransactionList"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "TransactionList"
BuildableName = "TransactionList"
BlueprintName = "TransactionList"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "UIComponents"
BuildableName = "UIComponents"
BlueprintName = "UIComponents"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "UIComponents"
BuildableName = "UIComponents"
BlueprintName = "UIComponents"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "UIComponents"
BuildableName = "UIComponents"
BlueprintName = "UIComponents"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "UIComponents"
BuildableName = "UIComponents"
BlueprintName = "UIComponents"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1520"
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "Welcome"
BuildableName = "Welcome"
BlueprintName = "Welcome"
ReferencedContainer = "container:">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "Welcome"
BuildableName = "Welcome"
BlueprintName = "Welcome"
ReferencedContainer = "container:">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

383
modules/Package.resolved Normal file
View File

@ -0,0 +1,383 @@
{
"pins" : [
{
"identity" : "abseil-cpp-binary",
"kind" : "remoteSourceControl",
"location" : "https://github.com/google/abseil-cpp-binary.git",
"state" : {
"revision" : "bfc0b6f81adc06ce5121eb23f628473638d67c5c",
"version" : "1.2022062300.0"
}
},
{
"identity" : "app-check",
"kind" : "remoteSourceControl",
"location" : "https://github.com/google/app-check.git",
"state" : {
"revision" : "3e464dad87dad2d29bb29a97836789bf0f8f67d2",
"version" : "10.18.1"
}
},
{
"identity" : "combine-schedulers",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/combine-schedulers",
"state" : {
"revision" : "9dc9cbe4bc45c65164fa653a563d8d8db61b09bb",
"version" : "1.0.0"
}
},
{
"identity" : "firebase-ios-sdk",
"kind" : "remoteSourceControl",
"location" : "https://github.com/firebase/firebase-ios-sdk",
"state" : {
"revision" : "f91c8167141d0279726c6f6d9d4a47c026785cbc",
"version" : "10.21.0"
}
},
{
"identity" : "googleappmeasurement",
"kind" : "remoteSourceControl",
"location" : "https://github.com/google/GoogleAppMeasurement.git",
"state" : {
"revision" : "cb8617fab75d181270a1d8f763f26b15c73e2e1e",
"version" : "10.21.0"
}
},
{
"identity" : "googledatatransport",
"kind" : "remoteSourceControl",
"location" : "https://github.com/google/GoogleDataTransport.git",
"state" : {
"revision" : "a732a4b47f59e4f725a2ea10f0c77e93a7131117",
"version" : "9.3.0"
}
},
{
"identity" : "googleutilities",
"kind" : "remoteSourceControl",
"location" : "https://github.com/google/GoogleUtilities.git",
"state" : {
"revision" : "bc27fad73504f3d4af235de451f02ee22586ebd3",
"version" : "7.12.1"
}
},
{
"identity" : "grpc-binary",
"kind" : "remoteSourceControl",
"location" : "https://github.com/google/grpc-binary.git",
"state" : {
"revision" : "a673bc2937fbe886dd1f99c401b01b6d977a9c98",
"version" : "1.49.1"
}
},
{
"identity" : "grpc-swift",
"kind" : "remoteSourceControl",
"location" : "https://github.com/grpc/grpc-swift.git",
"state" : {
"revision" : "84bac657e9930d26e9124bac082f26586dc2d209",
"version" : "1.19.1"
}
},
{
"identity" : "gtm-session-fetcher",
"kind" : "remoteSourceControl",
"location" : "https://github.com/google/gtm-session-fetcher.git",
"state" : {
"revision" : "d415594121c9e8a4f9d79cecee0965cf35e74dbd",
"version" : "3.1.1"
}
},
{
"identity" : "interop-ios-for-google-sdks",
"kind" : "remoteSourceControl",
"location" : "https://github.com/google/interop-ios-for-google-sdks.git",
"state" : {
"revision" : "2d12673670417654f08f5f90fdd62926dc3a2648",
"version" : "100.0.0"
}
},
{
"identity" : "leveldb",
"kind" : "remoteSourceControl",
"location" : "https://github.com/firebase/leveldb.git",
"state" : {
"revision" : "0706abcc6b0bd9cedfbb015ba840e4a780b5159b",
"version" : "1.22.2"
}
},
{
"identity" : "mnemonicswift",
"kind" : "remoteSourceControl",
"location" : "https://github.com/zcash-hackworks/MnemonicSwift",
"state" : {
"revision" : "716a2c32ac2bbd8a1499ac834077df42b75edc85",
"version" : "2.2.4"
}
},
{
"identity" : "nanopb",
"kind" : "remoteSourceControl",
"location" : "https://github.com/firebase/nanopb.git",
"state" : {
"revision" : "819d0a2173aff699fb8c364b6fb906f7cdb1a692",
"version" : "2.30909.0"
}
},
{
"identity" : "promises",
"kind" : "remoteSourceControl",
"location" : "https://github.com/google/promises.git",
"state" : {
"revision" : "e70e889c0196c76d22759eb50d6a0270ca9f1d9e",
"version" : "2.3.1"
}
},
{
"identity" : "sqlite.swift",
"kind" : "remoteSourceControl",
"location" : "https://github.com/stephencelis/SQLite.swift.git",
"state" : {
"revision" : "7a2e3cd27de56f6d396e84f63beefd0267b55ccb",
"version" : "0.14.1"
}
},
{
"identity" : "swift-atomics",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-atomics.git",
"state" : {
"revision" : "6c89474e62719ddcc1e9614989fff2f68208fe10",
"version" : "1.1.0"
}
},
{
"identity" : "swift-case-paths",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-case-paths",
"state" : {
"revision" : "551150d5e60e3be78972607d89cd69069cca3e7c",
"version" : "1.2.4"
}
},
{
"identity" : "swift-clocks",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-clocks",
"state" : {
"revision" : "a8421d68068d8f45fbceb418fbf22c5dad4afd33",
"version" : "1.0.2"
}
},
{
"identity" : "swift-collections",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-collections",
"state" : {
"revision" : "937e904258d22af6e447a0b72c0bc67583ef64a2",
"version" : "1.0.4"
}
},
{
"identity" : "swift-composable-architecture",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-composable-architecture",
"state" : {
"revision" : "cf967a28a8605629559533320d604168d733fc9c",
"version" : "1.8.0"
}
},
{
"identity" : "swift-concurrency-extras",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-concurrency-extras",
"state" : {
"revision" : "bb5059bde9022d69ac516803f4f227d8ac967f71",
"version" : "1.1.0"
}
},
{
"identity" : "swift-crypto",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-crypto.git",
"state" : {
"revision" : "60f13f60c4d093691934dc6cfdf5f508ada1f894",
"version" : "2.6.0"
}
},
{
"identity" : "swift-custom-dump",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-custom-dump",
"state" : {
"revision" : "6ea3b1b6a4957806d72030a32360d4bcb155a0d2",
"version" : "1.2.0"
}
},
{
"identity" : "swift-dependencies",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-dependencies",
"state" : {
"revision" : "09e49dd46932adfe80ce672b4b3772d79ee6c21a",
"version" : "1.2.1"
}
},
{
"identity" : "swift-identified-collections",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-identified-collections",
"state" : {
"revision" : "d1e45f3e1eee2c9193f5369fa9d70a6ddad635e8",
"version" : "1.0.0"
}
},
{
"identity" : "swift-log",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-log.git",
"state" : {
"revision" : "32e8d724467f8fe623624570367e3d50c5638e46",
"version" : "1.5.2"
}
},
{
"identity" : "swift-nio",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio.git",
"state" : {
"revision" : "635b2589494c97e48c62514bc8b37ced762e0a62",
"version" : "2.63.0"
}
},
{
"identity" : "swift-nio-extras",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-extras.git",
"state" : {
"revision" : "0e0d0aab665ff1a0659ce75ac003081f2b1c8997",
"version" : "1.19.0"
}
},
{
"identity" : "swift-nio-http2",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-http2.git",
"state" : {
"revision" : "a8ccf13fa62775277a5d56844878c828bbb3be1a",
"version" : "1.27.0"
}
},
{
"identity" : "swift-nio-ssl",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-ssl.git",
"state" : {
"revision" : "e866a626e105042a6a72a870c88b4c531ba05f83",
"version" : "2.24.0"
}
},
{
"identity" : "swift-nio-transport-services",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-transport-services.git",
"state" : {
"revision" : "41f4098903878418537020075a4d8a6e20a0b182",
"version" : "1.17.0"
}
},
{
"identity" : "swift-parsing",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-parsing",
"state" : {
"revision" : "a0e7d73f462c1c38c59dc40a3969ac40cea42950",
"version" : "0.13.0"
}
},
{
"identity" : "swift-perception",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-perception",
"state" : {
"revision" : "42240120b2a8797595433288ab4118f8042214c3",
"version" : "1.1.1"
}
},
{
"identity" : "swift-protobuf",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-protobuf.git",
"state" : {
"revision" : "ce20dc083ee485524b802669890291c0d8090170",
"version" : "1.22.1"
}
},
{
"identity" : "swift-syntax",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-syntax",
"state" : {
"revision" : "64889f0c732f210a935a0ad7cda38f77f876262d",
"version" : "509.1.1"
}
},
{
"identity" : "swift-system",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-system.git",
"state" : {
"revision" : "025bcb1165deab2e20d4eaba79967ce73013f496",
"version" : "1.2.1"
}
},
{
"identity" : "swift-url-routing",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-url-routing",
"state" : {
"revision" : "13f65cec4de950ba30f08d9bc4abcfa41f9479b9",
"version" : "0.6.0"
}
},
{
"identity" : "swiftui-navigation",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swiftui-navigation",
"state" : {
"revision" : "d9e72f3083c08375794afa216fb2f89c0114f303",
"version" : "1.2.1"
}
},
{
"identity" : "xctest-dynamic-overlay",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/xctest-dynamic-overlay",
"state" : {
"revision" : "b58e6627149808b40634c4552fcf2f44d0b3ca87",
"version" : "1.1.0"
}
},
{
"identity" : "zcash-light-client-ffi",
"kind" : "remoteSourceControl",
"location" : "https://github.com/zcash-hackworks/zcash-light-client-ffi",
"state" : {
"revision" : "c90afd6cc092468e71810bc715ddb49be8210b75",
"version" : "0.5.1"
}
},
{
"identity" : "zcashlightclientkit",
"kind" : "remoteSourceControl",
"location" : "https://github.com/zcash/ZcashLightClientKit",
"state" : {
"revision" : "2ef0e00385a8495b9d7115f7d0f9f1f19f91afa8",
"version" : "2.0.10"
}
}
],
"version" : 2
}

795
modules/Package.swift Normal file
View File

@ -0,0 +1,795 @@
// swift-tools-version: 5.6
// The swift-tools-version declares the minimum version of Swift required to build this package.
import PackageDescription
let package = Package(
name: "modules",
platforms: [
.iOS(.v15)
],
products: [
.library(name: "About", targets: ["About"]),
.library(name: "AddressDetails", targets: ["AddressDetails"]),
.library(name: "AppVersion", targets: ["AppVersion"]),
.library(name: "AudioServices", targets: ["AudioServices"]),
.library(name: "BalanceBreakdown", targets: ["BalanceBreakdown"]),
.library(name: "BalanceFormatter", targets: ["BalanceFormatter"]),
.library(name: "CaptureDevice", targets: ["CaptureDevice"]),
.library(name: "CrashReporter", targets: ["CrashReporter"]),
.library(name: "DatabaseFiles", targets: ["DatabaseFiles"]),
.library(name: "Date", targets: ["Date"]),
.library(name: "Deeplink", targets: ["Deeplink"]),
.library(name: "DeleteWallet", targets: ["DeleteWallet"]),
.library(name: "DerivationTool", targets: ["DerivationTool"]),
.library(name: "DiskSpaceChecker", targets: ["DiskSpaceChecker"]),
.library(name: "ExportLogs", targets: ["ExportLogs"]),
.library(name: "FeedbackGenerator", targets: ["FeedbackGenerator"]),
.library(name: "FileManager", targets: ["FileManager"]),
.library(name: "Generated", targets: ["Generated"]),
.library(name: "HideBalances", targets: ["HideBalances"]),
.library(name: "Home", targets: ["Home"]),
.library(name: "ImportWallet", targets: ["ImportWallet"]),
.library(name: "LocalAuthenticationHandler", targets: ["LocalAuthenticationHandler"]),
.library(name: "LogsHandler", targets: ["LogsHandler"]),
.library(name: "MnemonicClient", targets: ["MnemonicClient"]),
.library(name: "Models", targets: ["Models"]),
.library(name: "NotEnoughFreeSpace", targets: ["NotEnoughFreeSpace"]),
.library(name: "NumberFormatter", targets: ["NumberFormatter"]),
.library(name: "OnboardingFlow", targets: ["OnboardingFlow"]),
.library(name: "PartialProposalError", targets: ["PartialProposalError"]),
.library(name: "Pasteboard", targets: ["Pasteboard"]),
.library(name: "PrivateDataConsent", targets: ["PrivateDataConsent"]),
.library(name: "QRImageDetector", targets: ["QRImageDetector"]),
.library(name: "RecoveryPhraseDisplay", targets: ["RecoveryPhraseDisplay"]),
.library(name: "ReviewRequest", targets: ["ReviewRequest"]),
.library(name: "Root", targets: ["Root"]),
.library(name: "Sandbox", targets: ["Sandbox"]),
.library(name: "Scan", targets: ["Scan"]),
.library(name: "SDKSynchronizer", targets: ["SDKSynchronizer"]),
.library(name: "SecItem", targets: ["SecItem"]),
.library(name: "SecurityWarning", targets: ["SecurityWarning"]),
.library(name: "SendConfirmation", targets: ["SendConfirmation"]),
.library(name: "SendFlow", targets: ["SendFlow"]),
.library(name: "ServerSetup", targets: ["ServerSetup"]),
.library(name: "Settings", targets: ["Settings"]),
.library(name: "SupportDataGenerator", targets: ["SupportDataGenerator"]),
.library(name: "SyncProgress", targets: ["SyncProgress"]),
.library(name: "ReadTransactionsStorage", targets: ["ReadTransactionsStorage"]),
.library(name: "RestoreWalletStorage", targets: ["RestoreWalletStorage"]),
.library(name: "Tabs", targets: ["Tabs"]),
.library(name: "TransactionList", targets: ["TransactionList"]),
.library(name: "UIComponents", targets: ["UIComponents"]),
.library(name: "URIParser", targets: ["URIParser"]),
.library(name: "UserDefaults", targets: ["UserDefaults"]),
.library(name: "UserPreferencesStorage", targets: ["UserPreferencesStorage"]),
.library(name: "Utils", targets: ["Utils"]),
.library(name: "WalletBalances", targets: ["WalletBalances"]),
.library(name: "WalletConfigProvider", targets: ["WalletConfigProvider"]),
.library(name: "WalletStorage", targets: ["WalletStorage"]),
.library(name: "Welcome", targets: ["Welcome"]),
.library(name: "WhatsNew", targets: ["WhatsNew"]),
.library(name: "WhatsNewProvider", targets: ["WhatsNewProvider"]),
.library(name: "ZcashSDKEnvironment", targets: ["ZcashSDKEnvironment"])
],
dependencies: [
.package(url: "https://github.com/pointfreeco/swift-custom-dump.git", from: "1.3.0"),
.package(url: "https://github.com/pointfreeco/swift-composable-architecture", from: "1.9.2"),
.package(url: "https://github.com/pointfreeco/swift-case-paths", from: "1.3.2"),
.package(url: "https://github.com/pointfreeco/swift-url-routing", from: "0.6.0"),
.package(url: "https://github.com/zcash-hackworks/MnemonicSwift", from: "2.2.4"),
.package(url: "https://github.com/Electric-Coin-Company/zcash-swift-wallet-sdk", from: "2.1.6"),
.package(url: "https://github.com/firebase/firebase-ios-sdk", from: "10.24.0")
],
targets: [
.target(
name: "About",
dependencies: [
"AppVersion",
"Generated",
"RestoreWalletStorage",
"UIComponents",
"WhatsNew",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
],
path: "Sources/Features/About"
),
.target(
name: "AddressDetails",
dependencies: [
"Generated",
"Pasteboard",
"UIComponents",
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/AddressDetails"
),
.target(
name: "AppVersion",
dependencies: [
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/AppVersion"
),
.target(
name: "AudioServices",
dependencies: [
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/AudioServices"
),
.target(
name: "BalanceBreakdown",
dependencies: [
"BalanceFormatter",
"Generated",
"DerivationTool",
"MnemonicClient",
"Models",
"NumberFormatter",
"PartialProposalError",
"RestoreWalletStorage",
"SDKSynchronizer",
"SyncProgress",
"UIComponents",
"Utils",
"WalletBalances",
"WalletStorage",
"ZcashSDKEnvironment",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/BalanceBreakdown"
),
.target(
name: "BalanceFormatter",
dependencies: [
"Generated",
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Dependencies/BalanceFormatter"
),
.target(
name: "CaptureDevice",
dependencies: [
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/CaptureDevice"
),
.target(
name: "CrashReporter",
dependencies: [
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "FirebaseCrashlytics", package: "firebase-ios-sdk")
],
path: "Sources/Dependencies/CrashReporter"
),
.target(
name: "DatabaseFiles",
dependencies: [
"FileManager",
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Dependencies/DatabaseFiles"
),
.target(
name: "Date",
dependencies: [
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/Date"
),
.target(
name: "Deeplink",
dependencies: [
"DerivationTool",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "URLRouting", package: "swift-url-routing"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Dependencies/Deeplink"
),
.target(
name: "DeleteWallet",
dependencies: [
"Generated",
"SDKSynchronizer",
"UIComponents",
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/DeleteWallet"
),
.target(
name: "DerivationTool",
dependencies: [
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Dependencies/DerivationTool"
),
.target(
name: "DiskSpaceChecker",
dependencies: [
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
],
path: "Sources/Dependencies/DiskSpaceChecker"
),
.target(
name: "ExportLogs",
dependencies: [
"Generated",
"LogsHandler",
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/ExportLogs"
),
.target(
name: "FeedbackGenerator",
dependencies: [
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/FeedbackGenerator"
),
.target(
name: "FileManager",
dependencies: [
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/FileManager"
),
.target(
name: "Generated",
resources: [.process("Resources")]
),
.target(
name: "HideBalances",
dependencies: [
"UserDefaults",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/HideBalances"
),
.target(
name: "Home",
dependencies: [
"Generated",
"Models",
"RestoreWalletStorage",
"ReviewRequest",
"Scan",
"Settings",
"SDKSynchronizer",
"SyncProgress",
"UIComponents",
"Utils",
"TransactionList",
"WalletBalances",
"ZcashSDKEnvironment",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/Home"
),
.target(
name: "ImportWallet",
dependencies: [
"Generated",
"MnemonicClient",
"UIComponents",
"Utils",
"WalletStorage",
"ZcashSDKEnvironment",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/ImportWallet"
),
.target(
name: "LocalAuthenticationHandler",
dependencies: [
"Generated",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/LocalAuthenticationHandler"
),
.target(
name: "LogsHandler",
dependencies: [
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/LogsHandler"
),
.target(
name: "MnemonicClient",
dependencies: [
.product(name: "MnemonicSwift", package: "MnemonicSwift"),
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/MnemonicClient"
),
.target(
name: "Models",
dependencies: [
"Utils",
"UIComponents",
.product(name: "MnemonicSwift", package: "MnemonicSwift")
],
path: "Sources/Models"
),
.target(
name: "NotEnoughFreeSpace",
dependencies: [
"DiskSpaceChecker",
"Generated",
"Settings",
"UIComponents",
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Features/NotEnoughFreeSpace"
),
.target(
name: "NumberFormatter",
dependencies: [
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/NumberFormatter"
),
.target(
name: "OnboardingFlow",
dependencies: [
"Generated",
"ImportWallet",
"Models",
"SecurityWarning",
"UIComponents",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/OnboardingFlow"
),
.target(
name: "PartialProposalError",
dependencies: [
"Generated",
"SupportDataGenerator",
"UIComponents",
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Features/PartialProposalError"
),
.target(
name: "Pasteboard",
dependencies: [
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/Pasteboard"
),
.target(
name: "PrivateDataConsent",
dependencies: [
"ExportLogs",
"DatabaseFiles",
"Generated",
"Models",
"RestoreWalletStorage",
"UIComponents",
"Utils",
"ZcashSDKEnvironment",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Features/PrivateDataConsent"
),
.target(
name: "QRImageDetector",
dependencies: [
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/QRImageDetector"
),
.target(
name: "RecoveryPhraseDisplay",
dependencies: [
"Generated",
"MnemonicClient",
"Models",
"NumberFormatter",
"UIComponents",
"Utils",
"WalletStorage",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/RecoveryPhraseDisplay"
),
.target(
name: "RestoreWalletStorage",
dependencies: [
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/RestoreWalletStorage"
),
.target(
name: "ReviewRequest",
dependencies: [
"AppVersion",
"Date",
"UserDefaults",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/ReviewRequest"
),
.target(
name: "Root",
dependencies: [
"CrashReporter",
"DatabaseFiles",
"Deeplink",
"DerivationTool",
"DiskSpaceChecker",
"ExportLogs",
"Generated",
"HideBalances",
"MnemonicClient",
"Models",
"NotEnoughFreeSpace",
"NumberFormatter",
"OnboardingFlow",
"Pasteboard",
"ReadTransactionsStorage",
"RecoveryPhraseDisplay",
"RestoreWalletStorage",
"Sandbox",
"SDKSynchronizer",
"Tabs",
"UIComponents",
"UserDefaults",
"UserPreferencesStorage",
"Utils",
"WalletConfigProvider",
"WalletStorage",
"Welcome",
"ZcashSDKEnvironment",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/Root"
),
.target(
name: "Sandbox",
dependencies: [
"RecoveryPhraseDisplay",
"Scan",
"SendFlow",
"TransactionList",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/Sandbox"
),
.target(
name: "Scan",
dependencies: [
"CaptureDevice",
"Generated",
"QRImageDetector",
"URIParser",
"UIComponents",
"Utils",
"ZcashSDKEnvironment",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/Scan"
),
.target(
name: "SDKSynchronizer",
dependencies: [
"DatabaseFiles",
"Models",
"ZcashSDKEnvironment",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Dependencies/SDKSynchronizer"
),
.target(
name: "SecItem",
dependencies: [
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/SecItem"
),
.target(
name: "SecurityWarning",
dependencies: [
"AppVersion",
"Generated",
"MnemonicClient",
"Models",
"NumberFormatter",
"RecoveryPhraseDisplay",
"UIComponents",
"Utils",
"WalletStorage",
"ZcashSDKEnvironment",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Features/SecurityWarning"
),
.target(
name: "SendConfirmation",
dependencies: [
"AudioServices",
"BalanceFormatter",
"DerivationTool",
"Generated",
"LocalAuthenticationHandler",
"MnemonicClient",
"Models",
"PartialProposalError",
"Scan",
"SDKSynchronizer",
"UIComponents",
"Utils",
"WalletBalances",
"WalletStorage",
"ZcashSDKEnvironment",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/SendConfirmation"
),
.target(
name: "SendFlow",
dependencies: [
"AudioServices",
"BalanceFormatter",
"DerivationTool",
"Generated",
"Models",
"Scan",
"SDKSynchronizer",
"UIComponents",
"Utils",
"WalletBalances",
"ZcashSDKEnvironment",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/SendFlow"
),
.target(
name: "ServerSetup",
dependencies: [
"Generated",
"SDKSynchronizer",
"UIComponents",
"UserPreferencesStorage",
"ZcashSDKEnvironment",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/ServerSetup"
),
.target(
name: "Settings",
dependencies: [
"About",
"AppVersion",
"DeleteWallet",
"Generated",
"LocalAuthenticationHandler",
"Models",
"Pasteboard",
"PrivateDataConsent",
"RecoveryPhraseDisplay",
"RestoreWalletStorage",
"ServerSetup",
"SupportDataGenerator",
"UIComponents",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/Settings"
),
.target(
name: "SupportDataGenerator",
dependencies: [
"Generated",
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/SupportDataGenerator"
),
.target(
name: "SyncProgress",
dependencies: [
"Generated",
"Models",
"SDKSynchronizer",
"UIComponents",
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Features/SyncProgress"
),
.target(
name: "ReadTransactionsStorage",
dependencies: [
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/ReadTransactionsStorage"
),
.target(
name: "Tabs",
dependencies: [
"AddressDetails",
"BalanceBreakdown",
"Generated",
"HideBalances",
"Home",
"RestoreWalletStorage",
"SendConfirmation",
"SendFlow",
"Settings",
"UIComponents",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/Tabs"
),
.target(
name: "TransactionList",
dependencies: [
"Generated",
"Models",
"Pasteboard",
"SDKSynchronizer",
"ReadTransactionsStorage",
"UIComponents",
"Utils",
"ZcashSDKEnvironment",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/TransactionList"
),
.target(
name: "UIComponents",
dependencies: [
"BalanceFormatter",
"DerivationTool",
"Generated",
"HideBalances",
"NumberFormatter",
"SupportDataGenerator",
"Utils",
"ZcashSDKEnvironment"
],
path: "Sources/UIComponents"
),
.target(
name: "URIParser",
dependencies: [
"DerivationTool",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Dependencies/URIParser"
),
.target(
name: "UserDefaults",
dependencies: [
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/UserDefaults"
),
.target(
name: "UserPreferencesStorage",
dependencies: [
"UserDefaults",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Dependencies/UserPreferencesStorage"
),
.target(
name: "Utils",
dependencies: [
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk"),
.product(name: "CasePaths", package: "swift-case-paths"),
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Utils"
),
.target(
name: "WalletBalances",
dependencies: [
"Generated",
"Models",
"SDKSynchronizer",
"UIComponents",
"Utils",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Features/WalletBalances"
),
.target(
name: "WalletConfigProvider",
dependencies: [
"Utils",
"Models",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/WalletConfigProvider"
),
.target(
name: "WalletStorage",
dependencies: [
"Utils",
"SecItem",
"MnemonicClient",
"Models",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture"),
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk")
],
path: "Sources/Dependencies/WalletStorage"
),
.target(
name: "Welcome",
dependencies: [
"Generated",
"NumberFormatter",
"UIComponents",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Features/Welcome"
),
.target(
name: "WhatsNew",
dependencies: [
"Generated",
"UIComponents",
"WhatsNewProvider",
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Features/WhatsNew"
),
.target(
name: "WhatsNewProvider",
dependencies: [
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/WhatsNewProvider"
),
.target(
name: "ZcashSDKEnvironment",
dependencies: [
"Generated",
"UserDefaults",
"UserPreferencesStorage",
.product(name: "ZcashLightClientKit", package: "zcash-swift-wallet-sdk"),
.product(name: "ComposableArchitecture", package: "swift-composable-architecture")
],
path: "Sources/Dependencies/ZcashSDKEnvironment"
)
]
)

View File

@ -0,0 +1,25 @@
//
// AppVersionInterface.swift
// secant-testnet
//
// Created by Lukáš Korba on 12.11.2022.
//
import ComposableArchitecture
extension DependencyValues {
public var appVersion: AppVersionClient {
get { self[AppVersionClient.self] }
set { self[AppVersionClient.self] = newValue }
}
}
public struct AppVersionClient {
public let appVersion: () -> String
public let appBuild: () -> String
public init(appVersion: @escaping () -> String, appBuild: @escaping () -> String) {
self.appVersion = appVersion
self.appBuild = appBuild
}
}

View File

@ -9,7 +9,7 @@ import Foundation
import ComposableArchitecture
extension AppVersionClient: DependencyKey {
static let liveValue = Self(
public static let liveValue = Self(
appVersion: { Bundle.main.infoDictionary?["CFBundleShortVersionString"] as? String ?? "" },
appBuild: { Bundle.main.infoDictionary?["CFBundleVersion"] as? String ?? "" }
)

View File

@ -6,7 +6,7 @@
//
extension AppVersionClient {
static let mock = Self(
public static let mock = Self(
appVersion: { "0.0.1" },
appBuild: { "31" }
)

View File

@ -9,7 +9,7 @@ import ComposableArchitecture
import XCTestDynamicOverlay
extension AppVersionClient: TestDependencyKey {
static let testValue = Self(
public static let testValue = Self(
appVersion: XCTUnimplemented("\(Self.self).appVersion", placeholder: ""),
appBuild: XCTUnimplemented("\(Self.self).appBuild", placeholder: "")
)

View File

@ -9,12 +9,16 @@ import ComposableArchitecture
import AVFoundation
extension DependencyValues {
var audioServices: AudioServicesClient {
public var audioServices: AudioServicesClient {
get { self[AudioServicesClient.self] }
set { self[AudioServicesClient.self] = newValue }
}
}
struct AudioServicesClient {
let systemSoundVibrate: () -> Void
public struct AudioServicesClient {
public let systemSoundVibrate: () -> Void
public init(systemSoundVibrate: @escaping () -> Void) {
self.systemSoundVibrate = systemSoundVibrate
}
}

View File

@ -9,7 +9,7 @@ import AVFoundation
import ComposableArchitecture
extension AudioServicesClient: DependencyKey {
static let liveValue = Self(
public static let liveValue = Self(
systemSoundVibrate: { AudioServicesPlaySystemSound(SystemSoundID(kSystemSoundID_Vibrate)) }
)
}

View File

@ -9,7 +9,7 @@ import ComposableArchitecture
import XCTestDynamicOverlay
extension AudioServicesClient: TestDependencyKey {
static let testValue = Self(
public static let testValue = Self(
systemSoundVibrate: XCTUnimplemented("\(Self.self).systemSoundVibrate")
)
}

View File

@ -0,0 +1,25 @@
//
// BalanceFormatterInterface.swift
// secant-testnet
//
// Created by Lukáš Korba on 12.11.2022.
//
import Foundation
import ComposableArchitecture
import ZcashLightClientKit
extension DependencyValues {
public var balanceFormatter: BalanceFormatterClient {
get { self[BalanceFormatterClient.self] }
set { self[BalanceFormatterClient.self] = newValue }
}
}
public struct BalanceFormatterClient {
public var convert: (
Zatoshi,
ZatoshiStringRepresentation.PrefixSymbol,
ZatoshiStringRepresentation.Format
) -> ZatoshiStringRepresentation
}

View File

@ -0,0 +1,15 @@
//
// BalanceFormatterLiveKey.swift
// secant-testnet
//
// Created by Lukáš Korba on 14.11.2022.
//
import Foundation
import ComposableArchitecture
extension BalanceFormatterClient: DependencyKey {
public static let liveValue = Self(
convert: { ZatoshiStringRepresentation($0, prefixSymbol: $1, format: $2) }
)
}

View File

@ -0,0 +1,21 @@
//
// BalanceFormatterTestKey.swift
// secant-testnet
//
// Created by Lukáš Korba on 14.11.2022.
//
import ComposableArchitecture
import XCTestDynamicOverlay
extension BalanceFormatterClient: TestDependencyKey {
public static let testValue = Self(
convert: XCTUnimplemented("\(Self.self).convert", placeholder: .placeholer)
)
}
extension BalanceFormatterClient {
public static let noOp = Self(
convert: { _, _, _ in .placeholer }
)
}

View File

@ -0,0 +1,92 @@
//
// ZatoshiStringRepresentation.swift
//
//
// Created by Lukáš Korba on 10.11.2023.
//
import Foundation
import ZcashLightClientKit
import ComposableArchitecture
import Generated
import Utils
public struct ZatoshiStringRepresentation: Equatable {
public enum PrefixSymbol: Equatable {
case none
case minus
case plus
}
public enum Format: Equatable {
case abbreviated
case expanded
}
public let mostSignificantDigits: String
public let leastSignificantDigits: String
public let feeFormat = ZatoshiStringRepresentation.feeFormat
public init(
_ zatoshi: Zatoshi,
prefixSymbol: PrefixSymbol = .none,
format: Format = .abbreviated
) {
var symbol = ""
switch prefixSymbol {
case .minus: symbol = "-"
case .plus: symbol = "+"
default: break
}
// 0 zatoshi case
if zatoshi.amount == 0 {
self.mostSignificantDigits = "\(symbol)\(Zatoshi(0).decimalZashiFormatted())"
self.leastSignificantDigits = ""
} else if zatoshi.amount < 100_000 && format == .abbreviated {
// 0 for most significant but non-0 for least ones
self.mostSignificantDigits = "\(symbol)\(Zatoshi(0).decimalZashiFormatted())..."
self.leastSignificantDigits = ""
} else {
if format == .expanded {
let formatted = zatoshi.decimalZashiFullFormatted()
let leastSignificantDigits = String(formatted.suffix(5))
let mostSignificantDigits = formatted.dropLast(5)
var leastTrimmed = ""
var useTheRest = false
for char in leastSignificantDigits.reversed() {
if char != "0" {
useTheRest = true
}
if useTheRest {
leastTrimmed += String(char)
}
}
leastTrimmed = String(leastTrimmed.reversed())
self.mostSignificantDigits = "\(symbol)\(mostSignificantDigits)"
self.leastSignificantDigits = "\(leastTrimmed)"
} else {
let formatted = zatoshi.decimalZashiFormatted()
self.mostSignificantDigits = "\(symbol)\(formatted)"
self.leastSignificantDigits = ""
}
}
}
}
extension ZatoshiStringRepresentation {
static let placeholer = Self(Zatoshi(123_456_000))
}
extension ZatoshiStringRepresentation {
public static var feeFormat: String { L10n.General.fee(Zatoshi(100_000).decimalZashiFormatted()) }
}

View File

@ -0,0 +1,28 @@
//
// CaptureDeviceInterface.swift
// secant-testnet
//
// Created by Lukáš Korba on 11.11.2022.
//
import ComposableArchitecture
extension DependencyValues {
public var captureDevice: CaptureDeviceClient {
get { self[CaptureDeviceClient.self] }
set { self[CaptureDeviceClient.self] = newValue }
}
}
public struct CaptureDeviceClient {
public enum CaptureDeviceClientError: Error {
case authorizationStatus
case captureDevice
case lockForConfiguration
case torchUnavailable
}
public let isAuthorized: () -> Bool
public let isTorchAvailable: () -> Bool
public let torch: (Bool) throws -> Void
}

View File

@ -9,17 +9,20 @@ import AVFoundation
import ComposableArchitecture
extension CaptureDeviceClient: DependencyKey {
static let liveValue = Self(
public static let liveValue = Self(
isAuthorized: {
AVCaptureDevice.authorizationStatus(for: .video) == .authorized
},
isTorchAvailable: {
guard let videoCaptureDevice = AVCaptureDevice.default(for: .video) else {
throw CaptureDeviceClientError.captureDeviceFailed
return false
}
return videoCaptureDevice.hasTorch
},
torch: { isTorchOn in
guard let videoCaptureDevice = AVCaptureDevice.default(for: .video) else {
throw CaptureDeviceClientError.captureDeviceFailed
throw CaptureDeviceClientError.captureDevice
}
guard videoCaptureDevice.hasTorch else {
@ -31,7 +34,7 @@ extension CaptureDeviceClient: DependencyKey {
videoCaptureDevice.torchMode = isTorchOn ? .on : .off
videoCaptureDevice.unlockForConfiguration()
} catch {
throw CaptureDeviceClientError.lockFailed
throw CaptureDeviceClientError.lockForConfiguration
}
}
)

View File

@ -9,14 +9,16 @@ import ComposableArchitecture
import XCTestDynamicOverlay
extension CaptureDeviceClient: TestDependencyKey {
static let testValue = Self(
public static let testValue = Self(
isAuthorized: XCTUnimplemented("\(Self.self).isAuthorized", placeholder: false),
isTorchAvailable: XCTUnimplemented("\(Self.self).isTorchAvailable", placeholder: false),
torch: XCTUnimplemented("\(Self.self).torch")
)
}
extension CaptureDeviceClient {
static let noOp = Self(
public static let noOp = Self(
isAuthorized: { false },
isTorchAvailable: { false },
torch: { _ in }
)

View File

@ -1,5 +1,5 @@
//
// CrashReportingInterface.swift
// CrashReporterInterface.swift
// secant-testnet
//
// Created by Francisco Gindre on 2/2/23.
@ -9,24 +9,24 @@ import ComposableArchitecture
import Foundation
extension DependencyValues {
var crashReporter: CrashReporterClient {
public var crashReporter: CrashReporterClient {
get { self[CrashReporterClient.self] }
set { self[CrashReporterClient.self] = newValue }
}
}
struct CrashReporterClient {
public struct CrashReporterClient {
/// Configures the crash reporter if possible.
/// if it can't be configured this will fail silently
var configure: (Bool) -> Void
public var configure: (Bool) -> Void
/// this will test the crash reporter
/// - Note: depending of the crash reporter this may or may not crash your app.
var testCrash: () -> Void
public var testCrash: () -> Void
/// this will tell the crash reporter that the user a has decided to opt-in crash reporting
var optIn: () -> Void
/// this will tell the crash reporter that the user has decided to opt-in crash reporting
public var optIn: () -> Void
/// this will tell the crash reporter that the user has decided to opt-out of crash reporting
var optOut: () -> Void
public var optOut: () -> Void
}

View File

@ -6,11 +6,12 @@
//
import ComposableArchitecture
import FirebaseCore
import Foundation
import Firebase
import FirebaseCrashlytics
extension CrashReporterClient: DependencyKey {
static let liveValue = CrashReporterClient(
public static let liveValue = CrashReporterClient(
configure: { canConfigure in
let fileName = "GoogleService-Info.plist"

View File

@ -0,0 +1,27 @@
//
// CrashReporterTestKey.swift
// secant-testnet
//
// Created by Francisco Gindre on 2/2/23.
//
import ComposableArchitecture
import XCTestDynamicOverlay
extension CrashReporterClient: TestDependencyKey {
public static let testValue = Self(
configure: XCTUnimplemented("\(Self.self).configure"),
testCrash: XCTUnimplemented("\(Self.self).testCrash"),
optIn: XCTUnimplemented("\(Self.self).optIn"),
optOut: XCTUnimplemented("\(Self.self).optOut")
)
}
extension CrashReporterClient {
public static let noOp = Self(
configure: { _ in },
testCrash: { },
optIn: { },
optOut: { }
)
}

View File

@ -0,0 +1,84 @@
//
// DatabaseFiles.swift
// secant-testnet
//
// Created by Lukáš Korba on 05.04.2022.
//
import Foundation
import ZcashLightClientKit
import FileManager
public struct DatabaseFiles {
enum DatabaseFilesError: Error {
case getFsBlockDbRoot
case getDocumentsURL
case getCacheURL
case getDataURL
case getOutputParamsURL
case getPendingURL
case getSpendParamsURL
case nukeFiles
case filesPresentCheck
}
private let fileManager: FileManagerClient
public init(fileManager: FileManagerClient) {
self.fileManager = fileManager
}
func documentsDirectory() -> URL {
do {
return try fileManager.url(.documentDirectory, .userDomainMask, nil, true)
} catch {
// This is not super clean but this is second best thing when the above call fails.
return URL(fileURLWithPath: NSHomeDirectory()).appendingPathComponent("Documents")
}
}
func cacheDbURL(for network: ZcashNetwork) -> URL {
return documentsDirectory()
.appendingPathComponent(
"\(network.constants.defaultDbNamePrefix)cache.db",
isDirectory: false
)
}
func dataDbURL(for network: ZcashNetwork) -> URL {
return documentsDirectory()
.appendingPathComponent(
"\(network.constants.defaultDbNamePrefix)data.db",
isDirectory: false
)
}
func outputParamsURL(for network: ZcashNetwork) -> URL {
return documentsDirectory()
.appendingPathComponent(
"\(network.constants.defaultDbNamePrefix)sapling-output.params",
isDirectory: false
)
}
func pendingDbURL(for network: ZcashNetwork) -> URL {
return documentsDirectory()
.appendingPathComponent(
"\(network.constants.defaultDbNamePrefix)pending.db",
isDirectory: false
)
}
func spendParamsURL(for network: ZcashNetwork) -> URL {
return documentsDirectory()
.appendingPathComponent(
"\(network.constants.defaultDbNamePrefix)sapling-spend.params",
isDirectory: false
)
}
func areDbFilesPresent(for network: ZcashNetwork) -> Bool {
let dataDbURL = dataDbURL(for: network)
return fileManager.fileExists(dataDbURL.path)
}
}

View File

@ -0,0 +1,28 @@
//
// DatabaseFilesInterface.swift
// secant-testnet
//
// Created by Lukáš Korba on 11.11.2022.
//
import Foundation
import ComposableArchitecture
import ZcashLightClientKit
extension DependencyValues {
public var databaseFiles: DatabaseFilesClient {
get { self[DatabaseFilesClient.self] }
set { self[DatabaseFilesClient.self] = newValue }
}
}
public struct DatabaseFilesClient {
public let documentsDirectory: () -> URL
public let fsBlockDbRootFor: (ZcashNetwork) -> URL
public let cacheDbURLFor: (ZcashNetwork) -> URL
public var dataDbURLFor: (ZcashNetwork) -> URL
public let outputParamsURLFor: (ZcashNetwork) -> URL
public let pendingDbURLFor: (ZcashNetwork) -> URL
public let spendParamsURLFor: (ZcashNetwork) -> URL
public var areDbFilesPresentFor: (ZcashNetwork) -> Bool
}

View File

@ -7,40 +7,38 @@
import ComposableArchitecture
import ZcashLightClientKit
import FileManager
extension DatabaseFilesClient: DependencyKey {
static let liveValue = DatabaseFilesClient.live()
public static let liveValue = DatabaseFilesClient.live()
static func live(databaseFiles: DatabaseFiles = DatabaseFiles(fileManager: .live)) -> Self {
public static func live(databaseFiles: DatabaseFiles = DatabaseFiles(fileManager: .live)) -> Self {
Self(
documentsDirectory: {
try databaseFiles.documentsDirectory()
databaseFiles.documentsDirectory()
},
fsBlockDbRootFor: { network in
try databaseFiles.documentsDirectory()
databaseFiles.documentsDirectory()
.appendingPathComponent(network.networkType.chainName)
.appendingPathComponent(ZcashSDK.defaultFsCacheName, isDirectory: true)
},
cacheDbURLFor: { network in
try databaseFiles.cacheDbURL(for: network)
databaseFiles.cacheDbURL(for: network)
},
dataDbURLFor: { network in
try databaseFiles.dataDbURL(for: network)
databaseFiles.dataDbURL(for: network)
},
outputParamsURLFor: { network in
try databaseFiles.outputParamsURL(for: network)
databaseFiles.outputParamsURL(for: network)
},
pendingDbURLFor: { network in
try databaseFiles.pendingDbURL(for: network)
databaseFiles.pendingDbURL(for: network)
},
spendParamsURLFor: { network in
try databaseFiles.spendParamsURL(for: network)
databaseFiles.spendParamsURL(for: network)
},
areDbFilesPresentFor: { network in
try databaseFiles.areDbFilesPresent(for: network)
},
nukeDbFilesFor: { network in
try databaseFiles.nukeDbFiles(for: network)
databaseFiles.areDbFilesPresent(for: network)
}
)
}

View File

@ -8,9 +8,10 @@
import Foundation
import ComposableArchitecture
import XCTestDynamicOverlay
import Utils
extension DatabaseFilesClient: TestDependencyKey {
static let testValue = Self(
public static let testValue = Self(
documentsDirectory: XCTUnimplemented("\(Self.self).documentsDirectory", placeholder: .emptyURL),
fsBlockDbRootFor: XCTUnimplemented("\(Self.self).fsBlockDbRootFor", placeholder: .emptyURL),
cacheDbURLFor: XCTUnimplemented("\(Self.self).cacheDbURLFor", placeholder: .emptyURL),
@ -18,19 +19,12 @@ extension DatabaseFilesClient: TestDependencyKey {
outputParamsURLFor: XCTUnimplemented("\(Self.self).outputParamsURLFor", placeholder: .emptyURL),
pendingDbURLFor: XCTUnimplemented("\(Self.self).pendingDbURLFor", placeholder: .emptyURL),
spendParamsURLFor: XCTUnimplemented("\(Self.self).spendParamsURLFor", placeholder: .emptyURL),
areDbFilesPresentFor: XCTUnimplemented("\(Self.self).areDbFilesPresentFor", placeholder: false),
nukeDbFilesFor: XCTUnimplemented("\(Self.self).nukeDbFilesFor")
areDbFilesPresentFor: XCTUnimplemented("\(Self.self).areDbFilesPresentFor", placeholder: false)
)
}
extension URL {
/// The `DatabaseFilesClient` API returns an instance of the URL or throws an error.
/// In order to use placeholders for the URL we need a URL instance, hence `emptyURL` and force unwrapp.
static let emptyURL = URL(string: "http://empty.url")!// swiftlint:disable:this force_unwrapping
}
extension DatabaseFilesClient {
static let noOp = Self(
public static let noOp = Self(
documentsDirectory: { .emptyURL },
fsBlockDbRootFor: { _ in .emptyURL },
cacheDbURLFor: { _ in .emptyURL },
@ -38,7 +32,6 @@ extension DatabaseFilesClient {
outputParamsURLFor: { _ in .emptyURL },
pendingDbURLFor: { _ in .emptyURL },
spendParamsURLFor: { _ in .emptyURL },
areDbFilesPresentFor: { _ in false },
nukeDbFilesFor: { _ in }
areDbFilesPresentFor: { _ in false }
)
}

View File

@ -0,0 +1,24 @@
//
// DateClient.swift
// secant-testnet
//
// Created by Lukáš Korba on 04.04.2023.
//
import Foundation
import ComposableArchitecture
extension DependencyValues {
public var date: DateClient {
get { self[DateClient.self] }
set { self[DateClient.self] = newValue }
}
}
public struct DateClient {
public let now: () -> Date
public init(now: @escaping () -> Date) {
self.now = now
}
}

View File

@ -0,0 +1,15 @@
//
// DateLiveKey.swift
// secant-testnet
//
// Created by Lukáš Korba on 04.04.2023.
//
import Foundation
import ComposableArchitecture
extension DateClient: DependencyKey {
public static let liveValue = Self(
now: { Date.now }
)
}

View File

@ -0,0 +1,16 @@
//
// DateTestKey.swift
// secant-testnet
//
// Created by Lukáš Korba on 15.11.2022.
//
import Foundation
import ComposableArchitecture
import XCTestDynamicOverlay
extension DateClient: TestDependencyKey {
public static let testValue = Self(
now: XCTUnimplemented("\(Self.self).now", placeholder: Date.now)
)
}

View File

@ -10,22 +10,28 @@ import URLRouting
import ComposableArchitecture
import ZcashLightClientKit
struct Deeplink {
enum Destination: Equatable {
public struct Deeplink {
public enum Destination: Equatable {
case home
case send(amount: Int64, address: String, memo: String)
case send(amount: Int, address: String, memo: String)
}
func resolveDeeplinkURL(_ url: URL, isValidZcashAddress: (String) throws -> Bool) throws -> Destination {
public init() { }
public func resolveDeeplinkURL(
_ url: URL,
networkType: NetworkType,
isValidZcashAddress: (String, NetworkType) throws -> Bool
) throws -> Destination {
// simplified format zcash:<address>
// TODO: [#109] simplified for now until ZIP-321 is implememnted (https://github.com/zcash/secant-ios-wallet/issues/109)
// TODO: [#109] simplified for now until ZIP-321 is implememnted (https://github.com/Electric-Coin-Company/zashi-ios/issues/109)
let address = url.absoluteString.replacingOccurrences(of: "zcash:", with: "")
do {
if try isValidZcashAddress(address) {
if try isValidZcashAddress(address, networkType) {
return .send(amount: 0, address: address, memo: "")
}
}
// regular URL format zcash://
let appRouter = OneOf {
// GET /home
@ -37,7 +43,7 @@ struct Deeplink {
Route(.case(Destination.send(amount:address:memo:))) {
Path { "home"; "send" }
Query {
Field("amount", default: 0) { Int64.parser() }
Field("amount", default: 0) { Digits() }
Field("address", .string, default: "")
Field("memo", .string, default: "")
}

View File

@ -0,0 +1,26 @@
//
// DeeplinkInterface.swift
// secant-testnet
//
// Created by Lukáš Korba on 11.11.2022.
//
import Foundation
import ComposableArchitecture
import ZcashLightClientKit
import DerivationTool
extension DependencyValues {
public var deeplink: DeeplinkClient {
get { self[DeeplinkClient.self] }
set { self[DeeplinkClient.self] = newValue }
}
}
public struct DeeplinkClient {
public let resolveDeeplinkURL: (URL, NetworkType, DerivationToolClient) throws -> Deeplink.Destination
public init(resolveDeeplinkURL: @escaping (URL, NetworkType, DerivationToolClient) throws -> Deeplink.Destination) {
self.resolveDeeplinkURL = resolveDeeplinkURL
}
}

View File

@ -8,7 +8,7 @@
import ComposableArchitecture
extension DeeplinkClient: DependencyKey {
static let liveValue = Self(
resolveDeeplinkURL: { try Deeplink().resolveDeeplinkURL($0, isValidZcashAddress: $1.isValidZcashAddress) }
public static let liveValue = Self(
resolveDeeplinkURL: { try Deeplink().resolveDeeplinkURL($0, networkType: $1, isValidZcashAddress: $2.isZcashAddress) }
)
}

View File

@ -9,7 +9,7 @@ import ComposableArchitecture
import XCTestDynamicOverlay
extension DeeplinkClient: TestDependencyKey {
static let testValue = Self(
public static let testValue = Self(
resolveDeeplinkURL: XCTUnimplemented("\(Self.self).resolveDeeplinkURL")
)
}

View File

@ -9,26 +9,32 @@ import ComposableArchitecture
import ZcashLightClientKit
extension DependencyValues {
var derivationTool: DerivationToolClient {
public var derivationTool: DerivationToolClient {
get { self[DerivationToolClient.self] }
set { self[DerivationToolClient.self] = newValue }
}
}
struct DerivationToolClient {
public struct DerivationToolClient {
/// Given a seed and a number of accounts, return the associated spending keys.
/// - Parameter seed: the seed from which to derive spending keys.
/// - Parameter accountIndex: Index of account to use. Multiple accounts are not fully
/// supported so the default value of 0 is recommended.
/// - Returns: the spending keys that correspond to the seed, formatted as Strings.
var deriveSpendingKey: ([UInt8], Int) throws -> UnifiedSpendingKey
public var deriveSpendingKey: ([UInt8], Int, NetworkType) throws -> UnifiedSpendingKey
/// Checks validity of the transparent address.
var isValidTransparentAddress: (String) throws -> Bool
/// Given a unified spending key, returns the associated unified viewwing key.
public var deriveUnifiedFullViewingKey: (UnifiedSpendingKey, NetworkType) throws -> UnifiedFullViewingKey
/// Checks validity of the unified address.
public var isUnifiedAddress: (String, NetworkType) -> Bool
/// Checks validity of the shielded address.
var isValidSaplingAddress: (String) throws -> Bool
public var isSaplingAddress: (String, NetworkType) -> Bool
/// Checks validity of the transparent address.
public var isTransparentAddress: (String, NetworkType) -> Bool
/// Checks if given address is a valid zcash address.
var isValidZcashAddress: (String) throws -> Bool
public var isZcashAddress: (String, NetworkType) -> Bool
}

View File

@ -0,0 +1,65 @@
//
// DerivationToolLiveKey.swift
// secant-testnet
//
// Created by Lukáš Korba on 12.11.2022.
//
import ComposableArchitecture
import ZcashLightClientKit
extension DerivationToolClient: DependencyKey {
public static let liveValue = DerivationToolClient.live()
public static func live() -> Self {
Self(
deriveSpendingKey: { seed, accountIndex, networkType in
try DerivationTool(networkType: networkType).deriveUnifiedSpendingKey(seed: seed, accountIndex: accountIndex)
},
deriveUnifiedFullViewingKey: { spendingKey, networkType in
try DerivationTool(networkType: networkType).deriveUnifiedFullViewingKey(from: spendingKey)
},
isUnifiedAddress: { address, networkType in
do {
if case .unified = try Recipient(address, network: networkType) {
return true
} else {
return false
}
} catch {
return false
}
},
isSaplingAddress: { address, networkType in
do {
if case .sapling = try Recipient(address, network: networkType) {
return true
} else {
return false
}
} catch {
return false
}
},
isTransparentAddress: { address, networkType in
do {
if case .transparent = try Recipient(address, network: networkType) {
return true
} else {
return false
}
} catch {
return false
}
},
isZcashAddress: { address, networkType in
do {
_ = try Recipient(address, network: networkType)
return true
} catch {
return false
}
}
)
}
}

View File

@ -0,0 +1,33 @@
//
// DerivationToolTestKey.swift
// secant-testnet
//
// Created by Lukáš Korba on 12.11.2022.
//
import ComposableArchitecture
import XCTestDynamicOverlay
import ZcashLightClientKit
import Utils
extension DerivationToolClient: TestDependencyKey {
public static let testValue = Self(
deriveSpendingKey: XCTUnimplemented("\(Self.self).deriveSpendingKey"),
deriveUnifiedFullViewingKey: XCTUnimplemented("\(Self.self).deriveUnifiedFullViewingKey"),
isUnifiedAddress: XCTUnimplemented("\(Self.self).isUnifiedAddress", placeholder: false),
isSaplingAddress: XCTUnimplemented("\(Self.self).isSaplingAddress", placeholder: false),
isTransparentAddress: XCTUnimplemented("\(Self.self).isTransparentAddress", placeholder: false),
isZcashAddress: XCTUnimplemented("\(Self.self).isZcashAddress", placeholder: false)
)
}
extension DerivationToolClient {
public static let noOp = Self(
deriveSpendingKey: { _, _, _ in throw "NotImplemented" },
deriveUnifiedFullViewingKey: { _, _ in throw "NotImplemented" },
isUnifiedAddress: { _, _ in return false },
isSaplingAddress: { _, _ in return false },
isTransparentAddress: { _, _ in return false },
isZcashAddress: { _, _ in return false }
)
}

View File

@ -7,17 +7,17 @@
import Foundation
struct DiskSpaceChecker {
public struct DiskSpaceChecker {
/// Free space on disk in bytes required to do sync
func freeSpaceRequiredForSync() -> Int64 {
return 1 * 1024 * 1024 * 1024 // 1GB converted to bytes
public func freeSpaceRequiredForSync() -> Int64 {
1 * 1024 * 1024 * 1024 // 1GB converted to bytes
}
func hasEnoughFreeSpaceForSync() -> Bool {
return freeSpace() > freeSpaceRequiredForSync()
public func hasEnoughFreeSpaceForSync() -> Bool {
freeSpace() > freeSpaceRequiredForSync()
}
func freeSpace() -> Int64 {
public func freeSpace() -> Int64 {
do {
let fileURL = URL(fileURLWithPath: NSHomeDirectory())
let values = try fileURL.resourceValues(forKeys: [.volumeAvailableCapacityForImportantUsageKey])

View File

@ -8,14 +8,14 @@
import ComposableArchitecture
extension DependencyValues {
var diskSpaceChecker: DiskSpaceCheckerClient {
public var diskSpaceChecker: DiskSpaceCheckerClient {
get { self[DiskSpaceCheckerClient.self] }
set { self[DiskSpaceCheckerClient.self] = newValue }
}
}
struct DiskSpaceCheckerClient {
var freeSpaceRequiredForSync: () -> Int64
var hasEnoughFreeSpaceForSync: () -> Bool
var freeSpace: () -> Int64
public struct DiskSpaceCheckerClient {
public var freeSpaceRequiredForSync: () -> Int64
public var hasEnoughFreeSpaceForSync: () -> Bool
public var freeSpace: () -> Int64
}

View File

@ -8,7 +8,7 @@
import ComposableArchitecture
extension DiskSpaceCheckerClient: DependencyKey {
static let liveValue: Self = {
public static let liveValue: Self = {
let diskSpaceChecker = DiskSpaceChecker()
return Self(
freeSpaceRequiredForSync: { diskSpaceChecker.freeSpaceRequiredForSync() },

View File

@ -6,13 +6,13 @@
//
extension DiskSpaceCheckerClient {
static let mockEmptyDisk = DiskSpaceCheckerClient(
public static let mockEmptyDisk = DiskSpaceCheckerClient(
freeSpaceRequiredForSync: { 1024 },
hasEnoughFreeSpaceForSync: { true },
freeSpace: { 2048 }
)
static let mockFullDisk = DiskSpaceCheckerClient(
public static let mockFullDisk = DiskSpaceCheckerClient(
freeSpaceRequiredForSync: { 1024 },
hasEnoughFreeSpaceForSync: { false },
freeSpace: { 0 }

View File

@ -9,7 +9,7 @@ import ComposableArchitecture
import XCTestDynamicOverlay
extension DiskSpaceCheckerClient: TestDependencyKey {
static let testValue = Self(
public static let testValue = Self(
freeSpaceRequiredForSync: XCTUnimplemented("\(Self.self).freeSpaceRequiredForSync", placeholder: 0),
hasEnoughFreeSpaceForSync: XCTUnimplemented("\(Self.self).hasEnoughFreeSpaceForSync", placeholder: false),
freeSpace: XCTUnimplemented("\(Self.self).freeSpace", placeholder: 0)

View File

@ -8,14 +8,14 @@
import ComposableArchitecture
extension DependencyValues {
var feedbackGenerator: FeedbackGeneratorClient {
public var feedbackGenerator: FeedbackGeneratorClient {
get { self[FeedbackGeneratorClient.self] }
set { self[FeedbackGeneratorClient.self] = newValue }
}
}
struct FeedbackGeneratorClient {
let generateSuccessFeedback: () -> Void
let generateWarningFeedback: () -> Void
let generateErrorFeedback: () -> Void
public struct FeedbackGeneratorClient {
public let generateSuccessFeedback: () -> Void
public let generateWarningFeedback: () -> Void
public let generateErrorFeedback: () -> Void
}

View File

@ -9,7 +9,7 @@ import UIKit
import ComposableArchitecture
extension FeedbackGeneratorClient: DependencyKey {
static let liveValue = Self(
public static let liveValue = Self(
generateSuccessFeedback: { UINotificationFeedbackGenerator().notificationOccurred(.success) },
generateWarningFeedback: { UINotificationFeedbackGenerator().notificationOccurred(.warning) },
generateErrorFeedback: { UINotificationFeedbackGenerator().notificationOccurred(.error) }

View File

@ -9,7 +9,7 @@ import ComposableArchitecture
import XCTestDynamicOverlay
extension FeedbackGeneratorClient: TestDependencyKey {
static let testValue = Self(
public static let testValue = Self(
generateSuccessFeedback: XCTUnimplemented("\(Self.self).generateSuccessFeedback"),
generateWarningFeedback: XCTUnimplemented("\(Self.self).generateWarningFeedback"),
generateErrorFeedback: XCTUnimplemented("\(Self.self).generateErrorFeedback")
@ -17,7 +17,7 @@ extension FeedbackGeneratorClient: TestDependencyKey {
}
extension FeedbackGeneratorClient {
static let noOp = Self(
public static let noOp = Self(
generateSuccessFeedback: { },
generateWarningFeedback: { },
generateErrorFeedback: { }

View File

@ -0,0 +1,24 @@
//
// FileManagerClient.swift
// secant-testnet
//
// Created by Lukáš Korba on 07.04.2022.
//
import Foundation
public struct FileManagerClient {
public let url: (FileManager.SearchPathDirectory, FileManager.SearchPathDomainMask, URL?, Bool) throws -> URL
public let fileExists: (String) -> Bool
public let removeItem: (URL) throws -> Void
public init(
url: @escaping (FileManager.SearchPathDirectory, FileManager.SearchPathDomainMask, URL?, Bool) throws -> URL,
fileExists: @escaping (String) -> Bool,
removeItem: @escaping (URL) throws -> Void)
{
self.url = url
self.fileExists = fileExists
self.removeItem = removeItem
}
}

View File

@ -8,7 +8,7 @@
import Foundation
extension FileManagerClient {
static let live = FileManagerClient(
public static let live = FileManagerClient(
url: { searchPathDirectory, searchPathDomainMask, appropriateForURL, shouldCreate in
try FileManager.default.url(for: searchPathDirectory, in: searchPathDomainMask, appropriateFor: appropriateForURL, create: shouldCreate)
},

View File

@ -9,7 +9,7 @@ import ComposableArchitecture
import XCTestDynamicOverlay
extension FileManagerClient: TestDependencyKey {
static let testValue = Self(
public static let testValue = Self(
url: XCTUnimplemented("\(Self.self).url"),
fileExists: XCTUnimplemented("\(Self.self).fileExists", placeholder: false),
removeItem: XCTUnimplemented("\(Self.self).removeItem")

View File

@ -0,0 +1,27 @@
//
// HideBalancesInterface.swift
//
//
// Created by Lukáš Korba on 11.11.2023.
//
import Foundation
import ComposableArchitecture
import Combine
extension DependencyValues {
public var hideBalances: HideBalancesClient {
get { self[HideBalancesClient.self] }
set { self[HideBalancesClient.self] = newValue }
}
}
public struct HideBalancesClient {
public enum Constants {
static let udHideBalances = "udHideBalances"
}
public var prepare: @Sendable () -> Void
public var value: @Sendable () -> CurrentValueSubject<Bool, Never>
public var updateValue: @Sendable (Bool) -> Void
}

View File

@ -0,0 +1,35 @@
//
// HideBalancesLiveKey.swift
//
//
// Created by Lukáš Korba on 11.11.2023.
//
import Foundation
import ComposableArchitecture
import Combine
import UserDefaults
extension HideBalancesClient: DependencyKey {
public static var liveValue: Self {
let storage = CurrentValueSubject<Bool, Never>(false)
return .init(
prepare: {
@Dependency(\.userDefaults) var userDefaults
if let value = userDefaults.objectForKey(Constants.udHideBalances) as? Bool {
storage.value = value
}
},
value: { storage },
updateValue: {
@Dependency(\.userDefaults) var userDefaults
userDefaults.setValue($0, Constants.udHideBalances)
storage.value = $0
}
)
}
}

View File

@ -0,0 +1,26 @@
//
// HideBalancesTestKey.swift
//
//
// Created by Lukáš Korba on 11.11.2023.
//
import ComposableArchitecture
import XCTestDynamicOverlay
import Combine
extension HideBalancesClient: TestDependencyKey {
public static let testValue = Self(
prepare: XCTUnimplemented("\(Self.self).prepare"),
value: XCTUnimplemented("\(Self.self).value", placeholder: .init(false)),
updateValue: XCTUnimplemented("\(Self.self).updateValue")
)
}
extension HideBalancesClient {
public static let noOp = Self(
prepare: { },
value: { .init(false) },
updateValue: { _ in }
)
}

View File

@ -6,15 +6,14 @@
//
import ComposableArchitecture
import LocalAuthentication
extension DependencyValues {
var localAuthentication: LocalAuthenticationClient {
public var localAuthentication: LocalAuthenticationClient {
get { self[LocalAuthenticationClient.self] }
set { self[LocalAuthenticationClient.self] = newValue }
}
}
struct LocalAuthenticationClient {
let authenticate: @Sendable () async -> Bool
public struct LocalAuthenticationClient {
public let authenticate: @Sendable () async -> Bool
}

View File

@ -7,9 +7,10 @@
import ComposableArchitecture
import LocalAuthentication
import Generated
extension LocalAuthenticationClient: DependencyKey {
static let liveValue = Self(
public static let liveValue = Self(
authenticate: {
let context = LAContext()
var error: NSError?

View File

@ -6,11 +6,11 @@
//
extension LocalAuthenticationClient {
static let mockAuthenticationSucceeded = Self(
public static let mockAuthenticationSucceeded = Self(
authenticate: { true }
)
static let mockAuthenticationFailed = Self(
public static let mockAuthenticationFailed = Self(
authenticate: { false }
)
}

View File

@ -9,7 +9,7 @@ import ComposableArchitecture
import XCTestDynamicOverlay
extension LocalAuthenticationClient: TestDependencyKey {
static let testValue = Self(
public static let testValue = Self(
authenticate: XCTUnimplemented("\(Self.self).authenticate", placeholder: false)
)
}

View File

@ -0,0 +1,24 @@
//
// LogsHandlerInterface.swift
// secant-testnet
//
// Created by Lukáš Korba on 30.01.2023.
//
import Foundation
import ComposableArchitecture
extension DependencyValues {
public var logsHandler: LogsHandlerClient {
get { self[LogsHandlerClient.self] }
set { self[LogsHandlerClient.self] = newValue }
}
}
public struct LogsHandlerClient {
public let exportAndStoreLogs: (String, String, String) async throws -> URL?
public init(exportAndStoreLogs: @escaping (String, String, String) async throws -> URL?) {
self.exportAndStoreLogs = exportAndStoreLogs
}
}

View File

@ -0,0 +1,95 @@
//
// LogsHandlerLive.swift
// secant-testnet
//
// Created by Lukáš Korba on 30.01.2023.
//
import Foundation
import ComposableArchitecture
import OSLog
import Utils
extension LogsHandlerClient: DependencyKey {
public static let liveValue = LogsHandlerClient(
exportAndStoreLogs: { sdkLogs, tcaLogs, walletLogs in
// create a directory
let logsURL = FileManager.default.temporaryDirectory.appendingPathComponent("zashiPrivateData")
try FileManager.default.createDirectory(atPath: logsURL.path, withIntermediateDirectories: true)
// export the logs
async let sdkLogsVerbose = LogsHandlerClient.exportAndStoreLogsFor(
key: sdkLogs,
atURL: logsURL.appendingPathComponent("sdkLogs_verbose.txt")
)
async let sdkLogsSync = LogsHandlerClient.exportAndStoreLogsFor(
key: sdkLogs,
atURL: logsURL.appendingPathComponent("sdkLogs_sync.txt"),
level: .info // The info level represents the sync log in the SDK
)
async let tcaLogs = LogsHandlerClient.exportAndStoreLogsFor(
key: tcaLogs,
atURL: logsURL.appendingPathComponent("tcaLogs.txt")
)
async let walletLogs = LogsHandlerClient.exportAndStoreLogsFor(
key: walletLogs,
atURL: logsURL.appendingPathComponent("walletLogs.txt")
)
let logs = try await [sdkLogsVerbose, sdkLogsSync, tcaLogs, walletLogs]
// store the log files into the logs folder
try logs.forEach { logsHandler in
try logsHandler.result.write(to: logsHandler.dir, atomically: true, encoding: String.Encoding.utf8)
}
// zip the logs folder
let coordinator = NSFileCoordinator()
var zipError: NSError?
var archiveURL: URL?
archiveURL = await withCheckedContinuation { continuation in
coordinator.coordinate(readingItemAt: logsURL, options: [.forUploading], error: &zipError) { zipURL in
do {
let tmpURL = try FileManager.default.url(
for: .itemReplacementDirectory,
in: .userDomainMask,
appropriateFor: zipURL,
create: true
)
.appendingPathComponent("zashiPrivateData.zip")
try FileManager.default.moveItem(at: zipURL, to: tmpURL)
continuation.resume(returning: tmpURL)
} catch {
continuation.resume(returning: nil)
}
}
}
return archiveURL
}
)
}
private extension LogsHandlerClient {
static func exportAndStoreLogsFor(
key: String,
atURL: URL,
level: OSLogEntryLog.Level = .debug
) async throws -> (result: String, dir: URL) {
let logsStr = try await LogStore.exportCategory(
key,
level: level,
fileSize: 2_000_000 // ~ 2MB of data
)
var result = ""
logsStr?.forEach({ line in
result.append(line)
result.append("\n\n")
})
return (result: result, dir: atURL)
}
}

View File

@ -9,7 +9,13 @@ import ComposableArchitecture
import XCTestDynamicOverlay
extension LogsHandlerClient: TestDependencyKey {
static let testValue = Self(
exportAndStoreLogs: XCTUnimplemented("\(Self.self).exportAndStoreLogs")
public static let testValue = Self(
exportAndStoreLogs: XCTUnimplemented("\(Self.self).exportAndStoreLogs", placeholder: nil)
)
}
extension LogsHandlerClient {
public static let noOp = Self(
exportAndStoreLogs: { _, _, _ in nil }
)
}

View File

@ -8,21 +8,21 @@
import ComposableArchitecture
extension DependencyValues {
var mnemonic: MnemonicClient {
public var mnemonic: MnemonicClient {
get { self[MnemonicClient.self] }
set { self[MnemonicClient.self] = newValue }
}
}
struct MnemonicClient {
public struct MnemonicClient {
/// Random 24 words mnemonic phrase
var randomMnemonic: () throws -> String
public var randomMnemonic: () throws -> String
/// Random 24 words mnemonic phrase as array of words
var randomMnemonicWords: () throws -> [String]
public var randomMnemonicWords: () throws -> [String]
/// Generate deterministic seed from mnemonic phrase
var toSeed: (String) throws -> [UInt8]
public var toSeed: (String) throws -> [UInt8]
/// Get this mnemonic phrase as array of words
var asWords: (String) -> [String]
public var asWords: (String) -> [String]
/// Validates whether the given mnemonic is correct
var isValid: (String) throws -> Void
public var isValid: (String) throws -> Void
}

View File

@ -9,7 +9,7 @@ import ComposableArchitecture
import MnemonicSwift
extension MnemonicClient: DependencyKey {
static let liveValue = Self(
public static let liveValue = Self(
randomMnemonic: {
try Mnemonic.generateMnemonic(strength: 256)
},

View File

@ -8,7 +8,7 @@
import Foundation
extension MnemonicClient {
static let mock = MnemonicClient(
public static let mock = MnemonicClient(
randomMnemonic: {
"""
still champion voice habit trend flight \

View File

@ -9,7 +9,7 @@ import ComposableArchitecture
import XCTestDynamicOverlay
extension MnemonicClient: TestDependencyKey {
static let testValue = Self(
public static let testValue = Self(
randomMnemonic: XCTUnimplemented("\(Self.self).randomMnemonic", placeholder: ""),
randomMnemonicWords: XCTUnimplemented("\(Self.self).randomMnemonicWords", placeholder: []),
toSeed: XCTUnimplemented("\(Self.self).toSeed", placeholder: []),
@ -19,7 +19,7 @@ extension MnemonicClient: TestDependencyKey {
}
extension MnemonicClient {
static let noOp = Self(
public static let noOp = Self(
randomMnemonic: { "" },
randomMnemonicWords: { [] },
toSeed: { _ in [] },

View File

@ -1,5 +1,5 @@
//
// AppVersionInterface.swift
// NumberFormatterInterface.swift
// secant-testnet
//
// Created by Lukáš Korba on 12.11.2022.
@ -9,13 +9,13 @@ import Foundation
import ComposableArchitecture
extension DependencyValues {
var numberFormatter: NumberFormatterClient {
public var numberFormatter: NumberFormatterClient {
get { self[NumberFormatterClient.self] }
set { self[NumberFormatterClient.self] = newValue }
}
}
struct NumberFormatterClient {
var string: (NSDecimalNumber) -> String?
var number: (String) -> NSNumber?
public struct NumberFormatterClient {
public var string: (NSDecimalNumber) -> String?
public var number: (String) -> NSNumber?
}

View File

@ -0,0 +1,21 @@
//
// NumberFormatterLiveKey.swift
// secant-testnet
//
// Created by Lukáš Korba on 14.11.2022.
//
import Foundation
import ComposableArchitecture
import Utils
extension NumberFormatterClient: DependencyKey {
public static let liveValue = NumberFormatterClient.live()
public static func live(numberFormatter: NumberFormatter = NumberFormatter.zcashNumberFormatter) -> Self {
Self(
string: { numberFormatter.string(from: $0) },
number: { numberFormatter.number(from: $0) }
)
}
}

View File

@ -9,14 +9,14 @@ import ComposableArchitecture
import XCTestDynamicOverlay
extension NumberFormatterClient: TestDependencyKey {
static let testValue = Self(
public static let testValue = Self(
string: XCTUnimplemented("\(Self.self).string", placeholder: nil),
number: XCTUnimplemented("\(Self.self).number", placeholder: nil)
)
}
extension NumberFormatterClient {
static let noOp = Self(
public static let noOp = Self(
string: { _ in nil },
number: { _ in nil }
)

View File

@ -6,15 +6,16 @@
//
import ComposableArchitecture
import Utils
extension DependencyValues {
var pasteboard: PasteboardClient {
public var pasteboard: PasteboardClient {
get { self[PasteboardClient.self] }
set { self[PasteboardClient.self] = newValue }
}
}
struct PasteboardClient {
let setString: (RedactableString) -> Void
let getString: () -> RedactableString?
public struct PasteboardClient {
public let setString: (RedactableString) -> Void
public let getString: () -> RedactableString?
}

View File

@ -9,7 +9,7 @@ import ComposableArchitecture
import UIKit
extension PasteboardClient: DependencyKey {
static let liveValue = Self(
public static let liveValue = Self(
setString: { UIPasteboard.general.string = $0.data },
getString: { UIPasteboard.general.string?.redacted }
)

View File

@ -7,9 +7,10 @@
import ComposableArchitecture
import XCTestDynamicOverlay
import Utils
extension PasteboardClient: TestDependencyKey {
static let testValue = Self(
public static let testValue = Self(
setString: XCTUnimplemented("\(Self.self).setString"),
getString: XCTUnimplemented("\(Self.self).getString", placeholder: "".redacted)
)
@ -19,7 +20,7 @@ extension PasteboardClient: TestDependencyKey {
var string: String?
}
static let testPasteboard = Self(
public static let testPasteboard = Self(
setString: { TestPasteboard.general.string = $0.data },
getString: { TestPasteboard.general.string?.redacted }
)

View File

@ -0,0 +1,20 @@
//
// QRImageDetectorInterface.swift
// secant-testnet
//
// Created by Lukáš Korba on 2024-04-18.
//
import SwiftUI
import ComposableArchitecture
extension DependencyValues {
public var qrImageDetector: QRImageDetectorClient {
get { self[QRImageDetectorClient.self] }
set { self[QRImageDetectorClient.self] = newValue }
}
}
public struct QRImageDetectorClient {
public var check: @Sendable (UIImage?) -> [String]?
}

View File

@ -0,0 +1,27 @@
//
// QRImageDetectorLiveKey.swift
// secant-testnet
//
// Created by Lukáš Korba on 2024-04-18.
//
import ComposableArchitecture
import CoreImage
extension QRImageDetectorClient: DependencyKey {
public static let liveValue = Self(
check: { image in
guard let image else { return nil }
guard let ciImage = CIImage(image: image) else { return nil }
let detectorOptions = [CIDetectorAccuracy: CIDetectorAccuracyHigh]
let qrDetector = CIDetector(ofType: CIDetectorTypeQRCode, context: CIContext(), options: detectorOptions)
let decoderOptions = [CIDetectorImageOrientation: ciImage.properties[(kCGImagePropertyOrientation as String)] ?? 1]
let features = qrDetector?.features(in: ciImage, options: decoderOptions)
return features?.compactMap {
($0 as? CIQRCodeFeature)?.messageString
}
}
)
}

View File

@ -0,0 +1,21 @@
//
// QRImageDetectorTestKey.swift
// secant-testnet
//
// Created by Lukáš Korba on 2024-04-18.
//
import ComposableArchitecture
import XCTestDynamicOverlay
extension QRImageDetectorClient: TestDependencyKey {
public static let testValue = Self(
check: XCTUnimplemented("\(Self.self).check", placeholder: nil)
)
}
extension QRImageDetectorClient {
public static let noOp = Self(
check: { _ in nil }
)
}

View File

@ -0,0 +1,35 @@
//
// ReadTransactionsStorageInterface.swift
//
//
// Created by Lukáš Korba on 11.11.2023.
//
import Foundation
import ComposableArchitecture
import Utils
extension DependencyValues {
public var readTransactionsStorage: ReadTransactionsStorageClient {
get { self[ReadTransactionsStorageClient.self] }
set { self[ReadTransactionsStorageClient.self] = newValue }
}
}
public struct ReadTransactionsStorageClient {
public enum Constants {
static let entityName = "ReadTransactionsStorageEntity"
static let modelName = "ReadTransactionsStorageModel"
static let availabilityEntityName = "ReadTransactionsStorageAvailabilityTimestampEntity"
}
public enum ReadTransactionsStorageError: Error {
case createEntity
case availability
}
public let markIdAsRead: (RedactableString) throws -> Void
public var readIds: () throws -> [RedactableString: Bool]
public var availabilityTimestamp: () throws -> TimeInterval
public var nukeWallet: () throws -> Void
}

View File

@ -0,0 +1,145 @@
//
// ReadTransactionsStorageLiveKey.swift
//
//
// Created by Lukáš Korba on 11.11.2023.
//
import ComposableArchitecture
import CoreData
import Utils
extension ReadTransactionsStorageClient: DependencyKey {
public static let liveValue = Self(
markIdAsRead: {
let context = persistentContainer.viewContext
if let entity = NSEntityDescription.entity(
forEntityName: ReadTransactionsStorageClient.Constants.entityName,
in: context
) {
let newRead = NSManagedObject(entity: entity, insertInto: context)
newRead.setValue($0.data, forKey: "id")
do {
try context.save()
} catch {
throw error
}
} else {
throw ReadTransactionsStorageError.createEntity
}
},
readIds: {
let context = persistentContainer.viewContext
let request = NSFetchRequest<NSFetchRequestResult>(entityName: ReadTransactionsStorageClient.Constants.entityName)
request.returnsObjectsAsFaults = false
do {
let result = try context.fetch(request)
if let managedObjects = result as? [NSManagedObject] {
let ids = managedObjects.compactMap { element in
(element.value(forKey: "id") as? String)?.redacted
}
var idsDict: [RedactableString: Bool] = [:]
ids.forEach { id in
idsDict[id] = true
}
return idsDict
}
return [:]
} catch {
throw error
}
},
availabilityTimestamp: {
let context = persistentContainer.viewContext
// check presence of the timestamp
let request = NSFetchRequest<NSFetchRequestResult>(entityName: ReadTransactionsStorageClient.Constants.availabilityEntityName)
request.returnsObjectsAsFaults = false
do {
let result = try context.fetch(request)
if let managedObjects = result as? [NSManagedObject] {
// no timestamp stored, create one
if managedObjects.isEmpty {
if let entity = NSEntityDescription.entity(
forEntityName: ReadTransactionsStorageClient.Constants.availabilityEntityName,
in: context
) {
let newAvailability = NSManagedObject(entity: entity, insertInto: context)
let now = Date.now.timeIntervalSince1970
newAvailability.setValue(now, forKey: "timestamp")
do {
try context.save()
} catch {
throw error
}
return now
} else {
throw ReadTransactionsStorageError.createEntity
}
} else {
if let timestamp = managedObjects.first?.value(forKey: "timestamp") as? TimeInterval {
return timestamp
}
throw ReadTransactionsStorageError.availability
}
} else {
throw ReadTransactionsStorageError.availability
}
} catch {
throw error
}
},
nukeWallet: {
let context = persistentContainer.viewContext
let deleteRequestIds = NSBatchDeleteRequest(
fetchRequest: NSFetchRequest<NSFetchRequestResult>(
entityName: ReadTransactionsStorageClient.Constants.entityName
)
)
let deleteRequestTimestamp = NSBatchDeleteRequest(
fetchRequest: NSFetchRequest<NSFetchRequestResult>(
entityName: ReadTransactionsStorageClient.Constants.availabilityEntityName
)
)
do {
try context.execute(deleteRequestIds)
try context.execute(deleteRequestTimestamp)
try context.save()
} catch {
throw error
}
}
)
}
private extension ReadTransactionsStorageClient {
static let persistentContainer: NSPersistentContainer = {
let container = NSPersistentContainer(name: ReadTransactionsStorageClient.Constants.modelName)
container.loadPersistentStores { description, error in
if let error = error {
fatalError("Unable to load persistent stores: \(error)")
}
}
return container
}()
}

View File

@ -0,0 +1,27 @@
//
// ReadTransactionsStorageTestKey.swift
//
//
// Created by Lukáš Korba on 11.11.2023.
//
import ComposableArchitecture
import XCTestDynamicOverlay
extension ReadTransactionsStorageClient: TestDependencyKey {
public static let testValue = Self(
markIdAsRead: XCTUnimplemented("\(Self.self).markIdAsRead"),
readIds: XCTUnimplemented("\(Self.self).readIds", placeholder: [:]),
availabilityTimestamp: XCTUnimplemented("\(Self.self).availabilityTimestamp", placeholder: 0),
nukeWallet: XCTUnimplemented("\(Self.self).nukeWallet")
)
}
extension ReadTransactionsStorageClient {
public static let noOp = Self(
markIdAsRead: { _ in },
readIds: { [:] },
availabilityTimestamp: { 0 },
nukeWallet: { }
)
}

View File

@ -0,0 +1,22 @@
//
// RestoreWalletStorageInterface.swift
//
//
// Created by Lukáš Korba on 19.12.2023.
//
import Foundation
import ComposableArchitecture
import Combine
extension DependencyValues {
public var restoreWalletStorage: RestoreWalletStorageClient {
get { self[RestoreWalletStorageClient.self] }
set { self[RestoreWalletStorageClient.self] = newValue }
}
}
public struct RestoreWalletStorageClient {
public var value: @Sendable () async -> AsyncStream<Bool>
public var updateValue: @Sendable (Bool) async -> Void
}

View File

@ -0,0 +1,35 @@
//
// RestoreWalletStorageLiveKey.swift
//
//
// Created by Lukáš Korba on 19.12.2023.
//
import Foundation
import ComposableArchitecture
import Combine
extension RestoreWalletStorageClient: DependencyKey {
public static var liveValue: Self {
let storage = CurrentValueSubject<Bool, Never>(false)
return .init(
value: {
AsyncStream { continuation in
let cancellable = storage.sink {
continuation.yield($0)
}
continuation.onTermination = { _ in
cancellable.cancel()
}
}
},
updateValue: { storage.value = $0 }
)
}
}
extension AsyncStream<Bool> {
static let placeholder = AsyncStream { continuation in continuation.finish() }
}

View File

@ -0,0 +1,24 @@
//
// RestoreWalletStorageTestKey.swift
//
//
// Created by Lukáš Korba on 19.12.2023.
//
import ComposableArchitecture
import XCTestDynamicOverlay
import Combine
extension RestoreWalletStorageClient: TestDependencyKey {
public static let testValue = Self(
value: XCTUnimplemented("\(Self.self).value", placeholder: .placeholder),
updateValue: XCTUnimplemented("\(Self.self).updateValue")
)
}
extension RestoreWalletStorageClient {
public static let noOp = Self(
value: { .placeholder },
updateValue: { _ in }
)
}

View File

@ -0,0 +1,22 @@
//
// ReviewRequestInterface.swift
// secant-testnet
//
// Created by Lukáš Korba on 3.4.2023.
//
import ComposableArchitecture
extension DependencyValues {
public var reviewRequest: ReviewRequestClient {
get { self[ReviewRequestClient.self] }
set { self[ReviewRequestClient.self] = newValue }
}
}
public struct ReviewRequestClient {
public let canRequestReview: () -> Bool
public let foundTransactions: () -> Void
public let reviewRequested: () -> Void
public let syncFinished: () -> Void
}

View File

@ -0,0 +1,67 @@
//
// ReviewRequestLiveKey.swift
// secant-testnet
//
// Created by Lukáš Korba on 3.4.2023.
//
import Foundation
import ComposableArchitecture
import AppVersion
import Date
import UserDefaults
extension ReviewRequestClient: DependencyKey {
public static let liveValue = ReviewRequestClient.live()
public static func live(
appVersion: AppVersionClient = .liveValue,
date: DateClient = .liveValue,
userDefaults: UserDefaultsClient = .live()
) -> Self {
Self(
canRequestReview: {
// set of conditions that must be fulfilled in order to trigger review request
// the wallet must be synced
guard userDefaults.objectForKey(Constants.latestSyncKey) != nil else { return false }
// the version is ether nil or latest review is from some older version
let currentVersion = appVersion.appVersion()
if let storedVersion = userDefaults.objectForKey(Constants.versionKey) as? String {
guard currentVersion.compare(storedVersion, options: .numeric) == .orderedDescending else {
return false
}
}
// there has been at least one found transaction since the very first sync
guard userDefaults.objectForKey(Constants.foundTransactionsKey) != nil else { return false }
return true
},
foundTransactions: {
// only if there's the very first sync stored
guard userDefaults.objectForKey(Constants.latestSyncKey) != nil else { return }
userDefaults.setValue(date.now().timeIntervalSince1970, Constants.foundTransactionsKey)
},
reviewRequested: {
// the review has been requested, update the version and timestamp
userDefaults.setValue(date.now().timeIntervalSince1970, Constants.reviewRequestedKey)
userDefaults.setValue(appVersion.appVersion(), Constants.versionKey)
},
syncFinished: {
// synchronizer's sync has been finished successfuly
userDefaults.setValue(date.now().timeIntervalSince1970, Constants.latestSyncKey)
}
)
}
}
extension ReviewRequestClient {
public enum Constants: CaseIterable {
public static let foundTransactionsKey = "ReviewRequestClient.foundTransactions"
public static let latestSyncKey = "ReviewRequestClient.latestSyncKey"
public static let reviewRequestedKey = "ReviewRequestClient.reviewRequestedKey"
public static let versionKey = "ReviewRequestClient.versionKey"
}
}

View File

@ -0,0 +1,27 @@
//
// ReviewRequestTestKey.swift
// secant-testnet
//
// Created by Lukáš Korba on 3.4.2023.
//
import ComposableArchitecture
import XCTestDynamicOverlay
extension ReviewRequestClient: TestDependencyKey {
public static let testValue = Self(
canRequestReview: XCTUnimplemented("\(Self.self).canRequestReview", placeholder: false),
foundTransactions: XCTUnimplemented("\(Self.self).foundTransactions"),
reviewRequested: XCTUnimplemented("\(Self.self).reviewRequested"),
syncFinished: XCTUnimplemented("\(Self.self).syncFinished")
)
}
extension ReviewRequestClient {
public static let noOp = Self(
canRequestReview: { false },
foundTransactions: { },
reviewRequested: { },
syncFinished: { }
)
}

View File

@ -0,0 +1,61 @@
//
// SDKSynchronizerClient.swift
// secant-testnet
//
// Created by Lukáš Korba on 13.04.2022.
//
import Foundation
import Combine
import ComposableArchitecture
import ZcashLightClientKit
import Models
extension DependencyValues {
public var sdkSynchronizer: SDKSynchronizerClient {
get { self[SDKSynchronizerClient.self] }
set { self[SDKSynchronizerClient.self] = newValue }
}
}
public struct SDKSynchronizerClient {
public enum CreateProposedTransactionsResult: Equatable {
case failure
case partial(txIds: [String], statuses: [String])
case success
}
public let stateStream: () -> AnyPublisher<SynchronizerState, Never>
public let eventStream: () -> AnyPublisher<SynchronizerEvent, Never>
public let latestState: () -> SynchronizerState
public let prepareWith: ([UInt8], BlockHeight, WalletInitMode) async throws -> Void
public let start: (_ retry: Bool) async throws -> Void
public let stop: () -> Void
public let isSyncing: () -> Bool
public let isInitialized: () -> Bool
public let rewind: (RewindPolicy) -> AnyPublisher<Void, Error>
public var getAllTransactions: () async throws -> [TransactionState]
public let getUnifiedAddress: (_ account: Int) async throws -> UnifiedAddress?
public let getTransparentAddress: (_ account: Int) async throws -> TransparentAddress?
public let getSaplingAddress: (_ accountIndex: Int) async throws -> SaplingAddress?
public let getAccountBalance: (_ accountIndex: Int) async throws -> AccountBalance?
public var sendTransaction: (UnifiedSpendingKey, Zatoshi, Recipient, Memo?) async throws -> TransactionState
public let shieldFunds: (UnifiedSpendingKey, Memo, Zatoshi) async throws -> TransactionState
public var wipe: () -> AnyPublisher<Void, Error>?
public var switchToEndpoint: (LightWalletEndpoint) async throws -> Void
// Proposals
public var proposeTransfer: (Int, Recipient, Zatoshi, Memo?) async throws -> Proposal
public var createProposedTransactions: (Proposal, UnifiedSpendingKey) async throws -> CreateProposedTransactionsResult
public var proposeShielding: (Int, Zatoshi, Memo, TransparentAddress?) async throws -> Proposal?
public var isSeedRelevantToAnyDerivedAccount: ([UInt8]) async throws -> Bool
}

View File

@ -0,0 +1,203 @@
//
// SDKSynchronizerLive.swift
// secant-testnet
//
// Created by Lukáš Korba on 15.11.2022.
//
import Foundation
import Combine
import ComposableArchitecture
import ZcashLightClientKit
import DatabaseFiles
import Models
import ZcashSDKEnvironment
extension SDKSynchronizerClient: DependencyKey {
public static let liveValue: SDKSynchronizerClient = Self.live()
public static func live(
databaseFiles: DatabaseFilesClient = .liveValue
) -> Self {
@Dependency (\.zcashSDKEnvironment) var zcashSDKEnvironment
let network = zcashSDKEnvironment.network
#if DEBUG
let loggingPolicy = Initializer.LoggingPolicy.default(.debug)
#else
let loggingPolicy = Initializer.LoggingPolicy.noLogging
#endif
let initializer = Initializer(
cacheDbURL: databaseFiles.cacheDbURLFor(network),
fsBlockDbRoot: databaseFiles.fsBlockDbRootFor(network),
generalStorageURL: databaseFiles.documentsDirectory(),
dataDbURL: databaseFiles.dataDbURLFor(network),
endpoint: zcashSDKEnvironment.endpoint(),
network: network,
spendParamsURL: databaseFiles.spendParamsURLFor(network),
outputParamsURL: databaseFiles.outputParamsURLFor(network),
saplingParamsSourceURL: SaplingParamsSourceURL.default,
loggingPolicy: loggingPolicy
)
let synchronizer = SDKSynchronizer(initializer: initializer)
return SDKSynchronizerClient(
stateStream: { synchronizer.stateStream },
eventStream: { synchronizer.eventStream },
latestState: { synchronizer.latestState },
prepareWith: { seedBytes, walletBirtday, walletMode in
let result = try await synchronizer.prepare(with: seedBytes, walletBirthday: walletBirtday, for: walletMode)
if result != .success { throw ZcashError.synchronizerNotPrepared }
},
start: { retry in try await synchronizer.start(retry: retry) },
stop: { synchronizer.stop() },
isSyncing: { synchronizer.latestState.syncStatus.isSyncing },
isInitialized: { synchronizer.latestState.syncStatus != SyncStatus.unprepared },
rewind: { synchronizer.rewind($0) },
getAllTransactions: {
let clearedTransactions = try await synchronizer.allTransactions()
var clearedTxs: [TransactionState] = []
for clearedTransaction in clearedTransactions {
var transaction = TransactionState.init(
transaction: clearedTransaction,
memos: clearedTransaction.memoCount > 0 ? try await synchronizer.getMemos(for: clearedTransaction) : nil,
latestBlockHeight: try await SDKSynchronizerClient.latestBlockHeight(synchronizer: synchronizer)
)
let recipients = await synchronizer.getRecipients(for: clearedTransaction)
let addresses = recipients.compactMap {
if case let .address(address) = $0 {
return address
} else {
return nil
}
}
transaction.zAddress = addresses.first?.stringEncoded
if let someAddress = addresses.first, case .transparent = someAddress {
transaction.isTransparentRecipient = true
}
clearedTxs.append(transaction)
}
return clearedTxs
},
getUnifiedAddress: { try await synchronizer.getUnifiedAddress(accountIndex: $0) },
getTransparentAddress: { try await synchronizer.getTransparentAddress(accountIndex: $0) },
getSaplingAddress: { try await synchronizer.getSaplingAddress(accountIndex: $0) },
getAccountBalance: { try await synchronizer.getAccountBalance(accountIndex: $0) },
sendTransaction: { spendingKey, amount, recipient, memo in
let pendingTransaction = try await synchronizer.sendToAddress(
spendingKey: spendingKey,
zatoshi: amount,
toAddress: recipient,
memo: memo
)
return TransactionState(
transaction: pendingTransaction,
latestBlockHeight: try await SDKSynchronizerClient.latestBlockHeight(synchronizer: synchronizer)
)
},
shieldFunds: { spendingKey, memo, shieldingThreshold in
let pendingTransaction = try await synchronizer.shieldFunds(
spendingKey: spendingKey,
memo: memo,
shieldingThreshold: shieldingThreshold
)
return TransactionState(
transaction: pendingTransaction,
latestBlockHeight: try await SDKSynchronizerClient.latestBlockHeight(synchronizer: synchronizer)
)
},
wipe: { synchronizer.wipe() },
switchToEndpoint: { endpoint in
try await synchronizer.switchTo(endpoint: endpoint)
},
proposeTransfer: { accountIndex, recipient, amount, memo in
try await synchronizer.proposeTransfer(
accountIndex: accountIndex,
recipient: recipient,
amount: amount,
memo: memo
)
},
createProposedTransactions: { proposal, spendingKey in
let stream = try await synchronizer.createProposedTransactions(
proposal: proposal,
spendingKey: spendingKey
)
let transactionCount = proposal.transactionCount()
var successCount = 0
var iterator = stream.makeAsyncIterator()
var txIds: [String] = []
var statuses: [String] = []
for _ in 1...transactionCount {
if let transactionSubmitResult = try await iterator.next() {
switch transactionSubmitResult {
case .success(txId: let id):
successCount += 1
txIds.append(id.toHexStringTxId())
statuses.append("success")
case let .grpcFailure(txId: id, error: error):
txIds.append(id.toHexStringTxId())
statuses.append(error.localizedDescription)
case let .submitFailure(txId: id, code: code, description: description):
txIds.append(id.toHexStringTxId())
statuses.append("code: \(code) desc: \(description)")
case .notAttempted(txId: let id):
txIds.append(id.toHexStringTxId())
statuses.append("notAttempted")
}
}
}
if successCount == 0 {
return .failure
} else if successCount == transactionCount {
return .success
} else {
return .partial(txIds: txIds, statuses: statuses)
}
},
proposeShielding: { accountIndex, shieldingThreshold, memo, transparentReceiver in
try await synchronizer.proposeShielding(
accountIndex: accountIndex,
shieldingThreshold: shieldingThreshold,
memo: memo,
transparentReceiver: transparentReceiver
)
},
isSeedRelevantToAnyDerivedAccount: { seed in
try await synchronizer.isSeedRelevantToAnyDerivedAccount(seed: seed)
}
)
}
}
// TODO: [#1313] SDK improvements so a client doesn't need to determing if the transaction isPending
// https://github.com/zcash/ZcashLightClientKit/issues/1313
// Once #1313 is done, cleint will no longer need to call for a `latestHeight()`
private extension SDKSynchronizerClient {
static func latestBlockHeight(synchronizer: SDKSynchronizer) async throws -> BlockHeight {
let latestBlockHeight: BlockHeight
if synchronizer.latestState.latestBlockHeight > 0 {
latestBlockHeight = synchronizer.latestState.latestBlockHeight
} else {
latestBlockHeight = try await synchronizer.latestHeight()
}
return latestBlockHeight
}
}

Some files were not shown because too many files have changed in this diff Show More