diff --git a/i18n/po/template.pot b/i18n/po/template.pot index 574703a0f..915e072c4 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -22,7 +22,7 @@ msgstr "" msgid "5-star ratings help us get BitPay into more hands, and more users means more resources can be committed to the app!" msgstr "" -#: src/js/controllers/confirm.js:454 +#: src/js/controllers/confirm.js:455 msgid "A SMS containing a confirmation code was sent to your phone." msgstr "" @@ -31,16 +31,16 @@ msgstr "" msgid "A member of the team will review your feedback as soon as possible." msgstr "" -#: src/js/controllers/confirm.js:212 +#: src/js/controllers/confirm.js:213 msgid "A total of {{amountAboveMaxSizeStr}} were excluded. The maximum size allowed for a transaction was exceeded." msgstr "" -#: src/js/controllers/confirm.js:206 +#: src/js/controllers/confirm.js:207 msgid "A total of {{amountBelowFeeStr}} were excluded. These funds come from UTXOs smaller than the network fee provided." msgstr "" #: src/js/controllers/preferencesAbout.js:6 -#: www/views/tab-settings.html:159 +#: www/views/tab-settings.html:149 msgid "About" msgstr "" @@ -112,7 +112,7 @@ msgstr "" msgid "Add an optional password to secure the recovery phrase" msgstr "" -#: src/js/controllers/confirm.js:266 +#: src/js/controllers/confirm.js:267 msgid "Add description" msgstr "" @@ -140,7 +140,7 @@ msgstr "" msgid "Addresses With Balance" msgstr "" -#: www/views/tab-settings.html:152 +#: www/views/tab-settings.html:142 msgid "Advanced" msgstr "" @@ -192,10 +192,18 @@ msgstr "" msgid "Amount below minimum allowed" msgstr "" +#: src/js/controllers/confirm.js:382 +msgid "Amount too big" +msgstr "" + #: www/views/tab-home.html:14 msgid "An update to this app is available" msgstr "" +#: src/js/controllers/tab-home.js:133 +msgid "An update to this app is available. For your security, please update to the latest version." +msgstr "" + #: www/views/backupWarning.html:14 msgid "Anyone with your backup phrase can access or spend your bitcoin." msgstr "" @@ -285,6 +293,10 @@ msgstr "" msgid "Be sure to store your recovery phrase in a secure place. If this app is deleted, your money cannot be recovered without it." msgstr "" +#: src/js/controllers/tab-settings.js:52 +msgid "BitPay Help Center" +msgstr "" + #: www/views/addressbook.add.html:38 msgid "Bitcoin Address" msgstr "" @@ -367,7 +379,7 @@ msgstr "" msgid "Calculating fee" msgstr "" -#: src/js/controllers/confirm.js:510 +#: src/js/controllers/confirm.js:511 #: src/js/services/confirmDialog.js:9 #: src/js/services/popupService.js:58 #: www/views/addressbook.add.html:10 @@ -387,7 +399,7 @@ msgstr "" msgid "Cannot join the same wallet more that once" msgstr "" -#: src/js/controllers/amazon.js:25 +#: src/js/controllers/amazon.js:27 msgid "Card not found" msgstr "" @@ -433,7 +445,7 @@ msgstr "" msgid "Commit hash" msgstr "" -#: src/js/controllers/confirm.js:509 +#: src/js/controllers/confirm.js:510 #: src/js/controllers/copayers.js:42 #: src/js/services/confirmDialog.js:10 #: www/views/backup.html:53 @@ -448,7 +460,8 @@ msgstr "" msgid "Confirm & Finish" msgstr "" -#: src/js/services/walletService.js:839 +#: src/js/services/walletService.js:840 +#: src/js/services/walletService.js:841 msgid "Confirm you new spending password" msgstr "" @@ -537,6 +550,10 @@ msgstr "" msgid "Could not access wallet" msgstr "" +#: src/js/controllers/confirm.js:376 +msgid "Could not add message to imported wallet without shared encrypting key" +msgstr "" + #: src/js/controllers/modals/txpDetails.js:172 msgid "Could not broadcast payment" msgstr "" @@ -577,7 +594,7 @@ msgstr "" msgid "Could not get dynamic fee for level: {{feeLevel}}" msgstr "" -#: src/js/controllers/confirm.js:655 +#: src/js/controllers/confirm.js:656 msgid "Could not get the destination bitcoin address" msgstr "" @@ -608,7 +625,7 @@ msgstr "" msgid "Could not remove card" msgstr "" -#: src/js/controllers/confirm.js:449 +#: src/js/controllers/confirm.js:450 msgid "Could not send confirmation code to your phone" msgstr "" @@ -616,14 +633,10 @@ msgstr "" msgid "Could not send payment" msgstr "" -#: src/js/controllers/tab-home.js:200 +#: src/js/controllers/tab-home.js:206 msgid "Could not update" msgstr "" -#: src/js/services/walletService.js:147 -msgid "Could not update Wallet" -msgstr "" - #: www/views/tab-create-personal.html:3 msgid "Create Personal Wallet" msgstr "" @@ -636,6 +649,7 @@ msgstr "" msgid "Create a bitcoin wallet" msgstr "" +#: www/views/onboarding/tour.html:46 #: www/views/tab-send.html:16 msgid "Create bitcoin wallet" msgstr "" @@ -799,8 +813,8 @@ msgstr "" msgid "Enter Amount" msgstr "" -#: src/js/services/walletService.js:852 -#: src/js/services/walletService.js:867 +#: src/js/services/walletService.js:854 +#: src/js/services/walletService.js:869 msgid "Enter Spending Password" msgstr "" @@ -835,9 +849,9 @@ msgstr "" #: src/js/controllers/addresses.js:84 #: src/js/controllers/addresses.js:85 #: src/js/controllers/amazon.js:15 -#: src/js/controllers/amazon.js:25 -#: src/js/controllers/amazon.js:46 -#: src/js/controllers/amazon.js:66 +#: src/js/controllers/amazon.js:27 +#: src/js/controllers/amazon.js:48 +#: src/js/controllers/amazon.js:68 #: src/js/controllers/amount.js:265 #: src/js/controllers/amount.js:272 #: src/js/controllers/amount.js:280 @@ -848,23 +862,23 @@ msgstr "" #: src/js/controllers/bitpayCard.js:145 #: src/js/controllers/bitpayCard.js:68 #: src/js/controllers/bitpayCardIntro.js:27 -#: src/js/controllers/confirm.js:152 -#: src/js/controllers/confirm.js:165 -#: src/js/controllers/confirm.js:171 -#: src/js/controllers/confirm.js:449 -#: src/js/controllers/confirm.js:460 -#: src/js/controllers/confirm.js:472 -#: src/js/controllers/confirm.js:621 -#: src/js/controllers/confirm.js:649 -#: src/js/controllers/confirm.js:655 -#: src/js/controllers/confirm.js:683 -#: src/js/controllers/confirm.js:689 -#: src/js/controllers/confirm.js:696 -#: src/js/controllers/confirm.js:703 -#: src/js/controllers/confirm.js:721 -#: src/js/controllers/confirm.js:740 -#: src/js/controllers/confirm.js:754 -#: src/js/controllers/confirm.js:797 +#: src/js/controllers/confirm.js:153 +#: src/js/controllers/confirm.js:166 +#: src/js/controllers/confirm.js:172 +#: src/js/controllers/confirm.js:450 +#: src/js/controllers/confirm.js:461 +#: src/js/controllers/confirm.js:473 +#: src/js/controllers/confirm.js:622 +#: src/js/controllers/confirm.js:650 +#: src/js/controllers/confirm.js:656 +#: src/js/controllers/confirm.js:684 +#: src/js/controllers/confirm.js:690 +#: src/js/controllers/confirm.js:697 +#: src/js/controllers/confirm.js:704 +#: src/js/controllers/confirm.js:722 +#: src/js/controllers/confirm.js:741 +#: src/js/controllers/confirm.js:755 +#: src/js/controllers/confirm.js:798 #: src/js/controllers/copayers.js:54 #: src/js/controllers/create.js:101 #: src/js/controllers/create.js:129 @@ -917,14 +931,14 @@ msgstr "" #: src/js/controllers/preferencesDelete.js:22 #: src/js/controllers/preferencesFee.js:9 #: src/js/controllers/preferencesGlidera.js:60 -#: src/js/controllers/tab-home.js:154 +#: src/js/controllers/tab-home.js:160 #: src/js/controllers/tab-receive.js:24 #: src/js/controllers/tabsController.js:7 #: src/js/controllers/tx-details.js:18 msgid "Error" msgstr "" -#: src/js/controllers/confirm.js:353 +#: src/js/controllers/confirm.js:354 msgid "Error at confirm" msgstr "" @@ -948,7 +962,7 @@ msgstr "" msgid "Experimental Features" msgstr "" -#: src/js/controllers/confirm.js:311 +#: src/js/controllers/confirm.js:312 #: www/views/confirm.html:30 #: www/views/modals/txp-details.html:114 msgid "Expired" @@ -972,7 +986,7 @@ msgstr "" msgid "Export wallet" msgstr "" -#: src/js/services/walletService.js:999 +#: src/js/services/walletService.js:1000 #: www/views/tab-export-qrCode.html:9 msgid "Exporting via QR not supported for this wallet" msgstr "" @@ -998,16 +1012,13 @@ msgstr "" msgid "Family vacation funds" msgstr "" +#: www/views/confirm.html:79 #: www/views/includes/confirm-tx.html:19 #: www/views/modals/txp-details.html:95 #: www/views/tx-details.html:71 msgid "Fee" msgstr "" -#: www/views/confirm.html:79 -msgid "Fee: {{feeLevel}}" -msgstr "" - #: src/js/controllers/feedback/send.js:23 msgid "Feedback could not be submitted. Please try again later." msgstr "" @@ -1099,6 +1110,16 @@ msgstr "" msgid "Glidera Inc. (Glidera) is providing the service of buying or selling bitcoin to BitPay users. To enable this service, Glidera has registered with US Treasury Department’s FinCEN as a Money Service Business (#31000042625755). Users of BitPay must agree to the service agreement presented by Glidera prior to obtaining Glidera’s service of buying or selling bitcoin." msgstr "" +#: src/js/controllers/onboarding/terms.js:23 +#: src/js/controllers/preferencesAbout.js:15 +#: src/js/controllers/preferencesLanguage.js:14 +#: src/js/controllers/tab-home.js:135 +#: src/js/controllers/tab-settings.js:55 +#: src/js/controllers/translators.js:11 +#: src/js/controllers/tx-details.js:128 +msgid "Go Back" +msgstr "" + #: src/js/controllers/bitpayCardIntro.js:35 #: src/js/controllers/onboarding/backupRequest.js:13 #: src/js/controllers/onboarding/backupRequest.js:19 @@ -1111,6 +1132,10 @@ msgstr "" msgid "Got it" msgstr "" +#: www/views/onboarding/tour.html:18 +msgid "Got it →" +msgstr "" + #: www/views/preferences.html:20 #: www/views/preferencesInformation.html:47 msgid "Hardware Wallet" @@ -1128,6 +1153,10 @@ msgstr "" msgid "Help & Support" msgstr "" +#: src/js/controllers/tab-settings.js:53 +msgid "Help and support information is available at the BitPay Help Center website. Would you like to go there now?" +msgstr "" + #: www/views/addresses.html:29 msgid "Hide" msgstr "" @@ -1396,6 +1425,10 @@ msgstr "" msgid "Make a payment to" msgstr "" +#: www/views/onboarding/tour.html:33 +msgid "Makes sense →" +msgstr "" + #: src/js/controllers/modals/search.js:61 msgid "Matches:" msgstr "" @@ -1538,7 +1571,7 @@ msgstr "" msgid "Not authorized" msgstr "" -#: src/js/controllers/confirm.js:171 +#: src/js/controllers/confirm.js:172 msgid "Not enough funds for fee" msgstr "" @@ -1602,6 +1635,36 @@ msgstr "" msgid "On this screen you can see all your wallets, accounts, and assets." msgstr "" +#: src/js/controllers/preferencesLanguage.js:13 +#: src/js/controllers/translators.js:10 +msgid "Open Crowdin" +msgstr "" + +#: src/js/controllers/preferencesAbout.js:14 +msgid "Open GitHub" +msgstr "" + +#: src/js/controllers/preferencesAbout.js:12 +msgid "Open GitHub Project" +msgstr "" + +#: src/js/controllers/tab-settings.js:54 +msgid "Open Help Center" +msgstr "" + +#: src/js/controllers/tx-details.js:127 +msgid "Open Insight" +msgstr "" + +#: src/js/controllers/preferencesLanguage.js:11 +#: src/js/controllers/translators.js:8 +msgid "Open Translation Community" +msgstr "" + +#: src/js/controllers/onboarding/terms.js:22 +msgid "Open Website" +msgstr "" + #: www/views/tab-receive.html:41 msgid "Open wallet" msgstr "" @@ -1739,7 +1802,7 @@ msgstr "" msgid "Please upgrade Copay to perform this action" msgstr "" -#: src/js/controllers/confirm.js:453 +#: src/js/controllers/confirm.js:454 msgid "Please, enter the code below" msgstr "" @@ -2039,7 +2102,7 @@ msgstr "" msgid "Send by email" msgstr "" -#: src/js/controllers/confirm.js:247 +#: src/js/controllers/confirm.js:248 msgid "Send from" msgstr "" @@ -2074,7 +2137,7 @@ msgstr "" msgid "Sending transaction" msgstr "" -#: src/js/controllers/confirm.js:505 +#: src/js/controllers/confirm.js:506 msgid "Sending {{amountStr}} from your {{name}} wallet" msgstr "" @@ -2243,10 +2306,6 @@ msgstr "" msgid "Tap to retry" msgstr "" -#: www/views/tab-settings.html:142 -msgid "Tell a friend" -msgstr "" - #: www/views/termsOfUse.html:3 msgid "Terms Of Use" msgstr "" @@ -2297,11 +2356,15 @@ msgstr "" msgid "The maximum number of consecutive unused addresses (20) has been reached. When one of your unused addresses receives a payment, a new address will be generated and shown in your Receive tab." msgstr "" +#: src/js/controllers/onboarding/terms.js:21 +msgid "The official English Terms of Service are available on the BitPay website. Would you like to view them?" +msgstr "" + #: www/views/tab-import-phrase.html:4 msgid "The password of the recovery phrase (if set)" msgstr "" -#: src/js/services/walletService.js:951 +#: src/js/services/walletService.js:952 msgid "The payment was created but could not be completed. Please try again from home screen" msgstr "" @@ -2371,7 +2434,7 @@ msgstr "" msgid "This app stores your bitcoin with cutting-edge security." msgstr "" -#: src/js/controllers/confirm.js:438 +#: src/js/controllers/confirm.js:439 msgid "This bitcoin payment request has expired." msgstr "" @@ -2440,7 +2503,7 @@ msgid "Transaction already broadcasted" msgstr "" #: src/js/controllers/activity.js:45 -#: src/js/controllers/tab-home.js:154 +#: src/js/controllers/tab-home.js:160 #: src/js/controllers/tx-details.js:18 msgid "Transaction not found" msgstr "" @@ -2466,6 +2529,10 @@ msgstr "" msgid "Type the Recovery Phrase (usually 12 words)" msgstr "" +#: src/js/controllers/backup.js:75 +msgid "Uh oh..." +msgstr "" + #: www/views/modals/search.html:36 #: www/views/tx-details.html:79 msgid "Unconfirmed" @@ -2487,6 +2554,10 @@ msgstr "" msgid "Unused Addresses Limit" msgstr "" +#: src/js/controllers/tab-home.js:132 +msgid "Update Available" +msgstr "" + #: www/views/proposals.html:15 msgid "Updating pending proposals. Please stand by" msgstr "" @@ -2523,6 +2594,18 @@ msgstr "" msgid "View All Addresses" msgstr "" +#: src/js/controllers/onboarding/terms.js:20 +msgid "View Terms of Service" +msgstr "" + +#: src/js/controllers/tx-details.js:125 +msgid "View Transaction on Insight" +msgstr "" + +#: src/js/controllers/tab-home.js:134 +msgid "View Update" +msgstr "" + #: www/views/tx-details.html:117 msgid "View on blockchain" msgstr "" @@ -2678,7 +2761,7 @@ msgstr "" msgid "Wallet not found" msgstr "" -#: src/js/controllers/tab-home.js:199 +#: src/js/controllers/tab-home.js:205 msgid "Wallet not registered" msgstr "" @@ -2770,6 +2853,10 @@ msgstr "" msgid "Would you like to receive push notifications about payments?" msgstr "" +#: src/js/controllers/tx-details.js:126 +msgid "Would you like to view this transaction on the Insight blockchain explorer?" +msgstr "" + #: src/js/controllers/import.js:248 msgid "Wrong number of recovery words:" msgstr "" @@ -2791,10 +2878,19 @@ msgstr "" msgid "You can create a backup later from your wallet settings." msgstr "" +#: src/js/controllers/preferencesLanguage.js:12 +#: src/js/controllers/translators.js:9 +msgid "You can make contributions by signing up on our Crowdin community translation website. We’re looking forward to hearing from you!" +msgstr "" + #: www/views/tab-scan.html:16 msgid "You can scan bitcoin addresses, payment requests, paper wallets, and more." msgstr "" +#: src/js/controllers/preferencesAbout.js:13 +msgid "You can see the latest developments and contribute to this open source app by visiting our project on GitHub." +msgstr "" + #: www/views/onboarding/tour.html:14 msgid "You can spend bitcoin at millions of websites and stores worldwide." msgstr "" @@ -2827,6 +2923,10 @@ msgstr "" msgid "Your bitcoin wallet is ready!" msgstr "" +#: www/views/feedback/send.html:42 +msgid "Your ideas, feedback, or comments" +msgstr "" + #: www/views/tab-create-shared.html:22 msgid "Your name" msgstr "" @@ -2876,6 +2976,10 @@ msgstr "" msgid "me" msgstr "" +#: www/views/addressbook.add.html:32 +msgid "name@example.com" +msgstr "" + #: www/views/preferencesHistory.html:14 msgid "preparing..." msgstr "" @@ -2884,7 +2988,7 @@ msgstr "" msgid "{{feeRateStr}} of the transaction" msgstr "" -#: src/js/controllers/confirm.js:185 +#: src/js/controllers/confirm.js:186 msgid "{{fee}} will be deducted for bitcoin networking fees." msgstr "" diff --git a/src/js/controllers/backup.js b/src/js/controllers/backup.js index f40af13d8..63e6d996f 100644 --- a/src/js/controllers/backup.js +++ b/src/js/controllers/backup.js @@ -72,7 +72,7 @@ angular.module('copayApp.controllers').controller('backupController', var showBackupResult = function() { if ($scope.backupError) { - var title = 'Uh oh...'; + var title = gettextCatalog.getString('Uh oh...'); var message = gettextCatalog.getString("It's important that you write your backup phrase down correctly. If something happens to your wallet, you'll need this backup to recover your money. Please review your backup and try again."); popupService.showAlert(title, message, function() { $scope.setFlow(2); diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index fac11aa46..ee0f148ae 100644 --- a/src/js/controllers/confirm.js +++ b/src/js/controllers/confirm.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('confirmController', function($rootScope, $scope, $interval, $filter, $timeout, $ionicScrollDelegate, gettextCatalog, walletService, platformInfo, lodash, configService, rateService, $stateParams, $window, $state, $log, profileService, bitcore, gettext, txFormatService, ongoingProcess, $ionicModal, popupService, $ionicHistory, $ionicConfig, payproService, feeService, amazonService, glideraService, bwcError, bitpayCardService) { +angular.module('copayApp.controllers').controller('confirmController', function($rootScope, $scope, $interval, $filter, $timeout, $ionicScrollDelegate, gettextCatalog, walletService, platformInfo, lodash, configService, rateService, $stateParams, $window, $state, $log, profileService, bitcore, txFormatService, ongoingProcess, $ionicModal, popupService, $ionicHistory, $ionicConfig, payproService, feeService, amazonService, glideraService, bwcError, bitpayCardService) { var cachedTxp = {}; var toAmount; var isChromeApp = platformInfo.isChromeApp; @@ -45,7 +45,8 @@ angular.module('copayApp.controllers').controller('confirmController', function( }; var config = configService.getSync().wallet; - $scope.feeLevel = config.settings && config.settings.feeLevel ? config.settings.feeLevel : 'normal'; + var feeLevel = config.settings && config.settings.feeLevel ? config.settings.feeLevel : 'normal'; + $scope.feeLevel = feeService.feeOpts[feeLevel]; if ($scope.isGlidera) $scope.network = glideraService.getEnvironment(); else $scope.network = (new bitcore.Address($scope.toAddress)).network.name; resetValues(); @@ -350,7 +351,7 @@ angular.module('copayApp.controllers').controller('confirmController', function( $timeout(function() { $scope.$apply(); }); - popupService.showAlert(gettextCatalog.getString('Error at confirm'), msg); + popupService.showAlert(gettextCatalog.getString('Error at confirm'), bwcError.msg(msg)); }; function apply(txp) { @@ -372,13 +373,13 @@ angular.module('copayApp.controllers').controller('confirmController', function( // ToDo: use a credential's (or fc's) function for this if (description && !wallet.credentials.sharedEncryptingKey) { - var msg = 'Could not add message to imported wallet without shared encrypting key'; + var msg = gettextCatalog.getString('Could not add message to imported wallet without shared encrypting key'); $log.warn(msg); return setSendError(msg); } if (toAmount > Number.MAX_SAFE_INTEGER) { - var msg = 'Amount too big'; + var msg = gettextCatalog.getString('Amount too big'); $log.warn(msg); return setSendError(msg); } diff --git a/src/js/controllers/create.js b/src/js/controllers/create.js index bad361d93..73ef2f64d 100644 --- a/src/js/controllers/create.js +++ b/src/js/controllers/create.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.controllers').controller('createController', - function($scope, $rootScope, $timeout, $log, lodash, $state, $ionicScrollDelegate, $ionicHistory, profileService, configService, gettext, gettextCatalog, ledger, trezor, platformInfo, derivationPathHelper, ongoingProcess, walletService, storageService, popupService) { + function($scope, $rootScope, $timeout, $log, lodash, $state, $ionicScrollDelegate, $ionicHistory, profileService, configService, gettextCatalog, ledger, trezor, platformInfo, derivationPathHelper, ongoingProcess, walletService, storageService, popupService) { var isChromeApp = platformInfo.isChromeApp; var isCordova = platformInfo.isCordova; @@ -67,10 +67,10 @@ angular.module('copayApp.controllers').controller('createController', function updateSeedSourceSelect(n) { var seedOptions = [{ id: 'new', - label: gettext('Random'), + label: gettextCatalog.getString('Random'), }, { id: 'set', - label: gettext('Specify Recovery Phrase...'), + label: gettextCatalog.getString('Specify Recovery Phrase...'), }]; $scope.seedSource = seedOptions[0]; diff --git a/src/js/controllers/join.js b/src/js/controllers/join.js index c358b7fc9..d15f152b4 100644 --- a/src/js/controllers/join.js +++ b/src/js/controllers/join.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.controllers').controller('joinController', - function($scope, $rootScope, $timeout, $state, $ionicHistory, $ionicScrollDelegate, profileService, configService, storageService, applicationService, gettext, gettextCatalog, lodash, ledger, trezor, platformInfo, derivationPathHelper, ongoingProcess, walletService, $log, $stateParams, popupService) { + function($scope, $rootScope, $timeout, $state, $ionicHistory, $ionicScrollDelegate, profileService, configService, storageService, applicationService, gettextCatalog, lodash, ledger, trezor, platformInfo, derivationPathHelper, ongoingProcess, walletService, $log, $stateParams, popupService) { var isChromeApp = platformInfo.isChromeApp; var isDevel = platformInfo.isDevel; @@ -50,10 +50,10 @@ angular.module('copayApp.controllers').controller('joinController', var updateSeedSourceSelect = function() { self.seedOptions = [{ id: 'new', - label: gettext('Random'), + label: gettextCatalog.getString('Random'), }, { id: 'set', - label: gettext('Specify Recovery Phrase...'), + label: gettextCatalog.getString('Specify Recovery Phrase...'), }]; $scope.seedSource = self.seedOptions[0]; diff --git a/src/js/controllers/modals/txpDetails.js b/src/js/controllers/modals/txpDetails.js index eb88b5d02..a5783de17 100644 --- a/src/js/controllers/modals/txpDetails.js +++ b/src/js/controllers/modals/txpDetails.js @@ -107,7 +107,7 @@ angular.module('copayApp.controllers').controller('txpDetailsController', functi } } - var setError = function (err, prefix) { + var setError = function(err, prefix) { $scope.sendStatus = ''; $scope.loading = false; popupService.showAlert(gettextCatalog.getString('Error'), bwcError.msg(err, prefix)); @@ -164,9 +164,9 @@ angular.module('copayApp.controllers').controller('txpDetailsController', functi $scope.loading = true; $timeout(function() { - ongoingProcess.set('broadcastTx', true); + ongoingProcess.set('broadcastingTx', true); walletService.broadcastTx($scope.wallet, $scope.tx, function(err, txpb) { - ongoingProcess.set('broadcastTx', false); + ongoingProcess.set('broadcastingTx', false); if (err) { return setError(err, gettextCatalog.getString('Could not broadcast payment')); @@ -185,7 +185,7 @@ angular.module('copayApp.controllers').controller('txpDetailsController', functi $scope.wallet.getTx($scope.tx.id, function(err, tx) { if (err) { if (err.message && err.message == 'Transaction proposal not found' && - (eventName == 'transactionProposalRemoved' || eventName == 'TxProposalRemoved')) { + (eventName == 'transactionProposalRemoved' || eventName == 'TxProposalRemoved')) { $scope.tx.removed = true; $scope.tx.canBeRemoved = false; $scope.tx.pendingForUs = false; @@ -209,7 +209,7 @@ angular.module('copayApp.controllers').controller('txpDetailsController', functi }); }; - var bwsEvent = $rootScope.$on('bwsEvent', function(e, walletId, type, n) { + var bwsEvent = $rootScope.$on('bwsEvent', function(e, walletId, type, n) { lodash.each([ 'TxProposalRejectedBy', 'TxProposalAcceptedBy', diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index 0638a818c..9e915deed 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -284,7 +284,7 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun var scrollWatcherInitialized; $scope.$on("$ionicView.enter", function(event, data) { - setAndroidStatusBarColor(); + if ($scope.isCordova && $scope.isAndroid) setAndroidStatusBarColor(); $timeout(function() { screenInactive = false; }, 200); @@ -336,9 +336,6 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun function setAndroidStatusBarColor() { var SUBTRACT_AMOUNT = 15; - if (!$scope.isAndroid) { - return; - } var rgb = hexToRgb($scope.wallet.color); var keys = Object.keys(rgb); keys.forEach(function(k) { @@ -349,7 +346,8 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun } }); var statusBarColorHexString = rgbToHex(rgb.r, rgb.g, rgb.b); - $window.StatusBar.backgroundColorByHexString(statusBarColorHexString); + if ($window.StatusBar) + $window.StatusBar.backgroundColorByHexString(statusBarColorHexString); } function hexToRgb(hex) { diff --git a/src/js/services/trezor.js b/src/js/services/trezor.js index 199709886..f0a40c9dd 100644 --- a/src/js/services/trezor.js +++ b/src/js/services/trezor.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.services') - .factory('trezor', function($log, $timeout, gettext, lodash, bitcore, hwWallet) { + .factory('trezor', function($log, $timeout, lodash, bitcore, hwWallet) { var root = {}; var SETTLE_TIME = 3000; @@ -82,7 +82,7 @@ angular.module('copayApp.services') if (txp.outputs.length > 1) return callback('Only single output TXPs are supported in TREZOR'); } else { - return callback('Unknown TXP at TREZOR'); + return callback('Unknown TXP at TREZOR'); } if (txp.outputs) { diff --git a/src/js/services/walletService.js b/src/js/services/walletService.js index d7c7519f9..da59c5ffd 100644 --- a/src/js/services/walletService.js +++ b/src/js/services/walletService.js @@ -144,7 +144,7 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim if (err instanceof errors.NOT_AUTHORIZED) { return cb('WALLET_NOT_REGISTERED'); } - return cb(bwcError.msg(err, gettext('Could not update Wallet'))); + return cb(err); } return cb(null, ret); }); @@ -404,7 +404,7 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim function getNewTxs(newTxs, skip, cb) { getTxsFromServer(wallet, skip, endingTxid, requestLimit, function(err, res, shouldContinue) { if (err) { - $log.warn('BWS Error:' + err); //TODO + $log.warn(bwcError.msg(err, 'BWS Error')); //TODO if (err instanceof errors.CONNECTION_ERROR || (err.message && err.message.match(/5../))) { log.info('Retrying history download in 5 secs...'); return $timeout(function() { @@ -834,9 +834,11 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim root.encrypt = function(wallet, cb) { - askPassword(wallet.name, gettext('Enter new spending password'), function(password) { + var title = gettextCatalog.getString('Enter new spending password'); + askPassword(wallet.name, title, function(password) { if (!password) return cb('no password'); - askPassword(wallet.name, gettext('Confirm you new spending password'), function(password2) { + title = gettextCatalog.getString('Confirm you new spending password'); + askPassword(wallet.name, gettextCatalog.getString('Confirm you new spending password'), function(password2) { if (!password2 || password != password2) return cb('password mismatch'); @@ -849,7 +851,7 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim root.decrypt = function(wallet, cb) { $log.debug('Disabling private key encryption for' + wallet.name); - askPassword(wallet.name, gettext('Enter Spending Password'), function(password) { + askPassword(wallet.name, gettextCatalog.getString('Enter Spending Password'), function(password) { if (!password) return cb('no password'); try { @@ -864,7 +866,7 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim root.handleEncryptedWallet = function(wallet, cb) { if (!root.isEncrypted(wallet)) return cb(); - askPassword(wallet.name, gettext('Enter Spending Password'), function(password) { + askPassword(wallet.name, gettextCatalog.getString('Enter Spending Password'), function(password) { if (!password) return cb('No password'); if (!wallet.checkPassword(password)) return cb('Wrong password'); @@ -929,13 +931,13 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim } root.prepare(wallet, function(err, password) { - if (err) return cb('Prepare error: ' + err); + if (err) return cb(bwcError.msg(err)); ongoingProcess.set('sendingTx', true, customStatusHandler); publishFn(wallet, txp, function(err, publishedTxp) { ongoingProcess.set('sendingTx', false, customStatusHandler); - if (err) return cb('Send Error: ' + err); + if (err) return cb(bwcError.msg(err)); ongoingProcess.set('signingTx', true, customStatusHandler); root.signTx(wallet, publishedTxp, password, function(err, signedTxp) { @@ -945,10 +947,9 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim if (err) { $log.warn('sign error:' + err); - // TODO? - var msg = err.message ? + var msg = err && err.message ? err.message : - gettext('The payment was created but could not be completed. Please try again from home screen'); + gettextCatalog.getString('The payment was created but could not be completed. Please try again from home screen'); $rootScope.$emit('Local/TxAction', wallet.id); return cb(msg); @@ -958,7 +959,7 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim ongoingProcess.set('broadcastingTx', true, customStatusHandler); root.broadcastTx(wallet, signedTxp, function(err, broadcastedTxp) { ongoingProcess.set('broadcastingTx', false, customStatusHandler); - if (err) return cb('sign error' + err); + if (err) return cb(bwcError.msg(err)); $rootScope.$emit('Local/TxAction', wallet.id); var type = root.getViewStatus(wallet, broadcastedTxp); diff --git a/www/views/addressbook.add.html b/www/views/addressbook.add.html index 7a79f858b..088fbf47d 100644 --- a/www/views/addressbook.add.html +++ b/www/views/addressbook.add.html @@ -29,7 +29,7 @@ Email diff --git a/www/views/confirm.html b/www/views/confirm.html index 24a8aa41f..9af5b7664 100644 --- a/www/views/confirm.html +++ b/www/views/confirm.html @@ -76,7 +76,7 @@
- Fee: {{feeLevel}} + {{'Fee' | translate}}: {{feeLevel | translate}} {{fee || '...'}} diff --git a/www/views/feedback/send.html b/www/views/feedback/send.html index 14e74b5b6..4f6f4e409 100644 --- a/www/views/feedback/send.html +++ b/www/views/feedback/send.html @@ -39,7 +39,7 @@ {{comment}}
- + diff --git a/www/views/onboarding/tour.html b/www/views/onboarding/tour.html index de836e0c9..371842f81 100644 --- a/www/views/onboarding/tour.html +++ b/www/views/onboarding/tour.html @@ -15,7 +15,7 @@
Just scan the code to pay.
-
@@ -30,7 +30,7 @@
The exchange rate changes with the market.
-
@@ -38,12 +38,12 @@ -
You control your bitcoin.
-
This app stores your bitcoin with cutting-edge security.
+
You control your bitcoin.
+
This app stores your bitcoin with cutting-edge security.
Not even BitPay can access it.
-