From b421f82a881383b67d9b37584b9d948d03cd09ff Mon Sep 17 00:00:00 2001 From: banklesss <105349292+banklesss@users.noreply.github.com> Date: Tue, 16 Apr 2024 16:16:52 +0200 Subject: [PATCH 1/3] fix(wallet-setup): mnemonic input (#3199) --- .../SetupWallet/common/MnemonicInput/MnemonicInput.tsx | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/apps/wallet-mobile/src/features/SetupWallet/common/MnemonicInput/MnemonicInput.tsx b/apps/wallet-mobile/src/features/SetupWallet/common/MnemonicInput/MnemonicInput.tsx index c0a77711f6..e11f657cff 100644 --- a/apps/wallet-mobile/src/features/SetupWallet/common/MnemonicInput/MnemonicInput.tsx +++ b/apps/wallet-mobile/src/features/SetupWallet/common/MnemonicInput/MnemonicInput.tsx @@ -167,7 +167,6 @@ const MnemonicWordInput = React.forwardRef( const dateTime = React.useRef() const [error, setError] = React.useState('') const [matchingWords, setMatchingWords] = React.useState>([]) - const [wordSubmitted, setWordSubmitted] = React.useState(false) const selectWord = React.useCallback( (matchingWord: string) => { @@ -183,7 +182,6 @@ const MnemonicWordInput = React.forwardRef( ) const onSubmitEditing = React.useCallback(() => { - setWordSubmitted(true) if (!isEmptyString(matchingWords[0])) { selectWord(matchingWords[0]) } @@ -191,8 +189,6 @@ const MnemonicWordInput = React.forwardRef( const onChangeText = React.useCallback( (text: string) => { - if (wordSubmitted) return // to fix ios simulator issue - if (text.endsWith(' ')) { text = text.trimEnd() setWord(normalizeText(text)) @@ -210,7 +206,7 @@ const MnemonicWordInput = React.forwardRef( } else if (error !== '') setError('') } else setMatchingWords([]) }, - [error, onSubmitEditing, wordSubmitted], + [error, onSubmitEditing], ) React.useEffect(() => { @@ -236,7 +232,6 @@ const MnemonicWordInput = React.forwardRef( }) } - setWordSubmitted(false) onFocus() }} onChange={() => { From 9c4c668737921efe984a1aacdabfb16c5267cad9 Mon Sep 17 00:00:00 2001 From: banklesss <105349292+banklesss@users.noreply.github.com> Date: Tue, 16 Apr 2024 16:18:35 +0200 Subject: [PATCH 2/3] fix(setup-wallet): titles and hw wallet prod (#3192) --- .../SetupWallet/SetupWalletNavigator.tsx | 30 +++--- .../ChooseNetwork/ChooseNetworkScreen.tsx | 2 +- .../ChooseSetupType/ChooseSetupTypeScreen.tsx | 11 +- .../wallet-mobile/src/i18n/locales/en-US.json | 4 +- apps/wallet-mobile/src/navigation.tsx | 5 +- .../messages/src/WalletNavigator.json | 80 +++++++------- .../SetupWallet/SetupWalletNavigator.json | 102 +++++++++--------- 7 files changed, 122 insertions(+), 112 deletions(-) diff --git a/apps/wallet-mobile/src/features/SetupWallet/SetupWalletNavigator.tsx b/apps/wallet-mobile/src/features/SetupWallet/SetupWalletNavigator.tsx index 1f0f3aa5c6..8bda996c4c 100644 --- a/apps/wallet-mobile/src/features/SetupWallet/SetupWalletNavigator.tsx +++ b/apps/wallet-mobile/src/features/SetupWallet/SetupWalletNavigator.tsx @@ -37,19 +37,25 @@ export const AddWalletNavigator = () => { + + { ) @@ -129,13 +135,13 @@ export const AddWalletNavigator = () => { const ConnectNanoXScreenWrapper = () => const messages = defineMessages({ - addWalletTitle: { + addNewWalletTitle: { id: 'components.walletinit.walletinitscreen.title', - defaultMessage: '!!!Add wallet', + defaultMessage: '!!!Add new wallet', }, createWalletTitle: { id: 'components.walletinit.createwallet.createwalletscreen.title', - defaultMessage: '!!!Create a new wallet', + defaultMessage: '!!!Create wallet', }, restoreWalletTitle: { id: 'components.walletinit.restorewallet.restorewalletscreen.title', @@ -183,7 +189,7 @@ const useStrings = () => { const intl = useIntl() return { - addWalletTitle: intl.formatMessage(messages.addWalletTitle), + addNewWalletTitle: intl.formatMessage(messages.addNewWalletTitle), createWalletTitle: intl.formatMessage(messages.createWalletTitle), restoreWalletTitle: intl.formatMessage(messages.restoreWalletTitle), importReadOnlyTitle: intl.formatMessage(messages.importReadOnlyTitle), diff --git a/apps/wallet-mobile/src/features/SetupWallet/useCases/ChooseNetwork/ChooseNetworkScreen.tsx b/apps/wallet-mobile/src/features/SetupWallet/useCases/ChooseNetwork/ChooseNetworkScreen.tsx index 234cdf8cf2..1a65c57c26 100644 --- a/apps/wallet-mobile/src/features/SetupWallet/useCases/ChooseNetwork/ChooseNetworkScreen.tsx +++ b/apps/wallet-mobile/src/features/SetupWallet/useCases/ChooseNetwork/ChooseNetworkScreen.tsx @@ -96,7 +96,7 @@ export const useNavigateTo = () => { return React.useRef({ create: () => navigation.navigate('setup-wallet-about-recovery-phase'), restore: () => navigation.navigate('setup-wallet-restore-form'), - mnemonicType: () => navigation.navigate('setup-wallet-choose-mnemonic-type'), + mnemonicType: () => navigation.navigate('setup-wallet-restore-choose-mnemonic-type'), hw: () => navigation.navigate('setup-wallet-check-nano-x'), }).current } diff --git a/apps/wallet-mobile/src/features/SetupWallet/useCases/ChooseSetupType/ChooseSetupTypeScreen.tsx b/apps/wallet-mobile/src/features/SetupWallet/useCases/ChooseSetupType/ChooseSetupTypeScreen.tsx index 4a7c4f94a5..554fffd980 100644 --- a/apps/wallet-mobile/src/features/SetupWallet/useCases/ChooseSetupType/ChooseSetupTypeScreen.tsx +++ b/apps/wallet-mobile/src/features/SetupWallet/useCases/ChooseSetupType/ChooseSetupTypeScreen.tsx @@ -42,7 +42,8 @@ export const ChooseSetupTypeScreen = () => { return } - navigation.navigate('setup-wallet-choose-network') + // On production the step of network is skipped + navigation.navigate('setup-wallet-create-choose-network') } const handleRestore = () => { @@ -50,11 +51,12 @@ export const ChooseSetupTypeScreen = () => { if (isProduction()) { networkIdChanged(HASKELL_SHELLEY.NETWORK_ID) - navigation.navigate('setup-wallet-choose-mnemonic-type') + navigation.navigate('setup-wallet-restore-choose-mnemonic-type') return } - navigation.navigate('setup-wallet-choose-network') + // On production the step of network is skipped + navigation.navigate('setup-wallet-restore-choose-network') } const handleHw = () => { @@ -71,7 +73,8 @@ export const ChooseSetupTypeScreen = () => { return } - navigation.navigate('setup-wallet-choose-network') + // On production the step of network is skipped + navigation.navigate('setup-wallet-restore-choose-network') } return ( diff --git a/apps/wallet-mobile/src/i18n/locales/en-US.json b/apps/wallet-mobile/src/i18n/locales/en-US.json index 2b45138926..0fbeefa350 100644 --- a/apps/wallet-mobile/src/i18n/locales/en-US.json +++ b/apps/wallet-mobile/src/i18n/locales/en-US.json @@ -561,7 +561,7 @@ "components.walletinit.createwallet.createwalletscreen.passwordLengthRequirement": "Minimum {requiredPasswordLength} characters", "components.walletinit.createwallet.createwalletscreen.notFound": "Not found", "components.walletinit.createwallet.createwalletscreen.clearAll": "Clear all", - "components.walletinit.createwallet.createwalletscreen.title": "Create a new wallet", + "components.walletinit.createwallet.createwalletscreen.title": "Create wallet", "components.walletinit.createwallet.mnemonicbackupimportancemodal.confirmationButton": "I understand", "components.walletinit.createwallet.mnemonicbackupimportancemodal.keysStorageCheckbox": "I understand that my secret keys are held securely on this device only, not on the company`s servers", "components.walletinit.createwallet.mnemonicbackupimportancemodal.newDeviceRecoveryCheckbox": "I understand that if this application is moved to another device or deleted, my funds can be only recovered with the backup phrase that I have written down and saved in a secure place.", @@ -635,7 +635,7 @@ "components.walletinit.walletinitscreen.restoreNWordWalletExplanation": "If you have a recovery phrase consisting of {mnemonicLength} words, choose this option to restore your wallet.", "components.walletinit.walletinitscreen.restoreShelleyWalletButton": "Restore wallet (Shelley Testnet)", "components.walletinit.walletinitscreen.restoreWalletButton": "Restore wallet", - "components.walletinit.walletinitscreen.title": "Add wallet", + "components.walletinit.walletinitscreen.title": "Add new wallet", "components.walletselection.walletselectionscreen.addWalletButton": "Add wallet", "components.walletselection.walletselectionscreen.addWalletOnShelleyButton": "Add wallet (Jormungandr ITN)", "components.walletselection.walletselectionscreen.header": "My wallets", diff --git a/apps/wallet-mobile/src/navigation.tsx b/apps/wallet-mobile/src/navigation.tsx index 5f4c633f1f..7fbafd1a7a 100644 --- a/apps/wallet-mobile/src/navigation.tsx +++ b/apps/wallet-mobile/src/navigation.tsx @@ -115,8 +115,9 @@ export type WalletStackRouteNavigation = StackNavigationProp export type WalletInitRoutes = { 'setup-wallet-choose-setup-type': undefined - 'setup-wallet-choose-network': undefined - 'setup-wallet-choose-mnemonic-type': undefined + 'setup-wallet-create-choose-network': undefined + 'setup-wallet-restore-choose-network': undefined + 'setup-wallet-restore-choose-mnemonic-type': undefined 'initial-setup-wallet-choose-setup-type': undefined 'setup-wallet-details-form': undefined 'setup-wallet-restore-form': undefined diff --git a/apps/wallet-mobile/translations/messages/src/WalletNavigator.json b/apps/wallet-mobile/translations/messages/src/WalletNavigator.json index b897a5e8a5..067635c5cb 100644 --- a/apps/wallet-mobile/translations/messages/src/WalletNavigator.json +++ b/apps/wallet-mobile/translations/messages/src/WalletNavigator.json @@ -4,14 +4,14 @@ "defaultMessage": "!!!Transactions", "file": "src/WalletNavigator.tsx", "start": { - "line": 227, + "line": 230, "column": 22, - "index": 8024 + "index": 8180 }, "end": { - "line": 230, + "line": 233, "column": 3, - "index": 8127 + "index": 8283 } }, { @@ -19,14 +19,14 @@ "defaultMessage": "!!!Send", "file": "src/WalletNavigator.tsx", "start": { - "line": 231, + "line": 234, "column": 14, - "index": 8143 + "index": 8299 }, "end": { - "line": 234, + "line": 237, "column": 3, - "index": 8242 + "index": 8398 } }, { @@ -34,14 +34,14 @@ "defaultMessage": "!!!Receive", "file": "src/WalletNavigator.tsx", "start": { - "line": 235, + "line": 238, "column": 17, - "index": 8261 + "index": 8417 }, "end": { - "line": 238, + "line": 241, "column": 3, - "index": 8366 + "index": 8522 } }, { @@ -49,14 +49,14 @@ "defaultMessage": "!!!Dashboard", "file": "src/WalletNavigator.tsx", "start": { - "line": 239, + "line": 242, "column": 19, - "index": 8387 + "index": 8543 }, "end": { - "line": 242, + "line": 245, "column": 3, - "index": 8484 + "index": 8640 } }, { @@ -64,14 +64,14 @@ "defaultMessage": "!!!Delegate", "file": "src/WalletNavigator.tsx", "start": { - "line": 243, + "line": 246, "column": 18, - "index": 8504 + "index": 8660 }, "end": { - "line": 246, + "line": 249, "column": 3, - "index": 8599 + "index": 8755 } }, { @@ -79,14 +79,14 @@ "defaultMessage": "!!!Wallet", "file": "src/WalletNavigator.tsx", "start": { - "line": 247, + "line": 250, "column": 16, - "index": 8617 + "index": 8773 }, "end": { - "line": 250, + "line": 253, "column": 3, - "index": 8715 + "index": 8871 } }, { @@ -94,14 +94,14 @@ "defaultMessage": "!!!Staking", "file": "src/WalletNavigator.tsx", "start": { - "line": 251, + "line": 254, "column": 17, - "index": 8734 + "index": 8890 }, "end": { - "line": 254, + "line": 257, "column": 3, - "index": 8799 + "index": 8955 } }, { @@ -109,14 +109,14 @@ "defaultMessage": "!!!NFT Gallery", "file": "src/WalletNavigator.tsx", "start": { - "line": 255, + "line": 258, "column": 14, - "index": 8815 + "index": 8971 }, "end": { - "line": 258, + "line": 261, "column": 3, - "index": 8909 + "index": 9065 } }, { @@ -124,14 +124,14 @@ "defaultMessage": "!!!Menu", "file": "src/WalletNavigator.tsx", "start": { - "line": 259, + "line": 262, "column": 14, - "index": 8925 + "index": 9081 }, "end": { - "line": 262, + "line": 265, "column": 3, - "index": 8977 + "index": 9133 } }, { @@ -139,14 +139,14 @@ "defaultMessage": "!!!My wallets", "file": "src/WalletNavigator.tsx", "start": { - "line": 263, + "line": 266, "column": 31, - "index": 9010 + "index": 9166 }, "end": { - "line": 266, + "line": 269, "column": 3, - "index": 9119 + "index": 9275 } } ] \ No newline at end of file diff --git a/apps/wallet-mobile/translations/messages/src/features/SetupWallet/SetupWalletNavigator.json b/apps/wallet-mobile/translations/messages/src/features/SetupWallet/SetupWalletNavigator.json index 7471c040d0..75ef2f0236 100644 --- a/apps/wallet-mobile/translations/messages/src/features/SetupWallet/SetupWalletNavigator.json +++ b/apps/wallet-mobile/translations/messages/src/features/SetupWallet/SetupWalletNavigator.json @@ -1,32 +1,32 @@ [ { "id": "components.walletinit.walletinitscreen.title", - "defaultMessage": "!!!Add wallet", + "defaultMessage": "!!!Add new wallet", "file": "src/features/SetupWallet/SetupWalletNavigator.tsx", "start": { - "line": 132, - "column": 18, - "index": 4623 + "line": 138, + "column": 21, + "index": 4825 }, "end": { - "line": 135, + "line": 141, "column": 3, - "index": 4721 + "index": 4927 } }, { "id": "components.walletinit.createwallet.createwalletscreen.title", - "defaultMessage": "!!!Create a new wallet", + "defaultMessage": "!!!Create wallet", "file": "src/features/SetupWallet/SetupWalletNavigator.tsx", "start": { - "line": 136, + "line": 142, "column": 21, - "index": 4744 + "index": 4950 }, "end": { - "line": 139, + "line": 145, "column": 3, - "index": 4866 + "index": 5066 } }, { @@ -34,14 +34,14 @@ "defaultMessage": "!!!Restore wallet", "file": "src/features/SetupWallet/SetupWalletNavigator.tsx", "start": { - "line": 140, + "line": 146, "column": 22, - "index": 4890 + "index": 5090 }, "end": { - "line": 143, + "line": 149, "column": 3, - "index": 5009 + "index": 5209 } }, { @@ -49,14 +49,14 @@ "defaultMessage": "!!!Read-only Wallet", "file": "src/features/SetupWallet/SetupWalletNavigator.tsx", "start": { - "line": 144, + "line": 150, "column": 23, - "index": 5034 + "index": 5234 }, "end": { - "line": 147, + "line": 153, "column": 3, - "index": 5148 + "index": 5348 } }, { @@ -64,14 +64,14 @@ "defaultMessage": "!!!Verify read-only wallet", "file": "src/features/SetupWallet/SetupWalletNavigator.tsx", "start": { - "line": 148, + "line": 154, "column": 27, - "index": 5177 + "index": 5377 }, "end": { - "line": 151, + "line": 157, "column": 3, - "index": 5296 + "index": 5496 } }, { @@ -79,14 +79,14 @@ "defaultMessage": "!!!Recovery phrase", "file": "src/features/SetupWallet/SetupWalletNavigator.tsx", "start": { - "line": 152, + "line": 158, "column": 21, - "index": 5319 + "index": 5519 }, "end": { - "line": 155, + "line": 161, "column": 3, - "index": 5437 + "index": 5637 } }, { @@ -94,14 +94,14 @@ "defaultMessage": "!!!Recovery phrase", "file": "src/features/SetupWallet/SetupWalletNavigator.tsx", "start": { - "line": 156, + "line": 162, "column": 22, - "index": 5461 + "index": 5661 }, "end": { - "line": 159, + "line": 165, "column": 3, - "index": 5580 + "index": 5780 } }, { @@ -109,14 +109,14 @@ "defaultMessage": "!!!Verify restored wallet", "file": "src/features/SetupWallet/SetupWalletNavigator.tsx", "start": { - "line": 160, + "line": 166, "column": 29, - "index": 5611 + "index": 5811 }, "end": { - "line": 163, + "line": 169, "column": 3, - "index": 5725 + "index": 5925 } }, { @@ -124,14 +124,14 @@ "defaultMessage": "!!!Wallet credentials", "file": "src/features/SetupWallet/SetupWalletNavigator.tsx", "start": { - "line": 164, + "line": 170, "column": 26, - "index": 5753 + "index": 5953 }, "end": { - "line": 167, + "line": 173, "column": 3, - "index": 5880 + "index": 6080 } }, { @@ -139,14 +139,14 @@ "defaultMessage": "!!!Connect to Ledger Device", "file": "src/features/SetupWallet/SetupWalletNavigator.tsx", "start": { - "line": 168, + "line": 174, "column": 21, - "index": 5903 + "index": 6103 }, "end": { - "line": 171, + "line": 177, "column": 3, - "index": 6030 + "index": 6230 } }, { @@ -154,14 +154,14 @@ "defaultMessage": "!!!Connect to Ledger Device", "file": "src/features/SetupWallet/SetupWalletNavigator.tsx", "start": { - "line": 172, + "line": 178, "column": 19, - "index": 6051 + "index": 6251 }, "end": { - "line": 175, + "line": 181, "column": 3, - "index": 6176 + "index": 6376 } }, { @@ -169,14 +169,14 @@ "defaultMessage": "!!!Save wallet", "file": "src/features/SetupWallet/SetupWalletNavigator.tsx", "start": { - "line": 176, + "line": 182, "column": 18, - "index": 6196 + "index": 6396 }, "end": { - "line": 179, + "line": 185, "column": 3, - "index": 6307 + "index": 6507 } } ] \ No newline at end of file From b4c9dcafb9ae2235a43dec72472c372e2febb168 Mon Sep 17 00:00:00 2001 From: ci-bot Date: Tue, 16 Apr 2024 14:20:33 +0000 Subject: [PATCH 3/3] chore(release): nightly --- apps/wallet-mobile/android/app/build.gradle | 2 +- apps/wallet-mobile/ios/nightly.plist | 2 +- apps/wallet-mobile/ios/yoroi.xcodeproj/project.pbxproj | 8 ++++---- apps/wallet-mobile/ios/yoroi/Info.plist | 2 +- apps/wallet-mobile/ios/yoroiTests/Info.plist | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/apps/wallet-mobile/android/app/build.gradle b/apps/wallet-mobile/android/app/build.gradle index ce5aacd177..c1bd47c41b 100644 --- a/apps/wallet-mobile/android/app/build.gradle +++ b/apps/wallet-mobile/android/app/build.gradle @@ -108,7 +108,7 @@ android { applicationId "com.emurgo" minSdkVersion rootProject.ext.minSdkVersion targetSdkVersion rootProject.ext.targetSdkVersion - versionCode 641 + versionCode 642 versionName "4.27.0" testBuildType System.getProperty('testBuildType', 'debug') testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner' diff --git a/apps/wallet-mobile/ios/nightly.plist b/apps/wallet-mobile/ios/nightly.plist index 74c3f17995..ff2dbbaa7f 100644 --- a/apps/wallet-mobile/ios/nightly.plist +++ b/apps/wallet-mobile/ios/nightly.plist @@ -21,7 +21,7 @@ CFBundleSignature ???? CFBundleVersion - 528 + 529 ITSAppUsesNonExemptEncryption LSApplicationCategoryType diff --git a/apps/wallet-mobile/ios/yoroi.xcodeproj/project.pbxproj b/apps/wallet-mobile/ios/yoroi.xcodeproj/project.pbxproj index 1fdebfe0c0..ee289c7bf8 100644 --- a/apps/wallet-mobile/ios/yoroi.xcodeproj/project.pbxproj +++ b/apps/wallet-mobile/ios/yoroi.xcodeproj/project.pbxproj @@ -839,7 +839,7 @@ CODE_SIGN_ENTITLEMENTS = yoroi/yoroi.entitlements; CODE_SIGN_IDENTITY = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 528; + CURRENT_PROJECT_VERSION = 529; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = F8NVT2G2L4; ENABLE_BITCODE = NO; @@ -884,7 +884,7 @@ CODE_SIGN_ENTITLEMENTS = yoroi/yoroi.entitlements; CODE_SIGN_IDENTITY = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 528; + CURRENT_PROJECT_VERSION = 529; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = F8NVT2G2L4; ENVFILE = "$(PODS_ROOT)/../../.env.production"; @@ -1079,7 +1079,7 @@ CODE_SIGN_ENTITLEMENTS = nightly.entitlements; CODE_SIGN_IDENTITY = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 528; + CURRENT_PROJECT_VERSION = 529; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = F8NVT2G2L4; ENABLE_BITCODE = NO; @@ -1124,7 +1124,7 @@ CODE_SIGN_ENTITLEMENTS = nightly.entitlements; CODE_SIGN_IDENTITY = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 528; + CURRENT_PROJECT_VERSION = 529; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = F8NVT2G2L4; ENVFILE = "$(PODS_ROOT)/../../.env.nightly"; diff --git a/apps/wallet-mobile/ios/yoroi/Info.plist b/apps/wallet-mobile/ios/yoroi/Info.plist index 14611772a5..d21376b87a 100644 --- a/apps/wallet-mobile/ios/yoroi/Info.plist +++ b/apps/wallet-mobile/ios/yoroi/Info.plist @@ -34,7 +34,7 @@ CFBundleVersion - 528 + 529 ITSAppUsesNonExemptEncryption LSApplicationCategoryType diff --git a/apps/wallet-mobile/ios/yoroiTests/Info.plist b/apps/wallet-mobile/ios/yoroiTests/Info.plist index 913e11b409..27eadd1ff1 100644 --- a/apps/wallet-mobile/ios/yoroiTests/Info.plist +++ b/apps/wallet-mobile/ios/yoroiTests/Info.plist @@ -19,6 +19,6 @@ CFBundleSignature ???? CFBundleVersion - 528 + 529