From f9f852211970d6d39786eb968d476b219ede09a2 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Wed, 6 Jun 2018 17:56:50 +0900 Subject: [PATCH 001/386] Increment version --- app-template/bitcoincom/appConfig.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app-template/bitcoincom/appConfig.json b/app-template/bitcoincom/appConfig.json index 41c2789c8..2c9f4308e 100644 --- a/app-template/bitcoincom/appConfig.json +++ b/app-template/bitcoincom/appConfig.json @@ -24,9 +24,9 @@ "windowsAppId": "804636ee-b017-4cad-8719-e58ac97ffa5c", "pushSenderId": "1036948132229", "description": "A Secure Bitcoin Wallet", - "version": "4.11.0", - "fullVersion": "4.11-rc1", - "androidVersion": "411000", + "version": "4.11.1", + "fullVersion": "4.11-hotfix1", + "androidVersion": "411100", "_extraCSS": "", "_enabledExtensions": { "coinbase": false, From a6d2799510849606d2a88942979ef1e73a78c37f Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 13 Jun 2018 15:56:39 +1200 Subject: [PATCH 002/386] Display fiat on Payment Received screen, according to preferences. --- src/js/controllers/tab-receive.js | 6 ++++++ www/views/tab-receive.html | 3 ++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index c9fa46de9..4d048e22e 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -125,6 +125,12 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi for (var i = 0; i < data.x.out.length; i++) { if (data.x.out[i].addr == watchAddress) { $scope.paymentReceivedAmount = txFormatService.formatAmount(data.x.out[i].value, 'full'); + $scope.paymentReceivedAlternativeAmount = null; // For when a subsequent payment is received. + txFormatService.formatAlternativeStr($scope.wallet.coin, data.x.out[i].value, function(alternativeStr){ + if (alternativeStr) { + $scope.paymentReceivedAlternativeAmount = alternativeStr; + } + }); } } $scope.paymentReceivedCoin = $scope.wallet.coin; diff --git a/www/views/tab-receive.html b/www/views/tab-receive.html index 0eb598096..a6b94b74e 100644 --- a/www/views/tab-receive.html +++ b/www/views/tab-receive.html @@ -61,7 +61,8 @@


Payment Received! - {{ paymentReceivedAmount }} {{ paymentReceivedCoin }} + {{ paymentReceivedAmount }} {{ paymentReceivedCoin }} + {{ paymentReceivedAlternativeAmount }} Return To Address

From a186e4d04f353626e50acedfcb34d82299007c7c Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 14 Jun 2018 22:16:25 +1200 Subject: [PATCH 003/386] Display fiat on Network Fees popup. Display subcent amounts as '< 0.01'. --- src/js/controllers/confirm.js | 17 ++++-- src/js/services/txFormatService.js | 14 +++-- src/js/services/txFormatService.spec.js | 71 +++++++++++++++++++++++++ 3 files changed, 96 insertions(+), 6 deletions(-) create mode 100644 src/js/services/txFormatService.spec.js diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index fc92a2287..53589cf22 100644 --- a/src/js/controllers/confirm.js +++ b/src/js/controllers/confirm.js @@ -426,6 +426,8 @@ angular.module('copayApp.controllers').controller('confirmController', function( function showSendMaxWarning(wallet, sendMaxInfo) { + var feeAlternative, + msg; function verifyExcludedUtxos() { var warningMsg = []; @@ -443,9 +445,18 @@ angular.module('copayApp.controllers').controller('confirmController', function( return warningMsg.join('\n'); }; - var msg = gettextCatalog.getString("{{fee}} will be deducted for bitcoin networking fees.", { - fee: txFormatService.formatAmountStr(wallet.coin, sendMaxInfo.fee) - }); + feeAlternative = txFormatService.formatAlternativeStr(wallet.coin, sendMaxInfo.fee); + if (feeAlternative) { + msg = gettextCatalog.getString("{{feeAlternative}} will be deducted for bitcoin networking fees ({{fee}}).", { + fee: txFormatService.formatAmountStr(wallet.coin, sendMaxInfo.fee), + feeAlternative: feeAlternative + }); + } else { + gettextCatalog.getString("{{fee}} will be deducted for bitcoin networking fees).", { + fee: txFormatService.formatAmountStr(wallet.coin, sendMaxInfo.fee) + }); + } + var warningMsg = verifyExcludedUtxos(); if (!lodash.isEmpty(warningMsg)) diff --git a/src/js/services/txFormatService.js b/src/js/services/txFormatService.js index 5817c1a27..c208857a8 100644 --- a/src/js/services/txFormatService.js +++ b/src/js/services/txFormatService.js @@ -72,11 +72,19 @@ angular.module('copayApp.services').factory('txFormatService', function($filter, var config = configService.getSync().wallet.settings; var val = function() { - var v1 = parseFloat((rateService.toFiat(satoshis, config.alternativeIsoCode, coin)).toFixed(2)); - v1 = $filter('formatFiatAmount')(v1); + var fiatAmount = rateService.toFiat(satoshis, config.alternativeIsoCode, coin); + var roundedStr = fiatAmount.toFixed(2); + var roundedNum = parseFloat(roundedStr); + var subcent = roundedNum === 0 && fiatAmount > 0; + var lessThanPrefix = ''; + if (subcent) { + roundedNum = 0.01; + lessThanPrefix = '< ' + } + var v1 = $filter('formatFiatAmount')(roundedNum); if (!v1) return null; - return v1 + ' ' + config.alternativeIsoCode; + return lessThanPrefix + v1 + ' ' + config.alternativeIsoCode; }; // Async version diff --git a/src/js/services/txFormatService.spec.js b/src/js/services/txFormatService.spec.js new file mode 100644 index 000000000..5ca60210d --- /dev/null +++ b/src/js/services/txFormatService.spec.js @@ -0,0 +1,71 @@ +describe('txFormatService', function(){ + var configServiceMock, + rateServiceMock, + txFormatService; + + beforeEach(function(){ + module('ngLodash'); + module('bwcModule'); + module('copayApp.filters'); + module('copayApp.services'); + + configServiceMock = { + getSync: jasmine.createSpy() + }; + + rateServiceMock = { + isAvailable: jasmine.createSpy(), + toFiat: jasmine.createSpy() + }; + + module(function($provide) { + $provide.value('configService', configServiceMock); + //$provide.value('$log', log); // Handy for debugging test failures + $provide.value('rateService', rateServiceMock); + }); + + inject(function($injector){ + txFormatService = $injector.get('txFormatService'); + }); + + }); + + it('formatAlternativeStr 0.49 cents.', function() { + + configServiceMock.getSync.and.returnValue({ + wallet: { + settings: { + alternativeIsoCode: 'USD' + } + } + }); + + rateServiceMock.isAvailable.and.returnValue(true); + rateServiceMock.toFiat.and.returnValue(0.00499); + + var formatted = txFormatService.formatAlternativeStr('bch', 123); + + expect(formatted).toBe('< 0.01 USD'); + //expect(formatted).toBe('0.00 USD'); + + }); + + it('formatAlternativeStr 0.5 cents.', function() { + + configServiceMock.getSync.and.returnValue({ + wallet: { + settings: { + alternativeIsoCode: 'USD' + } + } + }); + + rateServiceMock.isAvailable.and.returnValue(true); + rateServiceMock.toFiat.and.returnValue(0.005); + + var formatted = txFormatService.formatAlternativeStr('bch', 123); + + expect(formatted).toBe('0.01 USD'); + }); + +}); \ No newline at end of file From 143b39970b55bfb15606a04c591099eaba6a95d6 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 14 Jun 2018 22:18:17 +1200 Subject: [PATCH 004/386] Removed some commented out code. --- src/js/services/txFormatService.spec.js | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/js/services/txFormatService.spec.js b/src/js/services/txFormatService.spec.js index 5ca60210d..c67e86f21 100644 --- a/src/js/services/txFormatService.spec.js +++ b/src/js/services/txFormatService.spec.js @@ -20,7 +20,6 @@ describe('txFormatService', function(){ module(function($provide) { $provide.value('configService', configServiceMock); - //$provide.value('$log', log); // Handy for debugging test failures $provide.value('rateService', rateServiceMock); }); @@ -46,8 +45,6 @@ describe('txFormatService', function(){ var formatted = txFormatService.formatAlternativeStr('bch', 123); expect(formatted).toBe('< 0.01 USD'); - //expect(formatted).toBe('0.00 USD'); - }); it('formatAlternativeStr 0.5 cents.', function() { From 1e73eae4d2db7fdfdc398deb818704d38fc83fad Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 15 Jun 2018 10:04:15 +1200 Subject: [PATCH 005/386] Bugfix for undefined wallet status on send tab. --- src/js/controllers/tab-send.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 29f1749cb..2282ab878 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -76,8 +76,11 @@ angular.module('copayApp.controllers').controller('tabSendController', function( var walletList = []; lodash.each(walletsToTransfer, function(v) { var displayBalanceAsFiat = - v.status.alternativeBalanceAvailable && - config.wallet.settings.priceDisplay === 'fiat'; + // BD got v.status as undefined here once during development, just + // after creating a new wallet. + v.status && + v.status.alternativeBalanceAvailable && + config.wallet.settings.priceDisplay === 'fiat'; walletList.push({ color: v.color, From e416deec44a66937b1848852ad4a64859c0fb90e Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 15 Jun 2018 10:06:38 +1200 Subject: [PATCH 006/386] Amount shown confirm screen is now primarily fiat. --- src/sass/views/includes/txp-details.scss | 12 ++++-------- www/views/confirm.html | 2 +- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/src/sass/views/includes/txp-details.scss b/src/sass/views/includes/txp-details.scss index c32faaacd..9da0811e0 100644 --- a/src/sass/views/includes/txp-details.scss +++ b/src/sass/views/includes/txp-details.scss @@ -36,17 +36,13 @@ .amount-label{ line-height: 30px; .amount{ - font-size: 38px; + font-size: 16px; margin-bottom: .5rem; - - > .unit { - font-family: "Roboto-Light"; - } + color: #9B9B9B; + font-family: "Roboto-Light"; } .alternative { - font-size: 16px; - font-family: "Roboto-Light"; - color: #9B9B9B; + font-size: 38px; } } } diff --git a/www/views/confirm.html b/www/views/confirm.html index 443043d49..57f3a60e8 100644 --- a/www/views/confirm.html +++ b/www/views/confirm.html @@ -16,8 +16,8 @@ Sending maximum amount
-
{{tx.amountValueStr || '...'}} {{tx.amountUnitStr}}
{{tx.alternativeAmountStr || '...'}}
+
{{tx.amountValueStr || '...'}} {{tx.amountUnitStr}}
From fffbda2458ac9cd860893c31afb97b58a00024a7 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 15 Jun 2018 10:14:21 +1200 Subject: [PATCH 007/386] Matched amount formatting on Confirm screen, to previous formatting. --- src/js/controllers/confirm.js | 2 ++ src/sass/views/includes/txp-details.scss | 4 ++++ www/views/confirm.html | 2 +- 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index 53589cf22..cebf9cb3a 100644 --- a/src/js/controllers/confirm.js +++ b/src/js/controllers/confirm.js @@ -288,6 +288,8 @@ angular.module('copayApp.controllers').controller('confirmController', function( tx.amountUnitStr = tx.amountStr.split(' ')[1]; txFormatService.formatAlternativeStr(wallet.coin, tx.toAmount, function(v) { tx.alternativeAmountStr = v; + tx.alternativeAmountValueStr = tx.alternativeAmountStr.split(' ')[0]; + tx.alternativeAmountUnitStr = tx.alternativeAmountStr.split(' ')[1]; }); } diff --git a/src/sass/views/includes/txp-details.scss b/src/sass/views/includes/txp-details.scss index 9da0811e0..ae6c0d218 100644 --- a/src/sass/views/includes/txp-details.scss +++ b/src/sass/views/includes/txp-details.scss @@ -43,6 +43,10 @@ } .alternative { font-size: 38px; + + > .unit { + font-family: "Roboto-Light"; + } } } } diff --git a/www/views/confirm.html b/www/views/confirm.html index 57f3a60e8..ad34e1f08 100644 --- a/www/views/confirm.html +++ b/www/views/confirm.html @@ -16,7 +16,7 @@ Sending maximum amount
-
{{tx.alternativeAmountStr || '...'}}
+
{{tx.alternativeAmountValueStr || '...'}} {{tx.alternativeAmountUnitStr}}
{{tx.amountValueStr || '...'}} {{tx.amountUnitStr}}
From a9a05da07d267fee0f243226e94d61c27acb775c Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 15 Jun 2018 10:19:46 +1200 Subject: [PATCH 008/386] Fee on confirm screen now shown primarily in fiat. --- www/views/confirm.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/www/views/confirm.html b/www/views/confirm.html index ad34e1f08..e54837f34 100644 --- a/www/views/confirm.html +++ b/www/views/confirm.html @@ -77,9 +77,9 @@
{{'Fee:' | translate}} {{tx.feeLevelName | translate}} - {{tx.txp[wallet.id].feeStr || '...'}} + {{tx.txp[wallet.id].alternativeFeeStr || '...'}} - {{tx.txp[wallet.id].alternativeFeeStr || '...'}}  + {{tx.txp[wallet.id].feeStr || '...'}}  ·   {{tx.txp[wallet.id].feeRatePerStr}} of the sending amount From 901d202f857c07a366d0f1b3c33f711e516f2374 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 15 Jun 2018 10:24:00 +1200 Subject: [PATCH 009/386] Bugfix for when alternative string is not available in Network Fees alert. --- src/js/controllers/confirm.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index cebf9cb3a..cc48bf6b9 100644 --- a/src/js/controllers/confirm.js +++ b/src/js/controllers/confirm.js @@ -454,7 +454,7 @@ angular.module('copayApp.controllers').controller('confirmController', function( feeAlternative: feeAlternative }); } else { - gettextCatalog.getString("{{fee}} will be deducted for bitcoin networking fees).", { + msg = gettextCatalog.getString("{{fee}} will be deducted for bitcoin networking fees).", { fee: txFormatService.formatAmountStr(wallet.coin, sendMaxInfo.fee) }); } From 86be126e951f715d481491564cb55d6ce40e55b1 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 15 Jun 2018 15:43:37 +1200 Subject: [PATCH 010/386] Adjust spacing on amount in confirm screen, to match original. --- src/sass/views/includes/txp-details.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sass/views/includes/txp-details.scss b/src/sass/views/includes/txp-details.scss index ae6c0d218..240ee444b 100644 --- a/src/sass/views/includes/txp-details.scss +++ b/src/sass/views/includes/txp-details.scss @@ -37,12 +37,12 @@ line-height: 30px; .amount{ font-size: 16px; - margin-bottom: .5rem; color: #9B9B9B; font-family: "Roboto-Light"; } .alternative { font-size: 38px; + margin-bottom: .5rem; > .unit { font-family: "Roboto-Light"; From c26c7ab8c3119e9204472bf3950a8053957c4421 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 19 Jun 2018 06:19:51 +1200 Subject: [PATCH 011/386] Decorator for displaying debug messages as info. --- Gruntfile.js | 1 + src/js/decorators/displayLogDebug.js | 17 +++++++++++++++++ 2 files changed, 18 insertions(+) create mode 100644 src/js/decorators/displayLogDebug.js diff --git a/Gruntfile.js b/Gruntfile.js index f9ed59621..6c06404fa 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -152,6 +152,7 @@ module.exports = function(grunt) { src: [ 'src/js/app.js', 'src/js/routes.js', + 'src/js/decorators/*.js', 'src/js/directives/*.js', '!src/js/directives/*.spec.js', diff --git a/src/js/decorators/displayLogDebug.js b/src/js/decorators/displayLogDebug.js new file mode 100644 index 000000000..d6ce33dc3 --- /dev/null +++ b/src/js/decorators/displayLogDebug.js @@ -0,0 +1,17 @@ + angular.module('copayApp') + .config(['$provide', '$logProvider', function($provide, $logProvider) { + console.log('Config for profileService'); + // expose a provider to reach debugEnabled in $log + $provide.value('$logProvider', $logProvider); +}]) +.decorator('$log', ['$logProvider', '$delegate', function($logProvider, $delegate) { + console.log('Config for profileService'); + // override $log.debug to display in Chrome + $delegate.debug = function () { + if ($logProvider.debugEnabled()) { + $delegate.info.apply($delegate, arguments); + } + }; + + return $delegate; +}]); \ No newline at end of file From 09dc418f5ee9f15a408586464ee5ae4a1a86a2c3 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 19 Jun 2018 06:23:21 +1200 Subject: [PATCH 012/386] Remove log statements. --- src/js/decorators/displayLogDebug.js | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/js/decorators/displayLogDebug.js b/src/js/decorators/displayLogDebug.js index d6ce33dc3..4eacf34b3 100644 --- a/src/js/decorators/displayLogDebug.js +++ b/src/js/decorators/displayLogDebug.js @@ -1,11 +1,9 @@ angular.module('copayApp') .config(['$provide', '$logProvider', function($provide, $logProvider) { - console.log('Config for profileService'); // expose a provider to reach debugEnabled in $log $provide.value('$logProvider', $logProvider); }]) .decorator('$log', ['$logProvider', '$delegate', function($logProvider, $delegate) { - console.log('Config for profileService'); // override $log.debug to display in Chrome $delegate.debug = function () { if ($logProvider.debugEnabled()) { From 06ab1d1062b07569dc128f6fa6e2559fcff497de Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 25 Jun 2018 11:07:13 +0200 Subject: [PATCH 013/386] - remove native audio plugin references - soundService for playing sounds - file naming changed on sound files - Bug where sounds were playing when mute switch on iPhone was on - added cordova media plugin (with support for a fix the found mute-switch bug) - play all sounds to use the new soundService --- app-template/config-template.xml | 4 +- src/js/controllers/confirm.js | 7 +--- src/js/controllers/tab-receive.js | 30 +------------- src/js/services/soundService.js | 39 ++++++++++++++++++ ...coin_received.mp3 => payment_received.mp3} | Bin ...coin_received.ogg => payment_received.ogg} | Bin www/misc/{bch_sent.mp3 => payment_sent.mp3} | Bin www/misc/payment_sent.ogg | Bin 0 -> 14156 bytes 8 files changed, 46 insertions(+), 34 deletions(-) create mode 100644 src/js/services/soundService.js rename www/misc/{coin_received.mp3 => payment_received.mp3} (100%) rename www/misc/{coin_received.ogg => payment_received.ogg} (100%) rename www/misc/{bch_sent.mp3 => payment_sent.mp3} (100%) create mode 100644 www/misc/payment_sent.ogg diff --git a/app-template/config-template.xml b/app-template/config-template.xml index ed4b192ba..239f78d6c 100644 --- a/app-template/config-template.xml +++ b/app-template/config-template.xml @@ -72,7 +72,9 @@ - + + + diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index fc92a2287..51c193d4a 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, $stateParams, $window, $state, $log, profileService, bitcore, bitcoreCash, txFormatService, ongoingProcess, $ionicModal, popupService, $ionicHistory, $ionicConfig, payproService, feeService, bwcError, txConfirmNotification, externalLinkService, firebaseEventsService) { +angular.module('copayApp.controllers').controller('confirmController', function($rootScope, $scope, $interval, $filter, $timeout, $ionicScrollDelegate, gettextCatalog, walletService, platformInfo, lodash, configService, $stateParams, $window, $state, $log, profileService, bitcore, bitcoreCash, txFormatService, ongoingProcess, $ionicModal, popupService, $ionicHistory, $ionicConfig, payproService, feeService, bwcError, txConfirmNotification, externalLinkService, firebaseEventsService, soundService) { var countDown = null; var FEE_TOO_HIGH_LIMIT_PER = 15; @@ -624,10 +624,7 @@ angular.module('copayApp.controllers').controller('confirmController', function( (processName == 'sendingTx' && !$scope.wallet.canSign() && !$scope.wallet.isPrivKeyExternal()) ) && !isOn) { $scope.sendStatus = 'success'; - if (config.soundsEnabled && $scope.wallet.coin == 'bch') { - var audio = new Audio('misc/bch_sent.mp3'); - audio.play(); - } + soundService.play('misc/payment_sent.mp3'); firebaseEventsService.logEvent('sent_bitcoin', { coin: $scope.wallet.coin }); $timeout(function() { $scope.$digest(); diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index 32cd5281a..44db9b0bc 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('tabReceiveController', function($rootScope, $scope, $timeout, $log, $ionicModal, $state, $ionicHistory, $ionicPopover, storageService, platformInfo, walletService, profileService, configService, lodash, gettextCatalog, popupService, bwcError, bitcoinCashJsService, $ionicNavBarDelegate, txFormatService) { +angular.module('copayApp.controllers').controller('tabReceiveController', function($rootScope, $scope, $timeout, $log, $ionicModal, $state, $ionicHistory, $ionicPopover, storageService, platformInfo, walletService, profileService, configService, lodash, gettextCatalog, popupService, bwcError, bitcoinCashJsService, $ionicNavBarDelegate, txFormatService, soundService) { var listeners = []; $scope.bchAddressType = { type: 'cashaddr' }; @@ -15,22 +15,6 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi var config; - var soundLoaded = false; - var nativeAudioAvailable = (window.plugins && window.plugins.NativeAudio); - - if (nativeAudioAvailable) { - window.plugins.NativeAudio.preloadSimple('received', 'misc/coin_received.mp3', function (msg) { - $log.debug('Receive sound loaded.'); - soundLoaded = true; - }, function (error) { - $log.debug('Error loading receive sound.'); - $log.debug(error); - }); - } else { - $log.debug('isNW: Using HTML5-Audio instead of native audio'); - soundLoaded = true; - } - $scope.displayBalanceAsFiat = true; $scope.requestSpecificAmount = function() { @@ -147,17 +131,7 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi } $scope.paymentReceivedCoin = $scope.wallet.coin; $scope.$apply(function () { - - if (config.soundsEnabled && soundLoaded) { - $log.debug('Play sound.'); - if (nativeAudioAvailable) { - window.plugins.NativeAudio.play('received'); - } else { - new Audio('misc/coin_received.ogg').play(); // NW.js has no mp3 support - } - } else { - $log.debug('Sound is disabled.'); - } + soundService.play('misc/payment_received.mp3'); $scope.showingPaymentReceived = true; }); } diff --git a/src/js/services/soundService.js b/src/js/services/soundService.js new file mode 100644 index 000000000..20318883f --- /dev/null +++ b/src/js/services/soundService.js @@ -0,0 +1,39 @@ +'use strict'; + +angular.module('copayApp.services').service('soundService', function($log, $timeout, platformInfo, configService) { + + var root = {}; + + /** + * Play a sound (when enabled in the configuration) using the Cordova Media-plugin (on Mobile) or html5-audio (on Desktop) relative to the www-root + * Make sure there is a .ogg file as well for NW.js (desktop) implementation + * @param soundFile + */ + root.play = function(soundFile) { + configService.whenAvailable(function(config) { + if (config.soundsEnabled) { + if (platformInfo.isCordova) { + var p = window.location.pathname; + var device_path = p.substring(0, p.lastIndexOf('/')); + var audio = new Media(device_path + '/' + soundFile, + function () { + $log.debug("playAudio(bch_sent):Audio Success"); + }, + function (err) { + $log.debug("playAudio():Audio Error: " + err); + } + ); + audio.play({playAudioWhenScreenIsLocked: false}); // XX SP: "Locked" is also the mute switch in iOS + } else { + if (platformInfo.isNW) { + soundFile = soundFile.substring(0, soundFile.lastIndexOf('.')) + ".ogg"; + $log.debug("Playing .ogg file ("+soundFile+"), as NW.js has no mp3 support"); + } + new Audio(soundFile).play(); + } + } + }); + }; + + return root; +}); \ No newline at end of file diff --git a/www/misc/coin_received.mp3 b/www/misc/payment_received.mp3 similarity index 100% rename from www/misc/coin_received.mp3 rename to www/misc/payment_received.mp3 diff --git a/www/misc/coin_received.ogg b/www/misc/payment_received.ogg similarity index 100% rename from www/misc/coin_received.ogg rename to www/misc/payment_received.ogg diff --git a/www/misc/bch_sent.mp3 b/www/misc/payment_sent.mp3 similarity index 100% rename from www/misc/bch_sent.mp3 rename to www/misc/payment_sent.mp3 diff --git a/www/misc/payment_sent.ogg b/www/misc/payment_sent.ogg new file mode 100644 index 0000000000000000000000000000000000000000..8527a893cca30b57276062eb9e6ca6fb25898420 GIT binary patch literal 14156 zcmaiabzD_VxA2@pm$cHMv>@Ge=m4 zU%voAiNOB8+hAJPE&ol|Ew5`jc}_5HApZQX6o&Q>83L$Q-Nw&RP~;x3&^=xro@;b^ z=;z>J=V|ZYEeTcHT~~@im3$0tF1G))gJJyhzAYWMiNoUYEy2| z$d0-0Q_89nhtu$>n+-Gjq%f8i$;O(og^i~efa?Y^G67_faWdG9k<60DsS&J_P$^av zg1KD7h-Cl!P!M&7YGtr#BR6HR6IH0EiGeWP=ZA-aVmt*Fb}Z zO<;ln=>cFvc*=35%1NJ>`o4 zGUK>1=eX_IB<#rOYB)dvfDUydAg3pxlrH~4-(a@Ieer)~vrGrdzs(^T5>2`|R$#{R zpiyG})dR!^ia3s^5A|OmqbO8wl;G5euI6nNncT=xZ4jl+Q*I7S&5dgp-OlqFd$*Ox zI|h|X@=Wk^AiV9oz9JLce@d(kf#W$G*RTg;U##s)#(<-H9FN(sVIw=8Olrs;vJA91alJj8SB|%Kv@X#xh1z zc)w?VQ53GqQBhu!z&Fg!Ij&PQ*(?Q`eei zT~+q7bY0xP@?(HxFN;ZOpQ3Y3**2E_MV>b{>%5q8%Ra`-4{p(kWv zVCZg?>2B77Tzu-VcpkF)zp@3^-yxC!AeMTEJ@qzw>V`-XlM2Flhyx%nuRStuoh@lY zB$Y`emDwfLDKN7Ff zqFGJRtMw(z`dB3`?!L0w)s{DDlF$aD-yXy`x(@+;mU-aZ=dF_m2=g)vbM+Oh#r zrHW@$I;suNO~qBqTJ&8v@}ST6Y-OfuR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_PEsUPfi0X86JVrh^3-I{A>b z1v5a&qDRYFD=t^uI~CIwmRwd6ci;l@j#Q+JF#P&zvu^^2ek;`6V|?=t9=FH_$=VA2 zj2vZ6-f{e9x3lF-9Ac|!D5!Qs11$4adTEy>4DOo2T%Yg2zqu=&>D=NP&SeU&JBu25 zH{Ba)4tInTUfa^Jk$(8)VvmPcPOJyuY(B(5ct&cFqS93u_Goy8K@kNEL&Qm0Ga(*X z^nT&t#0OuD6fZ*E-((D7q(0v_42{Z5HqIX0CDUrl*u+I^%ICNi0n-U^vNHcG)IxTFm%c3A#8^o&NOPtn_e>=W*Lt9+_WuI#TUOb6HyXV zd)6;-3V)6X$?D&1;VMfno#P4l`&Uq=;|cBu%y#LpbuKb$|qCv?MFXbcV0#D{L+k*@z|0)6k@vb=BJJh{7W(lYmBQmC3mKakG1TKx%ba8QrWNPgVlvM z&E5S+)URmyi5CD7mWgt=qVEjOnmYXUIY1!>tx>Wvo_R7ymBc8bt8a^2BgC&6p1WJT z;5e2PI=0(eC={%=S^n9ht6yYofAFi#BDKc#wIMr7(&8vD?re4zTXbV&qG#YmIU2}k zX?kIA;i*$YE}U1(zJ7}=UOuLa*^T+tSYOE3S}Af9CS&Pu<=@56ZUJwEI+9q2_MYF<&d!TZ=<4M{ma_}w;dpBKxP5oPo-&q=!JctA>JbV9*J+pF!UmWzPd6n#7Y zA}!R#aD-eG%jRG8)3(v=ScHoyW5DP#FOhxz?P$ruNL4-kR2A^;a(5b^0i=WlLNS~? z4~XR*pcoDf Date: Mon, 25 Jun 2018 17:13:56 +0200 Subject: [PATCH 014/386] Send mail instead of the Send Feedback screen. --- src/js/controllers/tab-settings.js | 12 ++++++++++++ www/views/tab-settings.html | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/tab-settings.js b/src/js/controllers/tab-settings.js index 6cfc80def..7106aa743 100644 --- a/src/js/controllers/tab-settings.js +++ b/src/js/controllers/tab-settings.js @@ -45,6 +45,18 @@ angular.module('copayApp.controllers').controller('tabSettingsController', funct }); }; + $scope.sendFeedback = function() { + var mailToLink = 'mailto:wallet@bitcoin.com?subject=Feedback%20for%20Bitcoin.com%20Wallet.com'; + if (platformInfo.isNW) { + nw.Shell.openExternal(mailToLink); + } else if (platformInfo.isCordova) { + var mailWindow = window.open(mailToLink, '_system'); + mailWindow.close(); // XX SP: bugfix for some browsers in cordova to change the view entirely + } else { + window.location.href = mailToLink; + } + }; + $scope.openExternalLink = function() { var appName = appConfigService.name; var url = appName == 'copay' ? 'https://github.com/bitcoin-com/wallet/issues' : 'https://www.bitcoin.com/wallet-support'; diff --git a/www/views/tab-settings.html b/www/views/tab-settings.html index 1105937d4..fefaf2fc2 100644 --- a/www/views/tab-settings.html +++ b/www/views/tab-settings.html @@ -22,7 +22,7 @@ - + From e8f2f2d188cc5668a648a73d31ac41e29c4aa729 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 25 Jun 2018 17:15:06 +0200 Subject: [PATCH 015/386] removed the route of the feedback form --- src/js/routes.js | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/src/js/routes.js b/src/js/routes.js index 4e72246ba..82987d1ac 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -795,22 +795,6 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr fromOnboarding: null }, }) - - /* - * - * Feedback - * - */ - - .state('tabs.feedback', { - url: '/feedback', - views: { - 'tab-settings@tabs': { - templateUrl: 'views/feedback/send.html', - controller: 'sendController' - } - } - }) .state('tabs.shareApp', { url: '/shareApp/:score/:skipped/:fromSettings', views: { From 8bc76d2e218e5f40961d584e4eb49ca1f491ddf9 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 25 Jun 2018 19:51:25 +0200 Subject: [PATCH 016/386] Fix for camera permission bug after reactivating camera permission --- src/js/controllers/tab-scan.js | 6 +++++- src/js/services/scannerService.js | 1 + www/views/tab-scan.html | 2 +- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/tab-scan.js b/src/js/controllers/tab-scan.js index a96591a25..bfb8d5bef 100644 --- a/src/js/controllers/tab-scan.js +++ b/src/js/controllers/tab-scan.js @@ -122,8 +122,12 @@ angular.module('copayApp.controllers').controller('tabScanController', function( scannerService.openSettings(); }; + $scope.reactivationCount = 0; $scope.attemptToReactivate = function(){ - scannerService.reinitialize(); + scannerService.reinitialize(function(){ + $scope.reactivationCount++; + activate(); + }); }; $scope.toggleLight = function(){ diff --git a/src/js/services/scannerService.js b/src/js/services/scannerService.js index ddf62895d..e09662396 100644 --- a/src/js/services/scannerService.js +++ b/src/js/services/scannerService.js @@ -103,6 +103,7 @@ angular.module('copayApp.services').service('scannerService', function($log, $ti _completeInitialization(status, callback); }); } else { + isAvailable = true; // XX SP: Availability can change after permissions are granted after being denied. _completeInitialization(status, callback); } }); diff --git a/www/views/tab-scan.html b/www/views/tab-scan.html index 1445adeb8..54c5efab3 100644 --- a/www/views/tab-scan.html +++ b/www/views/tab-scan.html @@ -16,7 +16,7 @@
You can scan bitcoin addresses, payment requests, paper wallets, and more.
Enable the camera to get started.
-
Enable camera access in your device settings to get started.
+
Enable camera access in your device settings to get started.
Please connect a camera to get started.
From ecbab6a5b5cfbe4b6955decde8948b066c1137c2 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 26 Jun 2018 13:01:24 +0200 Subject: [PATCH 017/386] Fix double permission screen on Android --- src/js/controllers/tab-scan.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/js/controllers/tab-scan.js b/src/js/controllers/tab-scan.js index bfb8d5bef..4a654d91d 100644 --- a/src/js/controllers/tab-scan.js +++ b/src/js/controllers/tab-scan.js @@ -126,7 +126,6 @@ angular.module('copayApp.controllers').controller('tabScanController', function( $scope.attemptToReactivate = function(){ scannerService.reinitialize(function(){ $scope.reactivationCount++; - activate(); }); }; From 9396c7c97faef4e2b64c88b4d4f19effc191f951 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 27 Jun 2018 16:43:09 +0200 Subject: [PATCH 018/386] Removed all references to the rating card & feedback --- src/js/controllers/feedback/rateApp.js | 53 --------- src/js/controllers/feedback/rateCard.js | 60 ----------- src/js/controllers/feedback/send.js | 102 ------------------ .../{feedback/complete.js => shareApp.js} | 33 +----- src/js/controllers/tab-home.js | 40 +------ src/js/routes.js | 38 +------ src/js/services/feedbackService.js | 59 ---------- src/js/services/storageService.js | 8 -- src/sass/views/feedback/rateApp.scss | 38 ------- src/sass/views/feedback/rateCard.scss | 18 ---- src/sass/views/feedback/send.scss | 54 ---------- .../{feedback/complete.scss => shareApp.scss} | 15 +-- src/sass/views/views.scss | 5 +- www/views/feedback/rateApp.html | 21 ---- www/views/feedback/rateCard.html | 43 -------- www/views/feedback/send.html | 48 --------- .../{feedback/complete.html => shareApp.html} | 30 ++---- www/views/tab-home.html | 2 - www/views/tab-settings.html | 2 +- 19 files changed, 17 insertions(+), 652 deletions(-) delete mode 100644 src/js/controllers/feedback/rateApp.js delete mode 100644 src/js/controllers/feedback/rateCard.js delete mode 100644 src/js/controllers/feedback/send.js rename src/js/controllers/{feedback/complete.js => shareApp.js} (77%) delete mode 100644 src/js/services/feedbackService.js delete mode 100644 src/sass/views/feedback/rateApp.scss delete mode 100644 src/sass/views/feedback/rateCard.scss delete mode 100644 src/sass/views/feedback/send.scss rename src/sass/views/{feedback/complete.scss => shareApp.scss} (86%) delete mode 100644 www/views/feedback/rateApp.html delete mode 100644 www/views/feedback/rateCard.html delete mode 100644 www/views/feedback/send.html rename www/views/{feedback/complete.html => shareApp.html} (55%) diff --git a/src/js/controllers/feedback/rateApp.js b/src/js/controllers/feedback/rateApp.js deleted file mode 100644 index 6ae485a3a..000000000 --- a/src/js/controllers/feedback/rateApp.js +++ /dev/null @@ -1,53 +0,0 @@ -'use strict'; - -angular.module('copayApp.controllers').controller('rateAppController', function($scope, $state, $stateParams, $window, lodash, externalLinkService, configService, platformInfo, feedbackService, ongoingProcess, popupService, appConfigService) { - $scope.score = parseInt($stateParams.score); - $scope.appName = appConfigService.nameCase; - var isAndroid = platformInfo.isAndroid; - var isIOS = platformInfo.isIOS; - - var config = configService.getSync(); - - $scope.skip = function() { - var dataSrc = { - "Email": lodash.values(config.emailFor)[0] || ' ', - "Feedback": ' ', - "Score": $stateParams.score, - "AppVersion": $window.version, - "Platform": ionic.Platform.platform(), - "DeviceVersion": ionic.Platform.version() - }; - feedbackService.send(dataSrc, function(err) { - if (err) { - // try to send, but not essential, since the user didn't add a message - $log.warn('Could not send feedback.'); - } - }); - $state.go('tabs.rate.complete', { - score: $stateParams.score, - skipped: true - }); - }; - - $scope.sendFeedback = function() { - $state.go('tabs.rate.send', { - score: $scope.score - }); - }; - - $scope.goAppStore = function() { - var defaults = configService.getDefaults(); - var url; - if (isAndroid) - url = defaults.rateApp.bitcoincom.android; - if (isIOS) - url = defaults.rateApp.bitcoincom.ios; - - externalLinkService.open(url); - $state.go('tabs.rate.complete', { - score: $stateParams.score, - skipped: true, - rated: true - }); - }; -}); diff --git a/src/js/controllers/feedback/rateCard.js b/src/js/controllers/feedback/rateCard.js deleted file mode 100644 index abc109796..000000000 --- a/src/js/controllers/feedback/rateCard.js +++ /dev/null @@ -1,60 +0,0 @@ -'use strict'; - -angular.module('copayApp.controllers').controller('rateCardController', function($scope, $state, $timeout, $log, gettextCatalog, platformInfo, storageService, appConfigService) { - - $scope.isCordova = platformInfo.isCordova; - $scope.score = 0; - $scope.appName = appConfigService.nameCase; - - $scope.goFeedbackFlow = function() { - $scope.hideCard(); - if ($scope.isCordova && $scope.score == 5) { - $state.go('tabs.rate.rateApp', { - score: $scope.score - }); - } else { - $state.go('tabs.rate.send', { - score: $scope.score - }); - } - }; - - $scope.setScore = function(score) { - $scope.score = score; - switch ($scope.score) { - case 1: - $scope.button_title = gettextCatalog.getString("I think this app is terrible."); - break; - case 2: - $scope.button_title = gettextCatalog.getString("I don't like it"); - break; - case 3: - $scope.button_title = gettextCatalog.getString("Meh - it's alright"); - break; - case 4: - $scope.button_title = gettextCatalog.getString("I like the app"); - break; - case 5: - $scope.button_title = gettextCatalog.getString("This app is fantastic!"); - break; - } - $timeout(function() { - $scope.$apply(); - }); - }; - - $scope.hideCard = function() { - $log.debug('Feedback card dismissed.') - storageService.getFeedbackInfo(function(error, info) { - var feedbackInfo = JSON.parse(info); - feedbackInfo.sent = true; - storageService.setFeedbackInfo(JSON.stringify(feedbackInfo), function() { - $scope.showRateCard.value = false; - $timeout(function() { - $scope.$apply(); - }, 100); - }); - }); - } - -}); diff --git a/src/js/controllers/feedback/send.js b/src/js/controllers/feedback/send.js deleted file mode 100644 index 23fb0ea59..000000000 --- a/src/js/controllers/feedback/send.js +++ /dev/null @@ -1,102 +0,0 @@ -'use strict'; - -angular.module('copayApp.controllers').controller('sendController', function($scope, $state, $log, $timeout, $stateParams, $ionicNavBarDelegate, $ionicHistory, $ionicConfig, $window, gettextCatalog, popupService, configService, lodash, feedbackService, ongoingProcess, platformInfo, appConfigService) { - - $scope.sendFeedback = function(feedback, goHome) { - - var config = configService.getSync(); - - var dataSrc = { - "Email": lodash.values(config.emailFor)[0] || ' ', - "Feedback": goHome ? ' ' : feedback, - "Score": $stateParams.score || ' ', - "AppVersion": $window.version, - "Platform": ionic.Platform.platform(), - "DeviceVersion": ionic.Platform.version() - }; - - if (!goHome) ongoingProcess.set('sendingFeedback', true); - feedbackService.send(dataSrc, function(err) { - if (goHome) return; - ongoingProcess.set('sendingFeedback', false); - if (err) { - popupService.showAlert(gettextCatalog.getString('Error'), gettextCatalog.getString('Feedback could not be submitted. Please try again later.')); - return; - } - if (!$stateParams.score) { - popupService.showAlert(gettextCatalog.getString('Thank you!'), gettextCatalog.getString('A member of the team will review your feedback as soon as possible.'), function() { - $scope.feedback.value = ''; - $ionicHistory.nextViewOptions({ - disableAnimate: false, - historyRoot: true - }); - $ionicHistory.goBack(); - }, gettextCatalog.getString('Finish')); - return; - } - $state.go('tabs.rate.complete', { - score: $stateParams.score - }); - }); - if (goHome) $state.go('tabs.home'); - }; - - $scope.$on("$ionicView.beforeLeave", function(event, data) { - $ionicConfig.views.swipeBackEnabled(true); - }); - - $scope.$on("$ionicView.enter", function(event, data) { - if ($scope.score) - $ionicConfig.views.swipeBackEnabled(false); - }); - - $scope.$on("$ionicView.beforeEnter", function(event, data) { - $scope.isCordova = platformInfo.isCordova; - $scope.score = (data.stateParams && data.stateParams.score) ? parseInt(data.stateParams.score) : null; - $scope.feedback = {}; - - switch ($scope.score) { - case 1: - $scope.reaction = "Ouch!"; - $scope.comment = gettextCatalog.getString("There's obviously something we're doing wrong.") + ' ' + gettextCatalog.getString("How could we improve your experience?"); - break; - case 2: - $scope.reaction = gettextCatalog.getString("Oh no!"); - $scope.comment = gettextCatalog.getString("There's obviously something we're doing wrong.") + ' ' + gettextCatalog.getString("How could we improve your experience?"); - break; - case 3: - $scope.reaction = "Hmm..."; - $scope.comment = gettextCatalog.getString("We'd love to do better.") + ' ' + gettextCatalog.getString("How could we improve your experience?"); - break; - case 4: - $scope.reaction = gettextCatalog.getString("Thanks!"); - $scope.comment = gettextCatalog.getString("That's exciting to hear. We'd love to earn that fifth star from you – how could we improve your experience?"); - break; - case 5: - $scope.reaction = gettextCatalog.getString("Thank you!"); - $scope.comment = gettextCatalog.getString("We're always looking for ways to improve {{appName}}.", { - appName: appConfigService.nameCase - }) + ' ' + gettextCatalog.getString("Is there anything we could do better?"); - break; - default: - $scope.justFeedback = true; - $scope.comment = gettextCatalog.getString("We're always looking for ways to improve {{appName}}. How could we improve your experience?", { - appName: appConfigService.nameCase - }); - break; - } - }); - - $scope.$on("$ionicView.afterEnter", function() { - $scope.showForm = true; - }); - - $scope.goBack = function() { - $ionicHistory.nextViewOptions({ - disableAnimate: false, - historyRoot: true - }); - $ionicHistory.goBack(); - }; - -}); diff --git a/src/js/controllers/feedback/complete.js b/src/js/controllers/shareApp.js similarity index 77% rename from src/js/controllers/feedback/complete.js rename to src/js/controllers/shareApp.js index 905880901..ba3fdedff 100644 --- a/src/js/controllers/feedback/complete.js +++ b/src/js/controllers/shareApp.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('completeController', function($scope, $stateParams, $timeout, $log, $ionicHistory, $state, $ionicNavBarDelegate, $ionicConfig, platformInfo, configService, storageService, lodash, appConfigService, gettextCatalog) { +angular.module('copayApp.controllers').controller('shareAppController', function($scope, $stateParams, $timeout, $log, $ionicHistory, $state, $ionicNavBarDelegate, $ionicConfig, platformInfo, configService, storageService, lodash, appConfigService, gettextCatalog) { $scope.isCordova = platformInfo.isCordova; $scope.title = gettextCatalog.getString("Share {{appName}}", { appName: appConfigService.nameCase @@ -57,28 +57,8 @@ angular.module('copayApp.controllers').controller('completeController', function $ionicConfig.views.swipeBackEnabled(true); }); - $scope.$on("$ionicView.enter", function() { - if (!$scope.fromSettings) - $ionicConfig.views.swipeBackEnabled(false); - }); - $scope.$on("$ionicView.beforeEnter", function(event, data) { - $scope.score = (data.stateParams && data.stateParams.score) ? parseInt(data.stateParams.score) : null; - $scope.skipped = (data.stateParams && data.stateParams.skipped) ? true : false; - $scope.rated = (data.stateParams && data.stateParams.rated) ? true : false; - $scope.fromSettings = (data.stateParams && data.stateParams.fromSettings) ? true : false; - - if (!$scope.fromSettings) { - $ionicNavBarDelegate.showBackButton(false); - } else { - $ionicNavBarDelegate.showBackButton(true); - } - - storageService.getFeedbackInfo(function(error, info) { - var feedbackInfo = lodash.isString(info) ? JSON.parse(info) : null; - feedbackInfo.sent = true; - storageService.setFeedbackInfo(JSON.stringify(feedbackInfo), function() {}); - }); + $ionicNavBarDelegate.showBackButton(true); if (!$scope.isCordova) return; $scope.animate = true; @@ -133,13 +113,4 @@ angular.module('copayApp.controllers').controller('completeController', function } }, 100); }); - - $scope.close = function() { - $ionicHistory.nextViewOptions({ - disableAnimate: false, - historyRoot: true - }); - if ($scope.score == 5) $ionicHistory.goBack(-3); - else $ionicHistory.goBack(-2); - }; }); diff --git a/src/js/controllers/tab-home.js b/src/js/controllers/tab-home.js index 1332287b6..56ce3279f 100644 --- a/src/js/controllers/tab-home.js +++ b/src/js/controllers/tab-home.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.controllers').controller('tabHomeController', - function($rootScope, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, storageService, txpModalService, appConfigService, startupService, addressbookService, feedbackService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { + function($rootScope, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, storageService, txpModalService, appConfigService, startupService, addressbookService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { var wallet; var listeners = []; var notifications = []; @@ -14,7 +14,6 @@ angular.module('copayApp.controllers').controller('tabHomeController', $scope.isAndroid = platformInfo.isAndroid; $scope.isWindowsPhoneApp = platformInfo.isCordova && platformInfo.isWP; $scope.isNW = platformInfo.isNW; - $scope.showRateCard = {}; $scope.showServices = false; $scope.$on("$ionicView.afterEnter", function() { @@ -42,43 +41,6 @@ angular.module('copayApp.controllers').controller('tabHomeController', } }); } - - storageService.getFeedbackInfo(function(error, info) { - - if ($scope.isWindowsPhoneApp) { - $scope.showRateCard.value = false; - return; - } - if (!info) { - initFeedBackInfo(); - } else { - var feedbackInfo = JSON.parse(info); - //Check if current version is greater than saved version - var currentVersion = $scope.version; - var savedVersion = feedbackInfo.version; - var isVersionUpdated = feedbackService.isVersionUpdated(currentVersion, savedVersion); - if (!isVersionUpdated) { - initFeedBackInfo(); - return; - } - var now = moment().unix(); - var timeExceeded = (now - feedbackInfo.time) >= 24 * 7 * 60 * 60; - $scope.showRateCard.value = timeExceeded && !feedbackInfo.sent; - $timeout(function() { - $scope.$apply(); - }); - } - }); - - function initFeedBackInfo() { - var feedbackInfo = {}; - feedbackInfo.time = moment().unix(); - feedbackInfo.version = $scope.version; - feedbackInfo.sent = false; - storageService.setFeedbackInfo(JSON.stringify(feedbackInfo), function() { - $scope.showRateCard.value = false; - }); - }; }); $scope.$on("$ionicView.enter", function(event, data) { diff --git a/src/js/routes.js b/src/js/routes.js index 82987d1ac..63f92ef8f 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -796,46 +796,14 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr }, }) .state('tabs.shareApp', { - url: '/shareApp/:score/:skipped/:fromSettings', + url: '/shareApp', views: { 'tab-settings@tabs': { - controller: 'completeController', - templateUrl: 'views/feedback/complete.html' + controller: 'shareAppController', + templateUrl: 'views/shareApp.html' } } }) - .state('tabs.rate', { - url: '/rate', - abstract: true - }) - .state('tabs.rate.send', { - url: '/send/:score', - views: { - 'tab-home@tabs': { - templateUrl: 'views/feedback/send.html', - controller: 'sendController' - } - } - }) - .state('tabs.rate.complete', { - url: '/complete/:score/:skipped', - views: { - 'tab-home@tabs': { - controller: 'completeController', - templateUrl: 'views/feedback/complete.html' - } - } - }) - .state('tabs.rate.rateApp', { - url: '/rateApp/:score', - views: { - 'tab-home@tabs': { - controller: 'rateAppController', - templateUrl: 'views/feedback/rateApp.html' - } - } - }) - /* * * Buy or Sell Bitcoin diff --git a/src/js/services/feedbackService.js b/src/js/services/feedbackService.js deleted file mode 100644 index ae4711d27..000000000 --- a/src/js/services/feedbackService.js +++ /dev/null @@ -1,59 +0,0 @@ -'use strict'; -angular.module('copayApp.services').factory('feedbackService', function($http, $log, $httpParamSerializer, configService) { - var root = {}; -// var URL = "https://script.google.com/macros/s/1pWGRxVSUX9CxPqNAKZTppWHtDvyVtZv9HteY_TRQbWc/exec"; - var URL = "https://wallet-data.bitcoin.com/feedback.php"; - - root.send = function(dataSrc, cb) { - $http(_post(dataSrc)).then(function() { - $log.info("SUCCESS: Feedback sent"); - return cb(); - }, function(err) { - $log.info("ERROR: Feedback sent anyway."); - return cb(err); - }); - }; - - var _post = function(dataSrc) { - return { - method: 'POST', - url: URL, - headers: { - 'content-type': 'application/x-www-form-urlencoded; charset=UTF-8' - }, - data: $httpParamSerializer(dataSrc) - }; - }; - - root.isVersionUpdated = function(currentVersion, savedVersion) { - - if (!verifyTagFormat(currentVersion)) - return 'Cannot verify the format of version tag: ' + currentVersion; - if (!verifyTagFormat(savedVersion)) - return 'Cannot verify the format of the saved version tag: ' + savedVersion; - - var current = formatTagNumber(currentVersion); - var saved = formatTagNumber(savedVersion); - if (saved.major > current.major || (saved.major == current.major && saved.minor > current.minor)) - return false; - - return true; - - function verifyTagFormat(tag) { - var regex = /^v?\d+\.\d+\.\d+$/i; - return regex.exec(tag); - }; - - function formatTagNumber(tag) { - var formattedNumber = tag.replace(/^v/i, '').split('.'); - return { - major: +formattedNumber[0], - minor: +formattedNumber[1], - patch: +formattedNumber[2] - }; - }; - - }; - - return root; -}); diff --git a/src/js/services/storageService.js b/src/js/services/storageService.js index a2d85950b..154391e55 100644 --- a/src/js/services/storageService.js +++ b/src/js/services/storageService.js @@ -250,14 +250,6 @@ angular.module('copayApp.services') }); }; - root.setFeedbackInfo = function(feedbackValues, cb) { - storage.set('feedback', feedbackValues, cb); - }; - - root.getFeedbackInfo = function(cb) { - storage.get('feedback', cb); - }; - root.storeFocusedWalletId = function(id, cb) { storage.set('focusedWalletId', id || '', cb); }; diff --git a/src/sass/views/feedback/rateApp.scss b/src/sass/views/feedback/rateApp.scss deleted file mode 100644 index 8a4cd2b8e..000000000 --- a/src/sass/views/feedback/rateApp.scss +++ /dev/null @@ -1,38 +0,0 @@ -#rate-app { - background-color: #ffffff; - text-align: center; - .skip-rating { - color: $v-dark-gray; - position: absolute; - top: 5px; - right: 10px; - padding: 15px; - } - .icon-svg > img { - width: 80px; - height: 80px; - margin-top: 15px; - } - .feedback-title { - font-size: 20px; - font-weight: bold; - color: $v-dark-gray; - margin: 80px 50px 10px; - text-align: center; - } - .share-the-love-illustration { - width: 5rem; - margin: 1rem; - } - .subtitle { - padding: 10px 30px 20px 40px; - color: $v-mid-gray; - } - .rate-buttons { - bottom: 0; - width: 100%; - position: absolute; - background-color: $v-subtle-gray; - padding: 30px 0 15px; - } -} diff --git a/src/sass/views/feedback/rateCard.scss b/src/sass/views/feedback/rateCard.scss deleted file mode 100644 index 9d57643d6..000000000 --- a/src/sass/views/feedback/rateCard.scss +++ /dev/null @@ -1,18 +0,0 @@ -#rate-card { - .item-heading { - font-weight: 700; - } - .row { - border: none; - } - .item-icon-right { - margin: 0; - } - .feedback-flow-button { - margin-bottom: 20px; - } - .icon-svg > img { - height: 1.8rem; - margin-bottom: 5px; - } -} diff --git a/src/sass/views/feedback/send.scss b/src/sass/views/feedback/send.scss deleted file mode 100644 index 807c4f8c5..000000000 --- a/src/sass/views/feedback/send.scss +++ /dev/null @@ -1,54 +0,0 @@ -#send-feedback { - @extend .deflash-blue; - background-color: #ffffff; - .row { - border: none; - } - .skip { - color: rgba(255, 255, 255, 0.3); - } - .feedback-heading { - padding-top: 20px - } - .feedback-title { - padding-left: 10px; - font-size: 20px; - font-weight: bold; - color: $v-dark-gray; - } - .rating { - text-align: right; - padding-right: 15px; - } - .comment { - padding: 0 20px 20px; - font-size: 1rem; - line-height: 1.5em; - font-weight: 300; - color: $v-dark-gray; - } - .user-feedback { - border-top: 1px solid $v-subtle-gray; - border-bottom: 1px solid $v-subtle-gray; - padding: 20px; - width: 100%; - margin-bottom: 20px; - -webkit-appearance: none; - } - .send-feedback-star { - height: 1rem; - margin-left: 5px; - } - .form-fade-in { - opacity: 0; - animation-name: fadeIn; - animation-duration: .5s; - animation-fill-mode: forwards; - animation-timing-function: ease-in; - } -} - -@keyframes fadeIn { - from { opacity: 0; } - to { opacity: 1; } -} diff --git a/src/sass/views/feedback/complete.scss b/src/sass/views/shareApp.scss similarity index 86% rename from src/sass/views/feedback/complete.scss rename to src/sass/views/shareApp.scss index bb2e75ea6..9a0ed0698 100644 --- a/src/sass/views/feedback/complete.scss +++ b/src/sass/views/shareApp.scss @@ -1,6 +1,6 @@ -#complete { +#share-app { background-color: #fff; - .complete-layout { + .share-app-layout { display: flex; flex-direction: column; height: 100%; @@ -22,17 +22,6 @@ width: 5rem; margin: 1rem; } - .send-feedback-illustration { - height: 16rem; - margin: 1rem; - } - .feedback-title { - font-size: 20px; - font-weight: bold; - color: $v-dark-gray; - margin: 20px 10px; - text-align: center; - } .subtitle { padding: 10px 30px 20px; text-align: center; diff --git a/src/sass/views/views.scss b/src/sass/views/views.scss index 37754970f..d4ed735ed 100644 --- a/src/sass/views/views.scss +++ b/src/sass/views/views.scss @@ -22,10 +22,7 @@ @import "wallet-backup-phrase"; @import "zero-state"; @import "onboarding/onboarding"; -@import "feedback/rateCard"; -@import "feedback/send"; -@import "feedback/complete"; -@import "feedback/rateApp"; +@import "shareApp"; @import "includes/actionSheet"; @import "export"; @import "import"; diff --git a/www/views/feedback/rateApp.html b/www/views/feedback/rateApp.html deleted file mode 100644 index 9913b9d4e..000000000 --- a/www/views/feedback/rateApp.html +++ /dev/null @@ -1,21 +0,0 @@ - - -
Not now - - -
- 5-star ratings help us get {{appName}} into more hands, and more users means more resources can be committed to the app! -
-
- Would you be willing to rate {{appName}} in the app store? -
-
- - -
- - diff --git a/www/views/feedback/rateCard.html b/www/views/feedback/rateCard.html deleted file mode 100644 index d31199466..000000000 --- a/www/views/feedback/rateCard.html +++ /dev/null @@ -1,43 +0,0 @@ -
-
- How do you like {{appName}}? - -
-
-
- - - - -
-
- - - - -
-
- - - - -
-
- - - - -
-
- - - - -
-
- -
diff --git a/www/views/feedback/send.html b/www/views/feedback/send.html deleted file mode 100644 index bb979bdee..000000000 --- a/www/views/feedback/send.html +++ /dev/null @@ -1,48 +0,0 @@ - - - {{'Send Feedback' | translate}} - - - - - - - - - - -
- {{comment}} -
-
- - -
-
-
diff --git a/www/views/feedback/complete.html b/www/views/shareApp.html similarity index 55% rename from www/views/feedback/complete.html rename to www/views/shareApp.html index 03a98a476..f148e81a0 100644 --- a/www/views/feedback/complete.html +++ b/www/views/shareApp.html @@ -1,32 +1,16 @@ - + {{title}} - - - -
-
-
- -
Share the love by inviting your friends.
-
-
- -
A member of the team will review your feedback as soon as possible.
-
-
If you have additional feedback, please let us know by tapping the "Send feedback" option in the Settings tab.
- -
-
Share the love by inviting your friends.
-
+ -
- From 8006af279b8ba65aee9908ec567c43c298c0955c Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 28 Jun 2018 10:52:06 +0200 Subject: [PATCH 020/386] clipboard service --- src/js/directives/copyToClipboard.js | 21 ++------------------- src/js/services/clipboardService.js | 28 ++++++++++++++++++++++++++++ 2 files changed, 30 insertions(+), 19 deletions(-) create mode 100644 src/js/services/clipboardService.js diff --git a/src/js/directives/copyToClipboard.js b/src/js/directives/copyToClipboard.js index 5de40f23e..35802b598 100644 --- a/src/js/directives/copyToClipboard.js +++ b/src/js/directives/copyToClipboard.js @@ -1,38 +1,21 @@ 'use strict'; angular.module('copayApp.directives') - .directive('copyToClipboard', function(platformInfo, nodeWebkitService, gettextCatalog, ionicToast, clipboard) { + .directive('copyToClipboard', function(clipboardService) { return { restrict: 'A', scope: { copyToClipboard: '=copyToClipboard' }, link: function(scope, elem, attrs, ctrl) { - var isCordova = platformInfo.isCordova; - var isChromeApp = platformInfo.isChromeApp; - var isNW = platformInfo.isNW; elem.bind('mouseover', function() { elem.css('cursor', 'pointer'); }); - var msg = gettextCatalog.getString('Copied to clipboard'); elem.bind('click', function() { var data = scope.copyToClipboard; - if (!data) return; - if (isCordova) { - cordova.plugins.clipboard.copy(data); - } else if (isNW) { - nodeWebkitService.writeToClipboard(data); - } else if (clipboard.supported) { - clipboard.copyText(data); - } else { - // No supported - return; - } - scope.$apply(function() { - ionicToast.show(msg, 'bottom', false, 1000); - }); + clipboardService.copyToClipboard(data, scope); }); } } diff --git a/src/js/services/clipboardService.js b/src/js/services/clipboardService.js new file mode 100644 index 000000000..ab8110b0a --- /dev/null +++ b/src/js/services/clipboardService.js @@ -0,0 +1,28 @@ +'use strict'; + +angular.module('copayApp.services').factory('clipboardService', function ($http, $log, platformInfo, nodeWebkitService, gettextCatalog, ionicToast, clipboard) { + var root = {}; + + root.copyToClipboard = function (data, scope) { + var msg = gettextCatalog.getString('Copied to clipboard'); + + if (!data) return; + + if (platformInfo.isCordova) { + cordova.plugins.clipboard.copy(data); + } else if (platformInfo.isNW) { + nodeWebkitService.writeToClipboard(data); + } else if (clipboard.supported) { + clipboard.copyText(data); + } else { + // No supported + return; + } + + scope.$apply(function () { + ionicToast.show(msg, 'bottom', false, 1000); + }); + }; + + return root; +}); \ No newline at end of file From 243f35c25d1699554e209ca1db9f34003b662c25 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 28 Jun 2018 14:16:33 +0200 Subject: [PATCH 021/386] copy to clipboard --- src/js/controllers/tab-receive.js | 3 ++- src/js/directives/copyToClipboard.js | 9 +++++++-- src/js/services/clipboardService.js | 5 ----- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index e4f7388d6..a77870cb4 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('tabReceiveController', function($rootScope, $scope, $timeout, $log, $ionicModal, $state, $ionicHistory, $ionicPopover, storageService, platformInfo, walletService, profileService, configService, lodash, gettextCatalog, popupService, bwcError, bitcoinCashJsService, $ionicNavBarDelegate, txFormatService) { +angular.module('copayApp.controllers').controller('tabReceiveController', function($rootScope, $scope, $timeout, $log, $ionicModal, $state, $ionicHistory, $ionicPopover, storageService, platformInfo, walletService, profileService, configService, lodash, gettextCatalog, popupService, bwcError, bitcoinCashJsService, $ionicNavBarDelegate, txFormatService, clipboardService) { var listeners = []; $scope.bchAddressType = { type: 'cashaddr' }; @@ -73,6 +73,7 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi currentAddressSocket = new WebSocket("wss://ws.blockchain.info/inv"); paymentSubscriptionObj.addr = $scope.addr } + clipboardService.copyToClipboard(paymentSubscriptionObj.addr); // create subscription var msg = JSON.stringify(paymentSubscriptionObj); diff --git a/src/js/directives/copyToClipboard.js b/src/js/directives/copyToClipboard.js index 35802b598..c81e0bd60 100644 --- a/src/js/directives/copyToClipboard.js +++ b/src/js/directives/copyToClipboard.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.directives') - .directive('copyToClipboard', function(clipboardService) { + .directive('copyToClipboard', function(clipboardService, ionicToast, gettextCatalog) { return { restrict: 'A', scope: { @@ -14,8 +14,13 @@ angular.module('copayApp.directives') elem.bind('click', function() { var data = scope.copyToClipboard; + clipboardService.copyToClipboard(data); + + var msg = gettextCatalog.getString('Copied to clipboard'); + scope.$apply(function () { + ionicToast.show(msg, 'bottom', false, 1000); + }); - clipboardService.copyToClipboard(data, scope); }); } } diff --git a/src/js/services/clipboardService.js b/src/js/services/clipboardService.js index ab8110b0a..67de530af 100644 --- a/src/js/services/clipboardService.js +++ b/src/js/services/clipboardService.js @@ -4,8 +4,6 @@ angular.module('copayApp.services').factory('clipboardService', function ($http, var root = {}; root.copyToClipboard = function (data, scope) { - var msg = gettextCatalog.getString('Copied to clipboard'); - if (!data) return; if (platformInfo.isCordova) { @@ -19,9 +17,6 @@ angular.module('copayApp.services').factory('clipboardService', function ($http, return; } - scope.$apply(function () { - ionicToast.show(msg, 'bottom', false, 1000); - }); }; return root; From f89499047a564c9f3d55cb8fb6a2e20a91089749 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 29 Jun 2018 15:11:34 +0200 Subject: [PATCH 022/386] Update sound to play on the screens they suppose to play only --- src/js/controllers/confirm.js | 4 +++- src/js/controllers/tab-receive.js | 5 ++++- src/js/services/soundService.js | 11 ++++++++--- 3 files changed, 15 insertions(+), 5 deletions(-) diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index 51c193d4a..f77e6db75 100644 --- a/src/js/controllers/confirm.js +++ b/src/js/controllers/confirm.js @@ -624,7 +624,9 @@ angular.module('copayApp.controllers').controller('confirmController', function( (processName == 'sendingTx' && !$scope.wallet.canSign() && !$scope.wallet.isPrivKeyExternal()) ) && !isOn) { $scope.sendStatus = 'success'; - soundService.play('misc/payment_sent.mp3'); + + if ($state.current.name === "tabs.send.confirm") // XX SP: Otherwise all open wallets on other devices play this sound if you have been in a send flow before on that device. + soundService.play('misc/payment_sent.mp3'); firebaseEventsService.logEvent('sent_bitcoin', { coin: $scope.wallet.coin }); $timeout(function() { $scope.$digest(); diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index 44db9b0bc..dcae37131 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -130,8 +130,11 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi } } $scope.paymentReceivedCoin = $scope.wallet.coin; - $scope.$apply(function () { + + if ($state.current.name === "tabs.receive") soundService.play('misc/payment_received.mp3'); + + $scope.$apply(function () { $scope.showingPaymentReceived = true; }); } diff --git a/src/js/services/soundService.js b/src/js/services/soundService.js index 20318883f..759789e21 100644 --- a/src/js/services/soundService.js +++ b/src/js/services/soundService.js @@ -13,9 +13,14 @@ angular.module('copayApp.services').service('soundService', function($log, $time configService.whenAvailable(function(config) { if (config.soundsEnabled) { if (platformInfo.isCordova) { - var p = window.location.pathname; - var device_path = p.substring(0, p.lastIndexOf('/')); - var audio = new Media(device_path + '/' + soundFile, + + if (platformInfo.isAndroid) { + var p = window.location.pathname; + var device_path = p.substring(0, p.lastIndexOf('/')); + soundFile = device_path + '/' + soundFile; + } + + var audio = new Media(soundFile, function () { $log.debug("playAudio(bch_sent):Audio Success"); }, From 40d0e5b896968b25eb471c2af1b9bf307f2b382c Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 29 Jun 2018 15:24:11 +0200 Subject: [PATCH 023/386] added protocol and use the new cashaddr instead of legacy --- src/js/controllers/tab-receive.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index a77870cb4..143fa9207 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -73,7 +73,8 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi currentAddressSocket = new WebSocket("wss://ws.blockchain.info/inv"); paymentSubscriptionObj.addr = $scope.addr } - clipboardService.copyToClipboard(paymentSubscriptionObj.addr); + + clipboardService.copyToClipboard($scope.protocolHandler + ":" + $scope.addr); // create subscription var msg = JSON.stringify(paymentSubscriptionObj); From c63bc06c76d67f1a7511a6476ee1a209e8dee26c Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Sun, 1 Jul 2018 23:35:06 +0200 Subject: [PATCH 024/386] try catch on copy-to-clipboard --- src/js/controllers/tab-receive.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index 143fa9207..7236b80c5 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -74,8 +74,12 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi paymentSubscriptionObj.addr = $scope.addr } - clipboardService.copyToClipboard($scope.protocolHandler + ":" + $scope.addr); - + try { + clipboardService.copyToClipboard($scope.protocolHandler + ":" + $scope.addr); + } catch (error) { + $log.debug("Error copying to clipboard:"); + $log.debug(error); + } // create subscription var msg = JSON.stringify(paymentSubscriptionObj); currentAddressSocket.onopen = function (event) { From ccf2dd45868ce2ee2c5df6b8487c80c96c68c0ba Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 2 Jul 2018 11:20:34 +1200 Subject: [PATCH 025/386] Changes as requested by PR. --- src/js/controllers/confirm.js | 9 +++++---- src/js/controllers/tab-receive.js | 2 +- src/js/services/txFormatService.js | 2 +- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index cc48bf6b9..55b94446c 100644 --- a/src/js/controllers/confirm.js +++ b/src/js/controllers/confirm.js @@ -287,9 +287,10 @@ angular.module('copayApp.controllers').controller('confirmController', function( tx.amountValueStr = tx.amountStr.split(' ')[0]; tx.amountUnitStr = tx.amountStr.split(' ')[1]; txFormatService.formatAlternativeStr(wallet.coin, tx.toAmount, function(v) { + var parts = v.split(' '); tx.alternativeAmountStr = v; - tx.alternativeAmountValueStr = tx.alternativeAmountStr.split(' ')[0]; - tx.alternativeAmountUnitStr = tx.alternativeAmountStr.split(' ')[1]; + tx.alternativeAmountValueStr = parts[0]; + tx.alternativeAmountUnitStr = (parts.length > 0) ? parts[1] : ''; }); } @@ -428,8 +429,8 @@ angular.module('copayApp.controllers').controller('confirmController', function( function showSendMaxWarning(wallet, sendMaxInfo) { - var feeAlternative, - msg; + var feeAlternative = '', + msg = ''; function verifyExcludedUtxos() { var warningMsg = []; diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index 4d048e22e..d5b7f1cd1 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -125,7 +125,7 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi for (var i = 0; i < data.x.out.length; i++) { if (data.x.out[i].addr == watchAddress) { $scope.paymentReceivedAmount = txFormatService.formatAmount(data.x.out[i].value, 'full'); - $scope.paymentReceivedAlternativeAmount = null; // For when a subsequent payment is received. + $scope.paymentReceivedAlternativeAmount = ''; // For when a subsequent payment is received. txFormatService.formatAlternativeStr($scope.wallet.coin, data.x.out[i].value, function(alternativeStr){ if (alternativeStr) { $scope.paymentReceivedAlternativeAmount = alternativeStr; diff --git a/src/js/services/txFormatService.js b/src/js/services/txFormatService.js index c208857a8..ebcb3886a 100644 --- a/src/js/services/txFormatService.js +++ b/src/js/services/txFormatService.js @@ -79,7 +79,7 @@ angular.module('copayApp.services').factory('txFormatService', function($filter, var lessThanPrefix = ''; if (subcent) { roundedNum = 0.01; - lessThanPrefix = '< ' + lessThanPrefix = '< '; } var v1 = $filter('formatFiatAmount')(roundedNum); if (!v1) return null; From 9224d40a6554c70b0c500ca4e80031fb89e867e6 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 2 Jul 2018 14:06:36 +0900 Subject: [PATCH 026/386] Remove secure storage feature, postpone --- app-template/config-template.xml | 2 -- src/js/services/storageService.js | 55 +++++-------------------------- 2 files changed, 8 insertions(+), 49 deletions(-) diff --git a/app-template/config-template.xml b/app-template/config-template.xml index ed4b192ba..52a3f8860 100644 --- a/app-template/config-template.xml +++ b/app-template/config-template.xml @@ -73,8 +73,6 @@ - - diff --git a/src/js/services/storageService.js b/src/js/services/storageService.js index a2d85950b..bde3215a2 100644 --- a/src/js/services/storageService.js +++ b/src/js/services/storageService.js @@ -1,6 +1,6 @@ 'use strict'; angular.module('copayApp.services') - .factory('storageService', function(appConfigService, logHeader, fileStorageService, localStorageService, sjcl, $log, lodash, platformInfo, secureStorageService, $timeout) { + .factory('storageService', function(appConfigService, logHeader, fileStorageService, localStorageService, sjcl, $log, lodash, platformInfo, $timeout) { var root = {}; var storage; @@ -121,11 +121,7 @@ angular.module('copayApp.services') root.storeProfile = function(profile, cb) { var profileString = profile.toObj(); - if (platformInfo.isNW) { - storage.set('profile', profileString, cb); - } else { - secureStorageService.set('profile', profileString, cb); - } + storage.set('profile', profileString, cb); }; /** @@ -205,48 +201,13 @@ angular.module('copayApp.services') * @param {getProfileCallback} cb */ root.getProfile = function(cb) { - if (platformInfo.isNW) { - storage.get('profile', function(getErr, getStr) { - _onOldProfileRetrieved(getErr, getStr, cb); - }); - return - } - - secureStorageService.get('profile', function(secureErr, secureStr) { - var secureProfile; - var oldProfile; - - if (secureErr) { - return cb(secureErr, null); + storage.get('profile', function(getErr, getStr) { + if (getErr) { + cb(getErr, null); + } else { + profile = Profile.fromString(getStr); + cb(null, profile); } - - if (secureStr) { - try { - secureProfile = Profile.fromString(secureStr); - $log.debug('profile: ' + JSON.stringify(secureProfile)); - } catch (e) { - $log.error(e); - return cb(e, null); - } - } - - storage.get('profile', function(getErr, getStr) { - _onOldProfileRetrieved(getErr, getStr, function(oldErr, oldProfile){ - if (oldErr) { - return cb(oldErr, null); - } - - if (!oldProfile) { - if (secureProfile) { - return cb(null, secureProfile); - } else { - // No profiles found. No errors either. - return cb(null, null); - } - } - _migrateProfiles(oldProfile, secureProfile, cb); - }); - }); }); }; From eaaafbba6fb8cb6c441ad94c2a9fd60e5ed813e2 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 2 Jul 2018 14:34:33 +0900 Subject: [PATCH 027/386] Mistake case where there is not profile --- src/js/services/storageService.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/js/services/storageService.js b/src/js/services/storageService.js index bde3215a2..85d2e58cf 100644 --- a/src/js/services/storageService.js +++ b/src/js/services/storageService.js @@ -203,10 +203,14 @@ angular.module('copayApp.services') root.getProfile = function(cb) { storage.get('profile', function(getErr, getStr) { if (getErr) { - cb(getErr, null); + return cb(getErr, null); } else { - profile = Profile.fromString(getStr); - cb(null, profile); + if (!getStr) { + return cb(null, null); + } else { + profile = Profile.fromString(getStr); + return cb(null, profile); + } } }); }; From 867063fc8f77e7669c837fdebab818c1e8ce2f15 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 2 Jul 2018 17:57:51 +1200 Subject: [PATCH 028/386] Handle first launch. --- src/js/services/storageService.js | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/src/js/services/storageService.js b/src/js/services/storageService.js index bde3215a2..44081a81f 100644 --- a/src/js/services/storageService.js +++ b/src/js/services/storageService.js @@ -204,10 +204,16 @@ angular.module('copayApp.services') storage.get('profile', function(getErr, getStr) { if (getErr) { cb(getErr, null); - } else { - profile = Profile.fromString(getStr); - cb(null, profile); + return; } + + if (!getStr) { + cb(null, null); + return; + } + + profile = Profile.fromString(getStr); + cb(null, profile); }); }; From 2422efdb462e1c9b252e2c9e3076810f16751539 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 2 Jul 2018 18:02:32 +1200 Subject: [PATCH 029/386] Bugfix for last commit. --- src/js/services/storageService.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/services/storageService.js b/src/js/services/storageService.js index 44081a81f..10f0cdd76 100644 --- a/src/js/services/storageService.js +++ b/src/js/services/storageService.js @@ -212,7 +212,7 @@ angular.module('copayApp.services') return; } - profile = Profile.fromString(getStr); + var profile = Profile.fromString(getStr); cb(null, profile); }); }; From 6b20a01e2565ed593f6c73b8ee92db94157e16ba Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 2 Jul 2018 10:34:32 +0200 Subject: [PATCH 030/386] remove protocolHandler, only apply on bitcoincash: + support legacy&bitpay address types --- src/js/controllers/tab-receive.js | 2 +- src/js/services/clipboardService.js | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index 7236b80c5..dedc00494 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -75,7 +75,7 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi } try { - clipboardService.copyToClipboard($scope.protocolHandler + ":" + $scope.addr); + clipboardService.copyToClipboard($scope.wallet.coin == 'bch' && $scope.bchAddressType.type == 'cashaddr' ? 'bitcoincash:' + $scope.addr : $scope.addr); } catch (error) { $log.debug("Error copying to clipboard:"); $log.debug(error); diff --git a/src/js/services/clipboardService.js b/src/js/services/clipboardService.js index 67de530af..e2e0e5fb3 100644 --- a/src/js/services/clipboardService.js +++ b/src/js/services/clipboardService.js @@ -3,9 +3,10 @@ angular.module('copayApp.services').factory('clipboardService', function ($http, $log, platformInfo, nodeWebkitService, gettextCatalog, ionicToast, clipboard) { var root = {}; - root.copyToClipboard = function (data, scope) { + root.copyToClipboard = function (data) { if (!data) return; + $log.debug("Copy '"+data+"' to clipboard"); if (platformInfo.isCordova) { cordova.plugins.clipboard.copy(data); } else if (platformInfo.isNW) { From c5cabcd5bbea2ecb42f41b1b8dc46d541fd70369 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 3 Jul 2018 11:23:43 +0900 Subject: [PATCH 031/386] Fix Android 4.4 (ArrayBuffer) by a shim --- Gruntfile.js | 1 + src/shim/shim.js | 11 +++++++++++ 2 files changed, 12 insertions(+) create mode 100644 src/shim/shim.js diff --git a/Gruntfile.js b/Gruntfile.js index 282c8e0fb..56852417e 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -136,6 +136,7 @@ module.exports = function(grunt) { }, angular: { src: [ + 'src/shim/shim.js', 'bower_components/qrcode-generator/js/qrcode.js', 'bower_components/qrcode-generator/js/qrcode_UTF8.js', 'bower_components/moment/min/moment-with-locales.js', diff --git a/src/shim/shim.js b/src/shim/shim.js new file mode 100644 index 000000000..495848f05 --- /dev/null +++ b/src/shim/shim.js @@ -0,0 +1,11 @@ +//--------------------------------------------------------------------- +// +// Add components what are missing in old JavaScript Engine +// +//--------------------------------------------------------------------- + +if (!ArrayBuffer['isView']) { + ArrayBuffer.isView = function(a) { + return a !== null && typeof(a) === "object" && a['buffer'] instanceof ArrayBuffer; + }; +} \ No newline at end of file From da0ffde1790738ef25369601a408c990fe8c0f0d Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 3 Jul 2018 12:15:42 +0900 Subject: [PATCH 032/386] Brackets missing --- src/js/controllers/confirm.js | 4 +++- src/js/controllers/tab-receive.js | 3 ++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index f77e6db75..c8dea6047 100644 --- a/src/js/controllers/confirm.js +++ b/src/js/controllers/confirm.js @@ -625,8 +625,10 @@ angular.module('copayApp.controllers').controller('confirmController', function( ) && !isOn) { $scope.sendStatus = 'success'; - if ($state.current.name === "tabs.send.confirm") // XX SP: Otherwise all open wallets on other devices play this sound if you have been in a send flow before on that device. + if ($state.current.name === "tabs.send.confirm") { // XX SP: Otherwise all open wallets on other devices play this sound if you have been in a send flow before on that device. soundService.play('misc/payment_sent.mp3'); + } + firebaseEventsService.logEvent('sent_bitcoin', { coin: $scope.wallet.coin }); $timeout(function() { $scope.$digest(); diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index dcae37131..5c9cef70f 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -131,8 +131,9 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi } $scope.paymentReceivedCoin = $scope.wallet.coin; - if ($state.current.name === "tabs.receive") + if ($state.current.name === "tabs.receive") { soundService.play('misc/payment_received.mp3'); + } $scope.$apply(function () { $scope.showingPaymentReceived = true; From 7c7ad63f7eaccf451969fd77a5f863940f8077c6 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 3 Jul 2018 12:34:57 +0900 Subject: [PATCH 033/386] Update the release version : 4.12-rc2 --- app-template/bitcoincom/appConfig.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app-template/bitcoincom/appConfig.json b/app-template/bitcoincom/appConfig.json index 2e9f82d29..9dc184e7c 100644 --- a/app-template/bitcoincom/appConfig.json +++ b/app-template/bitcoincom/appConfig.json @@ -24,9 +24,9 @@ "windowsAppId": "804636ee-b017-4cad-8719-e58ac97ffa5c", "pushSenderId": "1036948132229", "description": "A Secure Bitcoin Wallet", - "version": "4.12.0", - "fullVersion": "4.12-rc1", - "androidVersion": "412000", + "version": "4.12.1", + "fullVersion": "4.12-rc2", + "androidVersion": "412100", "_extraCSS": "", "_enabledExtensions": { "coinbase": false, From b10b6c54e926c9a29ccfe0e6c0556a9f41dd0167 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 3 Jul 2018 11:37:20 +0200 Subject: [PATCH 034/386] bannerService --- src/js/services/bannerService.js | 48 ++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 src/js/services/bannerService.js diff --git a/src/js/services/bannerService.js b/src/js/services/bannerService.js new file mode 100644 index 000000000..5c03ec484 --- /dev/null +++ b/src/js/services/bannerService.js @@ -0,0 +1,48 @@ +'use strict'; +angular.module('copayApp.services').factory('bannerService', function ($http, $log) { + var root = {}; + + var marketingApiService = 'http://127.0.0.1:3232/bws/api/v1/marketing'; + var bannersFetched = false; + var banners = [{ + id: 'default-banner', + image: 'img/banner-store.png', + url: 'https://store.bitcoin.com/', + local: true + }]; + + root.fetchBannerSettings = function (cb) { + if (bannersFetched) + return cb(banners); + + var req = { + method: 'GET', + url: marketingApiService+'/settings', + headers: { + 'Content-Type': 'application/json', + 'Accept': 'application/json' + } + }; + $http(req).then(function (data) { + $log.info('Get banner settings: SUCCESS'); + banners = banners.concat(data.data); + bannersFetched = true; + return cb(banners); + }, function (data) { + $log.error('Get banner settings: ERROR ' + data.statusText); + return cb(banners); + }); + }; + + root.getBannerImage = function (banner) { + if (banner.local) { + return banner.image; + } + + var fileName = banner.image.substring(0, banner.image.lastIndexOf('.')); + var extension = banner.image.substring(banner.image.lastIndexOf('.')); + return marketingApiService+'/banners/'+fileName+"/"+extension; + }; + + return root; +}); \ No newline at end of file From 1d5010de41b7150c2b570be0b7bcbfc12e4a3995 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 3 Jul 2018 11:38:22 +0200 Subject: [PATCH 035/386] home view changes for bannerService --- src/js/controllers/tab-home.js | 16 +++++++++++++--- www/views/tab-home.html | 6 ++++-- 2 files changed, 17 insertions(+), 5 deletions(-) diff --git a/src/js/controllers/tab-home.js b/src/js/controllers/tab-home.js index 1332287b6..28375be5f 100644 --- a/src/js/controllers/tab-home.js +++ b/src/js/controllers/tab-home.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.controllers').controller('tabHomeController', - function($rootScope, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, storageService, txpModalService, appConfigService, startupService, addressbookService, feedbackService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { + function($rootScope, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, bannerService, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, storageService, txpModalService, appConfigService, startupService, addressbookService, feedbackService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { var wallet; var listeners = []; var notifications = []; @@ -16,9 +16,19 @@ angular.module('copayApp.controllers').controller('tabHomeController', $scope.isNW = platformInfo.isNW; $scope.showRateCard = {}; $scope.showServices = false; + $scope.bannerIsLoading = true; + $scope.bannerImageUrl = ''; + $scope.bannerUrl = ''; + $scope.$on("$ionicView.afterEnter", function() { startupService.ready(); + bannerService.fetchBannerSettings(function(banners) { + var banner = banners[Math.floor(Math.random()*banners.length)]; + $scope.bannerImageUrl = bannerService.getBannerImage(banner); + $scope.bannerUrl = banner.url; + $scope.bannerIsLoading = false; + }); }); $scope.$on("$ionicView.beforeEnter", function(event, data) { @@ -155,8 +165,8 @@ angular.module('copayApp.controllers').controller('tabHomeController', externalLinkService.open(url, optIn, title, message, okText, cancelText); }; - $scope.openStore = function() { - externalLinkService.open('https://store.bitcoin.com/', false); + $scope.openBannerUrl = function() { + externalLinkService.open($scope.bannerUrl, false); }; $scope.openNotificationModal = function(n) { diff --git a/www/views/tab-home.html b/www/views/tab-home.html index 4f044f3d2..463709c1e 100644 --- a/www/views/tab-home.html +++ b/www/views/tab-home.html @@ -92,9 +92,11 @@
From 4fb847b603abfe50251d4f343538dcb4442e80f3 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 3 Jul 2018 11:58:29 +0200 Subject: [PATCH 036/386] fix on qr-icon --- src/sass/qr.scss | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/sass/qr.scss b/src/sass/qr.scss index 3f8c9f104..056ab531f 100644 --- a/src/sass/qr.scss +++ b/src/sass/qr.scss @@ -1,14 +1,15 @@ qrcode { + position: relative; &.qr-icon { &::before { content: ""; background-size: 100% 100%; display: block; - margin-left: calc(50% - 22px); + left: 88px; margin-top: 88px; width: 44px; height: 44px; - position: absolute; + position:absolute; } &--bch::before { background-image: url('../img/qr-overlay-bch.png'); From 6fcc08617e74186679d2ea1a2a58e6eb11fd278c Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 3 Jul 2018 12:06:44 +0200 Subject: [PATCH 037/386] renaming qr overlay classes --- src/sass/qr.scss | 2 +- www/views/tab-receive.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/sass/qr.scss b/src/sass/qr.scss index 056ab531f..62fd12eb7 100644 --- a/src/sass/qr.scss +++ b/src/sass/qr.scss @@ -1,6 +1,6 @@ qrcode { position: relative; - &.qr-icon { + &.qr-overlay { &::before { content: ""; background-size: 100% 100%; diff --git a/www/views/tab-receive.html b/www/views/tab-receive.html index 3dd8ce94a..12076812f 100644 --- a/www/views/tab-receive.html +++ b/www/views/tab-receive.html @@ -41,7 +41,7 @@ - +
{{addr}} From 4d3a63de51e945115b2b5cdd81b07764a193fec4 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Wed, 4 Jul 2018 13:01:02 +0900 Subject: [PATCH 038/386] Update tab-home (remove a comment) --- www/views/tab-home.html | 1 - 1 file changed, 1 deletion(-) diff --git a/www/views/tab-home.html b/www/views/tab-home.html index 4f044f3d2..1ac17a0f6 100644 --- a/www/views/tab-home.html +++ b/www/views/tab-home.html @@ -73,7 +73,6 @@
Bitcoin Core (BTC)
-
Slow transactions with high fees
From bbe78ea4ca03abcea744b4cf16523813b4572a24 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Wed, 4 Jul 2018 17:17:39 +0900 Subject: [PATCH 039/386] Updates --- src/js/controllers/tab-home.js | 12 ++--- src/js/services/bannerService.js | 76 ++++++++++++++++++++++---------- 2 files changed, 60 insertions(+), 28 deletions(-) diff --git a/src/js/controllers/tab-home.js b/src/js/controllers/tab-home.js index 28375be5f..3f1526cbd 100644 --- a/src/js/controllers/tab-home.js +++ b/src/js/controllers/tab-home.js @@ -23,11 +23,13 @@ angular.module('copayApp.controllers').controller('tabHomeController', $scope.$on("$ionicView.afterEnter", function() { startupService.ready(); - bannerService.fetchBannerSettings(function(banners) { - var banner = banners[Math.floor(Math.random()*banners.length)]; - $scope.bannerImageUrl = bannerService.getBannerImage(banner); - $scope.bannerUrl = banner.url; - $scope.bannerIsLoading = false; + + bannerService.getBanner(function (banner) { + $scope.$apply(function () { + $scope.bannerImageUrl = banner.imageURL; + $scope.bannerUrl = banner.url; + $scope.bannerIsLoading = false; + }); }); }); diff --git a/src/js/services/bannerService.js b/src/js/services/bannerService.js index 5c03ec484..00a72a6c6 100644 --- a/src/js/services/bannerService.js +++ b/src/js/services/bannerService.js @@ -1,20 +1,23 @@ 'use strict'; angular.module('copayApp.services').factory('bannerService', function ($http, $log) { + // Export var root = {}; - var marketingApiService = 'http://127.0.0.1:3232/bws/api/v1/marketing'; - var bannersFetched = false; - var banners = [{ + // Constant + var API_URL = 'https://bwscash.bitcoin.com/bws/api/v1/marketing'; + + // Variable + var hasFetched = false; + var banners = []; + var defaultBanner = { id: 'default-banner', - image: 'img/banner-store.png', + imageURL: 'img/banner-store.png', url: 'https://store.bitcoin.com/', - local: true - }]; - - root.fetchBannerSettings = function (cb) { - if (bannersFetched) - return cb(banners); + isLocal: true + }; + // Private methods + var fetchSettings = function (cb) { var req = { method: 'GET', url: marketingApiService+'/settings', @@ -23,25 +26,52 @@ angular.module('copayApp.services').factory('bannerService', function ($http, $l 'Accept': 'application/json' } }; - $http(req).then(function (data) { + $http(req).then(function (response) { $log.info('Get banner settings: SUCCESS'); - banners = banners.concat(data.data); - bannersFetched = true; - return cb(banners); - }, function (data) { + banners = response.data + return cb(true); + }, function (error) { $log.error('Get banner settings: ERROR ' + data.statusText); - return cb(banners); + return cb(false); }); }; - root.getBannerImage = function (banner) { - if (banner.local) { - return banner.image; - } + root.getBanner = function (cb) { + + // If not fetch get the banner + if (!hasFetched) { + hasFetched = true; - var fileName = banner.image.substring(0, banner.image.lastIndexOf('.')); - var extension = banner.image.substring(banner.image.lastIndexOf('.')); - return marketingApiService+'/banners/'+fileName+"/"+extension; + // If never fetch, lets fetch + fetchSettings(function (isSuccess) { + root.getBannerImage(cb); + }); + + // If fetch, and got banners, lets have a look + } else if (banners.length > 0) { + var selectedBanners = []; + for(var i in banners) { + var banner = banners[i]; + + // Generate the URL for the banner + var fileName = banner.image.substring(0, banner.image.lastIndexOf('.')); + var extension = banner.image.substring(banner.image.lastIndexOf('.')); + banner.imageURL = API_URL +'/banners/'+fileName+"/"+extension; + + // Add the banner + selectedBanners.push(banners[i]); + } + + // If no banner activated, I return the default one + if (selectedBanners.length == 0) { + return cb(defaultBanner); + } else { + return cb(selectedBanners[Math.floor(Math.random()*banners.length)]); + } + + } else { + return cb(defaultBanner); + } }; return root; From de32460fd7136db712f91051c98b8745b4e5030e Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 4 Jul 2018 11:05:31 +0200 Subject: [PATCH 040/386] bannerService fixes + some space for the loader --- src/js/controllers/tab-home.js | 8 +++----- src/js/services/bannerService.js | 12 ++++++------ src/sass/views/tab-home.scss | 3 +++ 3 files changed, 12 insertions(+), 11 deletions(-) diff --git a/src/js/controllers/tab-home.js b/src/js/controllers/tab-home.js index 3f1526cbd..3a56e6d5c 100644 --- a/src/js/controllers/tab-home.js +++ b/src/js/controllers/tab-home.js @@ -25,11 +25,9 @@ angular.module('copayApp.controllers').controller('tabHomeController', startupService.ready(); bannerService.getBanner(function (banner) { - $scope.$apply(function () { - $scope.bannerImageUrl = banner.imageURL; - $scope.bannerUrl = banner.url; - $scope.bannerIsLoading = false; - }); + $scope.bannerImageUrl = banner.imageURL; + $scope.bannerUrl = banner.url; + $scope.bannerIsLoading = false; }); }); diff --git a/src/js/services/bannerService.js b/src/js/services/bannerService.js index 00a72a6c6..cb32793a0 100644 --- a/src/js/services/bannerService.js +++ b/src/js/services/bannerService.js @@ -20,7 +20,7 @@ angular.module('copayApp.services').factory('bannerService', function ($http, $l var fetchSettings = function (cb) { var req = { method: 'GET', - url: marketingApiService+'/settings', + url: API_URL+'/settings', headers: { 'Content-Type': 'application/json', 'Accept': 'application/json' @@ -28,10 +28,10 @@ angular.module('copayApp.services').factory('bannerService', function ($http, $l }; $http(req).then(function (response) { $log.info('Get banner settings: SUCCESS'); - banners = response.data + banners = response.data; return cb(true); }, function (error) { - $log.error('Get banner settings: ERROR ' + data.statusText); + $log.error('Get banner settings: ERROR ' + response.statusText); return cb(false); }); }; @@ -44,7 +44,7 @@ angular.module('copayApp.services').factory('bannerService', function ($http, $l // If never fetch, lets fetch fetchSettings(function (isSuccess) { - root.getBannerImage(cb); + root.getBanner(cb); }); // If fetch, and got banners, lets have a look @@ -55,14 +55,14 @@ angular.module('copayApp.services').factory('bannerService', function ($http, $l // Generate the URL for the banner var fileName = banner.image.substring(0, banner.image.lastIndexOf('.')); - var extension = banner.image.substring(banner.image.lastIndexOf('.')); + var extension = banner.image.substring(banner.image.lastIndexOf('.')+1); banner.imageURL = API_URL +'/banners/'+fileName+"/"+extension; // Add the banner selectedBanners.push(banners[i]); } - // If no banner activated, I return the default one + // If no banner activated, return the default one if (selectedBanners.length == 0) { return cb(defaultBanner); } else { diff --git a/src/sass/views/tab-home.scss b/src/sass/views/tab-home.scss index 46fb15224..66a2f1d58 100644 --- a/src/sass/views/tab-home.scss +++ b/src/sass/views/tab-home.scss @@ -59,6 +59,9 @@ } } &-banner { + svg { + margin: 40px auto 40px; + } padding: 0; &__img { width: 100%; From be39986e2400b176795ddc4deef78fe7742e05f9 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 4 Jul 2018 11:07:33 +0200 Subject: [PATCH 041/386] catch error fix --- src/js/services/bannerService.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/services/bannerService.js b/src/js/services/bannerService.js index cb32793a0..d48d8861e 100644 --- a/src/js/services/bannerService.js +++ b/src/js/services/bannerService.js @@ -31,7 +31,7 @@ angular.module('copayApp.services').factory('bannerService', function ($http, $l banners = response.data; return cb(true); }, function (error) { - $log.error('Get banner settings: ERROR ' + response.statusText); + $log.error('Get banner settings: ERROR ' + error.statusText); return cb(false); }); }; From 39232ce7393b5134b09ae5377f73ab9a9df1bca1 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Wed, 4 Jul 2018 18:28:41 +0900 Subject: [PATCH 042/386] Update the translation --- i18n/docs/appstore_en.txt | 46 +- i18n/docs/updateinfo_en.txt | 2 +- i18n/po/ca/template-ca.po | 6 +- i18n/po/cs/template-cs.po | 6 +- i18n/po/de/template-de.po | 6 +- i18n/po/es-ES/template-es-ES.po | 6 +- i18n/po/fa/template-fa.po | 6 +- i18n/po/fr/template-fr.po | 6 +- i18n/po/it/template-it.po | 6 +- i18n/po/ja/template-ja.po | 10 +- i18n/po/ko/template-ko.po | 6 +- i18n/po/nl/template-nl.po | 6 +- i18n/po/pl/template-pl.po | 6 +- i18n/po/pt-BR/template-pt-BR.po | 6 +- i18n/po/ru/template-ru.po | 6 +- i18n/po/sv-SE/template-sv-SE.po | 8 +- i18n/po/template.pot | 7252 ++++++++++++++++--------------- i18n/po/vi/template-vi.po | 32 +- i18n/po/zh-CN/template-zh-CN.po | 6 +- 19 files changed, 3748 insertions(+), 3680 deletions(-) diff --git a/i18n/docs/appstore_en.txt b/i18n/docs/appstore_en.txt index bdcad6673..6b7cd0a60 100644 --- a/i18n/docs/appstore_en.txt +++ b/i18n/docs/appstore_en.txt @@ -1,23 +1,23 @@ -Secure bitcoin on your own terms with an open source, multisignature wallet from BitPay. -Copay users can hold funds individually or share finances securely with other users with multisignature wallets, which prevent unauthorized payments by requiring multiple approvals. Here are some ways Copay can be used with others: - -To save for vacations or joint purchases with friends -To track family spending and allowances -To manage business, club, or organization funds and expenses - -We built the following features into this version of Copay for a bitcoin wallet that doesn't compromise on security or accessibility: - -Multiple wallet creation and management in-app -Intuitive multisignature security for personal or shared wallets -Easy spending proposal flow for shared wallets and group payments -Hierarchical deterministic (HD) address generation and wallet backups -Device-based security: all private keys are stored locally, not in the cloud -Support for Bitcoin testnet wallets -Synchronous access across all major mobile and desktop platforms -Payment protocol (BIP70-BIP73) support: easily-identifiable payment requests and verifiably secure bitcoin payments -Support for 150+ currency pricing options and unit denomination in BTC or bits -Email notifications for payments and transfers -Customizable wallet naming and background colors -9 supported languages (EN, CS, FR, DE, IT, ES, JA, PL, RU) - -Copay is free and open source software run on non-proprietary servers, so there's no need to rely on any company for continuous support. Anyone can review or contribute to Copay's source code on GitHub (https://github.com/bitpay/copay). +Secure bitcoin on your own terms with an open source, multisignature wallet from BitPay. +Copay users can hold funds individually or share finances securely with other users with multisignature wallets, which prevent unauthorized payments by requiring multiple approvals. Here are some ways Copay can be used with others: + +To save for vacations or joint purchases with friends +To track family spending and allowances +To manage business, club, or organization funds and expenses + +We built the following features into this version of Copay for a bitcoin wallet that doesn't compromise on security or accessibility: + +Multiple wallet creation and management in-app +Intuitive multisignature security for personal or shared wallets +Easy spending proposal flow for shared wallets and group payments +Hierarchical deterministic (HD) address generation and wallet backups +Device-based security: all private keys are stored locally, not in the cloud +Support for Bitcoin testnet wallets +Synchronous access across all major mobile and desktop platforms +Payment protocol (BIP70-BIP73) support: easily-identifiable payment requests and verifiably secure bitcoin payments +Support for 150+ currency pricing options and unit denomination in BTC or bits +Email notifications for payments and transfers +Customizable wallet naming and background colors +9 supported languages (EN, CS, FR, DE, IT, ES, JA, PL, RU) + +Copay is free and open source software run on non-proprietary servers, so there's no need to rely on any company for continuous support. Anyone can review or contribute to Copay's source code on GitHub (https://github.com/bitpay/copay). diff --git a/i18n/docs/updateinfo_en.txt b/i18n/docs/updateinfo_en.txt index 8b1378917..d3f5a12fa 100644 --- a/i18n/docs/updateinfo_en.txt +++ b/i18n/docs/updateinfo_en.txt @@ -1 +1 @@ - + diff --git a/i18n/po/ca/template-ca.po b/i18n/po/ca/template-ca.po index f7f513bc2..515fcd814 100644 --- a/i18n/po/ca/template-ca.po +++ b/i18n/po/ca/template-ca.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Catalan\n" "Language: ca\n" -"PO-Revision-Date: 2018-06-22T04:02:43+0000\n" +"PO-Revision-Date: 2018-07-04 09:26\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "Compte" msgid "Account Number" msgstr "Número de compte" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "Transaccions instantànies amb comissions baixes" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "Comptes" diff --git a/i18n/po/cs/template-cs.po b/i18n/po/cs/template-cs.po index 8aad5ecb2..14fe7faf2 100644 --- a/i18n/po/cs/template-cs.po +++ b/i18n/po/cs/template-cs.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Czech\n" "Language: cs\n" -"PO-Revision-Date: 2018-06-22T04:02:46+0000\n" +"PO-Revision-Date: 2018-07-04 09:26\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "Účet" msgid "Account Number" msgstr "Číslo účtu" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "Okamžité transakce s nízkou platbou" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "Účty" diff --git a/i18n/po/de/template-de.po b/i18n/po/de/template-de.po index 9767a07a7..7b3a50d69 100644 --- a/i18n/po/de/template-de.po +++ b/i18n/po/de/template-de.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: German\n" "Language: de\n" -"PO-Revision-Date: 2018-06-22T04:02:49+0000\n" +"PO-Revision-Date: 2018-07-04 03:57\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "Benutzerkonto" msgid "Account Number" msgstr "Kontonummer" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "Konten" diff --git a/i18n/po/es-ES/template-es-ES.po b/i18n/po/es-ES/template-es-ES.po index 046826130..e062b4d1e 100644 --- a/i18n/po/es-ES/template-es-ES.po +++ b/i18n/po/es-ES/template-es-ES.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Spanish\n" "Language: es\n" -"PO-Revision-Date: 2018-06-22T04:02:57+0000\n" +"PO-Revision-Date: 2018-07-04 09:27\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "Cuenta" msgid "Account Number" msgstr "Número de cuenta" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "Transacciones instantáneas con comisiones bajas" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "Cuentas" diff --git a/i18n/po/fa/template-fa.po b/i18n/po/fa/template-fa.po index dfd490fda..aa4b76892 100644 --- a/i18n/po/fa/template-fa.po +++ b/i18n/po/fa/template-fa.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Persian\n" "Language: fa\n" -"PO-Revision-Date: 2018-06-22T04:02:53+0000\n" +"PO-Revision-Date: 2018-07-04 09:27\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "حساب" msgid "Account Number" msgstr "شماره حساب" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "معاملات فوری با پرداخت کم" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "حساب ها" diff --git a/i18n/po/fr/template-fr.po b/i18n/po/fr/template-fr.po index 559799342..f49b0fe55 100644 --- a/i18n/po/fr/template-fr.po +++ b/i18n/po/fr/template-fr.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: French\n" "Language: fr\n" -"PO-Revision-Date: 2018-06-22T04:02:48+0000\n" +"PO-Revision-Date: 2018-07-04 09:26\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "Compte" msgid "Account Number" msgstr "Numéro de compte" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "Transactions instantanées à bas frais" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "Comptes" diff --git a/i18n/po/it/template-it.po b/i18n/po/it/template-it.po index 0055adf06..1fcaea030 100644 --- a/i18n/po/it/template-it.po +++ b/i18n/po/it/template-it.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Italian\n" "Language: it\n" -"PO-Revision-Date: 2018-06-22T04:02:50+0000\n" +"PO-Revision-Date: 2018-07-04 09:27\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "Conto" msgid "Account Number" msgstr "Numero del Conto" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "Transazioni istantanee con commissioni basse" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "Account" diff --git a/i18n/po/ja/template-ja.po b/i18n/po/ja/template-ja.po index 8cdbd23ec..e7df99c1b 100644 --- a/i18n/po/ja/template-ja.po +++ b/i18n/po/ja/template-ja.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Japanese\n" "Language: ja\n" -"PO-Revision-Date: 2018-06-22T04:02:51+0000\n" +"PO-Revision-Date: 2018-07-04 09:27\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "ポケット" msgid "Account Number" msgstr "ポケット番号" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "僅かな手数料で即時決済" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "アカウント一覧" @@ -631,7 +635,7 @@ msgstr "翻訳に協力" #: src/js/controllers/confirm.js:130 msgid "Copay only supports Bitcoin Cash using new version numbers addresses" -msgstr "Copay のビットコインキャッシュはビットコインと完全に異なる別通貨なので、アドレスの頭文字が異なります。" +msgstr "のビットコインキャッシュはビットコインと完全に異なる別通貨なので、アドレスの頭文字が異なります。" #: src/js/services/bwcError.js:62 msgid "Copayer already in this wallet" @@ -2225,7 +2229,7 @@ msgstr "正しい順序で各単語をタップしてください。" #: src/js/services/bwcError.js:101 msgid "Please upgrade Copay to perform this action" -msgstr "この操作を実行するにはCopayを最新バージョンに更新してください" +msgstr "この操作を実行するにはを最新バージョンに更新してください" #: www/views/walletDetails.html:142 #: www/views/walletDetails.html:62 diff --git a/i18n/po/ko/template-ko.po b/i18n/po/ko/template-ko.po index 67cfe2496..cee1be7d1 100644 --- a/i18n/po/ko/template-ko.po +++ b/i18n/po/ko/template-ko.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Korean\n" "Language: ko\n" -"PO-Revision-Date: 2018-06-22T04:02:52+0000\n" +"PO-Revision-Date: 2018-07-04 09:27\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "계정" msgid "Account Number" msgstr "계정 번호" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "낮은 수수료로 빠른 송금을" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "계정들" diff --git a/i18n/po/nl/template-nl.po b/i18n/po/nl/template-nl.po index c47511226..754c41e21 100644 --- a/i18n/po/nl/template-nl.po +++ b/i18n/po/nl/template-nl.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Dutch\n" "Language: nl\n" -"PO-Revision-Date: 2018-06-22T04:02:48+0000\n" +"PO-Revision-Date: 2018-07-04 09:26\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "Account" msgid "Account Number" msgstr "Account Nummer" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "Directe transacties tegen lage kosten" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "Accounts" diff --git a/i18n/po/pl/template-pl.po b/i18n/po/pl/template-pl.po index 4a9f5c0ea..ce075e00b 100644 --- a/i18n/po/pl/template-pl.po +++ b/i18n/po/pl/template-pl.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Polish\n" "Language: pl\n" -"PO-Revision-Date: 2018-06-22T04:02:54+0000\n" +"PO-Revision-Date: 2018-07-04 03:58\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "Konto" msgid "Account Number" msgstr "Numer konta" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "Konta" diff --git a/i18n/po/pt-BR/template-pt-BR.po b/i18n/po/pt-BR/template-pt-BR.po index ef43aa4ef..c83259bf9 100644 --- a/i18n/po/pt-BR/template-pt-BR.po +++ b/i18n/po/pt-BR/template-pt-BR.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Portuguese, Brazilian\n" "Language: pt\n" -"PO-Revision-Date: 2018-06-22T04:02:55+0000\n" +"PO-Revision-Date: 2018-07-04 09:27\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "Conta" msgid "Account Number" msgstr "Número de conta" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "Transações instantâneas com taxas baixas" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "Contas" diff --git a/i18n/po/ru/template-ru.po b/i18n/po/ru/template-ru.po index 163473060..074fa9937 100644 --- a/i18n/po/ru/template-ru.po +++ b/i18n/po/ru/template-ru.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Russian\n" "Language: ru\n" -"PO-Revision-Date: 2018-06-22T04:02:56+0000\n" +"PO-Revision-Date: 2018-07-04 09:27\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "Учётная запись" msgid "Account Number" msgstr "Номер учётной записи" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "Мгновенные транзакции с низкой оплатой" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "Аккаунты" diff --git a/i18n/po/sv-SE/template-sv-SE.po b/i18n/po/sv-SE/template-sv-SE.po index ccdd0492b..bc496d6d5 100644 --- a/i18n/po/sv-SE/template-sv-SE.po +++ b/i18n/po/sv-SE/template-sv-SE.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Swedish\n" "Language: sv\n" -"PO-Revision-Date: 2018-06-22T04:02:58+0000\n" +"PO-Revision-Date: 2018-07-04 03:58\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "Konto" msgid "Account Number" msgstr "Kontonummer" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "Konton" @@ -369,7 +373,7 @@ msgstr "" #: www/views/tab-home.html:98 #: www/views/tab-settings.html:115 msgid "Bitcoin Cash Wallets" -msgstr "" +msgstr "Bitcoin Cash plånböcker" #: www/views/modals/chooseFeeLevel.html:4 #: www/views/preferencesFee.html:4 diff --git a/i18n/po/template.pot b/i18n/po/template.pot index d97008340..66a2e7ca8 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -1,3624 +1,3628 @@ -msgid "" -msgstr "" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Project-Id-Version: \n" - -#: www/views/modals/paypro.html:34 -msgid "(Trusted)" -msgstr "" - -#: www/views/includes/txp.html:23 -#: www/views/includes/walletHistory.html:64 -msgid "(possible double spend)" -msgstr "" - -#: www/views/modals/txp-details.html:159 -msgid "* A payment proposal can be deleted if 1) you are the creator, and no other copayer has signed, or 2) 24 hours have passed since the proposal was created." -msgstr "" - -#: www/views/tx-details.html:82 -msgid "- {{btx.feeRateStr}} of the transaction" -msgstr "" - -#: www/views/modals/txp-details.html:102 -msgid "- {{tx.feeRateStr}} of the transaction" -msgstr "" - -#: www/views/feedback/rateApp.html:7 -msgid "5-star ratings help us get {{appName}} into more hands, and more users means more resources can be committed to the app!" -msgstr "" - -#: www/views/mercadoLibre.html:18 -#: www/views/mercadoLibre.html:40 -msgid "Only redeemable on Mercado Livre (Brazil)" -msgstr "" - -#: src/js/controllers/feedback/send.js:27 -#: www/views/feedback/complete.html:21 -msgid "A member of the team will review your feedback as soon as possible." -msgstr "" - -#: src/js/controllers/confirm.js:401 -msgid "A total of {{amountAboveMaxSizeStr}} were excluded. The maximum size allowed for a transaction was exceeded." -msgstr "" - -#: src/js/controllers/confirm.js:395 -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:156 -msgid "About" -msgstr "" - -#: src/js/controllers/modals/txpDetails.js:62 -#: src/js/controllers/tx-details.js:79 -msgid "Accepted" -msgstr "" - -#: www/views/preferencesInformation.html:72 -msgid "Account" -msgstr "" - -#: www/views/join.html:72 -#: www/views/tab-create-personal.html:45 -#: www/views/tab-create-shared.html:74 -#: www/views/tab-import-hardware.html:19 -msgid "Account Number" -msgstr "" - -#: www/views/preferencesBitpayServices.html:23 -msgid "Accounts" -msgstr "" - -#: www/views/bitpayCard.html:56 -msgid "Activity" -msgstr "" - -#: src/js/services/bitpayAccountService.js:83 -msgid "Add Account" -msgstr "" - -#: src/js/services/bitpayAccountService.js:69 -msgid "Add BitPay Account?" -msgstr "" - -#: www/views/addressbook.add.html:4 -#: www/views/addressbook.html:22 -msgid "Add Contact" -msgstr "" - -#: www/views/bitpayCard.html:28 -msgid "Add Funds" -msgstr "" - -#: www/views/confirm.html:94 -msgid "Add Memo" -msgstr "" - -#: www/views/join.html:87 -#: www/views/tab-create-personal.html:59 -#: www/views/tab-create-shared.html:88 -msgid "Add a password" -msgstr "" - -#: www/views/includes/accountSelector.html:27 -msgid "Add account" -msgstr "" - -#: www/views/join.html:90 -#: www/views/tab-create-personal.html:62 -#: www/views/tab-create-shared.html:91 -msgid "Add an optional password to secure the recovery phrase" -msgstr "" - -#: www/views/includes/incomingDataMenu.html:41 -msgid "Add as a contact" -msgstr "" - -#: src/js/controllers/confirm.js:424 -msgid "Add description" -msgstr "" - -#: www/views/topup.html:6 -msgid "Add funds" -msgstr "" - -#: src/js/services/bitpayAccountService.js:78 -msgid "Add this BitPay account ({{email}})?" -msgstr "" - -#: www/views/add.html:3 -msgid "Add wallet" -msgstr "" - -#: www/views/addressbook.view.html:26 -#: www/views/customAmount.html:28 -#: www/views/modals/paypro.html:24 -msgid "Address" -msgstr "" - -#: www/views/addressbook.html:6 -#: www/views/tab-settings.html:13 -msgid "Address Book" -msgstr "" - -#: www/views/preferencesInformation.html:41 -msgid "Address Type" -msgstr "" - -#: www/views/addresses.html:64 -msgid "Addresses With Balance" -msgstr "" - -#: www/views/tab-settings.html:149 -msgid "Advanced" -msgstr "" - -#: www/views/advancedSettings.html:3 -msgid "Advanced Settings" -msgstr "" - -#: www/views/bitpayCard.html:62 -msgid "All" -msgstr "" - -#: www/views/allAddresses.html:3 -msgid "All Addresses" -msgstr "" - -#: www/views/modals/wallet-balance.html:18 -msgid "All of your bitcoin wallet balance may not be available for immediate spending." -msgstr "" - -#: www/views/tab-receive.html:25 -msgid "All signing devices must be added to this multisig wallet before bitcoin addresses can be created." -msgstr "" - -#: www/views/tab-scan.html:21 -msgid "Allow Camera Access" -msgstr "" - -#: www/views/onboarding/notifications.html:7 -msgid "Allow notifications" -msgstr "" - -#: www/views/onboarding/disclaimer.html:14 -msgid "Almost done! Let's review." -msgstr "" - -#: www/views/preferencesAltCurrency.html:4 -#: www/views/tab-settings.html:79 -msgid "Alternative Currency" -msgstr "" - -#: src/js/controllers/buyAmazon.js:98 -msgid "Amazon.com is not available at this moment. Please try back later." -msgstr "" - -#: www/views/amount.html:44 -#: www/views/customAmount.html:34 -#: www/views/includes/output.html:7 -msgid "Amount" -msgstr "" - -#: src/js/services/bwcError.js:110 -msgid "Amount below minimum allowed" -msgstr "" - -#: src/js/controllers/confirm.js:216 -msgid "Amount too big" -msgstr "" - -#: www/views/includes/walletHistory.html:31 -msgid "Amount too low to spend" -msgstr "" - -#: src/js/controllers/tab-home.js:147 -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 "" - -#: www/views/addresses.html:94 -msgid "Approximate Bitcoin network fee to transfer wallet's balance (with normal priority)" -msgstr "" - -#: www/views/backupWarning.html:10 -msgid "Are you being watched?" -msgstr "" - -#: src/js/controllers/preferencesExternal.js:15 -msgid "Are you being watched? Anyone with your recovery phrase can access or spend your bitcoin." -msgstr "" - -#: src/js/controllers/copayers.js:56 -msgid "Are you sure you want to cancel and delete this wallet?" -msgstr "" - -#: src/js/controllers/addressbookView.js:37 -msgid "Are you sure you want to delete this contact?" -msgstr "" - -#: src/js/controllers/preferencesDelete.js:25 -msgid "Are you sure you want to delete this wallet?" -msgstr "" - -#: src/js/controllers/modals/txpDetails.js:154 -msgid "Are you sure you want to reject this transaction?" -msgstr "" - -#: src/js/controllers/modals/txpDetails.js:171 -msgid "Are you sure you want to remove this transaction?" -msgstr "" - -#: src/js/controllers/onboarding/backupRequest.js:23 -msgid "Are you sure you want to skip it?" -msgstr "" - -#: www/views/modals/bitpay-card-confirmation.html:4 -msgid "Are you sure you would like to log out of your BitPay Card account?" -msgstr "" - -#: src/js/controllers/preferencesBitpayCard.js:7 -#: src/js/controllers/preferencesBitpayServices.js:20 -msgid "Are you sure you would like to remove your BitPay Card ({{lastFourDigits}}) from this device?" -msgstr "" - -#: www/views/includes/walletInfo.html:10 -msgid "Auditable" -msgstr "" - -#: www/views/modals/wallet-balance.html:42 -msgid "Available" -msgstr "" - -#: www/views/includes/available-balance.html:3 -msgid "Available Balance" -msgstr "" - -#: www/views/modals/chooseFeeLevel.html:24 -#: www/views/preferencesFee.html:15 -msgid "Average confirmation time" -msgstr "" - -#: www/views/join.html:143 -#: www/views/tab-create-personal.html:113 -#: www/views/tab-create-shared.html:142 -#: www/views/tab-import-phrase.html:51 -msgid "BIP32 path for address derivation" -msgstr "" - -#: www/views/cashScan.html:25 -msgid "BTC wallets" -msgstr "" - -#: www/views/preferences.html:34 -msgid "Backup" -msgstr "" - -#: www/views/includes/backupNeededPopup.html:7 -msgid "Backup Needed" -msgstr "" - -#: src/js/controllers/lockSetup.js:87 -msgid "Backup all livenet wallets before using this function" -msgstr "" - -#: src/js/controllers/cashScan.js:64 -#: www/views/includes/walletListSettings.html:12 -#: www/views/preferences.html:36 -msgid "Backup needed" -msgstr "" - -#: www/views/includes/backupNeededPopup.html:9 -msgid "Backup now" -msgstr "" - -#: www/views/onboarding/backupRequest.html:11 -#: www/views/tab-export-file.html:89 -msgid "Backup wallet" -msgstr "" - -#: src/js/controllers/lockSetup.js:84 -msgid "Backup your wallet before using this function" -msgstr "" - -#: src/js/services/profileService.js:446 -msgid "Bad wallet invitation" -msgstr "" - -#: www/views/preferencesInformation.html:102 -msgid "Balance By Address" -msgstr "" - -#: www/views/includes/confirmBackupPopup.html:7 -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 "" - -#: www/views/preferencesBitpayServices.html:9 -msgid "BitPay Visa® Cards" -msgstr "" - -#: www/views/addressbook.add.html:38 -#: www/views/includes/incomingDataMenu.html:29 -msgid "Bitcoin Address" -msgstr "" - -#: www/views/cashScan.html:4 -msgid "Bitcoin Cash (BCH) Balances" -msgstr "" - -#: www/views/preferencesCash.html:3 -#: www/views/tab-settings.html:47 -msgid "Bitcoin Cash Support" -msgstr "" - -#: www/views/tab-home.html:98 -#: www/views/tab-settings.html:115 -msgid "Bitcoin Cash Wallets" -msgstr "" - -#: www/views/modals/chooseFeeLevel.html:4 -#: www/views/preferencesFee.html:4 -#: www/views/tab-settings.html:90 -msgid "Bitcoin Network Fee Policy" -msgstr "" - -#: www/views/tab-home.html:83 -#: www/views/tab-settings.html:107 -msgid "Bitcoin Core Wallets" -msgstr "" - -#: src/js/services/incomingData.js:151 -msgid "Bitcoin cash Payment" -msgstr "" - -#: www/views/onboarding/tour.html:31 -msgid "Bitcoin is a currency." -msgstr "" - -#: www/views/onboarding/disclaimer.html:15 -msgid "Bitcoin is different – it cannot be safely held with a bank or web service." -msgstr "" - -#: www/views/onboarding/tour.html:18 -msgid "Bitcoin is secure,
digital money." -msgstr "" - -#: www/views/preferencesFee.html:11 -msgid "Bitcoin transactions include a fee collected by miners on the network." -msgstr "" - -#: www/views/buyAmazon.html:108 -msgid "Bought {{amountUnitStr}}" -msgstr "" - -#: www/views/modals/txp-details.html:36 -msgid "Broadcast Payment" -msgstr "" - -#: src/js/controllers/modals/txpDetails.js:64 -#: src/js/controllers/tx-details.js:81 -msgid "Broadcasted" -msgstr "" - -#: src/js/services/onGoingProcess.js:11 -msgid "Broadcasting transaction" -msgstr "" - -#: www/views/unsupported.html:6 -msgid "Browser unsupported" -msgstr "" - -#: www/views/buyAmazon.html:5 -#: www/views/buyMercadoLibre.html:6 -msgid "Buy" -msgstr "" - -#: www/views/includes/buyAndSellCard.html:3 -msgid "Buy & Sell Bitcoin" -msgstr "" - -#: www/views/tab-send.html:35 -msgid "Buy Bitcoin" -msgstr "" - -#: www/views/mercadoLibre.html:22 -#: www/views/mercadoLibre.html:50 -msgid "Buy a Gift Card" -msgstr "" - -#: src/js/controllers/buyAmazon.js:334 -msgid "Buy from" -msgstr "" - -#: src/js/services/onGoingProcess.js:40 -msgid "Buying Bitcoin..." -msgstr "" - -#: src/js/services/onGoingProcess.js:12 -msgid "Calculating fee" -msgstr "" - -#: src/js/controllers/buyAmazon.js:313 -#: src/js/controllers/buyMercadoLibre.js:307 -#: src/js/controllers/confirm.js:550 -#: src/js/controllers/topup.js:287 -#: src/js/services/incomingData.js:154 -#: src/js/services/popupService.js:62 -#: src/js/services/popupService.js:73 -#: www/views/addressbook.add.html:10 -#: www/views/feedback/send.html:5 -#: www/views/includes/incomingDataMenu.html:22 -#: www/views/includes/incomingDataMenu.html:54 -#: www/views/includes/incomingDataMenu.html:73 -#: www/views/includes/incomingDataMenu.html:97 -#: www/views/includes/note.html:6 -#: www/views/modals/bitpay-card-confirmation.html:8 -#: www/views/modals/confirmation.html:13 -msgid "Cancel" -msgstr "" - -#: www/views/copayers.html:36 -msgid "Cancel invitation" -msgstr "" - -#: src/js/controllers/onboarding/tour.js:52 -msgid "Cannot Create Wallet" -msgstr "" - -#: src/js/services/profileService.js:442 -msgid "Cannot join the same wallet more that once" -msgstr "" - -#: www/views/includes/bitpayCardsCard.html:2 -msgid "Cards" -msgstr "" - -#: www/views/modals/paypro.html:30 -msgid "Certified by" -msgstr "" - -#: www/views/preferencesExternal.html:19 -msgid "Check installation and retry." -msgstr "" - -#: www/views/tab-import-file.html:4 -msgid "Choose a backup file from your computer" -msgstr "" - -#: www/views/modals/wallets.html:9 -msgid "Choose your destination wallet" -msgstr "" - -#: www/views/modals/wallets.html:10 -msgid "Choose your source wallet" -msgstr "" - -#: www/views/backup.html:61 -msgid "Clear" -msgstr "" - -#: www/views/preferencesHistory.html:24 -msgid "Clear cache" -msgstr "" - -#: src/js/controllers/confirm.js:373 -#: src/js/controllers/modals/txpDetails.js:49 -msgid "Click to accept" -msgstr "" - -#: src/js/controllers/confirm.js:367 -msgid "Click to pay" -msgstr "" - -#: src/js/controllers/confirm.js:379 -#: src/js/controllers/modals/txpDetails.js:42 -msgid "Click to send" -msgstr "" - -#: www/views/customAmount.html:4 -#: www/views/modals/mercadolibre-card-details.html:3 -#: www/views/modals/paypro.html:4 -#: www/views/modals/pin.html:3 -#: www/views/modals/search.html:3 -#: www/views/modals/wallet-balance.html:3 -#: www/views/modals/wallets.html:5 -msgid "Close" -msgstr "" - -#: www/views/includes/cash.html:2 -#: www/views/preferencesInformation.html:17 -msgid "Coin" -msgstr "" - -#: www/views/preferences.html:22 -msgid "Color" -msgstr "" - -#: www/views/preferencesAbout.html:21 -msgid "Commit hash" -msgstr "" - -#: www/views/preferences.html:49 -msgid "Complete the backup process to use this option" -msgstr "" - -#: www/views/bitpayCard.html:93 -msgid "Completed" -msgstr "" - -#: src/js/controllers/buyAmazon.js:311 -#: src/js/controllers/buyMercadoLibre.js:305 -#: src/js/controllers/confirm.js:549 -#: src/js/controllers/copayers.js:55 -#: src/js/controllers/topup.js:285 -#: www/views/backup.html:60 -#: www/views/backup.html:79 -#: www/views/confirm.html:4 -#: www/views/onboarding/collectEmail.html:32 -msgid "Confirm" -msgstr "" - -#: www/views/modals/terms.html:26 -#: www/views/onboarding/disclaimer.html:44 -msgid "Confirm & Finish" -msgstr "" - -#: www/views/buyAmazon.html:90 -msgid "Confirm purchase" -msgstr "" - -#: www/views/modals/pin.html:10 -msgid "Confirm your PIN" -msgstr "" - -#: src/js/services/walletService.js:1033 -msgid "Confirm your new spending password" -msgstr "" - -#: www/views/tx-details.html:98 -msgid "Confirmations" -msgstr "" - -#: www/views/bitpayCard.html:68 -#: www/views/modals/wallet-balance.html:61 -msgid "Confirming" -msgstr "" - -#: www/views/bitpayCardIntro.html:37 -msgid "Connect my BitPay Card" -msgstr "" - -#: src/js/services/onGoingProcess.js:13 -msgid "Connecting to Coinbase..." -msgstr "" - -#: src/js/services/onGoingProcess.js:14 -msgid "Connecting to Glidera..." -msgstr "" - -#: src/js/services/bwcError.js:53 -msgid "Connection reset by peer" -msgstr "" - -#: www/views/tab-send.html:45 -msgid "Contacts" -msgstr "" - -#: www/views/onboarding/notifications.html:9 -msgid "Continue" -msgstr "" - -#: www/views/preferencesLanguage.html:26 -msgid "Contribute Translations" -msgstr "" - -#: src/js/controllers/confirm.js:130 -msgid "Copay only supports Bitcoin Cash using new version numbers addresses" -msgstr "" - -#: src/js/services/bwcError.js:62 -msgid "Copayer already in this wallet" -msgstr "" - -#: src/js/services/bwcError.js:77 -msgid "Copayer already voted on this spend proposal" -msgstr "" - -#: src/js/services/bwcError.js:107 -msgid "Copayer data mismatch" -msgstr "" - -#: www/views/includes/walletActivity.html:2 -msgid "Copayer joined" -msgstr "" - -#: www/views/preferencesInformation.html:94 -msgid "Copayer {{$index}}" -msgstr "" - -#: src/js/controllers/copayers.js:79 -#: src/js/controllers/export.js:193 -#: www/views/includes/copyToClipboard.html:4 -msgid "Copied to clipboard" -msgstr "" - -#: www/views/tab-export-file.html:94 -msgid "Copy this text as it is to a safe place (notepad or email)" -msgstr "" - -#: www/views/includes/incomingDataMenu.html:51 -#: www/views/includes/incomingDataMenu.html:70 -#: www/views/includes/incomingDataMenu.html:94 -#: www/views/includes/logOptions.html:9 -#: www/views/tab-export-file.html:78 -msgid "Copy to clipboard" -msgstr "" - -#: src/js/controllers/buyMercadoLibre.js:102 -msgid "Could not access Gift Card Service" -msgstr "" - -#: www/views/tab-import-phrase.html:2 -msgid "Could not access the wallet at the server. Please check:" -msgstr "" - -#: src/js/controllers/buyAmazon.js:102 -msgid "Could not access to Amazon.com" -msgstr "" - -#: src/js/services/profileService.js:511 -msgid "Could not access wallet" -msgstr "" - -#: src/js/controllers/confirm.js:210 -msgid "Could not add message to imported wallet without shared encrypting key" -msgstr "" - -#: src/js/controllers/modals/txpDetails.js:199 -msgid "Could not broadcast payment" -msgstr "" - -#: src/js/services/bwcError.js:41 -msgid "Could not build transaction" -msgstr "" - -#: src/js/services/walletService.js:854 -msgid "Could not create address" -msgstr "" - -#: src/js/controllers/topup.js:92 -msgid "Could not create the invoice" -msgstr "" - -#: src/js/controllers/buyAmazon.js:164 -#: src/js/controllers/buyMercadoLibre.js:164 -#: src/js/controllers/topup.js:142 -msgid "Could not create transaction" -msgstr "" - -#: src/js/services/profileService.js:350 -msgid "Could not create using the specified extended private key" -msgstr "" - -#: src/js/services/profileService.js:362 -msgid "Could not create using the specified extended public key" -msgstr "" - -#: src/js/services/profileService.js:338 -msgid "Could not create: Invalid wallet recovery phrase" -msgstr "" - -#: src/js/controllers/import.js:114 -msgid "Could not decrypt file, check your password" -msgstr "" - -#: src/js/controllers/modals/txpDetails.js:181 -msgid "Could not delete payment proposal" -msgstr "" - -#: src/js/controllers/cashScan.js:117 -msgid "Could not duplicate" -msgstr "" - -#: src/js/services/feeService.js:73 -msgid "Could not get dynamic fee" -msgstr "" - -#: src/js/services/feeService.js:43 -msgid "Could not get dynamic fee for level: {{feeLevel}}" -msgstr "" - -#: src/js/controllers/modals/feeLevels.js:112 -msgid "Could not get fee levels" -msgstr "" - -#: src/js/controllers/buyAmazon.js:122 -#: src/js/controllers/buyMercadoLibre.js:122 -#: src/js/controllers/topup.js:100 -msgid "Could not get the invoice" -msgstr "" - -#: src/js/controllers/bitpayCard.js:66 -msgid "Could not get transactions" -msgstr "" - -#: src/js/services/profileService.js:615 -#: src/js/services/profileService.js:650 -#: src/js/services/profileService.js:674 -msgid "Could not import" -msgstr "" - -#: src/js/services/profileService.js:584 -msgid "Could not import. Check input file and spending password" -msgstr "" - -#: src/js/services/profileService.js:457 -msgid "Could not join wallet" -msgstr "" - -#: src/js/controllers/modals/txpDetails.js:161 -msgid "Could not reject payment" -msgstr "" - -#: src/js/controllers/preferencesBitpayServices.js:33 -msgid "Could not remove account" -msgstr "" - -#: src/js/controllers/preferencesBitpayCard.js:20 -#: src/js/controllers/preferencesBitpayServices.js:50 -msgid "Could not remove card" -msgstr "" - -#: src/js/services/walletService.js:776 -msgid "Could not save preferences on the server" -msgstr "" - -#: src/js/controllers/modals/txpDetails.js:147 -msgid "Could not send payment" -msgstr "" - -#: src/js/controllers/buyAmazon.js:325 -#: src/js/controllers/buyMercadoLibre.js:318 -#: src/js/controllers/topup.js:299 -msgid "Could not send transaction" -msgstr "" - -#: www/views/walletDetails.html:210 -msgid "Could not update transaction history" -msgstr "" - -#: src/js/controllers/addresses.js:29 -#: src/js/controllers/addresses.js:37 -#: src/js/controllers/copayers.js:30 -#: src/js/controllers/walletDetails.js:78 -msgid "Could not update wallet" -msgstr "" - -#: www/views/tab-create-personal.html:3 -msgid "Create Personal Wallet" -msgstr "" - -#: www/views/tab-create-shared.html:3 -msgid "Create Shared Wallet" -msgstr "" - -#: www/views/onboarding/tour.html:51 -#: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 -msgid "Create bitcoin wallet" -msgstr "" - -#: www/views/tab-create-personal.html:131 -msgid "Create new wallet" -msgstr "" - -#: www/views/add.html:22 -msgid "Create shared wallet" -msgstr "" - -#: www/views/tab-create-shared.html:160 -msgid "Create {{formData.requiredCopayers}}-of-{{formData.totalCopayers}} wallet" -msgstr "" - -#: www/views/modals/txp-details.html:81 -#: www/views/tx-details.html:60 -msgid "Created by" -msgstr "" - -#: src/js/services/onGoingProcess.js:18 -msgid "Creating Wallet..." -msgstr "" - -#: src/js/services/onGoingProcess.js:17 -msgid "Creating transaction" -msgstr "" - -#: www/views/modals/chooseFeeLevel.html:34 -#: www/views/preferencesFee.html:20 -msgid "Current fee rate for this policy" -msgstr "" - -#: src/js/services/feeService.js:15 -msgid "Custom" -msgstr "" - -#: www/views/customAmount.html:9 -msgid "Custom Amount" -msgstr "" - -#: src/js/controllers/preferencesFee.js:85 -msgid "Custom Fee" -msgstr "" - -#: www/views/modals/mercadolibre-card-details.html:56 -#: www/views/modals/txp-details.html:87 -#: www/views/tx-details.html:66 -msgid "Date" -msgstr "" - -#: www/views/preferencesDeleteWallet.html:21 -msgid "Delete" -msgstr "" - -#: www/views/modals/txp-details.html:164 -msgid "Delete Payment Proposal" -msgstr "" - -#: www/views/preferencesAdvanced.html:33 -#: www/views/preferencesDeleteWallet.html:3 -msgid "Delete Wallet" -msgstr "" - -#: www/views/copayers.html:59 -msgid "Delete it and create a new one" -msgstr "" - -#: src/js/services/onGoingProcess.js:19 -msgid "Deleting Wallet..." -msgstr "" - -#: src/js/services/onGoingProcess.js:28 -msgid "Deleting payment proposal" -msgstr "" - -#: www/views/join.html:141 -#: www/views/tab-create-personal.html:111 -#: www/views/tab-create-shared.html:140 -#: www/views/tab-import-phrase.html:49 -msgid "Derivation Path" -msgstr "" - -#: www/views/preferencesInformation.html:47 -msgid "Derivation Strategy" -msgstr "" - -#: www/views/buyAmazon.html:39 -#: www/views/buyMercadoLibre.html:38 -#: www/views/modals/mercadolibre-card-details.html:6 -#: www/views/topup.html:45 -msgid "Details" -msgstr "" - -#: src/js/controllers/lockSetup.js:9 -#: src/js/controllers/tab-settings.js:65 -#: www/views/tab-settings.html:50 -msgid "Disabled" -msgstr "" - -#: www/views/includes/backupNeededPopup.html:10 -#: www/views/onboarding/backupRequest.html:12 -msgid "Do it later" -msgstr "" - -#: www/views/tab-export-file.html:29 -msgid "Do not include private key" -msgstr "" - -#: www/views/preferencesLanguage.html:21 -msgid "Don't see your language on Crowdin? Contact the Owner on Crowdin! We'd love to support your language." -msgstr "" - -#: www/views/tab-export-file.html:59 -#: www/views/tab-home.html:22 -msgid "Download" -msgstr "" - -#: www/views/cashScan.html:37 -msgid "Duplicate for BCH" -msgstr "" - -#: src/js/services/onGoingProcess.js:49 -msgid "Duplicating wallet..." -msgstr "" - -#: www/views/addresses.html:19 -msgid "Each bitcoin wallet can generate billions of addresses from your 12-word backup. A new address is automatically generated and shown each time you receive a payment." -msgstr "" - -#: src/js/services/feeService.js:13 -msgid "Economy" -msgstr "" - -#: www/views/onboarding/collectEmail.html:27 -msgid "Edit" -msgstr "" - -#: www/views/addressbook.add.html:29 -#: www/views/addressbook.view.html:22 -msgid "Email" -msgstr "" - -#: www/views/preferencesNotifications.html:42 -msgid "Email Address" -msgstr "" - -#: src/js/services/bwcError.js:122 -msgid "Empty addresses limit reached. New addresses cannot be generated." -msgstr "" - -#: www/views/preferencesCash.html:17 -msgid "Enable Bitcoin Cash wallet creation and operation within the App." -msgstr "" - -#: www/views/tab-scan.html:19 -msgid "Enable camera access in your device settings to get started." -msgstr "" - -#: www/views/preferencesNotifications.html:29 -msgid "Enable email notifications" -msgstr "" - -#: www/views/preferencesNotifications.html:12 -msgid "Enable push notifications" -msgstr "" - -#: www/views/preferencesNotifications.html:33 -msgid "Enable sound" -msgstr "" - -#: www/views/tab-scan.html:18 -msgid "Enable the camera to get started." -msgstr "" - -#: www/views/tab-settings.html:49 -msgid "Enabled" -msgstr "" - -#: src/js/services/walletService.js:1047 -#: src/js/services/walletService.js:1062 -msgid "Enter Spending Password" -msgstr "" - -#: src/js/services/bitpayAccountService.js:110 -msgid "Enter Two Factor for your BitPay account" -msgstr "" - -#: www/views/amount.html:4 -msgid "Enter amount" -msgstr "" - -#: www/views/modals/chooseFeeLevel.html:41 -msgid "Enter custom fee" -msgstr "" - -#: src/js/services/walletService.js:1029 -msgid "Enter new spending password" -msgstr "" - -#: www/views/join.html:79 -#: www/views/tab-create-personal.html:51 -#: www/views/tab-create-shared.html:80 -msgid "Enter the recovery phrase (BIP39)" -msgstr "" - -#: www/views/onboarding/collectEmail.html:13 -msgid "Enter your email" -msgstr "" - -#: www/views/backup.html:69 -msgid "Enter your password" -msgstr "" - -#. Trying to import a malformed wallet export QR code -#: src/js/controllers/activity.js:45 -#: src/js/controllers/addressbookAdd.js:30 -#: src/js/controllers/addressbookView.js:42 -#: src/js/controllers/addresses.js:125 -#: src/js/controllers/addresses.js:126 -#: src/js/controllers/bitpayCard.js:66 -#: src/js/controllers/bitpayCardIntro.js:40 -#: src/js/controllers/bitpayCardIntro.js:81 -#: src/js/controllers/buyAmazon.js:24 -#: src/js/controllers/buyAmazon.js:35 -#: src/js/controllers/buyMercadoLibre.js:24 -#: src/js/controllers/buyMercadoLibre.js:35 -#: src/js/controllers/confirm.js:307 -#: src/js/controllers/copayers.js:67 -#: src/js/controllers/create.js:161 -#: src/js/controllers/create.js:174 -#: src/js/controllers/create.js:180 -#: src/js/controllers/create.js:186 -#: src/js/controllers/create.js:208 -#: src/js/controllers/create.js:215 -#: src/js/controllers/create.js:233 -#: src/js/controllers/export.js:109 -#: src/js/controllers/export.js:115 -#: src/js/controllers/export.js:126 -#: src/js/controllers/export.js:154 -#: src/js/controllers/export.js:160 -#: src/js/controllers/export.js:171 -#: src/js/controllers/export.js:47 -#: src/js/controllers/export.js:53 -#: src/js/controllers/feedback/send.js:23 -#: src/js/controllers/import.js:119 -#: src/js/controllers/import.js:131 -#: src/js/controllers/import.js:149 -#: src/js/controllers/import.js:200 -#: src/js/controllers/import.js:229 -#: src/js/controllers/import.js:238 -#: src/js/controllers/import.js:254 -#: src/js/controllers/import.js:266 -#: src/js/controllers/import.js:278 -#: src/js/controllers/import.js:288 -#: src/js/controllers/import.js:312 -#: src/js/controllers/import.js:325 -#: src/js/controllers/import.js:335 -#: src/js/controllers/import.js:345 -#: src/js/controllers/import.js:369 -#: src/js/controllers/import.js:382 -#: src/js/controllers/import.js:85 -#: src/js/controllers/import.js:98 -#: src/js/controllers/join.js:125 -#: src/js/controllers/join.js:139 -#: src/js/controllers/join.js:145 -#: src/js/controllers/join.js:151 -#: src/js/controllers/join.js:174 -#: src/js/controllers/join.js:182 -#: src/js/controllers/join.js:200 -#: src/js/controllers/modals/feeLevels.js:9 -#: src/js/controllers/modals/txpDetails.js:140 -#: src/js/controllers/paperWallet.js:47 -#: src/js/controllers/preferencesBitpayCard.js:20 -#: src/js/controllers/preferencesBitpayServices.js:33 -#: src/js/controllers/preferencesBitpayServices.js:50 -#: src/js/controllers/preferencesDelete.js:36 -#: src/js/controllers/preferencesExternal.js:20 -#: src/js/controllers/tab-home.js:174 -#: src/js/controllers/tab-send.js:143 -#: src/js/controllers/tabsController.js:36 -#: src/js/controllers/tabsController.js:7 -#: src/js/controllers/topup.js:21 -#: src/js/controllers/topup.js:32 -#: src/js/controllers/tx-details.js:119 -#: src/js/services/incomingData.js:101 -#: src/js/services/incomingData.js:125 -#: src/js/services/incomingData.js:168 -#: www/views/mercadoLibreCards.html:19 -#: www/views/modals/mercadolibre-card-details.html:45 -msgid "Error" -msgstr "" - -#: src/js/controllers/confirm.js:502 -msgid "Error at confirm" -msgstr "" - -#: src/js/controllers/buyAmazon.js:179 -msgid "Error creating gift card" -msgstr "" - -#: src/js/controllers/buyAmazon.js:94 -#: src/js/controllers/buyMercadoLibre.js:94 -msgid "Error creating the invoice" -msgstr "" - -#: src/js/services/profileService.js:412 -msgid "Error creating wallet" -msgstr "" - -#: src/js/controllers/confirm.js:296 -msgid "Error getting SendMax information" -msgstr "" - -#: src/js/controllers/buyAmazon.js:136 -#: src/js/controllers/buyMercadoLibre.js:136 -#: src/js/controllers/topup.js:114 -msgid "Error in Payment Protocol" -msgstr "" - -#: src/js/controllers/bitpayCardIntro.js:14 -msgid "Error pairing BitPay Account" -msgstr "" - -#: src/js/controllers/paperWallet.js:41 -msgid "Error scanning funds:" -msgstr "" - -#: src/js/controllers/paperWallet.js:90 -msgid "Error sweeping wallet:" -msgstr "" - -#: src/js/controllers/bitpayCardIntro.js:20 -msgid "Error updating Debit Cards" -msgstr "" - -#: src/js/services/bwcError.js:143 -msgid "Exceeded daily limit of $500 per user" -msgstr "" - -#: src/js/controllers/confirm.js:461 -#: www/views/confirm.html:27 -#: www/views/mercadoLibreCards.html:25 -#: www/views/modals/mercadolibre-card-details.html:34 -#: www/views/modals/txp-details.html:119 -msgid "Expired" -msgstr "" - -#: www/views/modals/paypro.html:54 -#: www/views/modals/txp-details.html:125 -msgid "Expires" -msgstr "" - -#: www/views/preferencesAdvanced.html:21 -msgid "Export Wallet" -msgstr "" - -#: www/views/preferencesHistory.html:11 -#: www/views/preferencesHistory.html:14 -msgid "Export to file" -msgstr "" - -#: www/views/export.html:3 -msgid "Export wallet" -msgstr "" - -#: src/js/services/walletService.js:1174 -#: www/views/tab-export-qrCode.html:9 -msgid "Exporting via QR not supported for this wallet" -msgstr "" - -#: www/views/preferencesInformation.html:89 -msgid "Extended Public Keys" -msgstr "" - -#: src/js/services/onGoingProcess.js:20 -msgid "Extracting Wallet information..." -msgstr "" - -#: src/js/controllers/export.js:115 -#: src/js/controllers/export.js:126 -#: src/js/controllers/export.js:160 -#: src/js/controllers/export.js:171 -#: www/views/tab-export-file.html:4 -msgid "Failed to export" -msgstr "" - -#: www/views/tab-create-personal.html:14 -#: www/views/tab-create-shared.html:14 -msgid "Family vacation funds" -msgstr "" - -#: www/views/tx-details.html:79 -msgid "Fee" -msgstr "" - -#: www/views/modals/chooseFeeLevel.html:75 -msgid "Fee level" -msgstr "" - -#: src/js/controllers/modals/feeLevels.js:100 -msgid "Fee level is not defined" -msgstr "" - -#: www/views/confirm.html:79 -#: www/views/modals/txp-details.html:99 -msgid "Fee:" -msgstr "" - -#: src/js/controllers/feedback/send.js:23 -msgid "Feedback could not be submitted. Please try again later." -msgstr "" - -#: src/js/services/onGoingProcess.js:42 -msgid "Fetching BitPay Account..." -msgstr "" - -#: src/js/services/onGoingProcess.js:21 -msgid "Fetching payment information" -msgstr "" - -#: www/views/export.html:14 -#: www/views/import.html:16 -msgid "File/Text" -msgstr "" - -#: www/views/preferencesLogs.html:17 -msgid "Filter setting" -msgstr "" - -#: src/js/services/fingerprintService.js:43 -#: src/js/services/fingerprintService.js:48 -msgid "Finger Scan Failed" -msgstr "" - -#: src/js/controllers/feedback/send.js:34 -#: www/views/feedback/complete.html:7 -msgid "Finish" -msgstr "" - -#: www/views/tab-create-personal.html:123 -#: www/views/tab-create-shared.html:152 -msgid "For audit purposes" -msgstr "" - -#: src/js/controllers/topup.js:308 -#: www/views/buyAmazon.html:29 -#: www/views/buyMercadoLibre.html:28 -#: www/views/confirm.html:65 -#: www/views/modals/txp-details.html:74 -#: www/views/topup.html:34 -#: www/views/tx-details.html:52 -msgid "From" -msgstr "" - -#: src/js/controllers/bitpayCardIntro.js:71 -msgid "From BitPay account" -msgstr "" - -#: www/views/tab-import-phrase.html:57 -msgid "From Hardware Wallet" -msgstr "" - -#: www/views/tab-export-qrCode.html:5 -msgid "From the destination device, go to Add wallet > Import wallet and scan this QR code" -msgstr "" - -#: src/js/services/bwcError.js:74 -msgid "Funds are locked by pending spend proposals" -msgstr "" - -#: www/views/paperWallet.html:16 -msgid "Funds found:" -msgstr "" - -#: www/views/topup.html:49 -msgid "Funds to be added" -msgstr "" - -#: www/views/paperWallet.html:51 -msgid "Funds transferred" -msgstr "" - -#: www/views/topup.html:103 -msgid "Funds were added to debit card" -msgstr "" - -#: www/views/paperWallet.html:22 -msgid "Funds will be transferred to" -msgstr "" - -#: www/views/tab-receive.html:51 -msgid "Generate new address" -msgstr "" - -#: src/js/services/onGoingProcess.js:22 -msgid "Generating .csv file..." -msgstr "" - -#: src/js/services/onGoingProcess.js:37 -msgid "Generating new address..." -msgstr "" - -#: www/views/bitpayCardIntro.html:23 -msgid "Get local cash anywhere you go, from any Visa® compatible ATM. ATM bank fees may apply." -msgstr "" - -#: www/views/onboarding/collectEmail.html:15 -msgid "Get news and updates from BitPay" -msgstr "" - -#: www/views/onboarding/welcome.html:8 -msgctxt "button" -msgid "Get started" -msgstr "" - -#: www/views/bitpayCard.html:49 -msgid "Get started" -msgstr "" - -#: www/views/addressbook.html:20 -msgid "Get started by adding your first one." -msgstr "" - -#: src/js/services/onGoingProcess.js:23 -msgid "Getting fee levels..." -msgstr "" - -#: www/views/buyAmazon.html:43 -#: www/views/buyMercadoLibre.html:42 -msgid "Gift Card" -msgstr "" - -#: www/views/modals/mercadolibre-card-details.html:30 -#: www/views/modals/mercadolibre-card-details.html:35 -msgid "Gift Card is not available to use anymore" -msgstr "" - -#: src/js/controllers/buyAmazon.js:204 -msgid "Gift card expired" -msgstr "" - -#: www/views/buyAmazon.html:111 -msgid "Gift card generated and ready to use." -msgstr "" - -#: src/js/controllers/bitpayCard.js:114 -#: src/js/controllers/bitpayCard.js:124 -#: src/js/controllers/cashScan.js:20 -#: src/js/controllers/onboarding/terms.js:23 -#: src/js/controllers/preferences.js:67 -#: src/js/controllers/preferencesAbout.js:16 -#: src/js/controllers/preferencesCash.js:34 -#: src/js/controllers/preferencesLanguage.js:14 -#: src/js/controllers/tab-home.js:149 -#: src/js/controllers/tab-settings.js:53 -#: src/js/controllers/tx-details.js:193 -#: src/js/controllers/tx-details.js:56 -msgid "Go Back" -msgstr "" - -#: src/js/controllers/confirm.js:131 -#: src/js/controllers/onboarding/backupRequest.js:20 -#: src/js/controllers/onboarding/backupRequest.js:26 -#: src/js/services/bitpayAccountService.js:84 -msgid "Go back" -msgstr "" - -#: www/views/backupWarning.html:15 -#: www/views/includes/confirmBackupPopup.html:8 -#: www/views/onboarding/tour.html:23 -msgid "Got it" -msgstr "" - -#: www/views/preferencesInformation.html:53 -#: www/views/preferencesInformation.html:59 -msgid "Hardware Wallet" -msgstr "" - -#: www/views/preferencesExternal.html:18 -msgid "Hardware not connected." -msgstr "" - -#: www/views/import.html:20 -msgid "Hardware wallet" -msgstr "" - -#: src/js/controllers/create.js:180 -#: src/js/controllers/join.js:145 -msgid "Hardware wallets are not yet supported with Bitcoin Cash" -msgstr "" - -#: www/views/tab-settings.html:20 -msgid "Help & Support" -msgstr "" - -#: src/js/controllers/bitpayCard.js:112 -#: src/js/controllers/tab-settings.js:51 -msgid "Help and support information is available at the website." -msgstr "" - -#: www/views/addresses.html:25 -msgid "Hide" -msgstr "" - -#: www/views/preferences.html:27 -msgid "Hide Balance" -msgstr "" - -#: www/views/advancedSettings.html:30 -msgid "Hide Next Steps Card" -msgstr "" - -#: www/views/join.html:49 -#: www/views/tab-create-personal.html:28 -#: www/views/tab-create-shared.html:57 -#: www/views/tab-export-file.html:25 -#: www/views/tab-import-file.html:30 -#: www/views/tab-import-hardware.html:31 -#: www/views/tab-import-phrase.html:36 -msgid "Hide advanced options" -msgstr "" - -#: www/views/tabs.html:3 -msgid "Home" -msgstr "" - -#: src/js/controllers/feedback/send.js:61 -#: src/js/controllers/feedback/send.js:65 -#: src/js/controllers/feedback/send.js:69 -msgid "How could we improve your experience?" -msgstr "" - -#: www/views/feedback/rateCard.html:3 -msgid "How do you like {{appName}}?" -msgstr "" - -#: src/js/controllers/feedback/rateCard.js:29 -msgid "I don't like it" -msgstr "" - -#: www/views/onboarding/disclaimer.html:43 -msgid "I have read, understood, and agree to the Terms of Use." -msgstr "" - -#: www/views/modals/terms.html:22 -msgid "I have read, understood, and agree with the Terms of use." -msgstr "" - -#: www/views/join.html:137 -#: www/views/tab-create-personal.html:107 -#: www/views/tab-create-shared.html:136 -msgid "I have written it down" -msgstr "" - -#: src/js/controllers/feedback/rateCard.js:35 -msgid "I like the app" -msgstr "" - -#: src/js/controllers/feedback/rateCard.js:26 -msgid "I think this app is terrible." -msgstr "" - -#: src/js/controllers/onboarding/backupRequest.js:19 -#: www/views/includes/screenshotWarningModal.html:9 -msgid "I understand" -msgstr "" - -#: www/views/onboarding/disclaimer.html:21 -msgid "I understand that if this app is moved to another device or deleted, my bitcoin can only be recovered with the backup phrase." -msgstr "" - -#: www/views/onboarding/disclaimer.html:18 -msgid "I understand that my funds are held securely on this device, not by a company." -msgstr "" - -#: www/views/backup.html:36 -msgid "I've written it down" -msgstr "" - -#: www/views/preferences.html:45 -msgid "If enabled, all sensitive information (private key and recovery phrase) and actions (spending and exporting) associated with this wallet will be protected." -msgstr "" - -#: www/views/advancedSettings.html:23 -msgid "If enabled, the Recent Transactions card - a list of transactions occuring across all wallets - will appear in the Home tab." -msgstr "" - -#: www/views/advancedSettings.html:14 -msgid "If enabled, wallets will also try to spend unconfirmed funds. This option may cause transaction delays." -msgstr "" - -#: src/js/controllers/onboarding/backupRequest.js:18 -msgid "If this device is replaced or this app is deleted, neither you nor BitPay can recover your funds without a backup." -msgstr "" - -#: www/views/feedback/complete.html:23 -msgid "If you have additional feedback, please let us know by tapping the \"Send feedback\" option in the Settings tab." -msgstr "" - -#: www/views/includes/screenshotWarningModal.html:8 -msgid "If you take a screenshot, your backup may be viewed by other apps. You can make a safe backup with physical paper and a pen." -msgstr "" - -#: www/views/tab-import-hardware.html:42 -#: www/views/tab-import-phrase.html:80 -msgid "Import" -msgstr "" - -#: www/views/import.html:3 -msgid "Import Wallet" -msgstr "" - -#: www/views/tab-import-file.html:41 -msgid "Import backup" -msgstr "" - -#: www/views/add.html:38 -msgid "Import wallet" -msgstr "" - -#: src/js/services/onGoingProcess.js:24 -msgid "Importing Wallet..." -msgstr "" - -#: www/views/backup.html:72 -msgid "In order to verify your wallet backup, please type your password." -msgstr "" - -#: www/views/mercadoLibreCards.html:24 -#: www/views/modals/mercadolibre-card-details.html:29 -msgid "Inactive" -msgstr "" - -#: www/views/includes/walletItem.html:9 -#: www/views/includes/walletList.html:6 -#: www/views/includes/walletListSettings.html:9 -#: www/views/includes/walletSelector.html:16 -msgid "Incomplete" -msgstr "" - -#: www/views/tab-receive.html:22 -msgid "Incomplete wallet" -msgstr "" - -#: www/views/modals/pin.html:12 -msgid "Incorrect PIN, try again." -msgstr "" - -#. Trying to import a malformed wallet export QR code -#: src/js/controllers/import.js:85 -msgid "Incorrect code format" -msgstr "" - -#: src/js/services/bwcError.js:113 -msgid "Incorrect network address" -msgstr "" - -#: src/js/controllers/confirm.js:114 -#: src/js/controllers/confirm.js:306 -#: src/js/services/bwcError.js:44 -msgid "Insufficient confirmed funds" -msgstr "" - -#: src/js/controllers/topup.js:165 -#: src/js/controllers/topup.js:177 -#: src/js/services/bwcError.js:71 -msgid "Insufficient funds for fee" -msgstr "" - -#: www/views/tab-settings.html:123 -msgid "Integrations" -msgstr "" - -#: www/views/includes/walletHistory.html:49 -msgid "Invalid" -msgstr "" - -#: src/js/controllers/buyAmazon.js:137 -#: src/js/controllers/buyMercadoLibre.js:137 -#: src/js/controllers/topup.js:115 -msgid "Invalid URL" -msgstr "" - -#: src/js/controllers/create.js:186 -#: src/js/controllers/import.js:345 -#: src/js/controllers/join.js:151 -msgid "Invalid account number" -msgstr "" - -#: src/js/services/bwcError.js:119 -msgid "Invalid address" -msgstr "" - -#: src/js/controllers/tabsController.js:7 -msgid "Invalid data" -msgstr "" - -#: src/js/controllers/create.js:161 -#: src/js/controllers/import.js:266 -#: src/js/controllers/join.js:125 -msgid "Invalid derivation path" -msgstr "" - -#: src/js/controllers/copayers.js:90 -msgid "Invitation to share a {{appName}} Wallet" -msgstr "" - -#: www/views/mercadoLibreCards.html:20 -#: www/views/modals/mercadolibre-card-details.html:48 -msgid "Invoice expired" -msgstr "" - -#: src/js/controllers/feedback/send.js:79 -msgid "Is there anything we could do better?" -msgstr "" - -#: www/views/backup.html:54 -msgid "Is this correct?" -msgstr "" - -#: www/views/onboarding/collectEmail.html:22 -msgid "Is this email address correct?" -msgstr "" - -#: www/views/addresses.html:25 -msgid "It's a good idea to avoid reusing addresses - this both protects your privacy and keeps your bitcoins secure against hypothetical attacks by quantum computers." -msgstr "" - -#: src/js/controllers/backup.js:76 -msgid "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." -msgstr "" - -#: www/views/join.html:151 -msgid "Join" -msgstr "" - -#: src/js/controllers/copayers.js:85 -msgid "Join my {{appName}} Wallet. Here is the invitation code: {{secret}} You can download {{appName}} for your phone or desktop at {{appUrl}}" -msgstr "" - -#: www/views/add.html:30 -#: www/views/join.html:5 -msgid "Join shared wallet" -msgstr "" - -#: src/js/services/onGoingProcess.js:25 -msgid "Joining Wallet..." -msgstr "" - -#: www/views/onboarding/tour.html:22 -msgid "Just scan the code to pay." -msgstr "" - -#: src/js/services/bwcError.js:116 -msgid "Key already associated with an existing wallet" -msgstr "" - -#: www/views/preferencesLanguage.html:4 -#: www/views/tab-settings.html:68 -msgid "Language" -msgstr "" - -#: www/views/bitpayCard.html:61 -msgid "Last Month" -msgstr "" - -#: src/js/controllers/confirm.js:132 -#: www/views/preferences.html:48 -#: www/views/preferencesCash.html:18 -#: www/views/tx-details.html:94 -msgid "Learn more" -msgstr "" - -#: www/views/backup.html:43 -msgid "Let's verify your backup phrase." -msgstr "" - -#: www/views/addresses.html:45 -#: www/views/allAddresses.html:14 -msgid "Loading addresses..." -msgstr "" - -#: src/js/services/onGoingProcess.js:35 -msgid "Loading transaction info..." -msgstr "" - -#: www/views/tab-settings.html:100 -msgid "Lock App" -msgstr "" - -#: src/js/controllers/lockSetup.js:23 -msgid "Lock by Fingerprint" -msgstr "" - -#: src/js/controllers/lockSetup.js:14 -msgid "Lock by PIN" -msgstr "" - -#: www/views/modals/wallet-balance.html:80 -msgid "Locked" -msgstr "" - -#: src/js/services/bwcError.js:86 -msgid "Locktime in effect. Please wait to create a new spend proposal" -msgstr "" - -#: src/js/services/bwcError.js:89 -msgid "Locktime in effect. Please wait to remove this spend proposal" -msgstr "" - -#: www/views/includes/logOptions.html:3 -msgid "Log options" -msgstr "" - -#: www/views/modals/bitpay-card-confirmation.html:14 -msgid "Log out" -msgstr "" - -#: www/views/addresses.html:87 -msgid "Low amount inputs" -msgstr "" - -#: www/views/includes/walletHistory.html:27 -msgid "Low fees" -msgstr "" - -#: www/views/onboarding/tour.html:38 -msgid "Makes sense" -msgstr "" - -#: src/js/controllers/modals/search.js:61 -msgid "Matches:" -msgstr "" - -#: www/views/includes/copayers.html:4 -#: www/views/preferencesInformation.html:85 -msgid "Me" -msgstr "" - -#: src/js/controllers/feedback/rateCard.js:32 -msgid "Meh - it's alright" -msgstr "" - -#: src/js/controllers/tx-details.js:165 -#: www/views/modals/paypro.html:48 -#: www/views/modals/txp-details.html:93 -#: www/views/tx-details.html:72 -msgid "Memo" -msgstr "" - -#: www/views/mercadoLibre.html:6 -msgid "Mercado Livre Brazil Gift Cards" -msgstr "" - -#: src/js/controllers/buyMercadoLibre.js:98 -msgid "Mercadolibre Gift Card Service is not available at this moment. Please try back later." -msgstr "" - -#: www/views/modals/txp-details.html:131 -msgid "Merchant Message" -msgstr "" - -#: www/views/buyAmazon.html:55 -#: www/views/buyMercadoLibre.html:54 -#: www/views/topup.html:63 -msgid "Miner Fee" -msgstr "" - -#: src/js/services/bwcError.js:134 -msgid "Missing parameter" -msgstr "" - -#: src/js/services/bwcError.js:32 -msgid "Missing private keys to sign" -msgstr "" - -#: www/views/preferences.html:61 -#: www/views/preferencesAdvanced.html:3 -msgid "More Options" -msgstr "" - -#: www/views/includes/walletHistory.html:47 -#: www/views/tx-details.html:19 -msgid "Moved" -msgstr "" - -#: src/js/controllers/tx-details.js:131 -msgid "Moved Funds" -msgstr "" - -#: www/views/modals/txp-details.html:57 -msgid "Multiple recipients" -msgstr "" - -#: www/views/tab-import-phrase.html:8 -msgid "NOTE: To import a wallet from a 3rd party software, please go to Add Wallet > Create Wallet, and specify the Recovery Phrase there." -msgstr "" - -#: www/views/addressbook.add.html:21 -#: www/views/addressbook.view.html:18 -#: www/views/preferences.html:15 -#: www/views/preferencesAlias.html:17 -msgid "Name" -msgstr "" - -#: www/views/buyAmazon.html:49 -#: www/views/buyMercadoLibre.html:48 -#: www/views/topup.html:56 -msgid "Network Cost" -msgstr "" - -#: src/js/services/bwcError.js:47 -msgid "Network error" -msgstr "" - -#: www/views/includes/walletActivity.html:43 -msgid "New Proposal" -msgstr "" - -#: src/js/controllers/addresses.js:126 -msgid "New address could not be generated. Please try again." -msgstr "" - -#: www/views/add.html:14 -msgid "New personal wallet" -msgstr "" - -#: www/views/includes/nextSteps.html:3 -msgid "Next steps" -msgstr "" - -#: www/views/tab-receive.html:16 -msgid "No Wallet" -msgstr "" - -#: src/js/controllers/buyAmazon.js:115 -#: src/js/controllers/buyMercadoLibre.js:115 -msgid "No access key defined" -msgstr "" - -#: www/views/onboarding/backupRequest.html:5 -msgid "No backup, no bitcoin." -msgstr "" - -#: www/views/addressbook.html:19 -msgid "No contacts yet" -msgstr "" - -#: www/views/preferencesLogs.html:16 -msgid "No entries for this log level" -msgstr "" - -#: www/views/preferencesExternal.html:12 -msgid "No hardware information available." -msgstr "" - -#: www/views/tab-import-hardware.html:3 -msgid "No hardware wallets supported on this device" -msgstr "" - -#: www/views/proposals.html:24 -msgid "No pending proposals" -msgstr "" - -#: www/views/activity.html:25 -msgid "No recent transactions" -msgstr "" - -#: src/js/controllers/buyAmazon.js:44 -#: src/js/controllers/topup.js:47 -msgid "No signing proposal: No private key" -msgstr "" - -#: www/views/walletDetails.html:204 -msgid "No transactions yet" -msgstr "" - -#: src/js/controllers/preferencesDelete.js:15 -msgid "No wallet found" -msgstr "" - -#: src/js/controllers/preferencesDelete.js:8 -msgid "No wallet selected" -msgstr "" - -#: src/js/controllers/buyAmazon.js:300 -#: src/js/controllers/buyMercadoLibre.js:292 -#: src/js/controllers/confirm.js:85 -#: src/js/controllers/topup.js:265 -msgid "No wallets available" -msgstr "" - -#: www/views/paperWallet.html:45 -msgid "No wallets available to receive funds" -msgstr "" - -#: www/views/cashScan.html:15 -msgid "No wallets eligible for Bitcoin Cash support" -msgstr "" - -#: src/js/controllers/cashScan.js:58 -msgid "Non BIP44 wallet" -msgstr "" - -#: www/views/cashScan.html:46 -msgid "Non eligible BTC wallets" -msgstr "" - -#: src/js/services/feeService.js:12 -msgid "Normal" -msgstr "" - -#: src/js/services/bwcError.js:80 -msgid "Not authorized" -msgstr "" - -#: src/js/controllers/confirm.js:307 -msgid "Not enough funds for fee" -msgstr "" - -#: www/views/onboarding/tour.html:50 -msgid "Not even BitPay can access it." -msgstr "" - -#: src/js/controllers/paperWallet.js:47 -msgid "Not funds found" -msgstr "" - -#: www/views/feedback/rateApp.html:3 -#: www/views/onboarding/notifications.html:8 -msgid "Not now" -msgstr "" - -#: www/views/includes/output.html:15 -msgid "Note" -msgstr "" - -#: www/views/backup.html:19 -msgid "Note: if this BCH wallet was duplicated from a BTC wallet, they share the same recovery phrase." -msgstr "" - -#: www/views/modals/wallets.html:25 -msgid "Notice: only 1-1 (single signature) wallets can be used for sell bitcoin" -msgstr "" - -#: www/views/preferencesNotifications.html:3 -#: www/views/tab-settings.html:61 -msgid "Notifications" -msgstr "" - -#: www/views/onboarding/collectEmail.html:9 -msgid "Notifications by email" -msgstr "" - -#: www/views/tx-details.html:117 -msgid "Notify me if confirmed" -msgstr "" - -#: www/views/preferencesNotifications.html:24 -msgid "Notify me when transactions are confirmed" -msgstr "" - -#: www/views/includes/backupNeededPopup.html:8 -msgid "Now is a good time to backup your wallet. If this device is lost, it is impossible to access your funds without a backup." -msgstr "" - -#: www/views/backupWarning.html:11 -msgid "Now is a perfect time to assess your surroundings. Nearby windows? Hidden cameras? Shoulder-spies?" -msgstr "" - -#: src/js/controllers/buyAmazon.js:312 -#: src/js/controllers/topup.js:286 -#: src/js/services/incomingData.js:153 -#: src/js/services/popupService.js:16 -#: src/js/services/popupService.js:52 -#: src/js/services/popupService.js:61 -#: src/js/services/popupService.js:72 -#: www/views/modals/chooseFeeLevel.html:6 -msgid "OK" -msgstr "" - -#: www/views/modals/tx-status.html:12 -#: www/views/modals/tx-status.html:24 -#: www/views/modals/tx-status.html:36 -#: www/views/modals/tx-status.html:46 -msgid "OKAY" -msgstr "" - -#: www/views/modals/terms.html:15 -msgid "Official English Disclaimer" -msgstr "" - -#: src/js/controllers/feedback/send.js:64 -msgid "Oh no!" -msgstr "" - -#: src/js/controllers/buyMercadoLibre.js:306 -msgid "Ok" -msgstr "" - -#: www/views/tab-home.html:39 -msgid "On this screen you can see all your wallets, accounts, and assets." -msgstr "" - -#: src/js/controllers/bitpayCard.js:113 -#: src/js/controllers/cashScan.js:19 -#: src/js/controllers/preferences.js:66 -#: src/js/controllers/preferencesCash.js:33 -#: src/js/controllers/tab-settings.js:52 -#: src/js/controllers/tx-details.js:55 -msgid "Open" -msgstr "" - -#: src/js/controllers/preferencesLanguage.js:13 -msgid "Open Crowdin" -msgstr "" - -#: src/js/controllers/preferencesAbout.js:15 -msgid "Open GitHub" -msgstr "" - -#: src/js/controllers/preferencesAbout.js:13 -msgid "Open GitHub Project" -msgstr "" - -#: src/js/controllers/bitpayCard.js:123 -#: src/js/controllers/tx-details.js:192 -msgid "Open Explorer" -msgstr "" - -#: www/views/tab-scan.html:22 -msgid "Open Settings" -msgstr "" - -#: src/js/controllers/preferencesLanguage.js:11 -msgid "Open Translation Community" -msgstr "" - -#: src/js/controllers/onboarding/terms.js:22 -msgid "Open Website" -msgstr "" - -#: src/js/controllers/preferencesCash.js:32 -msgid "Open bitcoincash.org?" -msgstr "" - -#: src/js/controllers/cashScan.js:18 -msgid "Open the recovery tool." -msgstr "" - -#: www/views/tab-receive.html:27 -msgid "Open wallet" -msgstr "" - -#: www/views/includes/incomingDataMenu.html:19 -msgid "Open website" -msgstr "" - -#: www/views/bitpayCardIntro.html:34 -msgid "Order the BitPay Card" -msgstr "" - -#: www/views/join.html:105 -#: www/views/join.html:96 -#: www/views/tab-create-personal.html:69 -#: www/views/tab-create-personal.html:77 -#: www/views/tab-create-shared.html:106 -#: www/views/tab-create-shared.html:98 -#: www/views/tab-import-file.html:18 -#: www/views/tab-import-phrase.html:41 -msgid "Password" -msgstr "" - -#: src/js/controllers/import.js:98 -msgid "Password required. Make sure to enter your password in advanced options" -msgstr "" - -#: www/views/join.html:33 -msgid "Paste invitation here" -msgstr "" - -#: www/views/tab-import-file.html:13 -msgid "Paste the backup plain text code" -msgstr "" - -#: www/views/bitpayCardIntro.html:28 -msgid "Pay 0% fees to turn bitcoin into dollars." -msgstr "" - -#: www/views/modals/paypro.html:18 -msgid "Pay To" -msgstr "" - -#: src/js/controllers/modals/txpDetails.js:51 -#: www/views/modals/tx-status.html:33 -msgid "Payment Accepted" -msgstr "" - -#: www/views/confirm.html:25 -msgid "Payment Expires:" -msgstr "" - -#: www/views/modals/txp-details.html:6 -msgid "Payment Proposal" -msgstr "" - -#: www/views/modals/tx-status.html:21 -msgid "Payment Proposal Created" -msgstr "" - -#: www/views/tab-home.html:46 -msgid "Payment Proposals" -msgstr "" - -#: src/js/services/payproService.js:32 -msgid "Payment Protocol Invalid" -msgstr "" - -#: src/js/services/payproService.js:18 -msgid "Payment Protocol not supported on Chrome App" -msgstr "" - -#: www/views/includes/walletActivity.html:20 -msgid "Payment Received" -msgstr "" - -#: www/views/modals/tx-status.html:43 -#: www/views/modals/txp-details.html:43 -msgid "Payment Rejected" -msgstr "" - -#: src/js/controllers/modals/txpDetails.js:44 -#: www/views/confirm.html:124 -#: www/views/includes/walletActivity.html:11 -#: www/views/modals/txp-details.html:42 -msgid "Payment Sent" -msgstr "" - -#: www/views/modals/txp-details.html:32 -msgid "Payment accepted, but not yet broadcasted" -msgstr "" - -#: www/views/modals/txp-details.html:40 -msgid "Payment accepted. It will be broadcasted by Glidera. In case there is a problem, it can be deleted 6 hours after it was created." -msgstr "" - -#: src/js/services/incomingData.js:152 -msgid "Payment address was translated to new Bitcoin Cash address format:" -msgstr "" - -#: www/views/modals/txp-details.html:107 -msgid "Payment details" -msgstr "" - -#: www/views/modals/paypro.html:6 -msgid "Payment request" -msgstr "" - -#: www/views/mercadoLibreCards.html:22 -#: www/views/modals/mercadolibre-card-details.html:39 -msgid "Pending" -msgstr "" - -#: www/views/proposals.html:4 -msgid "Pending Proposals" -msgstr "" - -#: www/views/preferencesDeleteWallet.html:13 -msgid "Permanently delete this wallet." -msgstr "" - -#: src/js/services/profileService.js:403 -msgid "Personal Wallet" -msgstr "" - -#: www/views/backup.html:25 -msgid "Please carefully write down this phrase." -msgstr "" - -#: www/views/tab-scan.html:20 -msgid "Please connect a camera to get started." -msgstr "" - -#: src/js/controllers/import.js:278 -msgid "Please enter the recovery phrase" -msgstr "" - -#: src/js/controllers/create.js:174 -#: src/js/controllers/join.js:139 -msgid "Please enter the wallet recovery phrase" -msgstr "" - -#: www/views/modals/pin.html:9 -msgid "Please enter your PIN" -msgstr "" - -#: www/views/backup.html:53 -msgid "Please tap each word in the correct order." -msgstr "" - -#: src/js/services/bwcError.js:101 -msgid "Please upgrade Copay to perform this action" -msgstr "" - -#: www/views/walletDetails.html:142 -#: www/views/walletDetails.html:62 -msgid "Please wait" -msgstr "" - -#: src/js/controllers/import.js:238 -msgid "Please, select your backup file" -msgstr "" - -#: www/views/bitpayCard.html:81 -msgid "Pre-Auth Holds" -msgstr "" - -#: www/views/tab-settings.html:40 -msgid "Preferences" -msgstr "" - -#: src/js/services/onGoingProcess.js:38 -msgid "Preparing addresses..." -msgstr "" - -#: src/js/controllers/export.js:198 -msgid "Preparing backup..." -msgstr "" - -#: src/js/routes.js:1264 -msgid "Press again to exit" -msgstr "" - -#: src/js/services/feeService.js:11 -msgid "Priority" -msgstr "" - -#: www/views/includes/incomingDataMenu.html:80 -msgid "Private Key" -msgstr "" - -#: src/js/controllers/paperWallet.js:136 -msgid "Private key encrypted. Enter password" -msgstr "" - -#: src/js/services/bwcError.js:35 -msgid "Private key is encrypted, cannot sign" -msgstr "" - -#: www/views/includes/walletActivity.html:51 -msgid "Proposal Accepted" -msgstr "" - -#: src/js/controllers/modals/txpDetails.js:61 -#: src/js/controllers/tx-details.js:78 -#: www/views/confirm.html:125 -msgid "Proposal Created" -msgstr "" - -#: www/views/includes/walletActivity.html:27 -msgid "Proposal Deleted" -msgstr "" - -#: www/views/includes/walletActivity.html:35 -msgid "Proposal Rejected" -msgstr "" - -#: www/views/walletDetails.html:189 -msgid "Proposals" -msgstr "" - -#: src/js/controllers/buyAmazon.js:282 -msgid "Purchase Amount is limited to {{limitPerDay}} {{currency}} per day" -msgstr "" - -#: src/js/controllers/buyMercadoLibre.js:281 -msgid "Purchase amount must be a value between 50 and 2000" -msgstr "" - -#: www/views/onboarding/notifications.html:3 -msgid "Push Notifications" -msgstr "" - -#: www/views/preferencesNotifications.html:17 -msgid "Push notifications for {{appName}} are currently disabled. Enable them in the Settings app." -msgstr "" - -#: www/views/export.html:17 -msgid "QR Code" -msgstr "" - -#: www/views/onboarding/disclaimer.html:13 -msgid "Quick review!" -msgstr "" - -#: src/js/controllers/create.js:84 -#: src/js/controllers/join.js:68 -msgid "Random" -msgstr "" - -#: www/views/feedback/rateApp.html:14 -msgid "Rate on the app store" -msgstr "" - -#: www/views/addresses.html:52 -msgid "Read less" -msgstr "" - -#: www/views/addresses.html:51 -msgid "Read more" -msgstr "" - -#: src/js/controllers/preferences.js:65 -#: src/js/controllers/tx-details.js:54 -msgid "Read more in our Wiki" -msgstr "" - -#: src/js/controllers/cashScan.js:61 -msgid "Read only wallet" -msgstr "" - -#: www/views/tab-receive.html:3 -#: www/views/tabs.html:7 -msgid "Receive" -msgstr "" - -#: www/views/customAmount.html:44 -msgid "Receive in" -msgstr "" - -#: www/views/includes/walletHistory.html:24 -#: www/views/tx-details.html:18 -msgid "Received" -msgstr "" - -#: src/js/controllers/tx-details.js:130 -msgid "Received Funds" -msgstr "" - -#: www/views/includes/walletHistory.html:57 -#: www/views/tx-details.html:24 -msgid "Receiving" -msgstr "" - -#: www/views/bitpayCard.html:60 -#: www/views/includes/walletHistory.html:3 -msgid "Recent" -msgstr "" - -#: www/views/advancedSettings.html:21 -msgid "Recent Transaction Card" -msgstr "" - -#: www/views/activity.html:4 -#: www/views/tab-home.html:58 -msgid "Recent Transactions" -msgstr "" - -#: www/views/amount.html:18 -#: www/views/tab-send.html:9 -msgid "Recipient" -msgstr "" - -#: www/views/modals/txp-details.html:62 -msgid "Recipients" -msgstr "" - -#: www/views/import.html:12 -msgid "Recovery phrase" -msgstr "" - -#: src/js/services/onGoingProcess.js:26 -msgid "Recreating Wallet..." -msgstr "" - -#: www/views/modals/mercadolibre-card-details.html:22 -msgid "Redeem now" -msgstr "" - -#: src/js/controllers/modals/txpDetails.js:63 -#: src/js/controllers/tx-details.js:80 -msgid "Rejected" -msgstr "" - -#: src/js/services/onGoingProcess.js:27 -msgid "Rejecting payment proposal" -msgstr "" - -#: www/views/preferencesAbout.html:9 -msgid "Release information" -msgstr "" - -#: www/views/addressbook.view.html:36 -#: www/views/modals/mercadolibre-card-details.html:69 -msgid "Remove" -msgstr "" - -#: src/js/controllers/preferencesBitpayServices.js:7 -msgid "Remove BitPay Account?" -msgstr "" - -#: src/js/controllers/preferencesBitpayServices.js:19 -msgid "Remove BitPay Card?" -msgstr "" - -#: src/js/controllers/preferencesBitpayServices.js:8 -msgid "Removing your BitPay account will remove all associated BitPay account data from this device. Are you sure you would like to remove your BitPay Account ({{email}}) from this device?" -msgstr "" - -#: www/views/join.html:116 -#: www/views/join.html:124 -#: www/views/tab-create-personal.html:86 -#: www/views/tab-create-personal.html:94 -#: www/views/tab-create-shared.html:115 -#: www/views/tab-create-shared.html:123 -#: www/views/tab-export-file.html:17 -msgid "Repeat password" -msgstr "" - -#: www/views/tab-export-file.html:16 -msgid "Repeat the password" -msgstr "" - -#: www/views/preferences.html:56 -msgid "Request Fingerprint" -msgstr "" - -#: www/views/tab-receive.html:45 -msgid "Request Specific amount" -msgstr "" - -#: www/views/preferences.html:42 -msgid "Request Spending Password" -msgstr "" - -#: www/views/tab-create-shared.html:44 -msgid "Required number of signatures" -msgstr "" - -#: www/views/onboarding/welcome.html:9 -msgid "Restore from backup" -msgstr "" - -#: src/js/services/onGoingProcess.js:29 -msgid "Retrieving inputs information" -msgstr "" - -#: src/js/controllers/onboarding/tour.js:56 -msgid "Retry" -msgstr "" - -#: www/views/tab-scan.html:23 -msgid "Retry Camera" -msgstr "" - -#: www/views/addressbook.add.html:56 -#: www/views/includes/note.html:9 -#: www/views/preferencesAlias.html:21 -#: www/views/preferencesBwsUrl.html:25 -#: www/views/preferencesNotifications.html:46 -msgid "Save" -msgstr "" - -#: www/views/tab-scan.html:3 -#: www/views/tabs.html:11 -msgid "Scan" -msgstr "" - -#: www/views/tab-scan.html:15 -msgid "Scan QR Codes" -msgstr "" - -#: www/views/addresses.html:31 -msgid "Scan addresses for funds" -msgstr "" - -#: www/views/modals/fingerprintCheck.html:11 -msgid "Scan again" -msgstr "" - -#: src/js/services/fingerprintService.js:56 -msgid "Scan your fingerprint please" -msgstr "" - -#: www/views/preferencesCash.html:23 -msgid "Scan your wallets for Bitcoin Cash" -msgstr "" - -#: src/js/services/onGoingProcess.js:30 -msgid "Scanning Wallet funds..." -msgstr "" - -#: www/views/includes/walletList.html:11 -msgid "Scanning funds..." -msgstr "" - -#: www/views/includes/screenshotWarningModal.html:7 -msgid "Screenshots are not secure" -msgstr "" - -#: www/views/modals/search.html:6 -msgid "Search Transactions" -msgstr "" - -#: www/views/tab-send.html:13 -msgid "Search or enter bitcoin address" -msgstr "" - -#: www/views/modals/search.html:16 -msgid "Search transactions" -msgstr "" - -#: www/views/preferencesAltCurrency.html:14 -msgid "Search your currency" -msgstr "" - -#: www/views/preferences.html:30 -msgid "Security" -msgstr "" - -#: www/views/modals/mercadolibre-card-details.html:64 -msgid "See invoice" -msgstr "" - -#: www/views/tab-import-file.html:7 -msgid "Select a backup file" -msgstr "" - -#: src/js/controllers/tab-receive.js:139 -msgid "Select a wallet" -msgstr "" - -#: www/views/modals/paypro.html:38 -msgid "Self-signed Certificate" -msgstr "" - -#: src/js/services/onGoingProcess.js:41 -msgid "Selling Bitcoin..." -msgstr "" - -#: www/views/feedback/send.html:13 -#: www/views/feedback/send.html:43 -#: www/views/tab-send.html:3 -#: www/views/tabs.html:15 -msgid "Send" -msgstr "" - -#: www/views/feedback/send.html:3 -#: www/views/tab-settings.html:29 -msgid "Send Feedback" -msgstr "" - -#: www/views/addressbook.view.html:31 -msgid "Send Money" -msgstr "" - -#: www/views/allAddresses.html:19 -msgid "Send addresses by email" -msgstr "" - -#: www/views/includes/logOptions.html:17 -#: www/views/tab-export-file.html:82 -msgid "Send by email" -msgstr "" - -#: src/js/controllers/confirm.js:177 -msgid "Send from" -msgstr "" - -#: www/views/includes/itemSelector.html:8 -msgid "Send max amount" -msgstr "" - -#: www/views/includes/incomingDataMenu.html:46 -msgid "Send payment to this address" -msgstr "" - -#: www/views/feedback/rateApp.html:17 -msgid "Send us feedback instead" -msgstr "" - -#: www/views/confirm.html:15 -#: www/views/includes/txp.html:12 -#: www/views/modals/txp-details.html:19 -#: www/views/tx-details.html:23 -msgid "Sending" -msgstr "" - -#: src/js/services/onGoingProcess.js:39 -msgid "Sending 2FA code..." -msgstr "" - -#: src/js/services/onGoingProcess.js:36 -msgid "Sending feedback..." -msgstr "" - -#: www/views/confirm.html:16 -msgid "Sending maximum amount" -msgstr "" - -#: src/js/services/onGoingProcess.js:31 -msgid "Sending transaction" -msgstr "" - -#: src/js/controllers/confirm.js:545 -msgid "Sending {{amountStr}} from your {{name}} wallet" -msgstr "" - -#: www/views/includes/walletHistory.html:42 -#: www/views/modals/tx-status.html:9 -#: www/views/topup.html:100 -#: www/views/tx-details.html:17 -msgid "Sent" -msgstr "" - -#: src/js/controllers/tx-details.js:129 -msgid "Sent Funds" -msgstr "" - -#: src/js/services/bwcError.js:38 -msgid "Server response could not be verified" -msgstr "" - -#: src/js/controllers/buyAmazon.js:97 -#: src/js/controllers/buyMercadoLibre.js:97 -msgid "Service not available" -msgstr "" - -#: www/views/includes/homeIntegrations.html:3 -msgid "Services" -msgstr "" - -#: www/views/preferencesLogs.html:3 -msgid "Session Log" -msgstr "" - -#: www/views/preferencesAbout.html:35 -msgid "Session log" -msgstr "" - -#: www/views/tab-export-file.html:10 -msgid "Set up a password" -msgstr "" - -#: src/js/controllers/preferencesFee.js:85 -msgid "Set your own fee in satoshis/byte" -msgstr "" - -#: www/views/tab-settings.html:3 -#: www/views/tabs.html:19 -msgid "Settings" -msgstr "" - -#: www/views/feedback/complete.html:17 -#: www/views/feedback/complete.html:26 -msgid "Share the love by inviting your friends." -msgstr "" - -#: www/views/copayers.html:20 -msgid "Share this invitation with your copayers" -msgstr "" - -#: src/js/controllers/feedback/complete.js:5 -#: www/views/tab-settings.html:36 -msgid "Share {{appName}}" -msgstr "" - -#: www/views/tab-import-hardware.html:24 -msgid "Shared Wallet" -msgstr "" - -#: www/views/preferencesExternal.html:34 -msgid "Show Recovery Phrase" -msgstr "" - -#: www/views/tab-receive.html:34 -msgid "Show address" -msgstr "" - -#: www/views/join.html:48 -#: www/views/tab-create-personal.html:27 -#: www/views/tab-create-shared.html:56 -#: www/views/tab-export-file.html:24 -#: www/views/tab-import-file.html:29 -#: www/views/tab-import-hardware.html:30 -#: www/views/tab-import-phrase.html:35 -msgid "Show advanced options" -msgstr "" - -#: www/views/tab-send.html:37 -msgid "Show bitcoin address" -msgstr "" - -#: www/views/tab-send.html:59 -msgid "Show more" -msgstr "" - -#: src/js/services/bwcError.js:104 -msgid "Signatures rejected by server" -msgstr "" - -#: src/js/services/onGoingProcess.js:32 -msgid "Signing transaction" -msgstr "" - -#: www/views/onboarding/backupRequest.html:6 -msgid "Since only you control your money, you’ll need to save your backup phrase in case this app is deleted." -msgstr "" - -#: www/views/tab-create-personal.html:122 -#: www/views/tab-create-shared.html:151 -msgid "Single Address Wallet" -msgstr "" - -#: www/views/onboarding/collectEmail.html:40 -#: www/views/onboarding/tour.html:11 -msgid "Skip" -msgstr "" - -#: src/js/controllers/confirm.js:371 -#: src/js/controllers/modals/txpDetails.js:47 -msgid "Slide to accept" -msgstr "" - -#: www/views/buyAmazon.html:96 -msgid "Slide to buy" -msgstr "" - -#: src/js/controllers/confirm.js:365 -msgid "Slide to pay" -msgstr "" - -#: src/js/controllers/confirm.js:377 -#: src/js/controllers/modals/txpDetails.js:40 -msgid "Slide to send" -msgstr "" - -#: www/views/cashScan.html:56 -msgid "Some of your wallets are not eligible for Bitcoin Cash support. You can try to access BCH funds from these wallets using the" -msgstr "" - -#: src/js/controllers/create.js:88 -#: src/js/controllers/join.js:71 -msgid "Specify Recovery Phrase..." -msgstr "" - -#: src/js/services/bwcError.js:92 -msgid "Spend proposal is not accepted" -msgstr "" - -#: src/js/services/bwcError.js:95 -msgid "Spend proposal not found" -msgstr "" - -#: src/js/services/bwcError.js:137 -msgid "Spending Password needed" -msgstr "" - -#: www/views/walletDetails.html:173 -msgid "Spending this balance will need significant Bitcoin network fees" -msgstr "" - -#: www/views/tab-send.html:28 -msgid "Start sending bitcoin" -msgstr "" - -#: www/views/lockSetup.html:3 -msgid "Startup Lock" -msgstr "" - -#: www/views/mercadoLibreCards.html:21 -#: www/views/modals/mercadolibre-card-details.html:42 -msgid "Still pending" -msgstr "" - -#: www/views/topup.html:101 -msgid "Success" -msgstr "" - -#: src/js/services/feeService.js:14 -msgid "Super Economy" -msgstr "" - -#: www/views/preferencesCash.html:11 -msgid "Support Bitcoin Cash" -msgstr "" - -#: www/views/paperWallet.html:7 -msgid "Sweep" -msgstr "" - -#: www/views/includes/incomingDataMenu.html:89 -#: www/views/paperWallet.html:3 -msgid "Sweep paper wallet" -msgstr "" - -#: src/js/services/onGoingProcess.js:33 -msgid "Sweeping Wallet..." -msgstr "" - -#: www/views/preferencesDeleteWallet.html:16 -msgid "THIS ACTION CANNOT BE REVERSED" -msgstr "" - -#: www/views/onboarding/welcome.html:5 -msgid "Take control of your money,
get started with bitcoin." -msgstr "" - -#: www/views/walletDetails.html:132 -#: www/views/walletDetails.html:52 -msgid "Tap and hold to show" -msgstr "" - -#: www/views/includes/walletInfo.html:3 -msgid "Tap to recreate" -msgstr "" - -#: www/views/includes/walletInfo.html:4 -msgid "Tap to retry" -msgstr "" - -#: www/views/termsOfUse.html:3 -msgid "Terms Of Use" -msgstr "" - -#: www/views/modals/terms.html:3 -#: www/views/onboarding/disclaimer.html:29 -#: www/views/onboarding/disclaimer.html:43 -#: www/views/preferencesAbout.html:30 -msgid "Terms of Use" -msgstr "" - -#: www/views/tab-create-personal.html:118 -#: www/views/tab-import-phrase.html:68 -msgid "Testnet" -msgstr "" - -#: www/views/includes/incomingDataMenu.html:61 -msgid "Text" -msgstr "" - -#: src/js/controllers/feedback/send.js:27 -#: src/js/controllers/feedback/send.js:76 -#: www/views/feedback/complete.html:20 -#: www/views/feedback/rateApp.html:4 -msgid "Thank you!" -msgstr "" - -#: src/js/controllers/feedback/send.js:72 -msgid "Thanks!" -msgstr "" - -#: src/js/controllers/feedback/send.js:73 -msgid "That's exciting to hear. We'd love to earn that fifth star from you – how could we improve your experience?" -msgstr "" - -#: src/js/services/ledger.js:152 -msgid "The Ledger Chrome application is not installed" -msgstr "" - -#: www/views/modals/wallet-balance.html:55 -msgid "The amount of bitcoin immediately spendable from this wallet." -msgstr "" - -#: www/views/modals/wallet-balance.html:93 -msgid "The amount of bitcoin stored in this wallet that is allocated as inputs to your pending transaction proposals. The amount is determined using unspent transaction outputs associated with this wallet and may be more than the actual amounts associated with your pending transaction proposals." -msgstr "" - -#: www/views/modals/wallet-balance.html:74 -msgid "The amount of bitcoin stored in this wallet with less than 1 blockchain confirmation." -msgstr "" - -#: www/views/tab-import-phrase.html:5 -msgid "The derivation path" -msgstr "" - -#: www/views/onboarding/tour.html:37 -msgid "The exchange rate changes with the market." -msgstr "" - -#: www/views/preferencesFee.html:12 -msgid "The higher the fee, the greater the incentive a miner has to include that transaction in a block. Current fees are determined based on network load and the selected policy." -msgstr "" - -#: www/views/addresses.html:51 -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." -msgstr "" - -#: www/views/tab-import-phrase.html:4 -msgid "The password of the recovery phrase (if set)" -msgstr "" - -#: src/js/services/walletService.js:1139 -msgid "The payment was created but could not be completed. Please try again from home screen" -msgstr "" - -#: www/views/modals/txp-details.html:26 -msgid "The payment was removed by creator" -msgstr "" - -#: www/views/join.html:91 -#: www/views/tab-create-personal.html:63 -#: www/views/tab-create-shared.html:92 -#: www/views/tab-import-phrase.html:43 -msgid "The recovery phrase could require a password to be imported" -msgstr "" - -#: src/js/services/bwcError.js:56 -msgid "The request could not be understood by the server" -msgstr "" - -#: www/views/addresses.html:52 -msgid "The restore process will stop when 20 addresses are generated in a row which contain no funds. To safely generate more addresses, make a payment to one of the unused addresses which has already been generated." -msgstr "" - -#: src/js/services/bwcError.js:98 -msgid "The spend proposal is not pending" -msgstr "" - -#: www/views/modals/wallet-balance.html:36 -msgid "The total amount of bitcoin stored in this wallet." -msgstr "" - -#: www/views/preferencesHistory.html:27 -msgid "The transaction history and every new incoming transaction are cached in the app. This feature clean this up and synchronizes again from the server" -msgstr "" - -#: www/views/tab-import-phrase.html:6 -msgid "The wallet service URL" -msgstr "" - -#: src/js/controllers/tab-home.js:38 -msgid "There is a new version of {{appName}} available" -msgstr "" - -#: src/js/controllers/import.js:229 -#: src/js/controllers/import.js:254 -#: src/js/controllers/import.js:335 -msgid "There is an error in the form" -msgstr "" - -#: src/js/controllers/feedback/send.js:61 -#: src/js/controllers/feedback/send.js:65 -msgid "There's obviously something we're doing wrong." -msgstr "" - -#: src/js/controllers/feedback/rateCard.js:38 -msgid "This app is fantastic!" -msgstr "" - -#: www/views/onboarding/tour.html:47 -msgid "This app stores your bitcoin with cutting-edge security." -msgstr "" - -#: src/js/controllers/confirm.js:523 -msgid "This bitcoin payment request has expired." -msgstr "" - -#: www/views/join.html:133 -#: www/views/tab-create-personal.html:103 -#: www/views/tab-create-shared.html:132 -msgid "This password cannot be recovered. If the password is lost, there is no way you could recover your funds." -msgstr "" - -#: www/views/backup.html:31 -msgid "This recovery phrase was created with a password. To recover this wallet both the recovery phrase and password are needed." -msgstr "" - -#: www/views/tx-details.html:91 -msgid "This transaction amount is too small compared to current Bitcoin network fees. Spending these funds will need a Bitcoin network fee cost comparable to the funds itself." -msgstr "" - -#: www/views/tx-details.html:87 -msgid "This transaction could take a long time to confirm or could be dropped due to the low fees set by the sender" -msgstr "" - -#: www/views/walletDetails.html:109 -#: www/views/walletDetails.html:29 -msgid "This wallet is not registered at the given Bitcore Wallet Service (BWS). You can recreate it from the local information." -msgstr "" - -#: www/views/modals/txp-details.html:136 -#: www/views/tx-details.html:121 -msgid "Timeline" -msgstr "" - -#: www/views/confirm.html:31 -#: www/views/includes/output.html:2 -#: www/views/modals/txp-details.html:109 -#: www/views/modals/txp-details.html:53 -#: www/views/tx-details.html:41 -#: www/views/tx-details.html:53 -msgid "To" -msgstr "" - -#: www/views/tab-send.html:32 -msgid "To get started, buy bitcoin or share your address. You can receive bitcoin from any wallet or service." -msgstr "" - -#: www/views/tab-send.html:33 -msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." -msgstr "" - -#: src/js/services/bitpayAccountService.js:73 -msgid "To {{reason}} you must first add your BitPay account - {{email}}" -msgstr "" - -#: src/js/services/onGoingProcess.js:48 -msgid "Top up in progress..." -msgstr "" - -#: src/js/controllers/topup.js:206 -msgid "Top up {{amountStr}} to debit card ({{cardLastNumber}})" -msgstr "" - -#: www/views/buyAmazon.html:61 -#: www/views/buyMercadoLibre.html:60 -#: www/views/modals/wallet-balance.html:23 -#: www/views/topup.html:70 -msgid "Total" -msgstr "" - -#: www/views/walletDetails.html:196 -msgid "Total Locked Balance" -msgstr "" - -#: www/views/tab-create-shared.html:35 -msgid "Total number of copayers" -msgstr "" - -#: www/views/addresses.html:81 -msgid "Total wallet inputs" -msgstr "" - -#: src/js/services/fingerprintService.js:63 -#: src/js/services/fingerprintService.js:68 -msgid "Touch ID Failed" -msgstr "" - -#: src/js/controllers/tx-details.js:12 -msgid "Transaction" -msgstr "" - -#: www/views/confirm.html:126 -msgid "Transaction Created" -msgstr "" - -#: www/views/preferencesAdvanced.html:29 -#: www/views/preferencesHistory.html:3 -msgid "Transaction History" -msgstr "" - -#: src/js/services/bwcError.js:83 -msgid "Transaction already broadcasted" -msgstr "" - -#: src/js/controllers/buyAmazon.js:308 -#: src/js/controllers/buyMercadoLibre.js:301 -#: src/js/controllers/topup.js:281 -msgid "Transaction has not been created" -msgstr "" - -#: www/views/topup.html:104 -msgid "Transaction initiated" -msgstr "" - -#: src/js/controllers/tx-details.js:119 -msgid "Transaction not available at this time" -msgstr "" - -#: src/js/controllers/activity.js:45 -#: src/js/controllers/tab-home.js:174 -msgid "Transaction not found" -msgstr "" - -#: www/views/modals/chooseFeeLevel.html:55 -msgid "Transactions without fee are not supported." -msgstr "" - -#: src/js/controllers/paperWallet.js:109 -msgid "Transfer to" -msgstr "" - -#: www/views/tab-send.html:67 -msgid "Transfer to Wallet" -msgstr "" - -#: www/views/modals/pin.html:13 -msgid "Try again in {{expires}}" -msgstr "" - -#: www/views/bitpayCardIntro.html:18 -msgid "Turn bitcoin into dollars, swipe anywhere Visa® is accepted." -msgstr "" - -#: www/views/tab-import-phrase.html:17 -msgid "Type the Recovery Phrase (usually 12 words)" -msgstr "" - -#: src/js/controllers/backup.js:75 -msgid "Uh oh..." -msgstr "" - -#: www/views/tx-details.html:100 -msgid "Unconfirmed" -msgstr "" - -#: www/views/walletDetails.html:190 -msgid "Unsent transactions" -msgstr "" - -#: www/views/addresses.html:39 -msgid "Unused Addresses" -msgstr "" - -#: www/views/addresses.html:50 -msgid "Unused Addresses Limit" -msgstr "" - -#: src/js/controllers/tab-home.js:146 -msgid "Update Available" -msgstr "" - -#: www/views/proposals.html:14 -msgid "Updating pending proposals. Please stand by" -msgstr "" - -#: www/views/walletDetails.html:217 -msgid "Updating transaction history. Please stand by." -msgstr "" - -#: www/views/activity.html:14 -msgid "Updating... Please stand by" -msgstr "" - -#: src/js/services/feeService.js:10 -msgid "Urgent" -msgstr "" - -#: www/views/advancedSettings.html:12 -msgid "Use Unconfirmed Funds" -msgstr "" - -#: src/js/services/onGoingProcess.js:34 -msgid "Validating recovery phrase..." -msgstr "" - -#: www/views/modals/fingerprintCheck.html:4 -msgid "Verify your identity" -msgstr "" - -#: www/views/preferencesAbout.html:14 -#: www/views/preferencesExternal.html:25 -msgid "Version" -msgstr "" - -#: www/views/tab-export-file.html:69 -msgid "View" -msgstr "" - -#: www/views/addresses.html:34 -msgid "View All Addresses" -msgstr "" - -#: src/js/controllers/onboarding/terms.js:20 -msgid "View Terms of Service" -msgstr "" - -#: src/js/controllers/bitpayCard.js:122 -#: src/js/controllers/tx-details.js:191 -msgid "View Transaction on Explorer.Bitcoin.com" -msgstr "" - -#: src/js/controllers/tab-home.js:148 -msgid "View Update" -msgstr "" - -#: www/views/tx-details.html:147 -msgid "View on blockchain" -msgstr "" - -#: www/views/mercadoLibre.html:26 -msgid "Visit mercadolivre.com.br →" -msgstr "" - -#: www/views/walletDetails.html:182 -msgid "WARNING: Key derivation is not working on this device/wallet. Actions cannot be performed on this wallet." -msgstr "" - -#: www/views/tab-export-file.html:45 -msgid "WARNING: Not including the private key allows to check the wallet balance, transaction history, and create spend proposals from the export. However, does not allow to approve (sign) proposals, so funds will not be accessible from the export." -msgstr "" - -#: www/views/tab-export-file.html:36 -msgid "WARNING: The private key of this wallet is not available. The export allows to check the wallet balance, transaction history, and create spend proposals from the export. However, does not allow to approve (sign) proposals, so funds will not be accessible from the export." -msgstr "" - -#: www/views/modals/paypro.html:42 -msgid "WARNING: UNTRUSTED CERTIFICATE" -msgstr "" - -#: src/js/services/onGoingProcess.js:15 -msgid "Waiting for Ledger..." -msgstr "" - -#: src/js/services/onGoingProcess.js:16 -msgid "Waiting for Trezor..." -msgstr "" - -#: www/views/copayers.html:48 -msgid "Waiting for copayers" -msgstr "" - -#: www/views/copayers.html:53 -msgid "Waiting..." -msgstr "" - -#: www/views/addresses.html:3 -#: www/views/preferencesAdvanced.html:17 -msgid "Wallet Addresses" -msgstr "" - -#: www/views/preferencesColor.html:4 -msgid "Wallet Color" -msgstr "" - -#: www/views/preferencesInformation.html:29 -msgid "Wallet Configuration (m-n)" -msgstr "" - -#: www/views/onboarding/collectEmail.html:5 -msgid "Wallet Created" -msgstr "" - -#: www/views/preferencesInformation.html:23 -msgid "Wallet Id" -msgstr "" - -#: www/views/preferencesAdvanced.html:13 -#: www/views/preferencesInformation.html:3 -msgid "Wallet Information" -msgstr "" - -#: www/views/addresses.html:76 -msgid "Wallet Inputs" -msgstr "" - -#: www/views/join.html:26 -msgid "Wallet Invitation" -msgstr "" - -#: www/views/join.html:60 -#: www/views/tab-create-personal.html:38 -#: www/views/tab-create-shared.html:67 -msgid "Wallet Key" -msgstr "" - -#: www/views/preferencesAlias.html:4 -msgid "Wallet Name" -msgstr "" - -#: www/views/preferencesInformation.html:11 -msgid "Wallet Name (at creation)" -msgstr "" - -#: www/views/preferencesInformation.html:35 -msgid "Wallet Network" -msgstr "" - -#: www/views/join.html:77 -#: www/views/tab-create-personal.html:50 -#: www/views/tab-create-shared.html:79 -msgid "Wallet Recovery Phrase" -msgstr "" - -#: src/js/services/bwcError.js:26 -msgid "Wallet Recovery Phrase is invalid" -msgstr "" - -#: www/views/preferencesAdvanced.html:25 -#: www/views/tab-import-phrase.html:73 -msgid "Wallet Service URL" -msgstr "" - -#: www/views/preferences.html:4 -msgid "Wallet Settings" -msgstr "" - -#: www/views/tab-import-hardware.html:11 -#: www/views/tab-import-phrase.html:61 -msgid "Wallet Type" -msgstr "" - -#: src/js/services/bwcError.js:59 -msgid "Wallet already exists" -msgstr "" - -#: src/js/services/profileService.js:516 -msgid "Wallet already in {{appName}}" -msgstr "" - -#: www/views/includes/walletActivity.html:6 -msgid "Wallet created" -msgstr "" - -#: www/views/copayers.html:58 -msgid "Wallet incomplete and broken" -msgstr "" - -#: src/js/services/bwcError.js:65 -msgid "Wallet is full" -msgstr "" - -#: src/js/services/bwcError.js:125 -msgid "Wallet is locked" -msgstr "" - -#: src/js/services/bwcError.js:128 -msgid "Wallet is not complete" -msgstr "" - -#: www/views/tab-create-personal.html:12 -#: www/views/tab-create-shared.html:12 -msgid "Wallet name" -msgstr "" - -#: src/js/services/bwcError.js:131 -msgid "Wallet needs backup" -msgstr "" - -#: www/views/tab-receive.html:59 -#: www/views/walletDetails.html:169 -msgid "Wallet not backed up" -msgstr "" - -#: src/js/services/bwcError.js:68 -msgid "Wallet not found" -msgstr "" - -#: src/js/controllers/cashScan.js:81 -#: src/js/controllers/tab-home.js:230 -msgid "Wallet not registered" -msgstr "" - -#: src/js/services/bwcError.js:29 -msgid "Wallet not registered at the wallet service. Recreate it from \"Create Wallet\" using \"Advanced Options\" to set your recovery phrase" -msgstr "" - -#: www/views/backup.html:12 -msgid "Wallet recovery phrase not available" -msgstr "" - -#: src/js/services/bwcError.js:50 -msgid "Wallet service not found" -msgstr "" - -#: www/views/tab-home.html:69 -msgid "Wallets" -msgstr "" - -#: src/js/controllers/addressbookView.js:36 -#: src/js/controllers/modals/txpDetails.js:153 -#: src/js/controllers/modals/txpDetails.js:170 -#: src/js/controllers/preferencesDelete.js:24 -#: src/js/controllers/preferencesExternal.js:14 -#: www/views/preferencesDeleteWallet.html:11 -msgid "Warning!" -msgstr "" - -#: www/views/modals/txp-details.html:47 -msgid "Warning: this transaction has unconfirmed inputs" -msgstr "" - -#: src/js/controllers/onboarding/backupRequest.js:17 -msgid "Watch out!" -msgstr "" - -#: src/js/controllers/feedback/send.js:69 -msgid "We'd love to do better." -msgstr "" - -#: www/views/backup.html:35 -msgid "We'll confirm on the next screen." -msgstr "" - -#: src/js/controllers/feedback/send.js:77 -msgid "We're always looking for ways to improve {{appName}}." -msgstr "" - -#: src/js/controllers/feedback/send.js:83 -msgid "We're always looking for ways to improve {{appName}}. How could we improve your experience?" -msgstr "" - -#: www/views/includes/incomingDataMenu.html:6 -msgid "Website" -msgstr "" - -#: www/views/preferencesLanguage.html:16 -msgid "We’re always looking for translation contributions! You can make corrections or help to make this app available in your native language by joining our community on Crowdin." -msgstr "" - -#: www/views/preferencesAlias.html:11 -msgid "What do you call this wallet?" -msgstr "" - -#: www/views/preferencesAlias.html:12 -msgid "When this wallet was created, it was called “{{walletName}}”. You can change the name displayed on this device below." -msgstr "" - -#: www/views/onboarding/collectEmail.html:10 -msgid "Where would you like to receive email notifications about payments?" -msgstr "" - -#: www/views/addresses.html:19 -msgid "Why?" -msgstr "" - -#: www/views/feedback/rateApp.html:10 -msgid "Would you be willing to rate {{appName}} in the app store?" -msgstr "" - -#: www/views/onboarding/notifications.html:4 -msgid "Would you like to receive push notifications about payments?" -msgstr "" - -#: src/js/controllers/import.js:288 -msgid "Wrong number of recovery words:" -msgstr "" - -#: src/js/services/bwcError.js:140 -msgid "Wrong spending password" -msgstr "" - -#: www/views/modals/confirmation.html:7 -msgid "Yes" -msgstr "" - -#: src/js/controllers/onboarding/backupRequest.js:25 -msgid "Yes, skip" -msgstr "" - -#: src/js/controllers/onboarding/backupRequest.js:24 -msgid "You can create a backup later from your wallet settings." -msgstr "" - -#: src/js/controllers/preferencesLanguage.js:12 -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:14 -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:19 -msgid "You can spend bitcoin at millions of websites and stores worldwide." -msgstr "" - -#: www/views/backup.html:15 -msgid "You can still export it from Advanced > Export." -msgstr "" - -#: www/views/onboarding/tour.html:32 -msgid "You can trade it for other currencies like US Dollars, Euros, or Pounds." -msgstr "" - -#: www/views/onboarding/tour.html:46 -msgid "You control your bitcoin." -msgstr "" - -#: www/views/modals/chooseFeeLevel.html:64 -msgid "You should not set a fee higher than {{maxFeeRecommended}} satoshis/byte." -msgstr "" - -#: www/views/modals/bitpay-card-confirmation.html:5 -msgid "You will need to log back for fill in your BitPay Card." -msgstr "" - -#: www/views/preferencesNotifications.html:34 -msgid "You'll receive email notifications about payments sent and received from your wallets." -msgstr "" - -#: www/views/bitpayCard.html:50 -msgid "Your BitPay Card is ready. Add funds to your card to start using it at stores and ATMs worldwide." -msgstr "" - -#: www/views/mercadoLibre.html:57 -#: www/views/mercadoLibreCards.html:6 -msgid "Your Gift Cards" -msgstr "" - -#: www/views/includes/confirmBackupPopup.html:6 -msgid "Your bitcoin wallet is backed up!" -msgstr "" - -#: www/views/tab-home.html:36 -msgid "Your bitcoin wallet is ready!" -msgstr "" - -#: www/views/modals/chooseFeeLevel.html:61 -msgid "Your fee is lower than recommended." -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 "" - -#: www/views/join.html:16 -msgid "Your nickname" -msgstr "" - -#: www/views/tab-export-file.html:11 -#: www/views/tab-import-file.html:20 -msgid "Your password" -msgstr "" - -#: www/views/buyAmazon.html:102 -msgid "Your purchase could not be completed" -msgstr "" - -#: www/views/buyAmazon.html:105 -msgid "Your purchase was added to the list of pending" -msgstr "" - -#: www/views/onboarding/backupRequest.html:10 -msgid "Your wallet is never saved to cloud storage or standard device backups." -msgstr "" - -#: src/js/services/walletService.js:1030 -msgid "Your wallet key will be encrypted. The Spending Password cannot be recovered. Be sure to write it down." -msgstr "" - -#: www/views/includes/walletList.html:13 -#: www/views/includes/walletSelector.html:21 -#: www/views/paperWallet.html:33 -#: www/views/tab-receive.html:72 -#: www/views/walletDetails.html:131 -#: www/views/walletDetails.html:51 -msgid "[Balance Hidden]" -msgstr "" - -#: www/views/walletDetails.html:141 -#: www/views/walletDetails.html:61 -msgid "[Scanning Funds]" -msgstr "" - -#: src/js/controllers/bitpayCardIntro.js:11 -msgid "add your BitPay Visa card(s)" -msgstr "" - -#: www/views/includes/available-balance.html:8 -msgid "locked by pending payments" -msgstr "" - -#: src/js/services/profileService.js:404 -msgid "me" -msgstr "" - -#: www/views/addressbook.add.html:32 -msgid "name@example.com" -msgstr "" - -#: www/views/preferencesHistory.html:15 -msgid "preparing..." -msgstr "" - -#: www/views/cashScan.html:57 -msgid "recovery tool." -msgstr "" - -#: src/js/controllers/buyAmazon.js:239 -msgid "{{amountStr}} for Amazon.com Gift Card" -msgstr "" - -#: src/js/controllers/buyMercadoLibre.js:237 -msgid "{{amountStr}} for Mercado Livre Brazil Gift Card" -msgstr "" - -#: www/views/preferencesBwsUrl.html:21 -msgid "{{appName}} depends on Bitcore Wallet Service (BWS) for blockchain information, networking and Copayer synchronization. The default configuration points to https://bws.bitpay.com (BitPay's public BWS instance)." -msgstr "" - -#: src/js/controllers/confirm.js:408 -msgid "{{fee}} will be deducted for bitcoin networking fees." -msgstr "" - -#: www/views/confirm.html:85 -msgid "{{tx.txp[wallet.id].feeRatePerStr}} of the sending amount" -msgstr "" - -#: www/views/walletDetails.html:218 -msgid "{{updatingTxHistoryProgress}} transactions downloaded" -msgstr "" - -#: www/views/cashScan.html:33 -#: www/views/copayers.html:46 -#: www/views/includes/walletInfo.html:18 -msgid "{{wallet.m}}-of-{{wallet.n}}" -msgstr "" +msgid "" +msgstr "" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Project-Id-Version: \n" + +#: www/views/modals/paypro.html:34 +msgid "(Trusted)" +msgstr "" + +#: www/views/includes/txp.html:23 +#: www/views/includes/walletHistory.html:64 +msgid "(possible double spend)" +msgstr "" + +#: www/views/modals/txp-details.html:159 +msgid "* A payment proposal can be deleted if 1) you are the creator, and no other copayer has signed, or 2) 24 hours have passed since the proposal was created." +msgstr "" + +#: www/views/tx-details.html:82 +msgid "- {{btx.feeRateStr}} of the transaction" +msgstr "" + +#: www/views/modals/txp-details.html:102 +msgid "- {{tx.feeRateStr}} of the transaction" +msgstr "" + +#: www/views/feedback/rateApp.html:7 +msgid "5-star ratings help us get {{appName}} into more hands, and more users means more resources can be committed to the app!" +msgstr "" + +#: www/views/mercadoLibre.html:18 +#: www/views/mercadoLibre.html:40 +msgid "Only redeemable on Mercado Livre (Brazil)" +msgstr "" + +#: src/js/controllers/feedback/send.js:27 +#: www/views/feedback/complete.html:21 +msgid "A member of the team will review your feedback as soon as possible." +msgstr "" + +#: src/js/controllers/confirm.js:401 +msgid "A total of {{amountAboveMaxSizeStr}} were excluded. The maximum size allowed for a transaction was exceeded." +msgstr "" + +#: src/js/controllers/confirm.js:395 +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:156 +msgid "About" +msgstr "" + +#: src/js/controllers/modals/txpDetails.js:62 +#: src/js/controllers/tx-details.js:79 +msgid "Accepted" +msgstr "" + +#: www/views/preferencesInformation.html:72 +msgid "Account" +msgstr "" + +#: www/views/join.html:72 +#: www/views/tab-create-personal.html:45 +#: www/views/tab-create-shared.html:74 +#: www/views/tab-import-hardware.html:19 +msgid "Account Number" +msgstr "" + +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "" + +#: www/views/preferencesBitpayServices.html:23 +msgid "Accounts" +msgstr "" + +#: www/views/bitpayCard.html:56 +msgid "Activity" +msgstr "" + +#: src/js/services/bitpayAccountService.js:83 +msgid "Add Account" +msgstr "" + +#: src/js/services/bitpayAccountService.js:69 +msgid "Add BitPay Account?" +msgstr "" + +#: www/views/addressbook.add.html:4 +#: www/views/addressbook.html:22 +msgid "Add Contact" +msgstr "" + +#: www/views/bitpayCard.html:28 +msgid "Add Funds" +msgstr "" + +#: www/views/confirm.html:94 +msgid "Add Memo" +msgstr "" + +#: www/views/join.html:87 +#: www/views/tab-create-personal.html:59 +#: www/views/tab-create-shared.html:88 +msgid "Add a password" +msgstr "" + +#: www/views/includes/accountSelector.html:27 +msgid "Add account" +msgstr "" + +#: www/views/join.html:90 +#: www/views/tab-create-personal.html:62 +#: www/views/tab-create-shared.html:91 +msgid "Add an optional password to secure the recovery phrase" +msgstr "" + +#: www/views/includes/incomingDataMenu.html:41 +msgid "Add as a contact" +msgstr "" + +#: src/js/controllers/confirm.js:424 +msgid "Add description" +msgstr "" + +#: www/views/topup.html:6 +msgid "Add funds" +msgstr "" + +#: src/js/services/bitpayAccountService.js:78 +msgid "Add this BitPay account ({{email}})?" +msgstr "" + +#: www/views/add.html:3 +msgid "Add wallet" +msgstr "" + +#: www/views/addressbook.view.html:26 +#: www/views/customAmount.html:28 +#: www/views/modals/paypro.html:24 +msgid "Address" +msgstr "" + +#: www/views/addressbook.html:6 +#: www/views/tab-settings.html:13 +msgid "Address Book" +msgstr "" + +#: www/views/preferencesInformation.html:41 +msgid "Address Type" +msgstr "" + +#: www/views/addresses.html:64 +msgid "Addresses With Balance" +msgstr "" + +#: www/views/tab-settings.html:149 +msgid "Advanced" +msgstr "" + +#: www/views/advancedSettings.html:3 +msgid "Advanced Settings" +msgstr "" + +#: www/views/bitpayCard.html:62 +msgid "All" +msgstr "" + +#: www/views/allAddresses.html:3 +msgid "All Addresses" +msgstr "" + +#: www/views/modals/wallet-balance.html:18 +msgid "All of your bitcoin wallet balance may not be available for immediate spending." +msgstr "" + +#: www/views/tab-receive.html:25 +msgid "All signing devices must be added to this multisig wallet before bitcoin addresses can be created." +msgstr "" + +#: www/views/tab-scan.html:21 +msgid "Allow Camera Access" +msgstr "" + +#: www/views/onboarding/notifications.html:7 +msgid "Allow notifications" +msgstr "" + +#: www/views/onboarding/disclaimer.html:14 +msgid "Almost done! Let's review." +msgstr "" + +#: www/views/preferencesAltCurrency.html:4 +#: www/views/tab-settings.html:79 +msgid "Alternative Currency" +msgstr "" + +#: src/js/controllers/buyAmazon.js:98 +msgid "Amazon.com is not available at this moment. Please try back later." +msgstr "" + +#: www/views/amount.html:44 +#: www/views/customAmount.html:34 +#: www/views/includes/output.html:7 +msgid "Amount" +msgstr "" + +#: src/js/services/bwcError.js:110 +msgid "Amount below minimum allowed" +msgstr "" + +#: src/js/controllers/confirm.js:216 +msgid "Amount too big" +msgstr "" + +#: www/views/includes/walletHistory.html:31 +msgid "Amount too low to spend" +msgstr "" + +#: src/js/controllers/tab-home.js:147 +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 "" + +#: www/views/addresses.html:94 +msgid "Approximate Bitcoin network fee to transfer wallet's balance (with normal priority)" +msgstr "" + +#: www/views/backupWarning.html:10 +msgid "Are you being watched?" +msgstr "" + +#: src/js/controllers/preferencesExternal.js:15 +msgid "Are you being watched? Anyone with your recovery phrase can access or spend your bitcoin." +msgstr "" + +#: src/js/controllers/copayers.js:56 +msgid "Are you sure you want to cancel and delete this wallet?" +msgstr "" + +#: src/js/controllers/addressbookView.js:37 +msgid "Are you sure you want to delete this contact?" +msgstr "" + +#: src/js/controllers/preferencesDelete.js:25 +msgid "Are you sure you want to delete this wallet?" +msgstr "" + +#: src/js/controllers/modals/txpDetails.js:154 +msgid "Are you sure you want to reject this transaction?" +msgstr "" + +#: src/js/controllers/modals/txpDetails.js:171 +msgid "Are you sure you want to remove this transaction?" +msgstr "" + +#: src/js/controllers/onboarding/backupRequest.js:23 +msgid "Are you sure you want to skip it?" +msgstr "" + +#: www/views/modals/bitpay-card-confirmation.html:4 +msgid "Are you sure you would like to log out of your BitPay Card account?" +msgstr "" + +#: src/js/controllers/preferencesBitpayCard.js:7 +#: src/js/controllers/preferencesBitpayServices.js:20 +msgid "Are you sure you would like to remove your BitPay Card ({{lastFourDigits}}) from this device?" +msgstr "" + +#: www/views/includes/walletInfo.html:10 +msgid "Auditable" +msgstr "" + +#: www/views/modals/wallet-balance.html:42 +msgid "Available" +msgstr "" + +#: www/views/includes/available-balance.html:3 +msgid "Available Balance" +msgstr "" + +#: www/views/modals/chooseFeeLevel.html:24 +#: www/views/preferencesFee.html:15 +msgid "Average confirmation time" +msgstr "" + +#: www/views/join.html:143 +#: www/views/tab-create-personal.html:113 +#: www/views/tab-create-shared.html:142 +#: www/views/tab-import-phrase.html:51 +msgid "BIP32 path for address derivation" +msgstr "" + +#: www/views/cashScan.html:25 +msgid "BTC wallets" +msgstr "" + +#: www/views/preferences.html:34 +msgid "Backup" +msgstr "" + +#: www/views/includes/backupNeededPopup.html:7 +msgid "Backup Needed" +msgstr "" + +#: src/js/controllers/lockSetup.js:87 +msgid "Backup all livenet wallets before using this function" +msgstr "" + +#: src/js/controllers/cashScan.js:64 +#: www/views/includes/walletListSettings.html:12 +#: www/views/preferences.html:36 +msgid "Backup needed" +msgstr "" + +#: www/views/includes/backupNeededPopup.html:9 +msgid "Backup now" +msgstr "" + +#: www/views/onboarding/backupRequest.html:11 +#: www/views/tab-export-file.html:89 +msgid "Backup wallet" +msgstr "" + +#: src/js/controllers/lockSetup.js:84 +msgid "Backup your wallet before using this function" +msgstr "" + +#: src/js/services/profileService.js:446 +msgid "Bad wallet invitation" +msgstr "" + +#: www/views/preferencesInformation.html:102 +msgid "Balance By Address" +msgstr "" + +#: www/views/includes/confirmBackupPopup.html:7 +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 "" + +#: www/views/preferencesBitpayServices.html:9 +msgid "BitPay Visa® Cards" +msgstr "" + +#: www/views/addressbook.add.html:38 +#: www/views/includes/incomingDataMenu.html:29 +msgid "Bitcoin Address" +msgstr "" + +#: www/views/cashScan.html:4 +msgid "Bitcoin Cash (BCH) Balances" +msgstr "" + +#: www/views/preferencesCash.html:3 +#: www/views/tab-settings.html:47 +msgid "Bitcoin Cash Support" +msgstr "" + +#: www/views/tab-home.html:98 +#: www/views/tab-settings.html:115 +msgid "Bitcoin Cash Wallets" +msgstr "" + +#: www/views/modals/chooseFeeLevel.html:4 +#: www/views/preferencesFee.html:4 +#: www/views/tab-settings.html:90 +msgid "Bitcoin Network Fee Policy" +msgstr "" + +#: www/views/tab-home.html:83 +#: www/views/tab-settings.html:107 +msgid "Bitcoin Core Wallets" +msgstr "" + +#: src/js/services/incomingData.js:151 +msgid "Bitcoin cash Payment" +msgstr "" + +#: www/views/onboarding/tour.html:31 +msgid "Bitcoin is a currency." +msgstr "" + +#: www/views/onboarding/disclaimer.html:15 +msgid "Bitcoin is different – it cannot be safely held with a bank or web service." +msgstr "" + +#: www/views/onboarding/tour.html:18 +msgid "Bitcoin is secure,
digital money." +msgstr "" + +#: www/views/preferencesFee.html:11 +msgid "Bitcoin transactions include a fee collected by miners on the network." +msgstr "" + +#: www/views/buyAmazon.html:108 +msgid "Bought {{amountUnitStr}}" +msgstr "" + +#: www/views/modals/txp-details.html:36 +msgid "Broadcast Payment" +msgstr "" + +#: src/js/controllers/modals/txpDetails.js:64 +#: src/js/controllers/tx-details.js:81 +msgid "Broadcasted" +msgstr "" + +#: src/js/services/onGoingProcess.js:11 +msgid "Broadcasting transaction" +msgstr "" + +#: www/views/unsupported.html:6 +msgid "Browser unsupported" +msgstr "" + +#: www/views/buyAmazon.html:5 +#: www/views/buyMercadoLibre.html:6 +msgid "Buy" +msgstr "" + +#: www/views/includes/buyAndSellCard.html:3 +msgid "Buy & Sell Bitcoin" +msgstr "" + +#: www/views/tab-send.html:35 +msgid "Buy Bitcoin" +msgstr "" + +#: www/views/mercadoLibre.html:22 +#: www/views/mercadoLibre.html:50 +msgid "Buy a Gift Card" +msgstr "" + +#: src/js/controllers/buyAmazon.js:334 +msgid "Buy from" +msgstr "" + +#: src/js/services/onGoingProcess.js:40 +msgid "Buying Bitcoin..." +msgstr "" + +#: src/js/services/onGoingProcess.js:12 +msgid "Calculating fee" +msgstr "" + +#: src/js/controllers/buyAmazon.js:313 +#: src/js/controllers/buyMercadoLibre.js:307 +#: src/js/controllers/confirm.js:550 +#: src/js/controllers/topup.js:287 +#: src/js/services/incomingData.js:154 +#: src/js/services/popupService.js:62 +#: src/js/services/popupService.js:73 +#: www/views/addressbook.add.html:10 +#: www/views/feedback/send.html:5 +#: www/views/includes/incomingDataMenu.html:22 +#: www/views/includes/incomingDataMenu.html:54 +#: www/views/includes/incomingDataMenu.html:73 +#: www/views/includes/incomingDataMenu.html:97 +#: www/views/includes/note.html:6 +#: www/views/modals/bitpay-card-confirmation.html:8 +#: www/views/modals/confirmation.html:13 +msgid "Cancel" +msgstr "" + +#: www/views/copayers.html:36 +msgid "Cancel invitation" +msgstr "" + +#: src/js/controllers/onboarding/tour.js:52 +msgid "Cannot Create Wallet" +msgstr "" + +#: src/js/services/profileService.js:442 +msgid "Cannot join the same wallet more that once" +msgstr "" + +#: www/views/includes/bitpayCardsCard.html:2 +msgid "Cards" +msgstr "" + +#: www/views/modals/paypro.html:30 +msgid "Certified by" +msgstr "" + +#: www/views/preferencesExternal.html:19 +msgid "Check installation and retry." +msgstr "" + +#: www/views/tab-import-file.html:4 +msgid "Choose a backup file from your computer" +msgstr "" + +#: www/views/modals/wallets.html:9 +msgid "Choose your destination wallet" +msgstr "" + +#: www/views/modals/wallets.html:10 +msgid "Choose your source wallet" +msgstr "" + +#: www/views/backup.html:61 +msgid "Clear" +msgstr "" + +#: www/views/preferencesHistory.html:24 +msgid "Clear cache" +msgstr "" + +#: src/js/controllers/confirm.js:373 +#: src/js/controllers/modals/txpDetails.js:49 +msgid "Click to accept" +msgstr "" + +#: src/js/controllers/confirm.js:367 +msgid "Click to pay" +msgstr "" + +#: src/js/controllers/confirm.js:379 +#: src/js/controllers/modals/txpDetails.js:42 +msgid "Click to send" +msgstr "" + +#: www/views/customAmount.html:4 +#: www/views/modals/mercadolibre-card-details.html:3 +#: www/views/modals/paypro.html:4 +#: www/views/modals/pin.html:3 +#: www/views/modals/search.html:3 +#: www/views/modals/wallet-balance.html:3 +#: www/views/modals/wallets.html:5 +msgid "Close" +msgstr "" + +#: www/views/includes/cash.html:2 +#: www/views/preferencesInformation.html:17 +msgid "Coin" +msgstr "" + +#: www/views/preferences.html:22 +msgid "Color" +msgstr "" + +#: www/views/preferencesAbout.html:21 +msgid "Commit hash" +msgstr "" + +#: www/views/preferences.html:49 +msgid "Complete the backup process to use this option" +msgstr "" + +#: www/views/bitpayCard.html:93 +msgid "Completed" +msgstr "" + +#: src/js/controllers/buyAmazon.js:311 +#: src/js/controllers/buyMercadoLibre.js:305 +#: src/js/controllers/confirm.js:549 +#: src/js/controllers/copayers.js:55 +#: src/js/controllers/topup.js:285 +#: www/views/backup.html:60 +#: www/views/backup.html:79 +#: www/views/confirm.html:4 +#: www/views/onboarding/collectEmail.html:32 +msgid "Confirm" +msgstr "" + +#: www/views/modals/terms.html:26 +#: www/views/onboarding/disclaimer.html:44 +msgid "Confirm & Finish" +msgstr "" + +#: www/views/buyAmazon.html:90 +msgid "Confirm purchase" +msgstr "" + +#: www/views/modals/pin.html:10 +msgid "Confirm your PIN" +msgstr "" + +#: src/js/services/walletService.js:1033 +msgid "Confirm your new spending password" +msgstr "" + +#: www/views/tx-details.html:98 +msgid "Confirmations" +msgstr "" + +#: www/views/bitpayCard.html:68 +#: www/views/modals/wallet-balance.html:61 +msgid "Confirming" +msgstr "" + +#: www/views/bitpayCardIntro.html:37 +msgid "Connect my BitPay Card" +msgstr "" + +#: src/js/services/onGoingProcess.js:13 +msgid "Connecting to Coinbase..." +msgstr "" + +#: src/js/services/onGoingProcess.js:14 +msgid "Connecting to Glidera..." +msgstr "" + +#: src/js/services/bwcError.js:53 +msgid "Connection reset by peer" +msgstr "" + +#: www/views/tab-send.html:45 +msgid "Contacts" +msgstr "" + +#: www/views/onboarding/notifications.html:9 +msgid "Continue" +msgstr "" + +#: www/views/preferencesLanguage.html:26 +msgid "Contribute Translations" +msgstr "" + +#: src/js/controllers/confirm.js:130 +msgid "Copay only supports Bitcoin Cash using new version numbers addresses" +msgstr "" + +#: src/js/services/bwcError.js:62 +msgid "Copayer already in this wallet" +msgstr "" + +#: src/js/services/bwcError.js:77 +msgid "Copayer already voted on this spend proposal" +msgstr "" + +#: src/js/services/bwcError.js:107 +msgid "Copayer data mismatch" +msgstr "" + +#: www/views/includes/walletActivity.html:2 +msgid "Copayer joined" +msgstr "" + +#: www/views/preferencesInformation.html:94 +msgid "Copayer {{$index}}" +msgstr "" + +#: src/js/controllers/copayers.js:79 +#: src/js/controllers/export.js:193 +#: www/views/includes/copyToClipboard.html:4 +msgid "Copied to clipboard" +msgstr "" + +#: www/views/tab-export-file.html:94 +msgid "Copy this text as it is to a safe place (notepad or email)" +msgstr "" + +#: www/views/includes/incomingDataMenu.html:51 +#: www/views/includes/incomingDataMenu.html:70 +#: www/views/includes/incomingDataMenu.html:94 +#: www/views/includes/logOptions.html:9 +#: www/views/tab-export-file.html:78 +msgid "Copy to clipboard" +msgstr "" + +#: src/js/controllers/buyMercadoLibre.js:102 +msgid "Could not access Gift Card Service" +msgstr "" + +#: www/views/tab-import-phrase.html:2 +msgid "Could not access the wallet at the server. Please check:" +msgstr "" + +#: src/js/controllers/buyAmazon.js:102 +msgid "Could not access to Amazon.com" +msgstr "" + +#: src/js/services/profileService.js:511 +msgid "Could not access wallet" +msgstr "" + +#: src/js/controllers/confirm.js:210 +msgid "Could not add message to imported wallet without shared encrypting key" +msgstr "" + +#: src/js/controllers/modals/txpDetails.js:199 +msgid "Could not broadcast payment" +msgstr "" + +#: src/js/services/bwcError.js:41 +msgid "Could not build transaction" +msgstr "" + +#: src/js/services/walletService.js:854 +msgid "Could not create address" +msgstr "" + +#: src/js/controllers/topup.js:92 +msgid "Could not create the invoice" +msgstr "" + +#: src/js/controllers/buyAmazon.js:164 +#: src/js/controllers/buyMercadoLibre.js:164 +#: src/js/controllers/topup.js:142 +msgid "Could not create transaction" +msgstr "" + +#: src/js/services/profileService.js:350 +msgid "Could not create using the specified extended private key" +msgstr "" + +#: src/js/services/profileService.js:362 +msgid "Could not create using the specified extended public key" +msgstr "" + +#: src/js/services/profileService.js:338 +msgid "Could not create: Invalid wallet recovery phrase" +msgstr "" + +#: src/js/controllers/import.js:114 +msgid "Could not decrypt file, check your password" +msgstr "" + +#: src/js/controllers/modals/txpDetails.js:181 +msgid "Could not delete payment proposal" +msgstr "" + +#: src/js/controllers/cashScan.js:117 +msgid "Could not duplicate" +msgstr "" + +#: src/js/services/feeService.js:73 +msgid "Could not get dynamic fee" +msgstr "" + +#: src/js/services/feeService.js:43 +msgid "Could not get dynamic fee for level: {{feeLevel}}" +msgstr "" + +#: src/js/controllers/modals/feeLevels.js:112 +msgid "Could not get fee levels" +msgstr "" + +#: src/js/controllers/buyAmazon.js:122 +#: src/js/controllers/buyMercadoLibre.js:122 +#: src/js/controllers/topup.js:100 +msgid "Could not get the invoice" +msgstr "" + +#: src/js/controllers/bitpayCard.js:66 +msgid "Could not get transactions" +msgstr "" + +#: src/js/services/profileService.js:615 +#: src/js/services/profileService.js:650 +#: src/js/services/profileService.js:674 +msgid "Could not import" +msgstr "" + +#: src/js/services/profileService.js:584 +msgid "Could not import. Check input file and spending password" +msgstr "" + +#: src/js/services/profileService.js:457 +msgid "Could not join wallet" +msgstr "" + +#: src/js/controllers/modals/txpDetails.js:161 +msgid "Could not reject payment" +msgstr "" + +#: src/js/controllers/preferencesBitpayServices.js:33 +msgid "Could not remove account" +msgstr "" + +#: src/js/controllers/preferencesBitpayCard.js:20 +#: src/js/controllers/preferencesBitpayServices.js:50 +msgid "Could not remove card" +msgstr "" + +#: src/js/services/walletService.js:776 +msgid "Could not save preferences on the server" +msgstr "" + +#: src/js/controllers/modals/txpDetails.js:147 +msgid "Could not send payment" +msgstr "" + +#: src/js/controllers/buyAmazon.js:325 +#: src/js/controllers/buyMercadoLibre.js:318 +#: src/js/controllers/topup.js:299 +msgid "Could not send transaction" +msgstr "" + +#: www/views/walletDetails.html:210 +msgid "Could not update transaction history" +msgstr "" + +#: src/js/controllers/addresses.js:29 +#: src/js/controllers/addresses.js:37 +#: src/js/controllers/copayers.js:30 +#: src/js/controllers/walletDetails.js:78 +msgid "Could not update wallet" +msgstr "" + +#: www/views/tab-create-personal.html:3 +msgid "Create Personal Wallet" +msgstr "" + +#: www/views/tab-create-shared.html:3 +msgid "Create Shared Wallet" +msgstr "" + +#: www/views/onboarding/tour.html:51 +#: www/views/tab-home.html:75 +#: www/views/tab-send.html:36 +msgid "Create bitcoin wallet" +msgstr "" + +#: www/views/tab-create-personal.html:131 +msgid "Create new wallet" +msgstr "" + +#: www/views/add.html:22 +msgid "Create shared wallet" +msgstr "" + +#: www/views/tab-create-shared.html:160 +msgid "Create {{formData.requiredCopayers}}-of-{{formData.totalCopayers}} wallet" +msgstr "" + +#: www/views/modals/txp-details.html:81 +#: www/views/tx-details.html:60 +msgid "Created by" +msgstr "" + +#: src/js/services/onGoingProcess.js:18 +msgid "Creating Wallet..." +msgstr "" + +#: src/js/services/onGoingProcess.js:17 +msgid "Creating transaction" +msgstr "" + +#: www/views/modals/chooseFeeLevel.html:34 +#: www/views/preferencesFee.html:20 +msgid "Current fee rate for this policy" +msgstr "" + +#: src/js/services/feeService.js:15 +msgid "Custom" +msgstr "" + +#: www/views/customAmount.html:9 +msgid "Custom Amount" +msgstr "" + +#: src/js/controllers/preferencesFee.js:85 +msgid "Custom Fee" +msgstr "" + +#: www/views/modals/mercadolibre-card-details.html:56 +#: www/views/modals/txp-details.html:87 +#: www/views/tx-details.html:66 +msgid "Date" +msgstr "" + +#: www/views/preferencesDeleteWallet.html:21 +msgid "Delete" +msgstr "" + +#: www/views/modals/txp-details.html:164 +msgid "Delete Payment Proposal" +msgstr "" + +#: www/views/preferencesAdvanced.html:33 +#: www/views/preferencesDeleteWallet.html:3 +msgid "Delete Wallet" +msgstr "" + +#: www/views/copayers.html:59 +msgid "Delete it and create a new one" +msgstr "" + +#: src/js/services/onGoingProcess.js:19 +msgid "Deleting Wallet..." +msgstr "" + +#: src/js/services/onGoingProcess.js:28 +msgid "Deleting payment proposal" +msgstr "" + +#: www/views/join.html:141 +#: www/views/tab-create-personal.html:111 +#: www/views/tab-create-shared.html:140 +#: www/views/tab-import-phrase.html:49 +msgid "Derivation Path" +msgstr "" + +#: www/views/preferencesInformation.html:47 +msgid "Derivation Strategy" +msgstr "" + +#: www/views/buyAmazon.html:39 +#: www/views/buyMercadoLibre.html:38 +#: www/views/modals/mercadolibre-card-details.html:6 +#: www/views/topup.html:45 +msgid "Details" +msgstr "" + +#: src/js/controllers/lockSetup.js:9 +#: src/js/controllers/tab-settings.js:65 +#: www/views/tab-settings.html:50 +msgid "Disabled" +msgstr "" + +#: www/views/includes/backupNeededPopup.html:10 +#: www/views/onboarding/backupRequest.html:12 +msgid "Do it later" +msgstr "" + +#: www/views/tab-export-file.html:29 +msgid "Do not include private key" +msgstr "" + +#: www/views/preferencesLanguage.html:21 +msgid "Don't see your language on Crowdin? Contact the Owner on Crowdin! We'd love to support your language." +msgstr "" + +#: www/views/tab-export-file.html:59 +#: www/views/tab-home.html:22 +msgid "Download" +msgstr "" + +#: www/views/cashScan.html:37 +msgid "Duplicate for BCH" +msgstr "" + +#: src/js/services/onGoingProcess.js:49 +msgid "Duplicating wallet..." +msgstr "" + +#: www/views/addresses.html:19 +msgid "Each bitcoin wallet can generate billions of addresses from your 12-word backup. A new address is automatically generated and shown each time you receive a payment." +msgstr "" + +#: src/js/services/feeService.js:13 +msgid "Economy" +msgstr "" + +#: www/views/onboarding/collectEmail.html:27 +msgid "Edit" +msgstr "" + +#: www/views/addressbook.add.html:29 +#: www/views/addressbook.view.html:22 +msgid "Email" +msgstr "" + +#: www/views/preferencesNotifications.html:42 +msgid "Email Address" +msgstr "" + +#: src/js/services/bwcError.js:122 +msgid "Empty addresses limit reached. New addresses cannot be generated." +msgstr "" + +#: www/views/preferencesCash.html:17 +msgid "Enable Bitcoin Cash wallet creation and operation within the App." +msgstr "" + +#: www/views/tab-scan.html:19 +msgid "Enable camera access in your device settings to get started." +msgstr "" + +#: www/views/preferencesNotifications.html:29 +msgid "Enable email notifications" +msgstr "" + +#: www/views/preferencesNotifications.html:12 +msgid "Enable push notifications" +msgstr "" + +#: www/views/preferencesNotifications.html:33 +msgid "Enable sound" +msgstr "" + +#: www/views/tab-scan.html:18 +msgid "Enable the camera to get started." +msgstr "" + +#: www/views/tab-settings.html:49 +msgid "Enabled" +msgstr "" + +#: src/js/services/walletService.js:1047 +#: src/js/services/walletService.js:1062 +msgid "Enter Spending Password" +msgstr "" + +#: src/js/services/bitpayAccountService.js:110 +msgid "Enter Two Factor for your BitPay account" +msgstr "" + +#: www/views/amount.html:4 +msgid "Enter amount" +msgstr "" + +#: www/views/modals/chooseFeeLevel.html:41 +msgid "Enter custom fee" +msgstr "" + +#: src/js/services/walletService.js:1029 +msgid "Enter new spending password" +msgstr "" + +#: www/views/join.html:79 +#: www/views/tab-create-personal.html:51 +#: www/views/tab-create-shared.html:80 +msgid "Enter the recovery phrase (BIP39)" +msgstr "" + +#: www/views/onboarding/collectEmail.html:13 +msgid "Enter your email" +msgstr "" + +#: www/views/backup.html:69 +msgid "Enter your password" +msgstr "" + +#. Trying to import a malformed wallet export QR code +#: src/js/controllers/activity.js:45 +#: src/js/controllers/addressbookAdd.js:30 +#: src/js/controllers/addressbookView.js:42 +#: src/js/controllers/addresses.js:125 +#: src/js/controllers/addresses.js:126 +#: src/js/controllers/bitpayCard.js:66 +#: src/js/controllers/bitpayCardIntro.js:40 +#: src/js/controllers/bitpayCardIntro.js:81 +#: src/js/controllers/buyAmazon.js:24 +#: src/js/controllers/buyAmazon.js:35 +#: src/js/controllers/buyMercadoLibre.js:24 +#: src/js/controllers/buyMercadoLibre.js:35 +#: src/js/controllers/confirm.js:307 +#: src/js/controllers/copayers.js:67 +#: src/js/controllers/create.js:161 +#: src/js/controllers/create.js:174 +#: src/js/controllers/create.js:180 +#: src/js/controllers/create.js:186 +#: src/js/controllers/create.js:208 +#: src/js/controllers/create.js:215 +#: src/js/controllers/create.js:233 +#: src/js/controllers/export.js:109 +#: src/js/controllers/export.js:115 +#: src/js/controllers/export.js:126 +#: src/js/controllers/export.js:154 +#: src/js/controllers/export.js:160 +#: src/js/controllers/export.js:171 +#: src/js/controllers/export.js:47 +#: src/js/controllers/export.js:53 +#: src/js/controllers/feedback/send.js:23 +#: src/js/controllers/import.js:119 +#: src/js/controllers/import.js:131 +#: src/js/controllers/import.js:149 +#: src/js/controllers/import.js:200 +#: src/js/controllers/import.js:229 +#: src/js/controllers/import.js:238 +#: src/js/controllers/import.js:254 +#: src/js/controllers/import.js:266 +#: src/js/controllers/import.js:278 +#: src/js/controllers/import.js:288 +#: src/js/controllers/import.js:312 +#: src/js/controllers/import.js:325 +#: src/js/controllers/import.js:335 +#: src/js/controllers/import.js:345 +#: src/js/controllers/import.js:369 +#: src/js/controllers/import.js:382 +#: src/js/controllers/import.js:85 +#: src/js/controllers/import.js:98 +#: src/js/controllers/join.js:125 +#: src/js/controllers/join.js:139 +#: src/js/controllers/join.js:145 +#: src/js/controllers/join.js:151 +#: src/js/controllers/join.js:174 +#: src/js/controllers/join.js:182 +#: src/js/controllers/join.js:200 +#: src/js/controllers/modals/feeLevels.js:9 +#: src/js/controllers/modals/txpDetails.js:140 +#: src/js/controllers/paperWallet.js:47 +#: src/js/controllers/preferencesBitpayCard.js:20 +#: src/js/controllers/preferencesBitpayServices.js:33 +#: src/js/controllers/preferencesBitpayServices.js:50 +#: src/js/controllers/preferencesDelete.js:36 +#: src/js/controllers/preferencesExternal.js:20 +#: src/js/controllers/tab-home.js:174 +#: src/js/controllers/tab-send.js:143 +#: src/js/controllers/tabsController.js:36 +#: src/js/controllers/tabsController.js:7 +#: src/js/controllers/topup.js:21 +#: src/js/controllers/topup.js:32 +#: src/js/controllers/tx-details.js:119 +#: src/js/services/incomingData.js:101 +#: src/js/services/incomingData.js:125 +#: src/js/services/incomingData.js:168 +#: www/views/mercadoLibreCards.html:19 +#: www/views/modals/mercadolibre-card-details.html:45 +msgid "Error" +msgstr "" + +#: src/js/controllers/confirm.js:502 +msgid "Error at confirm" +msgstr "" + +#: src/js/controllers/buyAmazon.js:179 +msgid "Error creating gift card" +msgstr "" + +#: src/js/controllers/buyAmazon.js:94 +#: src/js/controllers/buyMercadoLibre.js:94 +msgid "Error creating the invoice" +msgstr "" + +#: src/js/services/profileService.js:412 +msgid "Error creating wallet" +msgstr "" + +#: src/js/controllers/confirm.js:296 +msgid "Error getting SendMax information" +msgstr "" + +#: src/js/controllers/buyAmazon.js:136 +#: src/js/controllers/buyMercadoLibre.js:136 +#: src/js/controllers/topup.js:114 +msgid "Error in Payment Protocol" +msgstr "" + +#: src/js/controllers/bitpayCardIntro.js:14 +msgid "Error pairing BitPay Account" +msgstr "" + +#: src/js/controllers/paperWallet.js:41 +msgid "Error scanning funds:" +msgstr "" + +#: src/js/controllers/paperWallet.js:90 +msgid "Error sweeping wallet:" +msgstr "" + +#: src/js/controllers/bitpayCardIntro.js:20 +msgid "Error updating Debit Cards" +msgstr "" + +#: src/js/services/bwcError.js:143 +msgid "Exceeded daily limit of $500 per user" +msgstr "" + +#: src/js/controllers/confirm.js:461 +#: www/views/confirm.html:27 +#: www/views/mercadoLibreCards.html:25 +#: www/views/modals/mercadolibre-card-details.html:34 +#: www/views/modals/txp-details.html:119 +msgid "Expired" +msgstr "" + +#: www/views/modals/paypro.html:54 +#: www/views/modals/txp-details.html:125 +msgid "Expires" +msgstr "" + +#: www/views/preferencesAdvanced.html:21 +msgid "Export Wallet" +msgstr "" + +#: www/views/preferencesHistory.html:11 +#: www/views/preferencesHistory.html:14 +msgid "Export to file" +msgstr "" + +#: www/views/export.html:3 +msgid "Export wallet" +msgstr "" + +#: src/js/services/walletService.js:1174 +#: www/views/tab-export-qrCode.html:9 +msgid "Exporting via QR not supported for this wallet" +msgstr "" + +#: www/views/preferencesInformation.html:89 +msgid "Extended Public Keys" +msgstr "" + +#: src/js/services/onGoingProcess.js:20 +msgid "Extracting Wallet information..." +msgstr "" + +#: src/js/controllers/export.js:115 +#: src/js/controllers/export.js:126 +#: src/js/controllers/export.js:160 +#: src/js/controllers/export.js:171 +#: www/views/tab-export-file.html:4 +msgid "Failed to export" +msgstr "" + +#: www/views/tab-create-personal.html:14 +#: www/views/tab-create-shared.html:14 +msgid "Family vacation funds" +msgstr "" + +#: www/views/tx-details.html:79 +msgid "Fee" +msgstr "" + +#: www/views/modals/chooseFeeLevel.html:75 +msgid "Fee level" +msgstr "" + +#: src/js/controllers/modals/feeLevels.js:100 +msgid "Fee level is not defined" +msgstr "" + +#: www/views/confirm.html:79 +#: www/views/modals/txp-details.html:99 +msgid "Fee:" +msgstr "" + +#: src/js/controllers/feedback/send.js:23 +msgid "Feedback could not be submitted. Please try again later." +msgstr "" + +#: src/js/services/onGoingProcess.js:42 +msgid "Fetching BitPay Account..." +msgstr "" + +#: src/js/services/onGoingProcess.js:21 +msgid "Fetching payment information" +msgstr "" + +#: www/views/export.html:14 +#: www/views/import.html:16 +msgid "File/Text" +msgstr "" + +#: www/views/preferencesLogs.html:17 +msgid "Filter setting" +msgstr "" + +#: src/js/services/fingerprintService.js:43 +#: src/js/services/fingerprintService.js:48 +msgid "Finger Scan Failed" +msgstr "" + +#: src/js/controllers/feedback/send.js:34 +#: www/views/feedback/complete.html:7 +msgid "Finish" +msgstr "" + +#: www/views/tab-create-personal.html:123 +#: www/views/tab-create-shared.html:152 +msgid "For audit purposes" +msgstr "" + +#: src/js/controllers/topup.js:308 +#: www/views/buyAmazon.html:29 +#: www/views/buyMercadoLibre.html:28 +#: www/views/confirm.html:65 +#: www/views/modals/txp-details.html:74 +#: www/views/topup.html:34 +#: www/views/tx-details.html:52 +msgid "From" +msgstr "" + +#: src/js/controllers/bitpayCardIntro.js:71 +msgid "From BitPay account" +msgstr "" + +#: www/views/tab-import-phrase.html:57 +msgid "From Hardware Wallet" +msgstr "" + +#: www/views/tab-export-qrCode.html:5 +msgid "From the destination device, go to Add wallet > Import wallet and scan this QR code" +msgstr "" + +#: src/js/services/bwcError.js:74 +msgid "Funds are locked by pending spend proposals" +msgstr "" + +#: www/views/paperWallet.html:16 +msgid "Funds found:" +msgstr "" + +#: www/views/topup.html:49 +msgid "Funds to be added" +msgstr "" + +#: www/views/paperWallet.html:51 +msgid "Funds transferred" +msgstr "" + +#: www/views/topup.html:103 +msgid "Funds were added to debit card" +msgstr "" + +#: www/views/paperWallet.html:22 +msgid "Funds will be transferred to" +msgstr "" + +#: www/views/tab-receive.html:51 +msgid "Generate new address" +msgstr "" + +#: src/js/services/onGoingProcess.js:22 +msgid "Generating .csv file..." +msgstr "" + +#: src/js/services/onGoingProcess.js:37 +msgid "Generating new address..." +msgstr "" + +#: www/views/bitpayCardIntro.html:23 +msgid "Get local cash anywhere you go, from any Visa® compatible ATM. ATM bank fees may apply." +msgstr "" + +#: www/views/onboarding/collectEmail.html:15 +msgid "Get news and updates from BitPay" +msgstr "" + +#: www/views/onboarding/welcome.html:8 +msgctxt "button" +msgid "Get started" +msgstr "" + +#: www/views/bitpayCard.html:49 +msgid "Get started" +msgstr "" + +#: www/views/addressbook.html:20 +msgid "Get started by adding your first one." +msgstr "" + +#: src/js/services/onGoingProcess.js:23 +msgid "Getting fee levels..." +msgstr "" + +#: www/views/buyAmazon.html:43 +#: www/views/buyMercadoLibre.html:42 +msgid "Gift Card" +msgstr "" + +#: www/views/modals/mercadolibre-card-details.html:30 +#: www/views/modals/mercadolibre-card-details.html:35 +msgid "Gift Card is not available to use anymore" +msgstr "" + +#: src/js/controllers/buyAmazon.js:204 +msgid "Gift card expired" +msgstr "" + +#: www/views/buyAmazon.html:111 +msgid "Gift card generated and ready to use." +msgstr "" + +#: src/js/controllers/bitpayCard.js:114 +#: src/js/controllers/bitpayCard.js:124 +#: src/js/controllers/cashScan.js:20 +#: src/js/controllers/onboarding/terms.js:23 +#: src/js/controllers/preferences.js:67 +#: src/js/controllers/preferencesAbout.js:16 +#: src/js/controllers/preferencesCash.js:34 +#: src/js/controllers/preferencesLanguage.js:14 +#: src/js/controllers/tab-home.js:149 +#: src/js/controllers/tab-settings.js:53 +#: src/js/controllers/tx-details.js:193 +#: src/js/controllers/tx-details.js:56 +msgid "Go Back" +msgstr "" + +#: src/js/controllers/confirm.js:131 +#: src/js/controllers/onboarding/backupRequest.js:20 +#: src/js/controllers/onboarding/backupRequest.js:26 +#: src/js/services/bitpayAccountService.js:84 +msgid "Go back" +msgstr "" + +#: www/views/backupWarning.html:15 +#: www/views/includes/confirmBackupPopup.html:8 +#: www/views/onboarding/tour.html:23 +msgid "Got it" +msgstr "" + +#: www/views/preferencesInformation.html:53 +#: www/views/preferencesInformation.html:59 +msgid "Hardware Wallet" +msgstr "" + +#: www/views/preferencesExternal.html:18 +msgid "Hardware not connected." +msgstr "" + +#: www/views/import.html:20 +msgid "Hardware wallet" +msgstr "" + +#: src/js/controllers/create.js:180 +#: src/js/controllers/join.js:145 +msgid "Hardware wallets are not yet supported with Bitcoin Cash" +msgstr "" + +#: www/views/tab-settings.html:20 +msgid "Help & Support" +msgstr "" + +#: src/js/controllers/bitpayCard.js:112 +#: src/js/controllers/tab-settings.js:51 +msgid "Help and support information is available at the website." +msgstr "" + +#: www/views/addresses.html:25 +msgid "Hide" +msgstr "" + +#: www/views/preferences.html:27 +msgid "Hide Balance" +msgstr "" + +#: www/views/advancedSettings.html:30 +msgid "Hide Next Steps Card" +msgstr "" + +#: www/views/join.html:49 +#: www/views/tab-create-personal.html:28 +#: www/views/tab-create-shared.html:57 +#: www/views/tab-export-file.html:25 +#: www/views/tab-import-file.html:30 +#: www/views/tab-import-hardware.html:31 +#: www/views/tab-import-phrase.html:36 +msgid "Hide advanced options" +msgstr "" + +#: www/views/tabs.html:3 +msgid "Home" +msgstr "" + +#: src/js/controllers/feedback/send.js:61 +#: src/js/controllers/feedback/send.js:65 +#: src/js/controllers/feedback/send.js:69 +msgid "How could we improve your experience?" +msgstr "" + +#: www/views/feedback/rateCard.html:3 +msgid "How do you like {{appName}}?" +msgstr "" + +#: src/js/controllers/feedback/rateCard.js:29 +msgid "I don't like it" +msgstr "" + +#: www/views/onboarding/disclaimer.html:43 +msgid "I have read, understood, and agree to the Terms of Use." +msgstr "" + +#: www/views/modals/terms.html:22 +msgid "I have read, understood, and agree with the Terms of use." +msgstr "" + +#: www/views/join.html:137 +#: www/views/tab-create-personal.html:107 +#: www/views/tab-create-shared.html:136 +msgid "I have written it down" +msgstr "" + +#: src/js/controllers/feedback/rateCard.js:35 +msgid "I like the app" +msgstr "" + +#: src/js/controllers/feedback/rateCard.js:26 +msgid "I think this app is terrible." +msgstr "" + +#: src/js/controllers/onboarding/backupRequest.js:19 +#: www/views/includes/screenshotWarningModal.html:9 +msgid "I understand" +msgstr "" + +#: www/views/onboarding/disclaimer.html:21 +msgid "I understand that if this app is moved to another device or deleted, my bitcoin can only be recovered with the backup phrase." +msgstr "" + +#: www/views/onboarding/disclaimer.html:18 +msgid "I understand that my funds are held securely on this device, not by a company." +msgstr "" + +#: www/views/backup.html:36 +msgid "I've written it down" +msgstr "" + +#: www/views/preferences.html:45 +msgid "If enabled, all sensitive information (private key and recovery phrase) and actions (spending and exporting) associated with this wallet will be protected." +msgstr "" + +#: www/views/advancedSettings.html:23 +msgid "If enabled, the Recent Transactions card - a list of transactions occuring across all wallets - will appear in the Home tab." +msgstr "" + +#: www/views/advancedSettings.html:14 +msgid "If enabled, wallets will also try to spend unconfirmed funds. This option may cause transaction delays." +msgstr "" + +#: src/js/controllers/onboarding/backupRequest.js:18 +msgid "If this device is replaced or this app is deleted, neither you nor BitPay can recover your funds without a backup." +msgstr "" + +#: www/views/feedback/complete.html:23 +msgid "If you have additional feedback, please let us know by tapping the \"Send feedback\" option in the Settings tab." +msgstr "" + +#: www/views/includes/screenshotWarningModal.html:8 +msgid "If you take a screenshot, your backup may be viewed by other apps. You can make a safe backup with physical paper and a pen." +msgstr "" + +#: www/views/tab-import-hardware.html:42 +#: www/views/tab-import-phrase.html:80 +msgid "Import" +msgstr "" + +#: www/views/import.html:3 +msgid "Import Wallet" +msgstr "" + +#: www/views/tab-import-file.html:41 +msgid "Import backup" +msgstr "" + +#: www/views/add.html:38 +msgid "Import wallet" +msgstr "" + +#: src/js/services/onGoingProcess.js:24 +msgid "Importing Wallet..." +msgstr "" + +#: www/views/backup.html:72 +msgid "In order to verify your wallet backup, please type your password." +msgstr "" + +#: www/views/mercadoLibreCards.html:24 +#: www/views/modals/mercadolibre-card-details.html:29 +msgid "Inactive" +msgstr "" + +#: www/views/includes/walletItem.html:9 +#: www/views/includes/walletList.html:6 +#: www/views/includes/walletListSettings.html:9 +#: www/views/includes/walletSelector.html:16 +msgid "Incomplete" +msgstr "" + +#: www/views/tab-receive.html:22 +msgid "Incomplete wallet" +msgstr "" + +#: www/views/modals/pin.html:12 +msgid "Incorrect PIN, try again." +msgstr "" + +#. Trying to import a malformed wallet export QR code +#: src/js/controllers/import.js:85 +msgid "Incorrect code format" +msgstr "" + +#: src/js/services/bwcError.js:113 +msgid "Incorrect network address" +msgstr "" + +#: src/js/controllers/confirm.js:114 +#: src/js/controllers/confirm.js:306 +#: src/js/services/bwcError.js:44 +msgid "Insufficient confirmed funds" +msgstr "" + +#: src/js/controllers/topup.js:165 +#: src/js/controllers/topup.js:177 +#: src/js/services/bwcError.js:71 +msgid "Insufficient funds for fee" +msgstr "" + +#: www/views/tab-settings.html:123 +msgid "Integrations" +msgstr "" + +#: www/views/includes/walletHistory.html:49 +msgid "Invalid" +msgstr "" + +#: src/js/controllers/buyAmazon.js:137 +#: src/js/controllers/buyMercadoLibre.js:137 +#: src/js/controllers/topup.js:115 +msgid "Invalid URL" +msgstr "" + +#: src/js/controllers/create.js:186 +#: src/js/controllers/import.js:345 +#: src/js/controllers/join.js:151 +msgid "Invalid account number" +msgstr "" + +#: src/js/services/bwcError.js:119 +msgid "Invalid address" +msgstr "" + +#: src/js/controllers/tabsController.js:7 +msgid "Invalid data" +msgstr "" + +#: src/js/controllers/create.js:161 +#: src/js/controllers/import.js:266 +#: src/js/controllers/join.js:125 +msgid "Invalid derivation path" +msgstr "" + +#: src/js/controllers/copayers.js:90 +msgid "Invitation to share a {{appName}} Wallet" +msgstr "" + +#: www/views/mercadoLibreCards.html:20 +#: www/views/modals/mercadolibre-card-details.html:48 +msgid "Invoice expired" +msgstr "" + +#: src/js/controllers/feedback/send.js:79 +msgid "Is there anything we could do better?" +msgstr "" + +#: www/views/backup.html:54 +msgid "Is this correct?" +msgstr "" + +#: www/views/onboarding/collectEmail.html:22 +msgid "Is this email address correct?" +msgstr "" + +#: www/views/addresses.html:25 +msgid "It's a good idea to avoid reusing addresses - this both protects your privacy and keeps your bitcoins secure against hypothetical attacks by quantum computers." +msgstr "" + +#: src/js/controllers/backup.js:76 +msgid "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." +msgstr "" + +#: www/views/join.html:151 +msgid "Join" +msgstr "" + +#: src/js/controllers/copayers.js:85 +msgid "Join my {{appName}} Wallet. Here is the invitation code: {{secret}} You can download {{appName}} for your phone or desktop at {{appUrl}}" +msgstr "" + +#: www/views/add.html:30 +#: www/views/join.html:5 +msgid "Join shared wallet" +msgstr "" + +#: src/js/services/onGoingProcess.js:25 +msgid "Joining Wallet..." +msgstr "" + +#: www/views/onboarding/tour.html:22 +msgid "Just scan the code to pay." +msgstr "" + +#: src/js/services/bwcError.js:116 +msgid "Key already associated with an existing wallet" +msgstr "" + +#: www/views/preferencesLanguage.html:4 +#: www/views/tab-settings.html:68 +msgid "Language" +msgstr "" + +#: www/views/bitpayCard.html:61 +msgid "Last Month" +msgstr "" + +#: src/js/controllers/confirm.js:132 +#: www/views/preferences.html:48 +#: www/views/preferencesCash.html:18 +#: www/views/tx-details.html:94 +msgid "Learn more" +msgstr "" + +#: www/views/backup.html:43 +msgid "Let's verify your backup phrase." +msgstr "" + +#: www/views/addresses.html:45 +#: www/views/allAddresses.html:14 +msgid "Loading addresses..." +msgstr "" + +#: src/js/services/onGoingProcess.js:35 +msgid "Loading transaction info..." +msgstr "" + +#: www/views/tab-settings.html:100 +msgid "Lock App" +msgstr "" + +#: src/js/controllers/lockSetup.js:23 +msgid "Lock by Fingerprint" +msgstr "" + +#: src/js/controllers/lockSetup.js:14 +msgid "Lock by PIN" +msgstr "" + +#: www/views/modals/wallet-balance.html:80 +msgid "Locked" +msgstr "" + +#: src/js/services/bwcError.js:86 +msgid "Locktime in effect. Please wait to create a new spend proposal" +msgstr "" + +#: src/js/services/bwcError.js:89 +msgid "Locktime in effect. Please wait to remove this spend proposal" +msgstr "" + +#: www/views/includes/logOptions.html:3 +msgid "Log options" +msgstr "" + +#: www/views/modals/bitpay-card-confirmation.html:14 +msgid "Log out" +msgstr "" + +#: www/views/addresses.html:87 +msgid "Low amount inputs" +msgstr "" + +#: www/views/includes/walletHistory.html:27 +msgid "Low fees" +msgstr "" + +#: www/views/onboarding/tour.html:38 +msgid "Makes sense" +msgstr "" + +#: src/js/controllers/modals/search.js:61 +msgid "Matches:" +msgstr "" + +#: www/views/includes/copayers.html:4 +#: www/views/preferencesInformation.html:85 +msgid "Me" +msgstr "" + +#: src/js/controllers/feedback/rateCard.js:32 +msgid "Meh - it's alright" +msgstr "" + +#: src/js/controllers/tx-details.js:165 +#: www/views/modals/paypro.html:48 +#: www/views/modals/txp-details.html:93 +#: www/views/tx-details.html:72 +msgid "Memo" +msgstr "" + +#: www/views/mercadoLibre.html:6 +msgid "Mercado Livre Brazil Gift Cards" +msgstr "" + +#: src/js/controllers/buyMercadoLibre.js:98 +msgid "Mercadolibre Gift Card Service is not available at this moment. Please try back later." +msgstr "" + +#: www/views/modals/txp-details.html:131 +msgid "Merchant Message" +msgstr "" + +#: www/views/buyAmazon.html:55 +#: www/views/buyMercadoLibre.html:54 +#: www/views/topup.html:63 +msgid "Miner Fee" +msgstr "" + +#: src/js/services/bwcError.js:134 +msgid "Missing parameter" +msgstr "" + +#: src/js/services/bwcError.js:32 +msgid "Missing private keys to sign" +msgstr "" + +#: www/views/preferences.html:61 +#: www/views/preferencesAdvanced.html:3 +msgid "More Options" +msgstr "" + +#: www/views/includes/walletHistory.html:47 +#: www/views/tx-details.html:19 +msgid "Moved" +msgstr "" + +#: src/js/controllers/tx-details.js:131 +msgid "Moved Funds" +msgstr "" + +#: www/views/modals/txp-details.html:57 +msgid "Multiple recipients" +msgstr "" + +#: www/views/tab-import-phrase.html:8 +msgid "NOTE: To import a wallet from a 3rd party software, please go to Add Wallet > Create Wallet, and specify the Recovery Phrase there." +msgstr "" + +#: www/views/addressbook.add.html:21 +#: www/views/addressbook.view.html:18 +#: www/views/preferences.html:15 +#: www/views/preferencesAlias.html:17 +msgid "Name" +msgstr "" + +#: www/views/buyAmazon.html:49 +#: www/views/buyMercadoLibre.html:48 +#: www/views/topup.html:56 +msgid "Network Cost" +msgstr "" + +#: src/js/services/bwcError.js:47 +msgid "Network error" +msgstr "" + +#: www/views/includes/walletActivity.html:43 +msgid "New Proposal" +msgstr "" + +#: src/js/controllers/addresses.js:126 +msgid "New address could not be generated. Please try again." +msgstr "" + +#: www/views/add.html:14 +msgid "New personal wallet" +msgstr "" + +#: www/views/includes/nextSteps.html:3 +msgid "Next steps" +msgstr "" + +#: www/views/tab-receive.html:16 +msgid "No Wallet" +msgstr "" + +#: src/js/controllers/buyAmazon.js:115 +#: src/js/controllers/buyMercadoLibre.js:115 +msgid "No access key defined" +msgstr "" + +#: www/views/onboarding/backupRequest.html:5 +msgid "No backup, no bitcoin." +msgstr "" + +#: www/views/addressbook.html:19 +msgid "No contacts yet" +msgstr "" + +#: www/views/preferencesLogs.html:16 +msgid "No entries for this log level" +msgstr "" + +#: www/views/preferencesExternal.html:12 +msgid "No hardware information available." +msgstr "" + +#: www/views/tab-import-hardware.html:3 +msgid "No hardware wallets supported on this device" +msgstr "" + +#: www/views/proposals.html:24 +msgid "No pending proposals" +msgstr "" + +#: www/views/activity.html:25 +msgid "No recent transactions" +msgstr "" + +#: src/js/controllers/buyAmazon.js:44 +#: src/js/controllers/topup.js:47 +msgid "No signing proposal: No private key" +msgstr "" + +#: www/views/walletDetails.html:204 +msgid "No transactions yet" +msgstr "" + +#: src/js/controllers/preferencesDelete.js:15 +msgid "No wallet found" +msgstr "" + +#: src/js/controllers/preferencesDelete.js:8 +msgid "No wallet selected" +msgstr "" + +#: src/js/controllers/buyAmazon.js:300 +#: src/js/controllers/buyMercadoLibre.js:292 +#: src/js/controllers/confirm.js:85 +#: src/js/controllers/topup.js:265 +msgid "No wallets available" +msgstr "" + +#: www/views/paperWallet.html:45 +msgid "No wallets available to receive funds" +msgstr "" + +#: www/views/cashScan.html:15 +msgid "No wallets eligible for Bitcoin Cash support" +msgstr "" + +#: src/js/controllers/cashScan.js:58 +msgid "Non BIP44 wallet" +msgstr "" + +#: www/views/cashScan.html:46 +msgid "Non eligible BTC wallets" +msgstr "" + +#: src/js/services/feeService.js:12 +msgid "Normal" +msgstr "" + +#: src/js/services/bwcError.js:80 +msgid "Not authorized" +msgstr "" + +#: src/js/controllers/confirm.js:307 +msgid "Not enough funds for fee" +msgstr "" + +#: www/views/onboarding/tour.html:50 +msgid "Not even BitPay can access it." +msgstr "" + +#: src/js/controllers/paperWallet.js:47 +msgid "Not funds found" +msgstr "" + +#: www/views/feedback/rateApp.html:3 +#: www/views/onboarding/notifications.html:8 +msgid "Not now" +msgstr "" + +#: www/views/includes/output.html:15 +msgid "Note" +msgstr "" + +#: www/views/backup.html:19 +msgid "Note: if this BCH wallet was duplicated from a BTC wallet, they share the same recovery phrase." +msgstr "" + +#: www/views/modals/wallets.html:25 +msgid "Notice: only 1-1 (single signature) wallets can be used for sell bitcoin" +msgstr "" + +#: www/views/preferencesNotifications.html:3 +#: www/views/tab-settings.html:61 +msgid "Notifications" +msgstr "" + +#: www/views/onboarding/collectEmail.html:9 +msgid "Notifications by email" +msgstr "" + +#: www/views/tx-details.html:117 +msgid "Notify me if confirmed" +msgstr "" + +#: www/views/preferencesNotifications.html:24 +msgid "Notify me when transactions are confirmed" +msgstr "" + +#: www/views/includes/backupNeededPopup.html:8 +msgid "Now is a good time to backup your wallet. If this device is lost, it is impossible to access your funds without a backup." +msgstr "" + +#: www/views/backupWarning.html:11 +msgid "Now is a perfect time to assess your surroundings. Nearby windows? Hidden cameras? Shoulder-spies?" +msgstr "" + +#: src/js/controllers/buyAmazon.js:312 +#: src/js/controllers/topup.js:286 +#: src/js/services/incomingData.js:153 +#: src/js/services/popupService.js:16 +#: src/js/services/popupService.js:52 +#: src/js/services/popupService.js:61 +#: src/js/services/popupService.js:72 +#: www/views/modals/chooseFeeLevel.html:6 +msgid "OK" +msgstr "" + +#: www/views/modals/tx-status.html:12 +#: www/views/modals/tx-status.html:24 +#: www/views/modals/tx-status.html:36 +#: www/views/modals/tx-status.html:46 +msgid "OKAY" +msgstr "" + +#: www/views/modals/terms.html:15 +msgid "Official English Disclaimer" +msgstr "" + +#: src/js/controllers/feedback/send.js:64 +msgid "Oh no!" +msgstr "" + +#: src/js/controllers/buyMercadoLibre.js:306 +msgid "Ok" +msgstr "" + +#: www/views/tab-home.html:39 +msgid "On this screen you can see all your wallets, accounts, and assets." +msgstr "" + +#: src/js/controllers/bitpayCard.js:113 +#: src/js/controllers/cashScan.js:19 +#: src/js/controllers/preferences.js:66 +#: src/js/controllers/preferencesCash.js:33 +#: src/js/controllers/tab-settings.js:52 +#: src/js/controllers/tx-details.js:55 +msgid "Open" +msgstr "" + +#: src/js/controllers/preferencesLanguage.js:13 +msgid "Open Crowdin" +msgstr "" + +#: src/js/controllers/preferencesAbout.js:15 +msgid "Open GitHub" +msgstr "" + +#: src/js/controllers/preferencesAbout.js:13 +msgid "Open GitHub Project" +msgstr "" + +#: src/js/controllers/bitpayCard.js:123 +#: src/js/controllers/tx-details.js:192 +msgid "Open Explorer" +msgstr "" + +#: www/views/tab-scan.html:22 +msgid "Open Settings" +msgstr "" + +#: src/js/controllers/preferencesLanguage.js:11 +msgid "Open Translation Community" +msgstr "" + +#: src/js/controllers/onboarding/terms.js:22 +msgid "Open Website" +msgstr "" + +#: src/js/controllers/preferencesCash.js:32 +msgid "Open bitcoincash.org?" +msgstr "" + +#: src/js/controllers/cashScan.js:18 +msgid "Open the recovery tool." +msgstr "" + +#: www/views/tab-receive.html:27 +msgid "Open wallet" +msgstr "" + +#: www/views/includes/incomingDataMenu.html:19 +msgid "Open website" +msgstr "" + +#: www/views/bitpayCardIntro.html:34 +msgid "Order the BitPay Card" +msgstr "" + +#: www/views/join.html:105 +#: www/views/join.html:96 +#: www/views/tab-create-personal.html:69 +#: www/views/tab-create-personal.html:77 +#: www/views/tab-create-shared.html:106 +#: www/views/tab-create-shared.html:98 +#: www/views/tab-import-file.html:18 +#: www/views/tab-import-phrase.html:41 +msgid "Password" +msgstr "" + +#: src/js/controllers/import.js:98 +msgid "Password required. Make sure to enter your password in advanced options" +msgstr "" + +#: www/views/join.html:33 +msgid "Paste invitation here" +msgstr "" + +#: www/views/tab-import-file.html:13 +msgid "Paste the backup plain text code" +msgstr "" + +#: www/views/bitpayCardIntro.html:28 +msgid "Pay 0% fees to turn bitcoin into dollars." +msgstr "" + +#: www/views/modals/paypro.html:18 +msgid "Pay To" +msgstr "" + +#: src/js/controllers/modals/txpDetails.js:51 +#: www/views/modals/tx-status.html:33 +msgid "Payment Accepted" +msgstr "" + +#: www/views/confirm.html:25 +msgid "Payment Expires:" +msgstr "" + +#: www/views/modals/txp-details.html:6 +msgid "Payment Proposal" +msgstr "" + +#: www/views/modals/tx-status.html:21 +msgid "Payment Proposal Created" +msgstr "" + +#: www/views/tab-home.html:46 +msgid "Payment Proposals" +msgstr "" + +#: src/js/services/payproService.js:32 +msgid "Payment Protocol Invalid" +msgstr "" + +#: src/js/services/payproService.js:18 +msgid "Payment Protocol not supported on Chrome App" +msgstr "" + +#: www/views/includes/walletActivity.html:20 +msgid "Payment Received" +msgstr "" + +#: www/views/modals/tx-status.html:43 +#: www/views/modals/txp-details.html:43 +msgid "Payment Rejected" +msgstr "" + +#: src/js/controllers/modals/txpDetails.js:44 +#: www/views/confirm.html:124 +#: www/views/includes/walletActivity.html:11 +#: www/views/modals/txp-details.html:42 +msgid "Payment Sent" +msgstr "" + +#: www/views/modals/txp-details.html:32 +msgid "Payment accepted, but not yet broadcasted" +msgstr "" + +#: www/views/modals/txp-details.html:40 +msgid "Payment accepted. It will be broadcasted by Glidera. In case there is a problem, it can be deleted 6 hours after it was created." +msgstr "" + +#: src/js/services/incomingData.js:152 +msgid "Payment address was translated to new Bitcoin Cash address format:" +msgstr "" + +#: www/views/modals/txp-details.html:107 +msgid "Payment details" +msgstr "" + +#: www/views/modals/paypro.html:6 +msgid "Payment request" +msgstr "" + +#: www/views/mercadoLibreCards.html:22 +#: www/views/modals/mercadolibre-card-details.html:39 +msgid "Pending" +msgstr "" + +#: www/views/proposals.html:4 +msgid "Pending Proposals" +msgstr "" + +#: www/views/preferencesDeleteWallet.html:13 +msgid "Permanently delete this wallet." +msgstr "" + +#: src/js/services/profileService.js:403 +msgid "Personal Wallet" +msgstr "" + +#: www/views/backup.html:25 +msgid "Please carefully write down this phrase." +msgstr "" + +#: www/views/tab-scan.html:20 +msgid "Please connect a camera to get started." +msgstr "" + +#: src/js/controllers/import.js:278 +msgid "Please enter the recovery phrase" +msgstr "" + +#: src/js/controllers/create.js:174 +#: src/js/controllers/join.js:139 +msgid "Please enter the wallet recovery phrase" +msgstr "" + +#: www/views/modals/pin.html:9 +msgid "Please enter your PIN" +msgstr "" + +#: www/views/backup.html:53 +msgid "Please tap each word in the correct order." +msgstr "" + +#: src/js/services/bwcError.js:101 +msgid "Please upgrade Copay to perform this action" +msgstr "" + +#: www/views/walletDetails.html:142 +#: www/views/walletDetails.html:62 +msgid "Please wait" +msgstr "" + +#: src/js/controllers/import.js:238 +msgid "Please, select your backup file" +msgstr "" + +#: www/views/bitpayCard.html:81 +msgid "Pre-Auth Holds" +msgstr "" + +#: www/views/tab-settings.html:40 +msgid "Preferences" +msgstr "" + +#: src/js/services/onGoingProcess.js:38 +msgid "Preparing addresses..." +msgstr "" + +#: src/js/controllers/export.js:198 +msgid "Preparing backup..." +msgstr "" + +#: src/js/routes.js:1264 +msgid "Press again to exit" +msgstr "" + +#: src/js/services/feeService.js:11 +msgid "Priority" +msgstr "" + +#: www/views/includes/incomingDataMenu.html:80 +msgid "Private Key" +msgstr "" + +#: src/js/controllers/paperWallet.js:136 +msgid "Private key encrypted. Enter password" +msgstr "" + +#: src/js/services/bwcError.js:35 +msgid "Private key is encrypted, cannot sign" +msgstr "" + +#: www/views/includes/walletActivity.html:51 +msgid "Proposal Accepted" +msgstr "" + +#: src/js/controllers/modals/txpDetails.js:61 +#: src/js/controllers/tx-details.js:78 +#: www/views/confirm.html:125 +msgid "Proposal Created" +msgstr "" + +#: www/views/includes/walletActivity.html:27 +msgid "Proposal Deleted" +msgstr "" + +#: www/views/includes/walletActivity.html:35 +msgid "Proposal Rejected" +msgstr "" + +#: www/views/walletDetails.html:189 +msgid "Proposals" +msgstr "" + +#: src/js/controllers/buyAmazon.js:282 +msgid "Purchase Amount is limited to {{limitPerDay}} {{currency}} per day" +msgstr "" + +#: src/js/controllers/buyMercadoLibre.js:281 +msgid "Purchase amount must be a value between 50 and 2000" +msgstr "" + +#: www/views/onboarding/notifications.html:3 +msgid "Push Notifications" +msgstr "" + +#: www/views/preferencesNotifications.html:17 +msgid "Push notifications for {{appName}} are currently disabled. Enable them in the Settings app." +msgstr "" + +#: www/views/export.html:17 +msgid "QR Code" +msgstr "" + +#: www/views/onboarding/disclaimer.html:13 +msgid "Quick review!" +msgstr "" + +#: src/js/controllers/create.js:84 +#: src/js/controllers/join.js:68 +msgid "Random" +msgstr "" + +#: www/views/feedback/rateApp.html:14 +msgid "Rate on the app store" +msgstr "" + +#: www/views/addresses.html:52 +msgid "Read less" +msgstr "" + +#: www/views/addresses.html:51 +msgid "Read more" +msgstr "" + +#: src/js/controllers/preferences.js:65 +#: src/js/controllers/tx-details.js:54 +msgid "Read more in our Wiki" +msgstr "" + +#: src/js/controllers/cashScan.js:61 +msgid "Read only wallet" +msgstr "" + +#: www/views/tab-receive.html:3 +#: www/views/tabs.html:7 +msgid "Receive" +msgstr "" + +#: www/views/customAmount.html:44 +msgid "Receive in" +msgstr "" + +#: www/views/includes/walletHistory.html:24 +#: www/views/tx-details.html:18 +msgid "Received" +msgstr "" + +#: src/js/controllers/tx-details.js:130 +msgid "Received Funds" +msgstr "" + +#: www/views/includes/walletHistory.html:57 +#: www/views/tx-details.html:24 +msgid "Receiving" +msgstr "" + +#: www/views/bitpayCard.html:60 +#: www/views/includes/walletHistory.html:3 +msgid "Recent" +msgstr "" + +#: www/views/advancedSettings.html:21 +msgid "Recent Transaction Card" +msgstr "" + +#: www/views/activity.html:4 +#: www/views/tab-home.html:58 +msgid "Recent Transactions" +msgstr "" + +#: www/views/amount.html:18 +#: www/views/tab-send.html:9 +msgid "Recipient" +msgstr "" + +#: www/views/modals/txp-details.html:62 +msgid "Recipients" +msgstr "" + +#: www/views/import.html:12 +msgid "Recovery phrase" +msgstr "" + +#: src/js/services/onGoingProcess.js:26 +msgid "Recreating Wallet..." +msgstr "" + +#: www/views/modals/mercadolibre-card-details.html:22 +msgid "Redeem now" +msgstr "" + +#: src/js/controllers/modals/txpDetails.js:63 +#: src/js/controllers/tx-details.js:80 +msgid "Rejected" +msgstr "" + +#: src/js/services/onGoingProcess.js:27 +msgid "Rejecting payment proposal" +msgstr "" + +#: www/views/preferencesAbout.html:9 +msgid "Release information" +msgstr "" + +#: www/views/addressbook.view.html:36 +#: www/views/modals/mercadolibre-card-details.html:69 +msgid "Remove" +msgstr "" + +#: src/js/controllers/preferencesBitpayServices.js:7 +msgid "Remove BitPay Account?" +msgstr "" + +#: src/js/controllers/preferencesBitpayServices.js:19 +msgid "Remove BitPay Card?" +msgstr "" + +#: src/js/controllers/preferencesBitpayServices.js:8 +msgid "Removing your BitPay account will remove all associated BitPay account data from this device. Are you sure you would like to remove your BitPay Account ({{email}}) from this device?" +msgstr "" + +#: www/views/join.html:116 +#: www/views/join.html:124 +#: www/views/tab-create-personal.html:86 +#: www/views/tab-create-personal.html:94 +#: www/views/tab-create-shared.html:115 +#: www/views/tab-create-shared.html:123 +#: www/views/tab-export-file.html:17 +msgid "Repeat password" +msgstr "" + +#: www/views/tab-export-file.html:16 +msgid "Repeat the password" +msgstr "" + +#: www/views/preferences.html:56 +msgid "Request Fingerprint" +msgstr "" + +#: www/views/tab-receive.html:45 +msgid "Request Specific amount" +msgstr "" + +#: www/views/preferences.html:42 +msgid "Request Spending Password" +msgstr "" + +#: www/views/tab-create-shared.html:44 +msgid "Required number of signatures" +msgstr "" + +#: www/views/onboarding/welcome.html:9 +msgid "Restore from backup" +msgstr "" + +#: src/js/services/onGoingProcess.js:29 +msgid "Retrieving inputs information" +msgstr "" + +#: src/js/controllers/onboarding/tour.js:56 +msgid "Retry" +msgstr "" + +#: www/views/tab-scan.html:23 +msgid "Retry Camera" +msgstr "" + +#: www/views/addressbook.add.html:56 +#: www/views/includes/note.html:9 +#: www/views/preferencesAlias.html:21 +#: www/views/preferencesBwsUrl.html:25 +#: www/views/preferencesNotifications.html:46 +msgid "Save" +msgstr "" + +#: www/views/tab-scan.html:3 +#: www/views/tabs.html:11 +msgid "Scan" +msgstr "" + +#: www/views/tab-scan.html:15 +msgid "Scan QR Codes" +msgstr "" + +#: www/views/addresses.html:31 +msgid "Scan addresses for funds" +msgstr "" + +#: www/views/modals/fingerprintCheck.html:11 +msgid "Scan again" +msgstr "" + +#: src/js/services/fingerprintService.js:56 +msgid "Scan your fingerprint please" +msgstr "" + +#: www/views/preferencesCash.html:23 +msgid "Scan your wallets for Bitcoin Cash" +msgstr "" + +#: src/js/services/onGoingProcess.js:30 +msgid "Scanning Wallet funds..." +msgstr "" + +#: www/views/includes/walletList.html:11 +msgid "Scanning funds..." +msgstr "" + +#: www/views/includes/screenshotWarningModal.html:7 +msgid "Screenshots are not secure" +msgstr "" + +#: www/views/modals/search.html:6 +msgid "Search Transactions" +msgstr "" + +#: www/views/tab-send.html:13 +msgid "Search or enter bitcoin address" +msgstr "" + +#: www/views/modals/search.html:16 +msgid "Search transactions" +msgstr "" + +#: www/views/preferencesAltCurrency.html:14 +msgid "Search your currency" +msgstr "" + +#: www/views/preferences.html:30 +msgid "Security" +msgstr "" + +#: www/views/modals/mercadolibre-card-details.html:64 +msgid "See invoice" +msgstr "" + +#: www/views/tab-import-file.html:7 +msgid "Select a backup file" +msgstr "" + +#: src/js/controllers/tab-receive.js:139 +msgid "Select a wallet" +msgstr "" + +#: www/views/modals/paypro.html:38 +msgid "Self-signed Certificate" +msgstr "" + +#: src/js/services/onGoingProcess.js:41 +msgid "Selling Bitcoin..." +msgstr "" + +#: www/views/feedback/send.html:13 +#: www/views/feedback/send.html:43 +#: www/views/tab-send.html:3 +#: www/views/tabs.html:15 +msgid "Send" +msgstr "" + +#: www/views/feedback/send.html:3 +#: www/views/tab-settings.html:29 +msgid "Send Feedback" +msgstr "" + +#: www/views/addressbook.view.html:31 +msgid "Send Money" +msgstr "" + +#: www/views/allAddresses.html:19 +msgid "Send addresses by email" +msgstr "" + +#: www/views/includes/logOptions.html:17 +#: www/views/tab-export-file.html:82 +msgid "Send by email" +msgstr "" + +#: src/js/controllers/confirm.js:177 +msgid "Send from" +msgstr "" + +#: www/views/includes/itemSelector.html:8 +msgid "Send max amount" +msgstr "" + +#: www/views/includes/incomingDataMenu.html:46 +msgid "Send payment to this address" +msgstr "" + +#: www/views/feedback/rateApp.html:17 +msgid "Send us feedback instead" +msgstr "" + +#: www/views/confirm.html:15 +#: www/views/includes/txp.html:12 +#: www/views/modals/txp-details.html:19 +#: www/views/tx-details.html:23 +msgid "Sending" +msgstr "" + +#: src/js/services/onGoingProcess.js:39 +msgid "Sending 2FA code..." +msgstr "" + +#: src/js/services/onGoingProcess.js:36 +msgid "Sending feedback..." +msgstr "" + +#: www/views/confirm.html:16 +msgid "Sending maximum amount" +msgstr "" + +#: src/js/services/onGoingProcess.js:31 +msgid "Sending transaction" +msgstr "" + +#: src/js/controllers/confirm.js:545 +msgid "Sending {{amountStr}} from your {{name}} wallet" +msgstr "" + +#: www/views/includes/walletHistory.html:42 +#: www/views/modals/tx-status.html:9 +#: www/views/topup.html:100 +#: www/views/tx-details.html:17 +msgid "Sent" +msgstr "" + +#: src/js/controllers/tx-details.js:129 +msgid "Sent Funds" +msgstr "" + +#: src/js/services/bwcError.js:38 +msgid "Server response could not be verified" +msgstr "" + +#: src/js/controllers/buyAmazon.js:97 +#: src/js/controllers/buyMercadoLibre.js:97 +msgid "Service not available" +msgstr "" + +#: www/views/includes/homeIntegrations.html:3 +msgid "Services" +msgstr "" + +#: www/views/preferencesLogs.html:3 +msgid "Session Log" +msgstr "" + +#: www/views/preferencesAbout.html:35 +msgid "Session log" +msgstr "" + +#: www/views/tab-export-file.html:10 +msgid "Set up a password" +msgstr "" + +#: src/js/controllers/preferencesFee.js:85 +msgid "Set your own fee in satoshis/byte" +msgstr "" + +#: www/views/tab-settings.html:3 +#: www/views/tabs.html:19 +msgid "Settings" +msgstr "" + +#: www/views/feedback/complete.html:17 +#: www/views/feedback/complete.html:26 +msgid "Share the love by inviting your friends." +msgstr "" + +#: www/views/copayers.html:20 +msgid "Share this invitation with your copayers" +msgstr "" + +#: src/js/controllers/feedback/complete.js:5 +#: www/views/tab-settings.html:36 +msgid "Share {{appName}}" +msgstr "" + +#: www/views/tab-import-hardware.html:24 +msgid "Shared Wallet" +msgstr "" + +#: www/views/preferencesExternal.html:34 +msgid "Show Recovery Phrase" +msgstr "" + +#: www/views/tab-receive.html:34 +msgid "Show address" +msgstr "" + +#: www/views/join.html:48 +#: www/views/tab-create-personal.html:27 +#: www/views/tab-create-shared.html:56 +#: www/views/tab-export-file.html:24 +#: www/views/tab-import-file.html:29 +#: www/views/tab-import-hardware.html:30 +#: www/views/tab-import-phrase.html:35 +msgid "Show advanced options" +msgstr "" + +#: www/views/tab-send.html:37 +msgid "Show bitcoin address" +msgstr "" + +#: www/views/tab-send.html:59 +msgid "Show more" +msgstr "" + +#: src/js/services/bwcError.js:104 +msgid "Signatures rejected by server" +msgstr "" + +#: src/js/services/onGoingProcess.js:32 +msgid "Signing transaction" +msgstr "" + +#: www/views/onboarding/backupRequest.html:6 +msgid "Since only you control your money, you’ll need to save your backup phrase in case this app is deleted." +msgstr "" + +#: www/views/tab-create-personal.html:122 +#: www/views/tab-create-shared.html:151 +msgid "Single Address Wallet" +msgstr "" + +#: www/views/onboarding/collectEmail.html:40 +#: www/views/onboarding/tour.html:11 +msgid "Skip" +msgstr "" + +#: src/js/controllers/confirm.js:371 +#: src/js/controllers/modals/txpDetails.js:47 +msgid "Slide to accept" +msgstr "" + +#: www/views/buyAmazon.html:96 +msgid "Slide to buy" +msgstr "" + +#: src/js/controllers/confirm.js:365 +msgid "Slide to pay" +msgstr "" + +#: src/js/controllers/confirm.js:377 +#: src/js/controllers/modals/txpDetails.js:40 +msgid "Slide to send" +msgstr "" + +#: www/views/cashScan.html:56 +msgid "Some of your wallets are not eligible for Bitcoin Cash support. You can try to access BCH funds from these wallets using the" +msgstr "" + +#: src/js/controllers/create.js:88 +#: src/js/controllers/join.js:71 +msgid "Specify Recovery Phrase..." +msgstr "" + +#: src/js/services/bwcError.js:92 +msgid "Spend proposal is not accepted" +msgstr "" + +#: src/js/services/bwcError.js:95 +msgid "Spend proposal not found" +msgstr "" + +#: src/js/services/bwcError.js:137 +msgid "Spending Password needed" +msgstr "" + +#: www/views/walletDetails.html:173 +msgid "Spending this balance will need significant Bitcoin network fees" +msgstr "" + +#: www/views/tab-send.html:28 +msgid "Start sending bitcoin" +msgstr "" + +#: www/views/lockSetup.html:3 +msgid "Startup Lock" +msgstr "" + +#: www/views/mercadoLibreCards.html:21 +#: www/views/modals/mercadolibre-card-details.html:42 +msgid "Still pending" +msgstr "" + +#: www/views/topup.html:101 +msgid "Success" +msgstr "" + +#: src/js/services/feeService.js:14 +msgid "Super Economy" +msgstr "" + +#: www/views/preferencesCash.html:11 +msgid "Support Bitcoin Cash" +msgstr "" + +#: www/views/paperWallet.html:7 +msgid "Sweep" +msgstr "" + +#: www/views/includes/incomingDataMenu.html:89 +#: www/views/paperWallet.html:3 +msgid "Sweep paper wallet" +msgstr "" + +#: src/js/services/onGoingProcess.js:33 +msgid "Sweeping Wallet..." +msgstr "" + +#: www/views/preferencesDeleteWallet.html:16 +msgid "THIS ACTION CANNOT BE REVERSED" +msgstr "" + +#: www/views/onboarding/welcome.html:5 +msgid "Take control of your money,
get started with bitcoin." +msgstr "" + +#: www/views/walletDetails.html:132 +#: www/views/walletDetails.html:52 +msgid "Tap and hold to show" +msgstr "" + +#: www/views/includes/walletInfo.html:3 +msgid "Tap to recreate" +msgstr "" + +#: www/views/includes/walletInfo.html:4 +msgid "Tap to retry" +msgstr "" + +#: www/views/termsOfUse.html:3 +msgid "Terms Of Use" +msgstr "" + +#: www/views/modals/terms.html:3 +#: www/views/onboarding/disclaimer.html:29 +#: www/views/onboarding/disclaimer.html:43 +#: www/views/preferencesAbout.html:30 +msgid "Terms of Use" +msgstr "" + +#: www/views/tab-create-personal.html:118 +#: www/views/tab-import-phrase.html:68 +msgid "Testnet" +msgstr "" + +#: www/views/includes/incomingDataMenu.html:61 +msgid "Text" +msgstr "" + +#: src/js/controllers/feedback/send.js:27 +#: src/js/controllers/feedback/send.js:76 +#: www/views/feedback/complete.html:20 +#: www/views/feedback/rateApp.html:4 +msgid "Thank you!" +msgstr "" + +#: src/js/controllers/feedback/send.js:72 +msgid "Thanks!" +msgstr "" + +#: src/js/controllers/feedback/send.js:73 +msgid "That's exciting to hear. We'd love to earn that fifth star from you – how could we improve your experience?" +msgstr "" + +#: src/js/services/ledger.js:152 +msgid "The Ledger Chrome application is not installed" +msgstr "" + +#: www/views/modals/wallet-balance.html:55 +msgid "The amount of bitcoin immediately spendable from this wallet." +msgstr "" + +#: www/views/modals/wallet-balance.html:93 +msgid "The amount of bitcoin stored in this wallet that is allocated as inputs to your pending transaction proposals. The amount is determined using unspent transaction outputs associated with this wallet and may be more than the actual amounts associated with your pending transaction proposals." +msgstr "" + +#: www/views/modals/wallet-balance.html:74 +msgid "The amount of bitcoin stored in this wallet with less than 1 blockchain confirmation." +msgstr "" + +#: www/views/tab-import-phrase.html:5 +msgid "The derivation path" +msgstr "" + +#: www/views/onboarding/tour.html:37 +msgid "The exchange rate changes with the market." +msgstr "" + +#: www/views/preferencesFee.html:12 +msgid "The higher the fee, the greater the incentive a miner has to include that transaction in a block. Current fees are determined based on network load and the selected policy." +msgstr "" + +#: www/views/addresses.html:51 +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." +msgstr "" + +#: www/views/tab-import-phrase.html:4 +msgid "The password of the recovery phrase (if set)" +msgstr "" + +#: src/js/services/walletService.js:1139 +msgid "The payment was created but could not be completed. Please try again from home screen" +msgstr "" + +#: www/views/modals/txp-details.html:26 +msgid "The payment was removed by creator" +msgstr "" + +#: www/views/join.html:91 +#: www/views/tab-create-personal.html:63 +#: www/views/tab-create-shared.html:92 +#: www/views/tab-import-phrase.html:43 +msgid "The recovery phrase could require a password to be imported" +msgstr "" + +#: src/js/services/bwcError.js:56 +msgid "The request could not be understood by the server" +msgstr "" + +#: www/views/addresses.html:52 +msgid "The restore process will stop when 20 addresses are generated in a row which contain no funds. To safely generate more addresses, make a payment to one of the unused addresses which has already been generated." +msgstr "" + +#: src/js/services/bwcError.js:98 +msgid "The spend proposal is not pending" +msgstr "" + +#: www/views/modals/wallet-balance.html:36 +msgid "The total amount of bitcoin stored in this wallet." +msgstr "" + +#: www/views/preferencesHistory.html:27 +msgid "The transaction history and every new incoming transaction are cached in the app. This feature clean this up and synchronizes again from the server" +msgstr "" + +#: www/views/tab-import-phrase.html:6 +msgid "The wallet service URL" +msgstr "" + +#: src/js/controllers/tab-home.js:38 +msgid "There is a new version of {{appName}} available" +msgstr "" + +#: src/js/controllers/import.js:229 +#: src/js/controllers/import.js:254 +#: src/js/controllers/import.js:335 +msgid "There is an error in the form" +msgstr "" + +#: src/js/controllers/feedback/send.js:61 +#: src/js/controllers/feedback/send.js:65 +msgid "There's obviously something we're doing wrong." +msgstr "" + +#: src/js/controllers/feedback/rateCard.js:38 +msgid "This app is fantastic!" +msgstr "" + +#: www/views/onboarding/tour.html:47 +msgid "This app stores your bitcoin with cutting-edge security." +msgstr "" + +#: src/js/controllers/confirm.js:523 +msgid "This bitcoin payment request has expired." +msgstr "" + +#: www/views/join.html:133 +#: www/views/tab-create-personal.html:103 +#: www/views/tab-create-shared.html:132 +msgid "This password cannot be recovered. If the password is lost, there is no way you could recover your funds." +msgstr "" + +#: www/views/backup.html:31 +msgid "This recovery phrase was created with a password. To recover this wallet both the recovery phrase and password are needed." +msgstr "" + +#: www/views/tx-details.html:91 +msgid "This transaction amount is too small compared to current Bitcoin network fees. Spending these funds will need a Bitcoin network fee cost comparable to the funds itself." +msgstr "" + +#: www/views/tx-details.html:87 +msgid "This transaction could take a long time to confirm or could be dropped due to the low fees set by the sender" +msgstr "" + +#: www/views/walletDetails.html:109 +#: www/views/walletDetails.html:29 +msgid "This wallet is not registered at the given Bitcore Wallet Service (BWS). You can recreate it from the local information." +msgstr "" + +#: www/views/modals/txp-details.html:136 +#: www/views/tx-details.html:121 +msgid "Timeline" +msgstr "" + +#: www/views/confirm.html:31 +#: www/views/includes/output.html:2 +#: www/views/modals/txp-details.html:109 +#: www/views/modals/txp-details.html:53 +#: www/views/tx-details.html:41 +#: www/views/tx-details.html:53 +msgid "To" +msgstr "" + +#: www/views/tab-send.html:32 +msgid "To get started, buy bitcoin or share your address. You can receive bitcoin from any wallet or service." +msgstr "" + +#: www/views/tab-send.html:33 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "" + +#: src/js/services/bitpayAccountService.js:73 +msgid "To {{reason}} you must first add your BitPay account - {{email}}" +msgstr "" + +#: src/js/services/onGoingProcess.js:48 +msgid "Top up in progress..." +msgstr "" + +#: src/js/controllers/topup.js:206 +msgid "Top up {{amountStr}} to debit card ({{cardLastNumber}})" +msgstr "" + +#: www/views/buyAmazon.html:61 +#: www/views/buyMercadoLibre.html:60 +#: www/views/modals/wallet-balance.html:23 +#: www/views/topup.html:70 +msgid "Total" +msgstr "" + +#: www/views/walletDetails.html:196 +msgid "Total Locked Balance" +msgstr "" + +#: www/views/tab-create-shared.html:35 +msgid "Total number of copayers" +msgstr "" + +#: www/views/addresses.html:81 +msgid "Total wallet inputs" +msgstr "" + +#: src/js/services/fingerprintService.js:63 +#: src/js/services/fingerprintService.js:68 +msgid "Touch ID Failed" +msgstr "" + +#: src/js/controllers/tx-details.js:12 +msgid "Transaction" +msgstr "" + +#: www/views/confirm.html:126 +msgid "Transaction Created" +msgstr "" + +#: www/views/preferencesAdvanced.html:29 +#: www/views/preferencesHistory.html:3 +msgid "Transaction History" +msgstr "" + +#: src/js/services/bwcError.js:83 +msgid "Transaction already broadcasted" +msgstr "" + +#: src/js/controllers/buyAmazon.js:308 +#: src/js/controllers/buyMercadoLibre.js:301 +#: src/js/controllers/topup.js:281 +msgid "Transaction has not been created" +msgstr "" + +#: www/views/topup.html:104 +msgid "Transaction initiated" +msgstr "" + +#: src/js/controllers/tx-details.js:119 +msgid "Transaction not available at this time" +msgstr "" + +#: src/js/controllers/activity.js:45 +#: src/js/controllers/tab-home.js:174 +msgid "Transaction not found" +msgstr "" + +#: www/views/modals/chooseFeeLevel.html:55 +msgid "Transactions without fee are not supported." +msgstr "" + +#: src/js/controllers/paperWallet.js:109 +msgid "Transfer to" +msgstr "" + +#: www/views/tab-send.html:67 +msgid "Transfer to Wallet" +msgstr "" + +#: www/views/modals/pin.html:13 +msgid "Try again in {{expires}}" +msgstr "" + +#: www/views/bitpayCardIntro.html:18 +msgid "Turn bitcoin into dollars, swipe anywhere Visa® is accepted." +msgstr "" + +#: www/views/tab-import-phrase.html:17 +msgid "Type the Recovery Phrase (usually 12 words)" +msgstr "" + +#: src/js/controllers/backup.js:75 +msgid "Uh oh..." +msgstr "" + +#: www/views/tx-details.html:100 +msgid "Unconfirmed" +msgstr "" + +#: www/views/walletDetails.html:190 +msgid "Unsent transactions" +msgstr "" + +#: www/views/addresses.html:39 +msgid "Unused Addresses" +msgstr "" + +#: www/views/addresses.html:50 +msgid "Unused Addresses Limit" +msgstr "" + +#: src/js/controllers/tab-home.js:146 +msgid "Update Available" +msgstr "" + +#: www/views/proposals.html:14 +msgid "Updating pending proposals. Please stand by" +msgstr "" + +#: www/views/walletDetails.html:217 +msgid "Updating transaction history. Please stand by." +msgstr "" + +#: www/views/activity.html:14 +msgid "Updating... Please stand by" +msgstr "" + +#: src/js/services/feeService.js:10 +msgid "Urgent" +msgstr "" + +#: www/views/advancedSettings.html:12 +msgid "Use Unconfirmed Funds" +msgstr "" + +#: src/js/services/onGoingProcess.js:34 +msgid "Validating recovery phrase..." +msgstr "" + +#: www/views/modals/fingerprintCheck.html:4 +msgid "Verify your identity" +msgstr "" + +#: www/views/preferencesAbout.html:14 +#: www/views/preferencesExternal.html:25 +msgid "Version" +msgstr "" + +#: www/views/tab-export-file.html:69 +msgid "View" +msgstr "" + +#: www/views/addresses.html:34 +msgid "View All Addresses" +msgstr "" + +#: src/js/controllers/onboarding/terms.js:20 +msgid "View Terms of Service" +msgstr "" + +#: src/js/controllers/bitpayCard.js:122 +#: src/js/controllers/tx-details.js:191 +msgid "View Transaction on Explorer.Bitcoin.com" +msgstr "" + +#: src/js/controllers/tab-home.js:148 +msgid "View Update" +msgstr "" + +#: www/views/tx-details.html:147 +msgid "View on blockchain" +msgstr "" + +#: www/views/mercadoLibre.html:26 +msgid "Visit mercadolivre.com.br →" +msgstr "" + +#: www/views/walletDetails.html:182 +msgid "WARNING: Key derivation is not working on this device/wallet. Actions cannot be performed on this wallet." +msgstr "" + +#: www/views/tab-export-file.html:45 +msgid "WARNING: Not including the private key allows to check the wallet balance, transaction history, and create spend proposals from the export. However, does not allow to approve (sign) proposals, so funds will not be accessible from the export." +msgstr "" + +#: www/views/tab-export-file.html:36 +msgid "WARNING: The private key of this wallet is not available. The export allows to check the wallet balance, transaction history, and create spend proposals from the export. However, does not allow to approve (sign) proposals, so funds will not be accessible from the export." +msgstr "" + +#: www/views/modals/paypro.html:42 +msgid "WARNING: UNTRUSTED CERTIFICATE" +msgstr "" + +#: src/js/services/onGoingProcess.js:15 +msgid "Waiting for Ledger..." +msgstr "" + +#: src/js/services/onGoingProcess.js:16 +msgid "Waiting for Trezor..." +msgstr "" + +#: www/views/copayers.html:48 +msgid "Waiting for copayers" +msgstr "" + +#: www/views/copayers.html:53 +msgid "Waiting..." +msgstr "" + +#: www/views/addresses.html:3 +#: www/views/preferencesAdvanced.html:17 +msgid "Wallet Addresses" +msgstr "" + +#: www/views/preferencesColor.html:4 +msgid "Wallet Color" +msgstr "" + +#: www/views/preferencesInformation.html:29 +msgid "Wallet Configuration (m-n)" +msgstr "" + +#: www/views/onboarding/collectEmail.html:5 +msgid "Wallet Created" +msgstr "" + +#: www/views/preferencesInformation.html:23 +msgid "Wallet Id" +msgstr "" + +#: www/views/preferencesAdvanced.html:13 +#: www/views/preferencesInformation.html:3 +msgid "Wallet Information" +msgstr "" + +#: www/views/addresses.html:76 +msgid "Wallet Inputs" +msgstr "" + +#: www/views/join.html:26 +msgid "Wallet Invitation" +msgstr "" + +#: www/views/join.html:60 +#: www/views/tab-create-personal.html:38 +#: www/views/tab-create-shared.html:67 +msgid "Wallet Key" +msgstr "" + +#: www/views/preferencesAlias.html:4 +msgid "Wallet Name" +msgstr "" + +#: www/views/preferencesInformation.html:11 +msgid "Wallet Name (at creation)" +msgstr "" + +#: www/views/preferencesInformation.html:35 +msgid "Wallet Network" +msgstr "" + +#: www/views/join.html:77 +#: www/views/tab-create-personal.html:50 +#: www/views/tab-create-shared.html:79 +msgid "Wallet Recovery Phrase" +msgstr "" + +#: src/js/services/bwcError.js:26 +msgid "Wallet Recovery Phrase is invalid" +msgstr "" + +#: www/views/preferencesAdvanced.html:25 +#: www/views/tab-import-phrase.html:73 +msgid "Wallet Service URL" +msgstr "" + +#: www/views/preferences.html:4 +msgid "Wallet Settings" +msgstr "" + +#: www/views/tab-import-hardware.html:11 +#: www/views/tab-import-phrase.html:61 +msgid "Wallet Type" +msgstr "" + +#: src/js/services/bwcError.js:59 +msgid "Wallet already exists" +msgstr "" + +#: src/js/services/profileService.js:516 +msgid "Wallet already in {{appName}}" +msgstr "" + +#: www/views/includes/walletActivity.html:6 +msgid "Wallet created" +msgstr "" + +#: www/views/copayers.html:58 +msgid "Wallet incomplete and broken" +msgstr "" + +#: src/js/services/bwcError.js:65 +msgid "Wallet is full" +msgstr "" + +#: src/js/services/bwcError.js:125 +msgid "Wallet is locked" +msgstr "" + +#: src/js/services/bwcError.js:128 +msgid "Wallet is not complete" +msgstr "" + +#: www/views/tab-create-personal.html:12 +#: www/views/tab-create-shared.html:12 +msgid "Wallet name" +msgstr "" + +#: src/js/services/bwcError.js:131 +msgid "Wallet needs backup" +msgstr "" + +#: www/views/tab-receive.html:59 +#: www/views/walletDetails.html:169 +msgid "Wallet not backed up" +msgstr "" + +#: src/js/services/bwcError.js:68 +msgid "Wallet not found" +msgstr "" + +#: src/js/controllers/cashScan.js:81 +#: src/js/controllers/tab-home.js:230 +msgid "Wallet not registered" +msgstr "" + +#: src/js/services/bwcError.js:29 +msgid "Wallet not registered at the wallet service. Recreate it from \"Create Wallet\" using \"Advanced Options\" to set your recovery phrase" +msgstr "" + +#: www/views/backup.html:12 +msgid "Wallet recovery phrase not available" +msgstr "" + +#: src/js/services/bwcError.js:50 +msgid "Wallet service not found" +msgstr "" + +#: www/views/tab-home.html:69 +msgid "Wallets" +msgstr "" + +#: src/js/controllers/addressbookView.js:36 +#: src/js/controllers/modals/txpDetails.js:153 +#: src/js/controllers/modals/txpDetails.js:170 +#: src/js/controllers/preferencesDelete.js:24 +#: src/js/controllers/preferencesExternal.js:14 +#: www/views/preferencesDeleteWallet.html:11 +msgid "Warning!" +msgstr "" + +#: www/views/modals/txp-details.html:47 +msgid "Warning: this transaction has unconfirmed inputs" +msgstr "" + +#: src/js/controllers/onboarding/backupRequest.js:17 +msgid "Watch out!" +msgstr "" + +#: src/js/controllers/feedback/send.js:69 +msgid "We'd love to do better." +msgstr "" + +#: www/views/backup.html:35 +msgid "We'll confirm on the next screen." +msgstr "" + +#: src/js/controllers/feedback/send.js:77 +msgid "We're always looking for ways to improve {{appName}}." +msgstr "" + +#: src/js/controllers/feedback/send.js:83 +msgid "We're always looking for ways to improve {{appName}}. How could we improve your experience?" +msgstr "" + +#: www/views/includes/incomingDataMenu.html:6 +msgid "Website" +msgstr "" + +#: www/views/preferencesLanguage.html:16 +msgid "We’re always looking for translation contributions! You can make corrections or help to make this app available in your native language by joining our community on Crowdin." +msgstr "" + +#: www/views/preferencesAlias.html:11 +msgid "What do you call this wallet?" +msgstr "" + +#: www/views/preferencesAlias.html:12 +msgid "When this wallet was created, it was called “{{walletName}}”. You can change the name displayed on this device below." +msgstr "" + +#: www/views/onboarding/collectEmail.html:10 +msgid "Where would you like to receive email notifications about payments?" +msgstr "" + +#: www/views/addresses.html:19 +msgid "Why?" +msgstr "" + +#: www/views/feedback/rateApp.html:10 +msgid "Would you be willing to rate {{appName}} in the app store?" +msgstr "" + +#: www/views/onboarding/notifications.html:4 +msgid "Would you like to receive push notifications about payments?" +msgstr "" + +#: src/js/controllers/import.js:288 +msgid "Wrong number of recovery words:" +msgstr "" + +#: src/js/services/bwcError.js:140 +msgid "Wrong spending password" +msgstr "" + +#: www/views/modals/confirmation.html:7 +msgid "Yes" +msgstr "" + +#: src/js/controllers/onboarding/backupRequest.js:25 +msgid "Yes, skip" +msgstr "" + +#: src/js/controllers/onboarding/backupRequest.js:24 +msgid "You can create a backup later from your wallet settings." +msgstr "" + +#: src/js/controllers/preferencesLanguage.js:12 +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:14 +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:19 +msgid "You can spend bitcoin at millions of websites and stores worldwide." +msgstr "" + +#: www/views/backup.html:15 +msgid "You can still export it from Advanced > Export." +msgstr "" + +#: www/views/onboarding/tour.html:32 +msgid "You can trade it for other currencies like US Dollars, Euros, or Pounds." +msgstr "" + +#: www/views/onboarding/tour.html:46 +msgid "You control your bitcoin." +msgstr "" + +#: www/views/modals/chooseFeeLevel.html:64 +msgid "You should not set a fee higher than {{maxFeeRecommended}} satoshis/byte." +msgstr "" + +#: www/views/modals/bitpay-card-confirmation.html:5 +msgid "You will need to log back for fill in your BitPay Card." +msgstr "" + +#: www/views/preferencesNotifications.html:34 +msgid "You'll receive email notifications about payments sent and received from your wallets." +msgstr "" + +#: www/views/bitpayCard.html:50 +msgid "Your BitPay Card is ready. Add funds to your card to start using it at stores and ATMs worldwide." +msgstr "" + +#: www/views/mercadoLibre.html:57 +#: www/views/mercadoLibreCards.html:6 +msgid "Your Gift Cards" +msgstr "" + +#: www/views/includes/confirmBackupPopup.html:6 +msgid "Your bitcoin wallet is backed up!" +msgstr "" + +#: www/views/tab-home.html:36 +msgid "Your bitcoin wallet is ready!" +msgstr "" + +#: www/views/modals/chooseFeeLevel.html:61 +msgid "Your fee is lower than recommended." +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 "" + +#: www/views/join.html:16 +msgid "Your nickname" +msgstr "" + +#: www/views/tab-export-file.html:11 +#: www/views/tab-import-file.html:20 +msgid "Your password" +msgstr "" + +#: www/views/buyAmazon.html:102 +msgid "Your purchase could not be completed" +msgstr "" + +#: www/views/buyAmazon.html:105 +msgid "Your purchase was added to the list of pending" +msgstr "" + +#: www/views/onboarding/backupRequest.html:10 +msgid "Your wallet is never saved to cloud storage or standard device backups." +msgstr "" + +#: src/js/services/walletService.js:1030 +msgid "Your wallet key will be encrypted. The Spending Password cannot be recovered. Be sure to write it down." +msgstr "" + +#: www/views/includes/walletList.html:13 +#: www/views/includes/walletSelector.html:21 +#: www/views/paperWallet.html:33 +#: www/views/tab-receive.html:72 +#: www/views/walletDetails.html:131 +#: www/views/walletDetails.html:51 +msgid "[Balance Hidden]" +msgstr "" + +#: www/views/walletDetails.html:141 +#: www/views/walletDetails.html:61 +msgid "[Scanning Funds]" +msgstr "" + +#: src/js/controllers/bitpayCardIntro.js:11 +msgid "add your BitPay Visa card(s)" +msgstr "" + +#: www/views/includes/available-balance.html:8 +msgid "locked by pending payments" +msgstr "" + +#: src/js/services/profileService.js:404 +msgid "me" +msgstr "" + +#: www/views/addressbook.add.html:32 +msgid "name@example.com" +msgstr "" + +#: www/views/preferencesHistory.html:15 +msgid "preparing..." +msgstr "" + +#: www/views/cashScan.html:57 +msgid "recovery tool." +msgstr "" + +#: src/js/controllers/buyAmazon.js:239 +msgid "{{amountStr}} for Amazon.com Gift Card" +msgstr "" + +#: src/js/controllers/buyMercadoLibre.js:237 +msgid "{{amountStr}} for Mercado Livre Brazil Gift Card" +msgstr "" + +#: www/views/preferencesBwsUrl.html:21 +msgid "{{appName}} depends on Bitcore Wallet Service (BWS) for blockchain information, networking and Copayer synchronization. The default configuration points to https://bws.bitpay.com (BitPay's public BWS instance)." +msgstr "" + +#: src/js/controllers/confirm.js:408 +msgid "{{fee}} will be deducted for bitcoin networking fees." +msgstr "" + +#: www/views/confirm.html:85 +msgid "{{tx.txp[wallet.id].feeRatePerStr}} of the sending amount" +msgstr "" + +#: www/views/walletDetails.html:218 +msgid "{{updatingTxHistoryProgress}} transactions downloaded" +msgstr "" + +#: www/views/cashScan.html:33 +#: www/views/copayers.html:46 +#: www/views/includes/walletInfo.html:18 +msgid "{{wallet.m}}-of-{{wallet.n}}" +msgstr "" diff --git a/i18n/po/vi/template-vi.po b/i18n/po/vi/template-vi.po index c005c649d..d965b6ee8 100644 --- a/i18n/po/vi/template-vi.po +++ b/i18n/po/vi/template-vi.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Vietnamese\n" "Language: vi\n" -"PO-Revision-Date: 2018-06-22T04:02:59+0000\n" +"PO-Revision-Date: 2018-07-04 03:58\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -54,67 +54,71 @@ msgstr "A total of {{amountAboveMaxSizeStr}} were excluded. The maximum size all #: src/js/controllers/confirm.js:395 msgid "A total of {{amountBelowFeeStr}} were excluded. These funds come from UTXOs smaller than the network fee provided." -msgstr "" +msgstr "A total of {{amountBelowFeeStr}} were excluded. These funds come from UTXOs smaller than the network fee provided." #: src/js/controllers/preferencesAbout.js:6 #: www/views/tab-settings.html:156 msgid "About" -msgstr "" +msgstr "About" #: src/js/controllers/modals/txpDetails.js:62 #: src/js/controllers/tx-details.js:79 msgid "Accepted" -msgstr "" +msgstr "Accepted" #: www/views/preferencesInformation.html:72 msgid "Account" -msgstr "" +msgstr "Account" #: www/views/join.html:72 #: www/views/tab-create-personal.html:45 #: www/views/tab-create-shared.html:74 #: www/views/tab-import-hardware.html:19 msgid "Account Number" +msgstr "Account Number" + +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" msgstr "" #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" -msgstr "" +msgstr "Accounts" #: www/views/bitpayCard.html:56 msgid "Activity" -msgstr "" +msgstr "Activity" #: src/js/services/bitpayAccountService.js:83 msgid "Add Account" -msgstr "" +msgstr "Add Account" #: src/js/services/bitpayAccountService.js:69 msgid "Add BitPay Account?" -msgstr "" +msgstr "Add BitPay Account?" #: www/views/addressbook.add.html:4 #: www/views/addressbook.html:22 msgid "Add Contact" -msgstr "" +msgstr "Add Contact" #: www/views/bitpayCard.html:28 msgid "Add Funds" -msgstr "" +msgstr "Add Funds" #: www/views/confirm.html:94 msgid "Add Memo" -msgstr "" +msgstr "Add Memo" #: www/views/join.html:87 #: www/views/tab-create-personal.html:59 #: www/views/tab-create-shared.html:88 msgid "Add a password" -msgstr "" +msgstr "Add a password" #: www/views/includes/accountSelector.html:27 msgid "Add account" -msgstr "" +msgstr "Add account" #: www/views/join.html:90 #: www/views/tab-create-personal.html:62 diff --git a/i18n/po/zh-CN/template-zh-CN.po b/i18n/po/zh-CN/template-zh-CN.po index 016f4db91..8c274b798 100644 --- a/i18n/po/zh-CN/template-zh-CN.po +++ b/i18n/po/zh-CN/template-zh-CN.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Chinese Simplified\n" "Language: zh\n" -"PO-Revision-Date: 2018-06-22T04:02:44+0000\n" +"PO-Revision-Date: 2018-07-04 03:57\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -77,6 +77,10 @@ msgstr "帐户" msgid "Account Number" msgstr "帐号" +#: www/views/tab-home.html:61 +msgid "Instant transactions with low fees" +msgstr "" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "帐户" From aa9a4575687e3fdceb5c1492264abc0fcd497d4d Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Wed, 4 Jul 2018 23:38:18 +0900 Subject: [PATCH 043/386] Update a text --- www/views/includes/walletSelector.html | 1 - 1 file changed, 1 deletion(-) diff --git a/www/views/includes/walletSelector.html b/www/views/includes/walletSelector.html index f0e4516fd..136aa4694 100644 --- a/www/views/includes/walletSelector.html +++ b/www/views/includes/walletSelector.html @@ -41,7 +41,6 @@
Bitcoin Core (BTC)
-
Slow transactions with high fees
Date: Wed, 4 Jul 2018 23:46:23 +0900 Subject: [PATCH 044/386] Update appConfig.json --- app-template/bitcoincom/appConfig.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app-template/bitcoincom/appConfig.json b/app-template/bitcoincom/appConfig.json index 9dc184e7c..28e24e9fb 100644 --- a/app-template/bitcoincom/appConfig.json +++ b/app-template/bitcoincom/appConfig.json @@ -24,9 +24,9 @@ "windowsAppId": "804636ee-b017-4cad-8719-e58ac97ffa5c", "pushSenderId": "1036948132229", "description": "A Secure Bitcoin Wallet", - "version": "4.12.1", - "fullVersion": "4.12-rc2", - "androidVersion": "412100", + "version": "4.12.2", + "fullVersion": "4.12-rc3", + "androidVersion": "412200", "_extraCSS": "", "_enabledExtensions": { "coinbase": false, From 1ee95cf26268346d0ea59f166ca799a72fbe3707 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 9 Jul 2018 18:22:11 +0200 Subject: [PATCH 045/386] new send-tab --- src/js/controllers/tab-send-v2.js | 301 +++++++++++++++++++++++++ src/js/directives/gravatar.js | 17 +- src/js/routes.js | 9 + src/js/services/clipboardService.js | 20 ++ src/sass/buttons.scss | 23 ++ src/sass/views/address-book.scss | 1 - src/sass/views/tab-send-v2.scss | 228 +++++++++++++++++++ src/sass/views/views.scss | 1 + www/img/contact-placeholder.svg | 30 ++- www/img/icon-clipboard-paste-white.svg | 25 ++ www/img/icon-clipboard-paste.svg | 25 ++ www/img/icon-contact-add.svg | 10 + www/img/icon-scan-qr.svg | 63 ++++++ www/img/icon-w2w.svg | 26 +++ www/views/tab-send-v2.html | 143 ++++++++++++ www/views/tabs.html | 2 +- 16 files changed, 907 insertions(+), 17 deletions(-) create mode 100644 src/js/controllers/tab-send-v2.js create mode 100644 src/sass/views/tab-send-v2.scss create mode 100644 www/img/icon-clipboard-paste-white.svg create mode 100644 www/img/icon-clipboard-paste.svg create mode 100644 www/img/icon-contact-add.svg create mode 100644 www/img/icon-scan-qr.svg create mode 100644 www/img/icon-w2w.svg create mode 100644 www/views/tab-send-v2.html diff --git a/src/js/controllers/tab-send-v2.js b/src/js/controllers/tab-send-v2.js new file mode 100644 index 000000000..624acb5bb --- /dev/null +++ b/src/js/controllers/tab-send-v2.js @@ -0,0 +1,301 @@ +'use strict'; + +angular.module('copayApp.controllers').controller('tabSendV2Controller', function($scope, $rootScope, $log, $timeout, $ionicScrollDelegate, addressbookService, profileService, lodash, $state, walletService, incomingData, popupService, platformInfo, bwcError, gettextCatalog, scannerService, configService, bitcoinCashJsService, $ionicNavBarDelegate, clipboardService) { + var clipboardHasAddress = false; + + $scope.addContact = function() { + $state.go('tabs.settings').then(function() { + $state.go('tabs.addressbook').then(function() { + $state.go('tabs.addressbook.add'); + }); + }); + }; + + $scope.pasteClipboard = function() { + clipboardService.readFromClipboard(function(text) { + $scope.formData.search = text; + $scope.findContact($scope.formData.search); + }); + } + + $scope.$on("$ionicView.enter", function(event, data) { + clipboardService.readFromClipboard(function(text) { + $scope.clipboardHasAddress = false; + if ((text.indexOf('bitcoincash:') === 0 || text[0] === 'C' || text[0] === 'H' || text[0] === 'p' || text[0] === 'q') && text.replace('bitcoincash:', '').length === 42) { // CashAddr + $scope.clipboardHasAddress = true; + } else if ((text[0] === "1" || text[0] === "3" || text.substring(0, 3) === "bc1") && text.length >= 26 && text.length <= 35) { // Legacy Addresses + $scope.clipboardHasAddress = true; + } + }); + + $ionicNavBarDelegate.showBar(true); + if (!$scope.hasWallets) { + $scope.checkingBalance = false; + return; + } + updateHasFunds(); + updateWalletsList(); + updateContactsList(function() { + updateList(); + }); + }); + + + + + + + + + + + + + + + + + var originalList; + var CONTACTS_SHOW_LIMIT; + var currentContactsPage; + + $scope.sectionDisplay = { + transferToWallet: false + }; + + var hasWallets = function() { + $scope.wallets = profileService.getWallets({ + onlyComplete: true + }); + $scope.hasWallets = lodash.isEmpty($scope.wallets) ? false : true; + }; + + // THIS is ONLY to show the 'buy bitcoins' message + // does not has any other function. + + var updateHasFunds = function() { + + if ($rootScope.everHasFunds) { + $scope.hasFunds = true; + return; + } + + $scope.hasFunds = false; + var index = 0; + lodash.each($scope.wallets, function(w) { + walletService.getStatus(w, {}, function(err, status) { + + ++index; + if (err && !status) { + $log.error(err); + // error updating the wallet. Probably a network error, do not show + // the 'buy bitcoins' message. + + $scope.hasFunds = true; + } else if (status.availableBalanceSat > 0) { + $scope.hasFunds = true; + $rootScope.everHasFunds = true; + } + + if (index == $scope.wallets.length) { + $scope.checkingBalance = false; + $timeout(function() { + $scope.$apply(); + }); + } + }); + }); + }; + + var updateWalletsList = function() { + var config = configService.getSync(); + var networkResult = lodash.countBy($scope.wallets, 'network'); + + $scope.showTransferCard = $scope.hasWallets && (networkResult.livenet > 1 || networkResult.testnet > 1); + + if ($scope.showTransferCard) { + var walletsToTransfer = $scope.wallets; + if (!(networkResult.livenet > 1)) { + walletsToTransfer = lodash.filter(walletsToTransfer, function(item) { + return item.network == 'testnet'; + }); + } + if (!(networkResult.testnet > 1)) { + walletsToTransfer = lodash.filter(walletsToTransfer, function(item) { + return item.network == 'livenet'; + }); + } + + var walletList = []; + lodash.each(walletsToTransfer, function(v) { + var displayBalanceAsFiat = + // BD got v.status as undefined here once during development, just + // after creating a new wallet. + v.status && + v.status.alternativeBalanceAvailable && + config.wallet.settings.priceDisplay === 'fiat'; + + walletList.push({ + color: v.color, + name: v.name, + recipientType: 'wallet', + coin: v.coin, + network: v.network, + balanceString: displayBalanceAsFiat ? + v.status.totalBalanceAlternative + ' ' + v.status.alternativeIsoCode : + v.cachedBalance, + getAddress: function(cb) { + walletService.getAddress(v, false, cb); + }, + }); + }); + originalList = originalList.concat(walletList); + } + } + + var updateContactsList = function(cb) { + var config = configService.getSync(); + var defaults = configService.getDefaults(); + addressbookService.list(function(err, ab) { + if (err) $log.error(err); + + $scope.hasContacts = lodash.isEmpty(ab) ? false : true; + if (!$scope.hasContacts) return cb(); + + var completeContacts = []; + lodash.each(ab, function(v, k) { + completeContacts.push({ + name: lodash.isObject(v) ? v.name : v, + address: k, + email: lodash.isObject(v) ? v.email : null, + recipientType: 'contact', + coin: v.coin, + displayCoin: (v.coin == 'bch' + ? (config.bitcoinCashAlias || defaults.bitcoinCashAlias) + : (config.bitcoinAlias || defaults.bitcoinAlias)).toUpperCase(), + getAddress: function(cb) { + return cb(null, k); + }, + }); + }); + var contacts = completeContacts.slice(0, (currentContactsPage + 1) * CONTACTS_SHOW_LIMIT); + $scope.contactsShowMore = completeContacts.length > contacts.length; + originalList = originalList.concat(contacts); + return cb(); + }); + }; + + var updateList = function() { + $scope.list = lodash.clone(originalList); + $timeout(function() { + $ionicScrollDelegate.resize(); + $scope.$apply(); + }, 10); + }; + + $scope.openScanner = function() { + var isWindowsPhoneApp = platformInfo.isCordova && platformInfo.isWP; + + if (!isWindowsPhoneApp) { + $state.go('tabs.scan'); + return; + } + + scannerService.useOldScanner(function(err, contents) { + if (err) { + popupService.showAlert(gettextCatalog.getString('Error'), err); + return; + } + incomingData.redir(contents); + }); + }; + + $scope.showMore = function() { + currentContactsPage++; + updateWalletsList(); + }; + + $scope.searchInFocus = function() { + $scope.searchFocus = true; + }; + + $scope.searchBlurred = function() { + if ($scope.formData.search == null || $scope.formData.search.length == 0) { + $scope.searchFocus = false; + } + }; + + $scope.findContact = function(search) { + + if (incomingData.redir(search)) { + return; + } + + if (!search || search.length < 2) { + $scope.list = originalList; + $timeout(function() { + $scope.$apply(); + }); + return; + } + + var result = lodash.filter(originalList, function(item) { + var val = item.name; + return lodash.includes(val.toLowerCase(), search.toLowerCase()); + }); + + $scope.list = result; + }; + + $scope.goToAmount = function(item) { + $timeout(function() { + item.getAddress(function(err, addr) { + if (err || !addr) { + //Error is already formated + return popupService.showAlert(err); + } + + if (item.recipientType && item.recipientType == 'contact') { + if (addr.indexOf('bch') == 0 || addr.indexOf('btc') == 0) { + addr = addr.substring(3); + } + } + + $log.debug('Got toAddress:' + addr + ' | ' + item.name); + return $state.transitionTo('tabs.send.amount', { + recipientType: item.recipientType, + displayAddress: item.coin == 'bch' ? bitcoinCashJsService.translateAddresses(addr).cashaddr : addr, + toAddress: addr, + toName: item.name, + toEmail: item.email, + toColor: item.color, + coin: item.coin + }); + }); + }); + }; + + // This could probably be enhanced refactoring the routes abstract states + $scope.createWallet = function() { + $state.go('tabs.home').then(function() { + $state.go('tabs.add.create-personal'); + }); + }; + + $scope.buyBitcoin = function() { + $state.go('tabs.home').then(function() { + $state.go('tabs.buyandsell'); + }); + }; + + $scope.$on("$ionicView.beforeEnter", function(event, data) { + $scope.checkingBalance = true; + $scope.formData = { + search: null + }; + originalList = []; + CONTACTS_SHOW_LIMIT = 10; + currentContactsPage = 0; + hasWallets(); + }); +}); diff --git a/src/js/directives/gravatar.js b/src/js/directives/gravatar.js index 5f7931798..c96a63cfe 100644 --- a/src/js/directives/gravatar.js +++ b/src/js/directives/gravatar.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.directives') - .directive('gravatar', function(md5) { + .directive('gravatar', function(md5, $http) { return { restrict: 'AE', replace: true, @@ -9,13 +9,24 @@ angular.module('copayApp.directives') name: '@', height: '@', width: '@', - email: '@' + email: '@', + url: '@' }, link: function(scope, el, attr) { if (typeof scope.email === "string") { scope.emailHash = md5.createHash(scope.email.toLowerCase() || ''); + var req = { + method: 'GET', + url: 'https://secure.gravatar.com/'+scope.emailHash+'.json', + }; + scope.url = 'img/contact-placeholder.svg'; + $http(req).then(function (response) { + scope.url = 'https://secure.gravatar.com/avatar/'+scope.emailHash+'.jpg?s='+scope.width+'&d=mm'; + }, function (error) { + scope.url = 'img/contact-placeholder.svg'; + }); } }, - template: '{{ name }}' + template: '{{ name }}' }; }); diff --git a/src/js/routes.js b/src/js/routes.js index 4e72246ba..2399a2db9 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -270,6 +270,15 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } } }) + .state('tabs.send2', { + url: '/send2', + views: { + 'tab-send': { + controller: 'tabSendV2Controller', + templateUrl: 'views/tab-send-v2.html', + } + } + }) .state('tabs.settings', { url: '/settings', views: { diff --git a/src/js/services/clipboardService.js b/src/js/services/clipboardService.js index e2e0e5fb3..ff28cd2e7 100644 --- a/src/js/services/clipboardService.js +++ b/src/js/services/clipboardService.js @@ -17,7 +17,27 @@ angular.module('copayApp.services').factory('clipboardService', function ($http, // No supported return; } + }; + root.readFromClipboard = function (cb) { + $log.debug("Read from clipboard"); + if (platformInfo.isCordova) { + cordova.plugins.clipboard.paste(function(text) { + cb(text); + }) + } else if (platformInfo.isNW) { + cb(nodeWebkitService.readFromClipboard()); + } else { + navigator.clipboard.readText() + .then(text => { + cb(text); + }) + .catch(err => { + $log.debug("Clipboard reading is not supported in browser.."); + }); + + return; + } }; return root; diff --git a/src/sass/buttons.scss b/src/sass/buttons.scss index 348d6d378..a8512ae64 100644 --- a/src/sass/buttons.scss +++ b/src/sass/buttons.scss @@ -16,6 +16,8 @@ &.button-primary, &.button-secondary, &.button-light, + &.button-white, + &.button-green, &.button-assertive { &.button-standard { @extend %button-standard; @@ -33,6 +35,10 @@ } } +@mixin button-shadow() { + box-shadow: 0 2px 11px 0 #C1C1C1;; +} + .button { &.button-secondary { @include button-style($v-button-secondary-bg, $v-button-secondary-border, $v-button-secondary-active-bg, $v-button-secondary-active-border, $v-button-secondary-color); @@ -47,7 +53,24 @@ } .button { + border-radius: 6px; &.button-full { display: block; } + &-green { + @include button-style(#719561, #FFF, #606060, #FFF, #FFF); + @include button-clear(#FFF); + @include button-outline(#C1C1C1); + border: 0px; + @include button-shadow(); + } + &-white { + @include button-style(#FFF, #C1C1C1, #C1C1C1, #FFF, #606060); + @include button-clear(#FFF); + @include button-outline(#C1C1C1); + @include button-shadow(); + &.activated { + color: #FFF; + } + } } \ No newline at end of file diff --git a/src/sass/views/address-book.scss b/src/sass/views/address-book.scss index c0d0f99a8..8bbdbc6be 100644 --- a/src/sass/views/address-book.scss +++ b/src/sass/views/address-book.scss @@ -124,7 +124,6 @@ position: relative; height: 70px; border-color: $royal; - background-color: $royal; padding-top: 20px; margin-bottom: 50px; text-align: center; diff --git a/src/sass/views/tab-send-v2.scss b/src/sass/views/tab-send-v2.scss new file mode 100644 index 000000000..e9905fc17 --- /dev/null +++ b/src/sass/views/tab-send-v2.scss @@ -0,0 +1,228 @@ +#tab-send2 { + @extend .deflash-blue; + .input { + width: 100%; + input { + width: 100%; + height: 57px; + background: #FFF; + border: 1px #D9D9D9 solid; + &::placeholder { + color: #DCDCDC; + } + } + i { + &.left { + padding-left: 15px; + } + &.qr { + cursor: pointer; + cursor: hand; + padding-right: 5px; + } + } + } + + .send-wrapper { + &:after { + display: block; + position: relative; + height: 1px; + background: #DEDEDE; + bottom: 0; + content: ''; + margin: 20px 6px 0px; + } + margin: 18px 0 0; + padding: 9px; + background-color: #f2f2f2; + border-radius: 3px; + border: none; + &.focus { + .search-input { + padding-left: 30px; + &:focus::-webkit-input-placeholder { + opacity: 0; + } + } + } + .buttons { + margin: auto; + margin-top: 18px; + .button { + &-clipboard-paste { + margin-left: 0; + .address { + display: none; + } + .icon { + background: url(../img/icon-clipboard-paste.svg); + width: 15px; + height: 19px; + display: inline-block; + margin-bottom: 4px; + } + &.contains-address { + background: #FAB915; + color: #FFF !important; + border: 0; + @include button-shadow(); + .icon { + background: url(../img/icon-clipboard-paste-white.svg); + } + .address { + display: inline; + } + .non-address { + display: none; + } + } + } + span { + font-size: 14px; + } + img { + height: 16px; + width: auto; + margin: 2px 0 4px; + } + height: 60px; + line-height: 16px; + margin-right: 0px; + width: 95%; + max-width: none; + padding: 2px; + &-qr { + font-weight: bold; + max-width: none; + width: 100%; + height: 95px; + margin-top: 20px; + img { + vertical-align: middle; + margin-right: 12px; + width: 43px; + height: 43px; + } + span { + font-size: 19px; + } + } + } + } + } + .search-input { + background-color: transparent; + padding-left: 30px; + } + .sendTip { + padding-top: 5vh; + text-align: center; + .item { + border-style: none; + } + & > .title { + font-size: 20px; + color: $v-dark-gray; + margin: 20px 10px; + } + & > .subtitle { + font-size: 1rem; + line-height: 1.5em; + font-weight: 300; + color: #6F6F70; + margin: 20px 1em 2.5em; + } + .big-icon-svg { + .bg.green { + padding: 0 10px; + box-shadow: none; + } + } + .buttons { + margin-top: 18px; + .button { + font-weight: bold; + font-size: 19px; + } + } + .button-first-contact img { + height: 19px; + width: 19px; + margin-right: 6px; + vertical-align: sub; + } + } + .item-heading { + line-height: 16px; + font-size: 14px; + font-weight: bold; + .subtitle { + color: #B5B2B2; + font-size: 12px; + font-weight: 300; + } + } + .list { + .item { + font-weight: 600; + padding-top: 12px; + padding-bottom: 12px; + p { + font-weight: normal; + } + &.item-icon-left { + padding-left: 64px; + } + color: #444; + //border-top: none; + padding-top: 1.5rem; + padding-bottom: 1.5rem; + .big-icon-svg { + left: 5px; + & > .bg { + width: 30px; + height: 30px; + box-shadow: none; + } + } + &:before { + display: block; + position: absolute; + width: 100%; + height: 1px; + background: rgba(221, 221, 221, 0.3); + top: 0; + right: 0; + content: ''; + } + &.item-divider { + color: rgba(74, 74, 74, .8); + } + &.item-heading { + &:before { + top: 99%; + width: 100%; + } + } + &:nth-child(2) { + &:before { + width: 0; + } + } + .item-note { + color: rgb(58, 58, 58); + } + } + } + .scroll { + height: 100%; + } + + .card.contacts { + margin: 4px; + border-radius: 6px; + box-shadow: 0px 2px 1px 0 #C1C1C1; + } + +} diff --git a/src/sass/views/views.scss b/src/sass/views/views.scss index 37754970f..5367ac5aa 100644 --- a/src/sass/views/views.scss +++ b/src/sass/views/views.scss @@ -8,6 +8,7 @@ @import "tab-receive"; @import "tab-scan"; @import "tab-send"; +@import "tab-send-v2"; @import "tab-settings"; @import "wallet-colors"; @import "walletBalance"; diff --git a/www/img/contact-placeholder.svg b/www/img/contact-placeholder.svg index f730da86b..54b0fcec2 100644 --- a/www/img/contact-placeholder.svg +++ b/www/img/contact-placeholder.svg @@ -1,12 +1,18 @@ - - - - - - + + + + Artboard + Created with Sketch. + + + + + + + + + + + + + \ No newline at end of file diff --git a/www/img/icon-clipboard-paste-white.svg b/www/img/icon-clipboard-paste-white.svg new file mode 100644 index 000000000..be0df78bc --- /dev/null +++ b/www/img/icon-clipboard-paste-white.svg @@ -0,0 +1,25 @@ + + + + + + + + + + + + diff --git a/www/img/icon-clipboard-paste.svg b/www/img/icon-clipboard-paste.svg new file mode 100644 index 000000000..a82edc11b --- /dev/null +++ b/www/img/icon-clipboard-paste.svg @@ -0,0 +1,25 @@ + + + + + + + + + + + + diff --git a/www/img/icon-contact-add.svg b/www/img/icon-contact-add.svg new file mode 100644 index 000000000..36d1f95bc --- /dev/null +++ b/www/img/icon-contact-add.svg @@ -0,0 +1,10 @@ + + + + + + diff --git a/www/img/icon-scan-qr.svg b/www/img/icon-scan-qr.svg new file mode 100644 index 000000000..bc4a2bc56 --- /dev/null +++ b/www/img/icon-scan-qr.svg @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/www/img/icon-w2w.svg b/www/img/icon-w2w.svg new file mode 100644 index 000000000..082a0d8cc --- /dev/null +++ b/www/img/icon-w2w.svg @@ -0,0 +1,26 @@ + + + + + + + + + + + + + diff --git a/www/views/tab-send-v2.html b/www/views/tab-send-v2.html new file mode 100644 index 000000000..b42784957 --- /dev/null +++ b/www/views/tab-send-v2.html @@ -0,0 +1,143 @@ + + + {{'Send' | translate}} + + +
+
+
+
+ +
+
+
+
+
+ +
+
+ +
+
+
+ +
+
+
+
+ +
+ +
+
+
+ Your Bitcoin wallet is empty +
+
+
+

To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address.

+

You can receive bitcoin from any wallet or service.

+
+
To get started, you'll need to create a bitcoin wallet and get some + bitcoin. +
+
+ + + +
+
+
+
+
+
+
+ +
+
Contacts
+
Saved frequently used addresses
+ + + +
+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/www/views/tabs.html b/www/views/tabs.html index 69cf93309..19c33aad9 100644 --- a/www/views/tabs.html +++ b/www/views/tabs.html @@ -12,7 +12,7 @@ - + From a2bd6fc31906ec56f14c0b7a263dc2783e614a2c Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 10 Jul 2018 16:39:30 +0900 Subject: [PATCH 046/386] Init BitAnalytics --- Gruntfile.js | 9 +- app-template/index.html | 3 +- bitanalytics/bitanalytics-0.1.0.js | 6493 ++++++++++++++++++++++++++++ src/js/routes.js | 6 +- www/index.html | 3 +- 5 files changed, 6510 insertions(+), 4 deletions(-) create mode 100644 bitanalytics/bitanalytics-0.1.0.js diff --git a/Gruntfile.js b/Gruntfile.js index 7ae74ed17..342cc85e7 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -161,6 +161,12 @@ module.exports = function(grunt) { ], dest: 'www/lib/bitcoin-cash-js.js' }, + bitanalytics: { + src: [ + 'bitanalytics/bitanalytics-0.1.0.js' + ], + dest: 'www/lib/bitanalytics.js' + }, js: { src: [ 'src/js/app.js', @@ -202,7 +208,8 @@ module.exports = function(grunt) { files: { 'www/js/app.js': ['www/js/app.js'], 'www/lib/angular-components.js': ['www/lib/angular-components.js'], - 'www/lib/bitcoin-cash-js.js': ['www/lib/bitcoin-cash-js.js'] + 'www/lib/bitcoin-cash-js.js': ['www/lib/bitcoin-cash-js.js'], + 'www/lib/bitanalytics.js': ['www/lib/bitanalytics.js'] } } }, diff --git a/app-template/index.html b/app-template/index.html index 2946d7928..fe5262f52 100644 --- a/app-template/index.html +++ b/app-template/index.html @@ -11,7 +11,7 @@ - *USERVISIBLENAME* - *PURPOSELINE* + *USERVISIBLENAME* @@ -31,6 +31,7 @@ + diff --git a/bitanalytics/bitanalytics-0.1.0.js b/bitanalytics/bitanalytics-0.1.0.js new file mode 100644 index 000000000..c1907d7a5 --- /dev/null +++ b/bitanalytics/bitanalytics-0.1.0.js @@ -0,0 +1,6493 @@ +(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.bitanalytics = f()}})(function(){var define,module,exports;return (function(){function r(e,n,t){function o(i,f){if(!n[i]){if(!e[i]){var c="function"==typeof require&&require;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,function(r){var n=e[i][1][r];return o(n||r)},p,p.exports,r,e,n,t)}return n[i].exports}for(var u="function"==typeof require&&require,i=0;i/g, '>') + .replace(/"/g, '"') + .replace(/'/g, '''); + } + return escaped; +}; + +_.extend = function(obj) { + _.each(slice.call(arguments, 1), function(source) { + for (var prop in source) { + if (source[prop] !== void 0) { + obj[prop] = source[prop]; + } + } + }); + return obj; +}; + +_.isArray = nativeIsArray || function(obj) { + return toString.call(obj) === '[object Array]'; +}; + +// from a comment on http://dbj.org/dbj/?p=286 +// fails on only one very rare and deliberate custom object: +// var bomb = { toString : undefined, valueOf: function(o) { return "function BOMBA!"; }}; +_.isFunction = function(f) { + try { + return /^\s*\bfunction\b/.test(f); + } catch (x) { + return false; + } +}; + +_.isArguments = function(obj) { + return !!(obj && hasOwnProperty.call(obj, 'callee')); +}; + +_.toArray = function(iterable) { + if (!iterable) { + return []; + } + if (iterable.toArray) { + return iterable.toArray(); + } + if (_.isArray(iterable)) { + return slice.call(iterable); + } + if (_.isArguments(iterable)) { + return slice.call(iterable); + } + return _.values(iterable); +}; + +_.keys = function(obj) { + var results = []; + if (obj === null) { + return results; + } + _.each(obj, function(value, key) { + results[results.length] = key; + }); + return results; +}; + +_.values = function(obj) { + var results = []; + if (obj === null) { + return results; + } + _.each(obj, function(value) { + results[results.length] = value; + }); + return results; +}; + +_.identity = function(value) { + return value; +}; + +_.include = function(obj, target) { + var found = false; + if (obj === null) { + return found; + } + if (nativeIndexOf && obj.indexOf === nativeIndexOf) { + return obj.indexOf(target) != -1; + } + _.each(obj, function(value) { + if (found || (found = (value === target))) { + return breaker; + } + }); + return found; +}; + +_.includes = function(str, needle) { + return str.indexOf(needle) !== -1; +}; + +// Underscore Addons +_.inherit = function(subclass, superclass) { + subclass.prototype = new superclass(); + subclass.prototype.constructor = subclass; + subclass.superclass = superclass.prototype; + return subclass; +}; + +_.isObject = function(obj) { + return (obj === Object(obj) && !_.isArray(obj)); +}; + +_.isEmptyObject = function(obj) { + if (_.isObject(obj)) { + for (var key in obj) { + if (hasOwnProperty.call(obj, key)) { + return false; + } + } + return true; + } + return false; +}; + +_.isUndefined = function(obj) { + return obj === void 0; +}; + +_.isString = function(obj) { + return toString.call(obj) == '[object String]'; +}; + +_.isDate = function(obj) { + return toString.call(obj) == '[object Date]'; +}; + +_.isNumber = function(obj) { + return toString.call(obj) == '[object Number]'; +}; + +_.isElement = function(obj) { + return !!(obj && obj.nodeType === 1); +}; + +_.encodeDates = function(obj) { + _.each(obj, function(v, k) { + if (_.isDate(v)) { + obj[k] = _.formatDate(v); + } else if (_.isObject(v)) { + obj[k] = _.encodeDates(v); // recurse + } + }); + return obj; +}; + +_.timestamp = function() { + Date.now = Date.now || function() { + return +new Date; + }; + return Date.now(); +}; + +_.formatDate = function(d) { + // YYYY-MM-DDTHH:MM:SS in UTC + function pad(n) { + return n < 10 ? '0' + n : n; + } + return d.getUTCFullYear() + '-' + + pad(d.getUTCMonth() + 1) + '-' + + pad(d.getUTCDate()) + 'T' + + pad(d.getUTCHours()) + ':' + + pad(d.getUTCMinutes()) + ':' + + pad(d.getUTCSeconds()); +}; + +_.safewrap = function(f) { + return function() { + try { + return f.apply(this, arguments); + } catch (e) { + console$1.critical('Implementation error. Please turn on debug and contact support@mixpanel.com.'); + if (Config.DEBUG){ + console$1.critical(e); + } + } + }; +}; + +_.safewrap_class = function(klass, functions) { + for (var i = 0; i < functions.length; i++) { + klass.prototype[functions[i]] = _.safewrap(klass.prototype[functions[i]]); + } +}; + +_.safewrap_instance_methods = function(obj) { + for (var func in obj) { + if (typeof(obj[func]) === 'function') { + obj[func] = _.safewrap(obj[func]); + } + } +}; + +_.strip_empty_properties = function(p) { + var ret = {}; + _.each(p, function(v, k) { + if (_.isString(v) && v.length > 0) { + ret[k] = v; + } + }); + return ret; +}; + +/* + * this function returns a copy of object after truncating it. If + * passed an Array or Object it will iterate through obj and + * truncate all the values recursively. + */ +_.truncate = function(obj, length) { + var ret; + + if (typeof(obj) === 'string') { + ret = obj.slice(0, length); + } else if (_.isArray(obj)) { + ret = []; + _.each(obj, function(val) { + ret.push(_.truncate(val, length)); + }); + } else if (_.isObject(obj)) { + ret = {}; + _.each(obj, function(val, key) { + ret[key] = _.truncate(val, length); + }); + } else { + ret = obj; + } + + return ret; +}; + +_.JSONEncode = (function() { + return function(mixed_val) { + var value = mixed_val; + var quote = function(string) { + var escapable = /[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g; // eslint-disable-line no-control-regex + var meta = { // table of character substitutions + '\b': '\\b', + '\t': '\\t', + '\n': '\\n', + '\f': '\\f', + '\r': '\\r', + '"': '\\"', + '\\': '\\\\' + }; + + escapable.lastIndex = 0; + return escapable.test(string) ? + '"' + string.replace(escapable, function(a) { + var c = meta[a]; + return typeof c === 'string' ? c : + '\\u' + ('0000' + a.charCodeAt(0).toString(16)).slice(-4); + }) + '"' : + '"' + string + '"'; + }; + + var str = function(key, holder) { + var gap = ''; + var indent = ' '; + var i = 0; // The loop counter. + var k = ''; // The member key. + var v = ''; // The member value. + var length = 0; + var mind = gap; + var partial = []; + var value = holder[key]; + + // If the value has a toJSON method, call it to obtain a replacement value. + if (value && typeof value === 'object' && + typeof value.toJSON === 'function') { + value = value.toJSON(key); + } + + // What happens next depends on the value's type. + switch (typeof value) { + case 'string': + return quote(value); + + case 'number': + // JSON numbers must be finite. Encode non-finite numbers as null. + return isFinite(value) ? String(value) : 'null'; + + case 'boolean': + case 'null': + // If the value is a boolean or null, convert it to a string. Note: + // typeof null does not produce 'null'. The case is included here in + // the remote chance that this gets fixed someday. + + return String(value); + + case 'object': + // If the type is 'object', we might be dealing with an object or an array or + // null. + // Due to a specification blunder in ECMAScript, typeof null is 'object', + // so watch out for that case. + if (!value) { + return 'null'; + } + + // Make an array to hold the partial results of stringifying this object value. + gap += indent; + partial = []; + + // Is the value an array? + if (toString.apply(value) === '[object Array]') { + // The value is an array. Stringify every element. Use null as a placeholder + // for non-JSON values. + + length = value.length; + for (i = 0; i < length; i += 1) { + partial[i] = str(i, value) || 'null'; + } + + // Join all of the elements together, separated with commas, and wrap them in + // brackets. + v = partial.length === 0 ? '[]' : + gap ? '[\n' + gap + + partial.join(',\n' + gap) + '\n' + + mind + ']' : + '[' + partial.join(',') + ']'; + gap = mind; + return v; + } + + // Iterate through all of the keys in the object. + for (k in value) { + if (hasOwnProperty.call(value, k)) { + v = str(k, value); + if (v) { + partial.push(quote(k) + (gap ? ': ' : ':') + v); + } + } + } + + // Join all of the member texts together, separated with commas, + // and wrap them in braces. + v = partial.length === 0 ? '{}' : + gap ? '{' + partial.join(',') + '' + + mind + '}' : '{' + partial.join(',') + '}'; + gap = mind; + return v; + } + }; + + // Make a fake root object containing our value under the key of ''. + // Return the result of stringifying the value. + return str('', { + '': value + }); + }; +})(); + +/** + * From https://github.com/douglascrockford/JSON-js/blob/master/json_parse.js + * Slightly modified to throw a real Error rather than a POJO + */ +_.JSONDecode = (function() { + var at, // The index of the current character + ch, // The current character + escapee = { + '"': '"', + '\\': '\\', + '/': '/', + 'b': '\b', + 'f': '\f', + 'n': '\n', + 'r': '\r', + 't': '\t' + }, + text, + error = function(m) { + var e = new SyntaxError(m); + e.at = at; + e.text = text; + throw e; + }, + next = function(c) { + // If a c parameter is provided, verify that it matches the current character. + if (c && c !== ch) { + error('Expected \'' + c + '\' instead of \'' + ch + '\''); + } + // Get the next character. When there are no more characters, + // return the empty string. + ch = text.charAt(at); + at += 1; + return ch; + }, + number = function() { + // Parse a number value. + var number, + string = ''; + + if (ch === '-') { + string = '-'; + next('-'); + } + while (ch >= '0' && ch <= '9') { + string += ch; + next(); + } + if (ch === '.') { + string += '.'; + while (next() && ch >= '0' && ch <= '9') { + string += ch; + } + } + if (ch === 'e' || ch === 'E') { + string += ch; + next(); + if (ch === '-' || ch === '+') { + string += ch; + next(); + } + while (ch >= '0' && ch <= '9') { + string += ch; + next(); + } + } + number = +string; + if (!isFinite(number)) { + error('Bad number'); + } else { + return number; + } + }, + + string = function() { + // Parse a string value. + var hex, + i, + string = '', + uffff; + // When parsing for string values, we must look for " and \ characters. + if (ch === '"') { + while (next()) { + if (ch === '"') { + next(); + return string; + } + if (ch === '\\') { + next(); + if (ch === 'u') { + uffff = 0; + for (i = 0; i < 4; i += 1) { + hex = parseInt(next(), 16); + if (!isFinite(hex)) { + break; + } + uffff = uffff * 16 + hex; + } + string += String.fromCharCode(uffff); + } else if (typeof escapee[ch] === 'string') { + string += escapee[ch]; + } else { + break; + } + } else { + string += ch; + } + } + } + error('Bad string'); + }, + white = function() { + // Skip whitespace. + while (ch && ch <= ' ') { + next(); + } + }, + word = function() { + // true, false, or null. + switch (ch) { + case 't': + next('t'); + next('r'); + next('u'); + next('e'); + return true; + case 'f': + next('f'); + next('a'); + next('l'); + next('s'); + next('e'); + return false; + case 'n': + next('n'); + next('u'); + next('l'); + next('l'); + return null; + } + error('Unexpected "' + ch + '"'); + }, + value, // Placeholder for the value function. + array = function() { + // Parse an array value. + var array = []; + + if (ch === '[') { + next('['); + white(); + if (ch === ']') { + next(']'); + return array; // empty array + } + while (ch) { + array.push(value()); + white(); + if (ch === ']') { + next(']'); + return array; + } + next(','); + white(); + } + } + error('Bad array'); + }, + object = function() { + // Parse an object value. + var key, + object = {}; + + if (ch === '{') { + next('{'); + white(); + if (ch === '}') { + next('}'); + return object; // empty object + } + while (ch) { + key = string(); + white(); + next(':'); + if (Object.hasOwnProperty.call(object, key)) { + error('Duplicate key "' + key + '"'); + } + object[key] = value(); + white(); + if (ch === '}') { + next('}'); + return object; + } + next(','); + white(); + } + } + error('Bad object'); + }; + + value = function() { + // Parse a JSON value. It could be an object, an array, a string, + // a number, or a word. + white(); + switch (ch) { + case '{': + return object(); + case '[': + return array(); + case '"': + return string(); + case '-': + return number(); + default: + return ch >= '0' && ch <= '9' ? number() : word(); + } + }; + + // Return the json_parse function. It will have access to all of the + // above functions and variables. + return function(source) { + var result; + + text = source; + at = 0; + ch = ' '; + result = value(); + white(); + if (ch) { + error('Syntax error'); + } + + return result; + }; +})(); + +_.base64Encode = function(data) { + var b64 = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/='; + var o1, o2, o3, h1, h2, h3, h4, bits, i = 0, + ac = 0, + enc = '', + tmp_arr = []; + + if (!data) { + return data; + } + + data = _.utf8Encode(data); + + do { // pack three octets into four hexets + o1 = data.charCodeAt(i++); + o2 = data.charCodeAt(i++); + o3 = data.charCodeAt(i++); + + bits = o1 << 16 | o2 << 8 | o3; + + h1 = bits >> 18 & 0x3f; + h2 = bits >> 12 & 0x3f; + h3 = bits >> 6 & 0x3f; + h4 = bits & 0x3f; + + // use hexets to index into b64, and append result to encoded string + tmp_arr[ac++] = b64.charAt(h1) + b64.charAt(h2) + b64.charAt(h3) + b64.charAt(h4); + } while (i < data.length); + + enc = tmp_arr.join(''); + + switch (data.length % 3) { + case 1: + enc = enc.slice(0, -2) + '=='; + break; + case 2: + enc = enc.slice(0, -1) + '='; + break; + } + + return enc; +}; + +_.utf8Encode = function(string) { + string = (string + '').replace(/\r\n/g, '\n').replace(/\r/g, '\n'); + + var utftext = '', + start, + end; + var stringl = 0, + n; + + start = end = 0; + stringl = string.length; + + for (n = 0; n < stringl; n++) { + var c1 = string.charCodeAt(n); + var enc = null; + + if (c1 < 128) { + end++; + } else if ((c1 > 127) && (c1 < 2048)) { + enc = String.fromCharCode((c1 >> 6) | 192, (c1 & 63) | 128); + } else { + enc = String.fromCharCode((c1 >> 12) | 224, ((c1 >> 6) & 63) | 128, (c1 & 63) | 128); + } + if (enc !== null) { + if (end > start) { + utftext += string.substring(start, end); + } + utftext += enc; + start = end = n + 1; + } + } + + if (end > start) { + utftext += string.substring(start, string.length); + } + + return utftext; +}; + +_.UUID = (function() { + + // Time/ticks information + // 1*new Date() is a cross browser version of Date.now() + var T = function() { + var d = 1 * new Date(), + i = 0; + + // this while loop figures how many browser ticks go by + // before 1*new Date() returns a new number, ie the amount + // of ticks that go by per millisecond + while (d == 1 * new Date()) { + i++; + } + + return d.toString(16) + i.toString(16); + }; + + // Math.Random entropy + var R = function() { + return Math.random().toString(16).replace('.', ''); + }; + + // User agent entropy + // This function takes the user agent string, and then xors + // together each sequence of 8 bytes. This produces a final + // sequence of 8 bytes which it returns as hex. + var UA = function() { + var ua = userAgent, + i, ch, buffer = [], + ret = 0; + + function xor(result, byte_array) { + var j, tmp = 0; + for (j = 0; j < byte_array.length; j++) { + tmp |= (buffer[j] << j * 8); + } + return result ^ tmp; + } + + for (i = 0; i < ua.length; i++) { + ch = ua.charCodeAt(i); + buffer.unshift(ch & 0xFF); + if (buffer.length >= 4) { + ret = xor(ret, buffer); + buffer = []; + } + } + + if (buffer.length > 0) { + ret = xor(ret, buffer); + } + + return ret.toString(16); + }; + + return function() { + var se = (screen.height * screen.width).toString(16); + return (T() + '-' + R() + '-' + UA() + '-' + se + '-' + T()); + }; +})(); + +// _.isBlockedUA() +// This is to block various web spiders from executing our JS and +// sending false tracking data +_.isBlockedUA = function(ua) { + if (/(google web preview|baiduspider|yandexbot|bingbot|googlebot|yahoo! slurp)/i.test(ua)) { + return true; + } + return false; +}; + +/** + * @param {Object=} formdata + * @param {string=} arg_separator + */ +_.HTTPBuildQuery = function(formdata, arg_separator) { + var use_val, use_key, tmp_arr = []; + + if (_.isUndefined(arg_separator)) { + arg_separator = '&'; + } + + _.each(formdata, function(val, key) { + use_val = encodeURIComponent(val.toString()); + use_key = encodeURIComponent(key); + tmp_arr[tmp_arr.length] = use_key + '=' + use_val; + }); + + return tmp_arr.join(arg_separator); +}; + +_.getQueryParam = function(url, param) { + // Expects a raw URL + + param = param.replace(/[\[]/, '\\\[').replace(/[\]]/, '\\\]'); + var regexS = '[\\?&]' + param + '=([^&#]*)', + regex = new RegExp(regexS), + results = regex.exec(url); + if (results === null || (results && typeof(results[1]) !== 'string' && results[1].length)) { + return ''; + } else { + return decodeURIComponent(results[1]).replace(/\+/g, ' '); + } +}; + +_.getHashParam = function(hash, param) { + var matches = hash.match(new RegExp(param + '=([^&]*)')); + return matches ? matches[1] : null; +}; + +// _.cookie +// Methods partially borrowed from quirksmode.org/js/cookies.html +_.cookie = { + get: function(name) { + var nameEQ = name + '='; + var ca = document$1.cookie.split(';'); + for (var i = 0; i < ca.length; i++) { + var c = ca[i]; + while (c.charAt(0) == ' ') { + c = c.substring(1, c.length); + } + if (c.indexOf(nameEQ) === 0) { + return decodeURIComponent(c.substring(nameEQ.length, c.length)); + } + } + return null; + }, + + parse: function(name) { + var cookie; + try { + cookie = _.JSONDecode(_.cookie.get(name)) || {}; + } catch (err) { + // noop + } + return cookie; + }, + + set_seconds: function(name, value, seconds, cross_subdomain, is_secure) { + var cdomain = '', + expires = '', + secure = ''; + + if (cross_subdomain) { + var matches = document$1.location.hostname.match(/[a-z0-9][a-z0-9\-]+\.[a-z\.]{2,6}$/i), + domain = matches ? matches[0] : ''; + + cdomain = ((domain) ? '; domain=.' + domain : ''); + } + + if (seconds) { + var date = new Date(); + date.setTime(date.getTime() + (seconds * 1000)); + expires = '; expires=' + date.toGMTString(); + } + + if (is_secure) { + secure = '; secure'; + } + + document$1.cookie = name + '=' + encodeURIComponent(value) + expires + '; path=/' + cdomain + secure; + }, + + set: function(name, value, days, cross_subdomain, is_secure) { + var cdomain = '', expires = '', secure = ''; + + if (cross_subdomain) { + var matches = document$1.location.hostname.match(/[a-z0-9][a-z0-9\-]+\.[a-z\.]{2,6}$/i), + domain = matches ? matches[0] : ''; + + cdomain = ((domain) ? '; domain=.' + domain : ''); + } + + if (days) { + var date = new Date(); + date.setTime(date.getTime() + (days * 24 * 60 * 60 * 1000)); + expires = '; expires=' + date.toGMTString(); + } + + if (is_secure) { + secure = '; secure'; + } + + var new_cookie_val = name + '=' + encodeURIComponent(value) + expires + '; path=/' + cdomain + secure; + document$1.cookie = new_cookie_val; + return new_cookie_val; + }, + + remove: function(name, cross_subdomain) { + _.cookie.set(name, '', -1, cross_subdomain); + } +}; + +// _.localStorage +var _localStorage_supported = null; +_.localStorage = { + is_supported: function() { + if (_localStorage_supported !== null) { + return _localStorage_supported; + } + + var supported = true; + try { + var key = '__mplssupport__', + val = 'xyz'; + _.localStorage.set(key, val); + if (_.localStorage.get(key) !== val) { + supported = false; + } + _.localStorage.remove(key); + } catch (err) { + supported = false; + } + if (!supported) { + console$1.error('localStorage unsupported; falling back to cookie store'); + } + + _localStorage_supported = supported; + return supported; + }, + + error: function(msg) { + console$1.error('localStorage error: ' + msg); + }, + + get: function(name) { + try { + return window.localStorage.getItem(name); + } catch (err) { + _.localStorage.error(err); + } + return null; + }, + + parse: function(name) { + try { + return _.JSONDecode(_.localStorage.get(name)) || {}; + } catch (err) { + // noop + } + return null; + }, + + set: function(name, value) { + try { + window.localStorage.setItem(name, value); + } catch (err) { + _.localStorage.error(err); + } + }, + + remove: function(name) { + try { + window.localStorage.removeItem(name); + } catch (err) { + _.localStorage.error(err); + } + } +}; + +_.register_event = (function() { + // written by Dean Edwards, 2005 + // with input from Tino Zijdel - crisp@xs4all.nl + // with input from Carl Sverre - mail@carlsverre.com + // with input from Mixpanel + // http://dean.edwards.name/weblog/2005/10/add-event/ + // https://gist.github.com/1930440 + + /** + * @param {Object} element + * @param {string} type + * @param {function(...[*])} handler + * @param {boolean=} oldSchool + * @param {boolean=} useCapture + */ + var register_event = function(element, type, handler, oldSchool, useCapture) { + if (!element) { + console$1.error('No valid element provided to register_event'); + return; + } + + if (element.addEventListener && !oldSchool) { + element.addEventListener(type, handler, !!useCapture); + } else { + var ontype = 'on' + type; + var old_handler = element[ontype]; // can be undefined + element[ontype] = makeHandler(element, handler, old_handler); + } + }; + + function makeHandler(element, new_handler, old_handlers) { + var handler = function(event) { + event = event || fixEvent(window.event); + + // this basically happens in firefox whenever another script + // overwrites the onload callback and doesn't pass the event + // object to previously defined callbacks. All the browsers + // that don't define window.event implement addEventListener + // so the dom_loaded handler will still be fired as usual. + if (!event) { + return undefined; + } + + var ret = true; + var old_result, new_result; + + if (_.isFunction(old_handlers)) { + old_result = old_handlers(event); + } + new_result = new_handler.call(element, event); + + if ((false === old_result) || (false === new_result)) { + ret = false; + } + + return ret; + }; + + return handler; + } + + function fixEvent(event) { + if (event) { + event.preventDefault = fixEvent.preventDefault; + event.stopPropagation = fixEvent.stopPropagation; + } + return event; + } + fixEvent.preventDefault = function() { + this.returnValue = false; + }; + fixEvent.stopPropagation = function() { + this.cancelBubble = true; + }; + + return register_event; +})(); + +_.dom_query = (function() { + /* document.getElementsBySelector(selector) + - returns an array of element objects from the current document + matching the CSS selector. Selectors can contain element names, + class names and ids and can be nested. For example: + + elements = document.getElementsBySelector('div#main p a.external') + + Will return an array of all 'a' elements with 'external' in their + class attribute that are contained inside 'p' elements that are + contained inside the 'div' element which has id="main" + + New in version 0.4: Support for CSS2 and CSS3 attribute selectors: + See http://www.w3.org/TR/css3-selectors/#attribute-selectors + + Version 0.4 - Simon Willison, March 25th 2003 + -- Works in Phoenix 0.5, Mozilla 1.3, Opera 7, Internet Explorer 6, Internet Explorer 5 on Windows + -- Opera 7 fails + + Version 0.5 - Carl Sverre, Jan 7th 2013 + -- Now uses jQuery-esque `hasClass` for testing class name + equality. This fixes a bug related to '-' characters being + considered not part of a 'word' in regex. + */ + + function getAllChildren(e) { + // Returns all children of element. Workaround required for IE5/Windows. Ugh. + return e.all ? e.all : e.getElementsByTagName('*'); + } + + var bad_whitespace = /[\t\r\n]/g; + + function hasClass(elem, selector) { + var className = ' ' + selector + ' '; + return ((' ' + elem.className + ' ').replace(bad_whitespace, ' ').indexOf(className) >= 0); + } + + function getElementsBySelector(selector) { + // Attempt to fail gracefully in lesser browsers + if (!document$1.getElementsByTagName) { + return []; + } + // Split selector in to tokens + var tokens = selector.split(' '); + var token, bits, tagName, found, foundCount, i, j, k, elements, currentContextIndex; + var currentContext = [document$1]; + for (i = 0; i < tokens.length; i++) { + token = tokens[i].replace(/^\s+/, '').replace(/\s+$/, ''); + if (token.indexOf('#') > -1) { + // Token is an ID selector + bits = token.split('#'); + tagName = bits[0]; + var id = bits[1]; + var element = document$1.getElementById(id); + if (!element || (tagName && element.nodeName.toLowerCase() != tagName)) { + // element not found or tag with that ID not found, return false + return []; + } + // Set currentContext to contain just this element + currentContext = [element]; + continue; // Skip to next token + } + if (token.indexOf('.') > -1) { + // Token contains a class selector + bits = token.split('.'); + tagName = bits[0]; + var className = bits[1]; + if (!tagName) { + tagName = '*'; + } + // Get elements matching tag, filter them for class selector + found = []; + foundCount = 0; + for (j = 0; j < currentContext.length; j++) { + if (tagName == '*') { + elements = getAllChildren(currentContext[j]); + } else { + elements = currentContext[j].getElementsByTagName(tagName); + } + for (k = 0; k < elements.length; k++) { + found[foundCount++] = elements[k]; + } + } + currentContext = []; + currentContextIndex = 0; + for (j = 0; j < found.length; j++) { + if (found[j].className && + _.isString(found[j].className) && // some SVG elements have classNames which are not strings + hasClass(found[j], className) + ) { + currentContext[currentContextIndex++] = found[j]; + } + } + continue; // Skip to next token + } + // Code to deal with attribute selectors + var token_match = token.match(/^(\w*)\[(\w+)([=~\|\^\$\*]?)=?"?([^\]"]*)"?\]$/); + if (token_match) { + tagName = token_match[1]; + var attrName = token_match[2]; + var attrOperator = token_match[3]; + var attrValue = token_match[4]; + if (!tagName) { + tagName = '*'; + } + // Grab all of the tagName elements within current context + found = []; + foundCount = 0; + for (j = 0; j < currentContext.length; j++) { + if (tagName == '*') { + elements = getAllChildren(currentContext[j]); + } else { + elements = currentContext[j].getElementsByTagName(tagName); + } + for (k = 0; k < elements.length; k++) { + found[foundCount++] = elements[k]; + } + } + currentContext = []; + currentContextIndex = 0; + var checkFunction; // This function will be used to filter the elements + switch (attrOperator) { + case '=': // Equality + checkFunction = function(e) { + return (e.getAttribute(attrName) == attrValue); + }; + break; + case '~': // Match one of space seperated words + checkFunction = function(e) { + return (e.getAttribute(attrName).match(new RegExp('\\b' + attrValue + '\\b'))); + }; + break; + case '|': // Match start with value followed by optional hyphen + checkFunction = function(e) { + return (e.getAttribute(attrName).match(new RegExp('^' + attrValue + '-?'))); + }; + break; + case '^': // Match starts with value + checkFunction = function(e) { + return (e.getAttribute(attrName).indexOf(attrValue) === 0); + }; + break; + case '$': // Match ends with value - fails with "Warning" in Opera 7 + checkFunction = function(e) { + return (e.getAttribute(attrName).lastIndexOf(attrValue) == e.getAttribute(attrName).length - attrValue.length); + }; + break; + case '*': // Match ends with value + checkFunction = function(e) { + return (e.getAttribute(attrName).indexOf(attrValue) > -1); + }; + break; + default: + // Just test for existence of attribute + checkFunction = function(e) { + return e.getAttribute(attrName); + }; + } + currentContext = []; + currentContextIndex = 0; + for (j = 0; j < found.length; j++) { + if (checkFunction(found[j])) { + currentContext[currentContextIndex++] = found[j]; + } + } + // alert('Attribute Selector: '+tagName+' '+attrName+' '+attrOperator+' '+attrValue); + continue; // Skip to next token + } + // If we get here, token is JUST an element (not a class or ID selector) + tagName = token; + found = []; + foundCount = 0; + for (j = 0; j < currentContext.length; j++) { + elements = currentContext[j].getElementsByTagName(tagName); + for (k = 0; k < elements.length; k++) { + found[foundCount++] = elements[k]; + } + } + currentContext = found; + } + return currentContext; + } + + return function(query) { + if (_.isElement(query)) { + return [query]; + } else if (_.isObject(query) && !_.isUndefined(query.length)) { + return query; + } else { + return getElementsBySelector.call(this, query); + } + }; +})(); + +_.info = { + campaignParams: function() { + var campaign_keywords = 'utm_source utm_medium utm_campaign utm_content utm_term'.split(' '), + kw = '', + params = {}; + _.each(campaign_keywords, function(kwkey) { + kw = _.getQueryParam(document$1.URL, kwkey); + if (kw.length) { + params[kwkey] = kw; + } + }); + + return params; + }, + + searchEngine: function(referrer) { + if (referrer.search('https?://(.*)google.([^/?]*)') === 0) { + return 'google'; + } else if (referrer.search('https?://(.*)bing.com') === 0) { + return 'bing'; + } else if (referrer.search('https?://(.*)yahoo.com') === 0) { + return 'yahoo'; + } else if (referrer.search('https?://(.*)duckduckgo.com') === 0) { + return 'duckduckgo'; + } else { + return null; + } + }, + + searchInfo: function(referrer) { + var search = _.info.searchEngine(referrer), + param = (search != 'yahoo') ? 'q' : 'p', + ret = {}; + + if (search !== null) { + ret['$search_engine'] = search; + + var keyword = _.getQueryParam(referrer, param); + if (keyword.length) { + ret['mp_keyword'] = keyword; + } + } + + return ret; + }, + + /** + * This function detects which browser is running this script. + * The order of the checks are important since many user agents + * include key words used in later checks. + */ + browser: function(user_agent, vendor, opera) { + vendor = vendor || ''; // vendor is undefined for at least IE9 + if (opera || _.includes(user_agent, ' OPR/')) { + if (_.includes(user_agent, 'Mini')) { + return 'Opera Mini'; + } + return 'Opera'; + } else if (/(BlackBerry|PlayBook|BB10)/i.test(user_agent)) { + return 'BlackBerry'; + } else if (_.includes(user_agent, 'IEMobile') || _.includes(user_agent, 'WPDesktop')) { + return 'Internet Explorer Mobile'; + } else if (_.includes(user_agent, 'Edge')) { + return 'Microsoft Edge'; + } else if (_.includes(user_agent, 'FBIOS')) { + return 'Facebook Mobile'; + } else if (_.includes(user_agent, 'Chrome')) { + return 'Chrome'; + } else if (_.includes(user_agent, 'CriOS')) { + return 'Chrome iOS'; + } else if (_.includes(user_agent, 'UCWEB') || _.includes(user_agent, 'UCBrowser')) { + return 'UC Browser'; + } else if (_.includes(user_agent, 'FxiOS')) { + return 'Firefox iOS'; + } else if (_.includes(vendor, 'Apple')) { + if (_.includes(user_agent, 'Mobile')) { + return 'Mobile Safari'; + } + return 'Safari'; + } else if (_.includes(user_agent, 'Android')) { + return 'Android Mobile'; + } else if (_.includes(user_agent, 'Konqueror')) { + return 'Konqueror'; + } else if (_.includes(user_agent, 'Firefox')) { + return 'Firefox'; + } else if (_.includes(user_agent, 'MSIE') || _.includes(user_agent, 'Trident/')) { + return 'Internet Explorer'; + } else if (_.includes(user_agent, 'Gecko')) { + return 'Mozilla'; + } else { + return ''; + } + }, + + /** + * This function detects which browser version is running this script, + * parsing major and minor version (e.g., 42.1). User agent strings from: + * http://www.useragentstring.com/pages/useragentstring.php + */ + browserVersion: function(userAgent, vendor, opera) { + var browser = _.info.browser(userAgent, vendor, opera); + var versionRegexs = { + 'Internet Explorer Mobile': /rv:(\d+(\.\d+)?)/, + 'Microsoft Edge': /Edge\/(\d+(\.\d+)?)/, + 'Chrome': /Chrome\/(\d+(\.\d+)?)/, + 'Chrome iOS': /CriOS\/(\d+(\.\d+)?)/, + 'UC Browser' : /(UCBrowser|UCWEB)\/(\d+(\.\d+)?)/, + 'Safari': /Version\/(\d+(\.\d+)?)/, + 'Mobile Safari': /Version\/(\d+(\.\d+)?)/, + 'Opera': /(Opera|OPR)\/(\d+(\.\d+)?)/, + 'Firefox': /Firefox\/(\d+(\.\d+)?)/, + 'Firefox iOS': /FxiOS\/(\d+(\.\d+)?)/, + 'Konqueror': /Konqueror:(\d+(\.\d+)?)/, + 'BlackBerry': /BlackBerry (\d+(\.\d+)?)/, + 'Android Mobile': /android\s(\d+(\.\d+)?)/, + 'Internet Explorer': /(rv:|MSIE )(\d+(\.\d+)?)/, + 'Mozilla': /rv:(\d+(\.\d+)?)/ + }; + var regex = versionRegexs[browser]; + if (regex === undefined) { + return null; + } + var matches = userAgent.match(regex); + if (!matches) { + return null; + } + return parseFloat(matches[matches.length - 2]); + }, + + os: function() { + var a = userAgent; + if (/Windows/i.test(a)) { + if (/Phone/.test(a) || /WPDesktop/.test(a)) { + return 'Windows Phone'; + } + return 'Windows'; + } else if (/(iPhone|iPad|iPod)/.test(a)) { + return 'iOS'; + } else if (/Android/.test(a)) { + return 'Android'; + } else if (/(BlackBerry|PlayBook|BB10)/i.test(a)) { + return 'BlackBerry'; + } else if (/Mac/i.test(a)) { + return 'Mac OS X'; + } else if (/Linux/.test(a)) { + return 'Linux'; + } else if (/CrOS/.test(a)) { + return 'Chrome OS'; + } else { + return ''; + } + }, + + device: function(user_agent) { + if (/Windows Phone/i.test(user_agent) || /WPDesktop/.test(user_agent)) { + return 'Windows Phone'; + } else if (/iPad/.test(user_agent)) { + return 'iPad'; + } else if (/iPod/.test(user_agent)) { + return 'iPod Touch'; + } else if (/iPhone/.test(user_agent)) { + return 'iPhone'; + } else if (/(BlackBerry|PlayBook|BB10)/i.test(user_agent)) { + return 'BlackBerry'; + } else if (/Android/.test(user_agent)) { + return 'Android'; + } else { + return ''; + } + }, + + referringDomain: function(referrer) { + var split = referrer.split('/'); + if (split.length >= 3) { + return split[2]; + } + return ''; + }, + + properties: function() { + return _.extend(_.strip_empty_properties({ + '$os': _.info.os(), + '$browser': _.info.browser(userAgent, navigator$1.vendor, windowOpera), + '$referrer': document$1.referrer, + '$referring_domain': _.info.referringDomain(document$1.referrer), + '$device': _.info.device(userAgent) + }), { + '$current_url': window$1.location.href, + '$browser_version': _.info.browserVersion(userAgent, navigator$1.vendor, windowOpera), + '$screen_height': screen.height, + '$screen_width': screen.width, + 'mp_lib': 'web', + '$lib_version': Config.LIB_VERSION + }); + }, + + people_properties: function() { + return _.extend(_.strip_empty_properties({ + '$os': _.info.os(), + '$browser': _.info.browser(userAgent, navigator$1.vendor, windowOpera) + }), { + '$browser_version': _.info.browserVersion(userAgent, navigator$1.vendor, windowOpera) + }); + }, + + pageviewInfo: function(page) { + return _.strip_empty_properties({ + 'mp_page': page, + 'mp_referrer': document$1.referrer, + 'mp_browser': _.info.browser(userAgent, navigator$1.vendor, windowOpera), + 'mp_platform': _.info.os() + }); + } +}; + +// EXPORTS (for closure compiler) +_['toArray'] = _.toArray; +_['isObject'] = _.isObject; +_['JSONEncode'] = _.JSONEncode; +_['JSONDecode'] = _.JSONDecode; +_['isBlockedUA'] = _.isBlockedUA; +_['isEmptyObject'] = _.isEmptyObject; +_['info'] = _.info; +_['info']['device'] = _.info.device; +_['info']['browser'] = _.info.browser; +_['info']['properties'] = _.info.properties; + +/* + * Get the className of an element, accounting for edge cases where element.className is an object + * @param {Element} el - element to get the className of + * @returns {string} the element's class + */ +function getClassName(el) { + switch(typeof el.className) { + case 'string': + return el.className; + case 'object': // handle cases where className might be SVGAnimatedString or some other type + return el.className.baseVal || el.getAttribute('class') || ''; + default: // future proof + return ''; + } +} + +/* + * Get the direct text content of an element, protecting against sensitive data collection. + * Concats textContent of each of the element's text node children; this avoids potential + * collection of sensitive data that could happen if we used element.textContent and the + * element had sensitive child elements, since element.textContent includes child content. + * Scrubs values that look like they could be sensitive (i.e. cc or ssn number). + * @param {Element} el - element to get the text of + * @returns {string} the element's direct text content + */ +function getSafeText(el) { + var elText = ''; + + if (shouldTrackElement(el) && el.childNodes && el.childNodes.length) { + _.each(el.childNodes, function(child) { + if (isTextNode(child) && child.textContent) { + elText += _.trim(child.textContent) + // scrub potentially sensitive values + .split(/(\s+)/).filter(shouldTrackValue).join('') + // normalize whitespace + .replace(/[\r\n]/g, ' ').replace(/[ ]+/g, ' ') + // truncate + .substring(0, 255); + } + }); + } + + return _.trim(elText); +} + +/* + * Check whether an element has nodeType Node.ELEMENT_NODE + * @param {Element} el - element to check + * @returns {boolean} whether el is of the correct nodeType + */ +function isElementNode(el) { + return el && el.nodeType === 1; // Node.ELEMENT_NODE - use integer constant for browser portability +} + +/* + * Check whether an element is of a given tag type. + * Due to potential reference discrepancies (such as the webcomponents.js polyfill), + * we want to match tagNames instead of specific references because something like + * element === document.body won't always work because element might not be a native + * element. + * @param {Element} el - element to check + * @param {string} tag - tag name (e.g., "div") + * @returns {boolean} whether el is of the given tag type + */ +function isTag(el, tag) { + return el && el.tagName && el.tagName.toLowerCase() === tag.toLowerCase(); +} + +/* + * Check whether an element has nodeType Node.TEXT_NODE + * @param {Element} el - element to check + * @returns {boolean} whether el is of the correct nodeType + */ +function isTextNode(el) { + return el && el.nodeType === 3; // Node.TEXT_NODE - use integer constant for browser portability +} + +/* + * Check whether a DOM event should be "tracked" or if it may contain sentitive data + * using a variety of heuristics. + * @param {Element} el - element to check + * @param {Event} event - event to check + * @returns {boolean} whether the event should be tracked + */ +function shouldTrackDomEvent(el, event) { + if (!el || isTag(el, 'html') || !isElementNode(el)) { + return false; + } + var tag = el.tagName.toLowerCase(); + switch (tag) { + case 'html': + return false; + case 'form': + return event.type === 'submit'; + case 'input': + if (['button', 'submit'].indexOf(el.getAttribute('type')) === -1) { + return event.type === 'change'; + } else { + return event.type === 'click'; + } + case 'select': + case 'textarea': + return event.type === 'change'; + default: + return event.type === 'click'; + } +} + +/* + * Check whether a DOM element should be "tracked" or if it may contain sentitive data + * using a variety of heuristics. + * @param {Element} el - element to check + * @returns {boolean} whether the element should be tracked + */ +function shouldTrackElement(el) { + for (var curEl = el; curEl.parentNode && !isTag(curEl, 'body'); curEl = curEl.parentNode) { + var classes = getClassName(curEl).split(' '); + if (_.includes(classes, 'mp-sensitive') || _.includes(classes, 'mp-no-track')) { + return false; + } + } + + if (_.includes(getClassName(el).split(' '), 'mp-include')) { + return true; + } + + // don't send data from inputs or similar elements since there will always be + // a risk of clientside javascript placing sensitive data in attributes + if ( + isTag(el, 'input') || + isTag(el, 'select') || + isTag(el, 'textarea') || + el.getAttribute('contenteditable') === 'true' + ) { + return false; + } + + // don't include hidden or password fields + var type = el.type || ''; + if (typeof type === 'string') { // it's possible for el.type to be a DOM element if el is a form with a child input[name="type"] + switch(type.toLowerCase()) { + case 'hidden': + return false; + case 'password': + return false; + } + } + + // filter out data from fields that look like sensitive fields + var name = el.name || el.id || ''; + if (typeof name === 'string') { // it's possible for el.name or el.id to be a DOM element if el is a form with a child input[name="name"] + var sensitiveNameRegex = /^cc|cardnum|ccnum|creditcard|csc|cvc|cvv|exp|pass|pwd|routing|seccode|securitycode|securitynum|socialsec|socsec|ssn/i; + if (sensitiveNameRegex.test(name.replace(/[^a-zA-Z0-9]/g, ''))) { + return false; + } + } + + return true; +} + +/* + * Check whether a string value should be "tracked" or if it may contain sentitive data + * using a variety of heuristics. + * @param {string} value - string value to check + * @returns {boolean} whether the element should be tracked + */ +function shouldTrackValue(value) { + if (value === null || _.isUndefined(value)) { + return false; + } + + if (typeof value === 'string') { + value = _.trim(value); + + // check to see if input value looks like a credit card number + // see: https://www.safaribooksonline.com/library/view/regular-expressions-cookbook/9781449327453/ch04s20.html + var ccRegex = /^(?:(4[0-9]{12}(?:[0-9]{3})?)|(5[1-5][0-9]{14})|(6(?:011|5[0-9]{2})[0-9]{12})|(3[47][0-9]{13})|(3(?:0[0-5]|[68][0-9])[0-9]{11})|((?:2131|1800|35[0-9]{3})[0-9]{11}))$/; + if (ccRegex.test((value || '').replace(/[\- ]/g, ''))) { + return false; + } + + // check to see if input value looks like a social security number + var ssnRegex = /(^\d{3}-?\d{2}-?\d{4}$)/; + if (ssnRegex.test(value)) { + return false; + } + } + + return true; +} + +var autotrack = { + _initializedTokens: [], + + _previousElementSibling: function(el) { + if (el.previousElementSibling) { + return el.previousElementSibling; + } else { + do { + el = el.previousSibling; + } while (el && !isElementNode(el)); + return el; + } + }, + + _loadScript: function(scriptUrlToLoad, callback) { + var scriptTag = document.createElement('script'); + scriptTag.type = 'text/javascript'; + scriptTag.src = scriptUrlToLoad; + scriptTag.onload = callback; + + var scripts = document.getElementsByTagName('script'); + if (scripts.length > 0) { + scripts[0].parentNode.insertBefore(scriptTag, scripts[0]); + } else { + document.body.appendChild(scriptTag); + } + }, + + _getPropertiesFromElement: function(elem) { + var props = { + 'classes': getClassName(elem).split(' '), + 'tag_name': elem.tagName.toLowerCase() + }; + + if (shouldTrackElement(elem)) { + _.each(elem.attributes, function(attr) { + if (shouldTrackValue(attr.value)) { + props['attr__' + attr.name] = attr.value; + } + }); + } + + var nthChild = 1; + var nthOfType = 1; + var currentElem = elem; + while (currentElem = this._previousElementSibling(currentElem)) { // eslint-disable-line no-cond-assign + nthChild++; + if (currentElem.tagName === elem.tagName) { + nthOfType++; + } + } + props['nth_child'] = nthChild; + props['nth_of_type'] = nthOfType; + + return props; + }, + + _getDefaultProperties: function(eventType) { + return { + '$event_type': eventType, + '$ce_version': 1, + '$host': window.location.host, + '$pathname': window.location.pathname + }; + }, + + _extractCustomPropertyValue: function(customProperty) { + var propValues = []; + _.each(document.querySelectorAll(customProperty['css_selector']), function(matchedElem) { + var value; + + if (['input', 'select'].indexOf(matchedElem.tagName.toLowerCase()) > -1) { + value = matchedElem['value']; + } else if (matchedElem['textContent']) { + value = matchedElem['textContent']; + } + + if (shouldTrackValue(value)) { + propValues.push(value); + } + }); + return propValues.join(', '); + }, + + _getCustomProperties: function(targetElementList) { + var props = {}; + _.each(this._customProperties, function(customProperty) { + _.each(customProperty['event_selectors'], function(eventSelector) { + var eventElements = document.querySelectorAll(eventSelector); + _.each(eventElements, function(eventElement) { + if (_.includes(targetElementList, eventElement) && shouldTrackElement(eventElement)) { + props[customProperty['name']] = this._extractCustomPropertyValue(customProperty); + } + }, this); + }, this); + }, this); + return props; + }, + + _getEventTarget: function(e) { + // https://developer.mozilla.org/en-US/docs/Web/API/Event/target#Compatibility_notes + if (typeof e.target === 'undefined') { + return e.srcElement; + } else { + return e.target; + } + }, + + _trackEvent: function(e, instance) { + /*** Don't mess with this code without running IE8 tests on it ***/ + var target = this._getEventTarget(e); + if (isTextNode(target)) { // defeat Safari bug (see: http://www.quirksmode.org/js/events_properties.html) + target = target.parentNode; + } + + if (shouldTrackDomEvent(target, e)) { + var targetElementList = [target]; + var curEl = target; + while (curEl.parentNode && !isTag(curEl, 'body')) { + targetElementList.push(curEl.parentNode); + curEl = curEl.parentNode; + } + + var elementsJson = []; + var href, explicitNoTrack = false; + _.each(targetElementList, function(el) { + var shouldTrackEl = shouldTrackElement(el); + + // if the element or a parent element is an anchor tag + // include the href as a property + if (el.tagName.toLowerCase() === 'a') { + href = el.getAttribute('href'); + href = shouldTrackEl && shouldTrackValue(href) && href; + } + + // allow users to programatically prevent tracking of elements by adding class 'mp-no-track' + var classes = getClassName(el).split(' '); + if (_.includes(classes, 'mp-no-track')) { + explicitNoTrack = true; + } + + elementsJson.push(this._getPropertiesFromElement(el)); + }, this); + + if (explicitNoTrack) { + return false; + } + + // only populate text content from target element (not parents) + // to prevent text within a sensitive element from being collected + // as part of a parent's el.textContent + var elementText; + var safeElementText = getSafeText(target); + if (safeElementText && safeElementText.length) { + elementText = safeElementText; + } + + var props = _.extend( + this._getDefaultProperties(e.type), + { + '$elements': elementsJson, + '$el_attr__href': href, + '$el_text': elementText + }, + this._getCustomProperties(targetElementList) + ); + + instance.track('$web_event', props); + return true; + } + }, + + // only reason is to stub for unit tests + // since you can't override window.location props + _navigate: function(href) { + window.location.href = href; + }, + + _addDomEventHandlers: function(instance) { + var handler = _.bind(function(e) { + e = e || window.event; + this._trackEvent(e, instance); + }, this); + _.register_event(document, 'submit', handler, false, true); + _.register_event(document, 'change', handler, false, true); + _.register_event(document, 'click', handler, false, true); + }, + + _customProperties: {}, + init: function(instance) { + if (!(document && document.body)) { + console.log('document not ready yet, trying again in 500 milliseconds...'); + var that = this; + setTimeout(function() { that.init(instance); }, 500); + return; + } + + var token = instance.get_config('token'); + if (this._initializedTokens.indexOf(token) > -1) { + console.log('autotrack already initialized for token "' + token + '"'); + return; + } + this._initializedTokens.push(token); + + if (!this._maybeLoadEditor(instance)) { // don't autotrack actions when the editor is enabled + var parseDecideResponse = _.bind(function(response) { + if (response && response['config'] && response['config']['enable_collect_everything'] === true) { + + if (response['custom_properties']) { + this._customProperties = response['custom_properties']; + } + + instance.track('$web_event', _.extend({ + '$title': document.title + }, this._getDefaultProperties('pageview'))); + + this._addDomEventHandlers(instance); + + } else { + instance['__autotrack_enabled'] = false; + } + }, this); + + instance._send_request( + instance.get_config('api_host') + '/decide/', { + 'verbose': true, + 'version': '1', + 'lib': 'web', + 'token': token + }, + instance._prepare_callback(parseDecideResponse) + ); + } + }, + + _editorParamsFromHash: function(instance, hash) { + var editorParams; + try { + var state = _.getHashParam(hash, 'state'); + state = JSON.parse(decodeURIComponent(state)); + var expiresInSeconds = _.getHashParam(hash, 'expires_in'); + editorParams = { + 'accessToken': _.getHashParam(hash, 'access_token'), + 'accessTokenExpiresAt': (new Date()).getTime() + (Number(expiresInSeconds) * 1000), + 'bookmarkletMode': !!state['bookmarkletMode'], + 'projectId': state['projectId'], + 'projectOwnerId': state['projectOwnerId'], + 'projectToken': state['token'], + 'readOnly': state['readOnly'], + 'userFlags': state['userFlags'], + 'userId': state['userId'] + }; + window.sessionStorage.setItem('editorParams', JSON.stringify(editorParams)); + + if (state['desiredHash']) { + window.location.hash = state['desiredHash']; + } else if (window.history) { + history.replaceState('', document.title, window.location.pathname + window.location.search); // completely remove hash + } else { + window.location.hash = ''; // clear hash (but leaves # unfortunately) + } + } catch (e) { + console.error('Unable to parse data from hash', e); + } + return editorParams; + }, + + /** + * To load the visual editor, we need an access token and other state. That state comes from one of three places: + * 1. In the URL hash params if the customer is using an old snippet + * 2. From session storage under the key `_mpcehash` if the snippet already parsed the hash + * 3. From session storage under the key `editorParams` if the editor was initialized on a previous page + */ + _maybeLoadEditor: function(instance) { + try { + var parseFromUrl = false; + if (_.getHashParam(window.location.hash, 'state')) { + var state = _.getHashParam(window.location.hash, 'state'); + state = JSON.parse(decodeURIComponent(state)); + parseFromUrl = state['action'] === 'mpeditor'; + } + var parseFromStorage = !!window.sessionStorage.getItem('_mpcehash'); + var editorParams; + + if (parseFromUrl) { // happens if they are initializing the editor using an old snippet + editorParams = this._editorParamsFromHash(instance, window.location.hash); + } else if (parseFromStorage) { // happens if they are initialized the editor and using the new snippet + editorParams = this._editorParamsFromHash(instance, window.sessionStorage.getItem('_mpcehash')); + window.sessionStorage.removeItem('_mpcehash'); + } else { // get credentials from sessionStorage from a previous initialzation + editorParams = JSON.parse(window.sessionStorage.getItem('editorParams') || '{}'); + } + + if (editorParams['projectToken'] && instance.get_config('token') === editorParams['projectToken']) { + this._loadEditor(instance, editorParams); + return true; + } else { + return false; + } + } catch (e) { + return false; + } + }, + + _loadEditor: function(instance, editorParams) { + if (!window['_mpEditorLoaded']) { // only load the codeless event editor once, even if there are multiple instances of MixpanelLib + window['_mpEditorLoaded'] = true; + var editorUrl = instance.get_config('app_host') + + '/js-bundle/reports/collect-everything/editor.js?_ts=' + + (new Date()).getTime(); + this._loadScript(editorUrl, function() { + window['mp_load_editor'](editorParams); + }); + return true; + } + return false; + }, + + // this is a mechanism to ramp up CE with no server-side interaction. + // when CE is active, every page load results in a decide request. we + // need to gently ramp this up so we don't overload decide. this decides + // deterministically if CE is enabled for this project by modding the char + // value of the project token. + enabledForProject: function(token, numBuckets, numEnabledBuckets) { + numBuckets = !_.isUndefined(numBuckets) ? numBuckets : 10; + numEnabledBuckets = !_.isUndefined(numEnabledBuckets) ? numEnabledBuckets : 10; + var charCodeSum = 0; + for (var i = 0; i < token.length; i++) { + charCodeSum += token.charCodeAt(i); + } + return (charCodeSum % numBuckets) < numEnabledBuckets; + }, + + isBrowserSupported: function() { + return _.isFunction(document.querySelectorAll); + } +}; + +_.bind_instance_methods(autotrack); +_.safewrap_instance_methods(autotrack); + +/** + * A function used to track a Mixpanel event (e.g. MixpanelLib.track) + * @callback trackFunction + * @param {String} event_name The name of the event. This can be anything the user does - 'Button Click', 'Sign Up', 'Item Purchased', etc. + * @param {Object} [properties] A set of properties to include with the event you're sending. These describe the user who did the event or details about the event itself. + * @param {Function} [callback] If provided, the callback function will be called after tracking the event. + */ + +/** Public **/ + +var GDPR_DEFAULT_PERSISTENCE_PREFIX = '__mp_opt_in_out_'; + +/** + * Opt the user in to data tracking and cookies/localstorage for the given token + * @param {string} token - Mixpanel project tracking token + * @param {Object} [options] + * @param {trackFunction} [options.track] - function used for tracking a Mixpanel event to record the opt-in action + * @param {string} [options.trackEventName] - event name to be used for tracking the opt-in action + * @param {Object} [options.trackProperties] - set of properties to be tracked along with the opt-in action + * @param {string} [options.persistenceType] Persistence mechanism used - cookie or localStorage + * @param {string} [options.persistencePrefix=__mp_opt_in_out] - custom prefix to be used in the cookie/localstorage name + * @param {Number} [options.cookieExpiration] - number of days until the opt-in cookie expires + * @param {boolean} [options.crossSubdomainCookie] - whether the opt-in cookie is set as cross-subdomain or not + * @param {boolean} [options.secureCookie] - whether the opt-in cookie is set as secure or not + */ +function optIn(token, options) { + _optInOut(true, token, options); +} + +/** + * Opt the user out of data tracking and cookies/localstorage for the given token + * @param {string} token - Mixpanel project tracking token + * @param {Object} [options] + * @param {string} [options.persistenceType] Persistence mechanism used - cookie or localStorage + * @param {string} [options.persistencePrefix=__mp_opt_in_out] - custom prefix to be used in the cookie/localstorage name + * @param {Number} [options.cookieExpiration] - number of days until the opt-out cookie expires + * @param {boolean} [options.crossSubdomainCookie] - whether the opt-out cookie is set as cross-subdomain or not + * @param {boolean} [options.secureCookie] - whether the opt-out cookie is set as secure or not + */ +function optOut(token, options) { + _optInOut(false, token, options); +} + +/** + * Check whether the user has opted in to data tracking and cookies/localstorage for the given token + * @param {string} token - Mixpanel project tracking token + * @param {Object} [options] + * @param {string} [options.persistenceType] Persistence mechanism used - cookie or localStorage + * @param {string} [options.persistencePrefix=__mp_opt_in_out] - custom prefix to be used in the cookie/localstorage name + * @returns {boolean} whether the user has opted in to the given opt type + */ +function hasOptedIn(token, options) { + return _getStorageValue(token, options) === '1'; +} + +/** + * Check whether the user has opted out of data tracking and cookies/localstorage for the given token + * @param {string} token - Mixpanel project tracking token + * @param {Object} [options] + * @param {string} [options.persistenceType] Persistence mechanism used - cookie or localStorage + * @param {string} [options.persistencePrefix=__mp_opt_in_out] - custom prefix to be used in the cookie/localstorage name + * @returns {boolean} whether the user has opted out of the given opt type + */ +function hasOptedOut(token, options) { + if (_hasDoNotTrackFlagOn()) { + return true; + } + return _getStorageValue(token, options) === '0'; +} + +/** + * Wrap a MixpanelLib method with a check for whether the user is opted out of data tracking and cookies/localstorage for the given token + * If the user has opted out, return early instead of executing the method. + * If a callback argument was provided, execute it passing the 0 error code. + * @param {function} method - wrapped method to be executed if the user has not opted out + * @returns {*} the result of executing method OR undefined if the user has opted out + */ +function addOptOutCheckMixpanelLib(method) { + return _addOptOutCheck(method, function(name) { + return this.get_config(name); + }); +} + +/** + * Wrap a MixpanelPeople method with a check for whether the user is opted out of data tracking and cookies/localstorage for the given token + * If the user has opted out, return early instead of executing the method. + * If a callback argument was provided, execute it passing the 0 error code. + * @param {function} method - wrapped method to be executed if the user has not opted out + * @returns {*} the result of executing method OR undefined if the user has opted out + */ +function addOptOutCheckMixpanelPeople(method) { + return _addOptOutCheck(method, function(name) { + return this._get_config(name); + }); +} + +/** + * Clear the user's opt in/out status of data tracking and cookies/localstorage for the given token + * @param {string} token - Mixpanel project tracking token + * @param {Object} [options] + * @param {string} [options.persistenceType] Persistence mechanism used - cookie or localStorage + * @param {string} [options.persistencePrefix=__mp_opt_in_out] - custom prefix to be used in the cookie/localstorage name + * @param {Number} [options.cookieExpiration] - number of days until the opt-in cookie expires + * @param {boolean} [options.crossSubdomainCookie] - whether the opt-in cookie is set as cross-subdomain or not + * @param {boolean} [options.secureCookie] - whether the opt-in cookie is set as secure or not + */ +function clearOptInOut(token, options) { + options = options || {}; + _getStorage(options).remove(_getStorageKey(token, options), !!options.crossSubdomainCookie); +} + +/** Private **/ + +/** + * Get storage util + * @param {Object} [options] + * @param {string} [options.persistenceType] + * @returns {object} either _.cookie or _.localstorage + */ +function _getStorage(options) { + options = options || {}; + return options.persistenceType === 'localStorage' ? _.localStorage : _.cookie; +} + +/** + * Get the name of the cookie that is used for the given opt type (tracking, cookie, etc.) + * @param {string} token - Mixpanel project tracking token + * @param {Object} [options] + * @param {string} [options.persistencePrefix=__mp_opt_in_out] - custom prefix to be used in the cookie/localstorage name + * @returns {string} the name of the cookie for the given opt type + */ +function _getStorageKey(token, options) { + options = options || {}; + return (options.persistencePrefix || GDPR_DEFAULT_PERSISTENCE_PREFIX) + token; +} + +/** + * Get the value of the cookie that is used for the given opt type (tracking, cookie, etc.) + * @param {string} token - Mixpanel project tracking token + * @param {Object} [options] + * @param {string} [options.persistencePrefix=__mp_opt_in_out] - custom prefix to be used in the cookie/localstorage name + * @returns {string} the value of the cookie for the given opt type + */ +function _getStorageValue(token, options) { + return _getStorage(options).get(_getStorageKey(token, options)); +} + +/** + * Check whether the user has set the DNT/doNotTrack setting to true in their browser + * @returns {boolean} whether the DNT setting is true + */ +function _hasDoNotTrackFlagOn() { + return !!(window$1.navigator && window$1.navigator.doNotTrack === '1'); +} + +/** + * Set cookie/localstorage for the user indicating that they are opted in or out for the given opt type + * @param {boolean} optValue - whether to opt the user in or out for the given opt type + * @param {string} token - Mixpanel project tracking token + * @param {Object} [options] + * @param {trackFunction} [options.track] - function used for tracking a Mixpanel event to record the opt-in action + * @param {string} [options.trackEventName] - event name to be used for tracking the opt-in action + * @param {Object} [options.trackProperties] - set of properties to be tracked along with the opt-in action + * @param {string} [options.persistencePrefix=__mp_opt_in_out] - custom prefix to be used in the cookie/localstorage name + * @param {Number} [options.cookieExpiration] - number of days until the opt-in cookie expires + * @param {boolean} [options.crossSubdomainCookie] - whether the opt-in cookie is set as cross-subdomain or not + * @param {boolean} [options.secureCookie] - whether the opt-in cookie is set as secure or not + */ +function _optInOut(optValue, token, options) { + if (!_.isString(token) || !token.length) { + console.error('gdpr.' + (optValue ? 'optIn' : 'optOut') + ' called with an invalid token'); + return; + } + + options = options || {}; + + _getStorage(options).set( + _getStorageKey(token, options), + optValue ? 1 : 0, + _.isNumber(options.cookieExpiration) ? options.cookieExpiration : null, + !!options.crossSubdomainCookie, + !!options.secureCookie + ); + + if (options.track && optValue) { // only track event if opting in (optValue=true) + options.track(options.trackEventName || '$opt_in', options.trackProperties); + } +} + +/** + * Wrap a method with a check for whether the user is opted out of data tracking and cookies/localstorage for the given token + * If the user has opted out, return early instead of executing the method. + * If a callback argument was provided, execute it passing the 0 error code. + * @param {function} method - wrapped method to be executed if the user has not opted out + * @param {function} getConfigValue - getter function for the Mixpanel API token and other options to be used with opt-out check + * @returns {*} the result of executing method OR undefined if the user has opted out + */ +function _addOptOutCheck(method, getConfigValue) { + return function() { + var optedOut = false; + + try { + var token = getConfigValue.call(this, 'token'); + var persistenceType = getConfigValue.call(this, 'opt_out_tracking_persistence_type'); + var persistencePrefix = getConfigValue.call(this, 'opt_out_tracking_cookie_prefix'); + + if (token) { // if there was an issue getting the token, continue method execution as normal + optedOut = hasOptedOut(token, { + persistenceType: persistenceType, + persistencePrefix: persistencePrefix + }); + } + } catch(err) { + console.error('Unexpected error when checking tracking opt-out status: ' + err); + } + + if (!optedOut) { + return method.apply(this, arguments); + } + + var callback = arguments[arguments.length - 1]; + if (typeof(callback) === 'function') { + callback(0); + } + + return; + }; +} + +/* + * Mixpanel JS Library + * + * Copyright 2012, Mixpanel, Inc. All Rights Reserved + * http://mixpanel.com/ + * + * Includes portions of Underscore.js + * http://documentcloud.github.com/underscore/ + * (c) 2011 Jeremy Ashkenas, DocumentCloud Inc. + * Released under the MIT License. + */ + +// ==ClosureCompiler== +// @compilation_level ADVANCED_OPTIMIZATIONS +// @output_file_name mixpanel-2.8.min.js +// ==/ClosureCompiler== + +/* +SIMPLE STYLE GUIDE: + +this.x === public function +this._x === internal - only use within this file +this.__x === private - only use within the class + +Globals should be all caps +*/ + +var init_type; // MODULE or SNIPPET loader +var mixpanel_master; // main mixpanel instance / object +var INIT_MODULE = 0; +var INIT_SNIPPET = 1; + +/* + * Constants + */ +/** @const */ var PRIMARY_INSTANCE_NAME = 'mixpanel'; +/** @const */ var SET_QUEUE_KEY = '__mps'; +/** @const */ var SET_ONCE_QUEUE_KEY = '__mpso'; +/** @const */ var UNSET_QUEUE_KEY = '__mpus'; +/** @const */ var ADD_QUEUE_KEY = '__mpa'; +/** @const */ var APPEND_QUEUE_KEY = '__mpap'; +/** @const */ var UNION_QUEUE_KEY = '__mpu'; +/** @const */ var SET_ACTION = '$set'; +/** @const */ var SET_ONCE_ACTION = '$set_once'; +/** @const */ var UNSET_ACTION = '$unset'; +/** @const */ var ADD_ACTION = '$add'; +/** @const */ var APPEND_ACTION = '$append'; +/** @const */ var UNION_ACTION = '$union'; +// This key is deprecated, but we want to check for it to see whether aliasing is allowed. +/** @const */ var PEOPLE_DISTINCT_ID_KEY = '$people_distinct_id'; +/** @const */ var ALIAS_ID_KEY = '__alias'; +/** @const */ var CAMPAIGN_IDS_KEY = '__cmpns'; +/** @const */ var EVENT_TIMERS_KEY = '__timers'; +/** @const */ var RESERVED_PROPERTIES = [ + SET_QUEUE_KEY, + SET_ONCE_QUEUE_KEY, + UNSET_QUEUE_KEY, + ADD_QUEUE_KEY, + APPEND_QUEUE_KEY, + UNION_QUEUE_KEY, + PEOPLE_DISTINCT_ID_KEY, + ALIAS_ID_KEY, + CAMPAIGN_IDS_KEY, + EVENT_TIMERS_KEY +]; + +/* + * Dynamic... constants? Is that an oxymoron? + */ + // http://hacks.mozilla.org/2009/07/cross-site-xmlhttprequest-with-cors/ + // https://developer.mozilla.org/en-US/docs/DOM/XMLHttpRequest#withCredentials +var USE_XHR = (window$1.XMLHttpRequest && 'withCredentials' in new XMLHttpRequest()); + + // IE<10 does not support cross-origin XHR's but script tags + // with defer won't block window.onload; ENQUEUE_REQUESTS + // should only be true for Opera<12 +var ENQUEUE_REQUESTS = !USE_XHR && (userAgent.indexOf('MSIE') === -1) && (userAgent.indexOf('Mozilla') === -1); + +/* + * Module-level globals + */ +var DEFAULT_CONFIG = { + 'api_host': 'https://api.mixpanel.com', + 'app_host': 'https://mixpanel.com', + 'autotrack': true, + 'cdn': 'https://cdn.mxpnl.com', + 'cross_subdomain_cookie': true, + 'persistence': 'cookie', + 'persistence_name': '', + 'cookie_name': '', + 'loaded': function() {}, + 'store_google': true, + 'save_referrer': true, + 'test': false, + 'verbose': false, + 'img': false, + 'track_pageview': true, + 'debug': false, + 'track_links_timeout': 300, + 'cookie_expiration': 365, + 'upgrade': false, + 'disable_persistence': false, + 'disable_cookie': false, + 'secure_cookie': false, + 'ip': true, + 'opt_out_tracking_by_default': false, + 'opt_out_tracking_persistence_type': 'localStorage', + 'opt_out_tracking_cookie_prefix': null, + 'property_blacklist': [], + 'xhr_headers': {} // { header: value, header2: value } +}; + +var DOM_LOADED = false; + +/** + * DomTracker Object + * @constructor + */ +var DomTracker = function() {}; + +// interface +DomTracker.prototype.create_properties = function() {}; +DomTracker.prototype.event_handler = function() {}; +DomTracker.prototype.after_track_handler = function() {}; + +DomTracker.prototype.init = function(mixpanel_instance) { + this.mp = mixpanel_instance; + return this; +}; + +/** + * @param {Object|string} query + * @param {string} event_name + * @param {Object=} properties + * @param {function(...[*])=} user_callback + */ +DomTracker.prototype.track = function(query, event_name, properties, user_callback) { + var that = this; + var elements = _.dom_query(query); + + if (elements.length === 0) { + console$1.error('The DOM query (' + query + ') returned 0 elements'); + return; + } + + _.each(elements, function(element) { + _.register_event(element, this.override_event, function(e) { + var options = {}; + var props = that.create_properties(properties, this); + var timeout = that.mp.get_config('track_links_timeout'); + + that.event_handler(e, this, options); + + // in case the mixpanel servers don't get back to us in time + window$1.setTimeout(that.track_callback(user_callback, props, options, true), timeout); + + // fire the tracking event + that.mp.track(event_name, props, that.track_callback(user_callback, props, options)); + }); + }, this); + + return true; +}; + +/** + * @param {function(...[*])} user_callback + * @param {Object} props + * @param {boolean=} timeout_occured + */ +DomTracker.prototype.track_callback = function(user_callback, props, options, timeout_occured) { + timeout_occured = timeout_occured || false; + var that = this; + + return function() { + // options is referenced from both callbacks, so we can have + // a 'lock' of sorts to ensure only one fires + if (options.callback_fired) { return; } + options.callback_fired = true; + + if (user_callback && user_callback(timeout_occured, props) === false) { + // user can prevent the default functionality by + // returning false from their callback + return; + } + + that.after_track_handler(props, options, timeout_occured); + }; +}; + +DomTracker.prototype.create_properties = function(properties, element) { + var props; + + if (typeof(properties) === 'function') { + props = properties(element); + } else { + props = _.extend({}, properties); + } + + return props; +}; + +/** + * LinkTracker Object + * @constructor + * @extends DomTracker + */ +var LinkTracker = function() { + this.override_event = 'click'; +}; +_.inherit(LinkTracker, DomTracker); + +LinkTracker.prototype.create_properties = function(properties, element) { + var props = LinkTracker.superclass.create_properties.apply(this, arguments); + + if (element.href) { props['url'] = element.href; } + + return props; +}; + +LinkTracker.prototype.event_handler = function(evt, element, options) { + options.new_tab = ( + evt.which === 2 || + evt.metaKey || + evt.ctrlKey || + element.target === '_blank' + ); + options.href = element.href; + + if (!options.new_tab) { + evt.preventDefault(); + } +}; + +LinkTracker.prototype.after_track_handler = function(props, options) { + if (options.new_tab) { return; } + + setTimeout(function() { + window$1.location = options.href; + }, 0); +}; + +/** + * FormTracker Object + * @constructor + * @extends DomTracker + */ +var FormTracker = function() { + this.override_event = 'submit'; +}; +_.inherit(FormTracker, DomTracker); + +FormTracker.prototype.event_handler = function(evt, element, options) { + options.element = element; + evt.preventDefault(); +}; + +FormTracker.prototype.after_track_handler = function(props, options) { + setTimeout(function() { + options.element.submit(); + }, 0); +}; + +/** + * Mixpanel Persistence Object + * @constructor + */ +var MixpanelPersistence = function(config) { + this['props'] = {}; + this.campaign_params_saved = false; + + if (config['persistence_name']) { + this.name = 'mp_' + config['persistence_name']; + } else { + this.name = 'mp_' + config['token'] + '_mixpanel'; + } + + var storage_type = config['persistence']; + if (storage_type !== 'cookie' && storage_type !== 'localStorage') { + console$1.critical('Unknown persistence type ' + storage_type + '; falling back to cookie'); + storage_type = config['persistence'] = 'cookie'; + } + + if (storage_type === 'localStorage' && _.localStorage.is_supported()) { + this.storage = _.localStorage; + } else { + this.storage = _.cookie; + } + + this.load(); + this.update_config(config); + this.upgrade(config); + this.save(); +}; + +MixpanelPersistence.prototype.properties = function() { + var p = {}; + // Filter out reserved properties + _.each(this['props'], function(v, k) { + if (!_.include(RESERVED_PROPERTIES, k)) { + p[k] = v; + } + }); + return p; +}; + +MixpanelPersistence.prototype.load = function() { + if (this.disabled) { return; } + + var entry = this.storage.parse(this.name); + + if (entry) { + this['props'] = _.extend({}, entry); + } +}; + +MixpanelPersistence.prototype.upgrade = function(config) { + var upgrade_from_old_lib = config['upgrade'], + old_cookie_name, + old_cookie; + + if (upgrade_from_old_lib) { + old_cookie_name = 'mp_super_properties'; + // Case where they had a custom cookie name before. + if (typeof(upgrade_from_old_lib) === 'string') { + old_cookie_name = upgrade_from_old_lib; + } + + old_cookie = this.storage.parse(old_cookie_name); + + // remove the cookie + this.storage.remove(old_cookie_name); + this.storage.remove(old_cookie_name, true); + + if (old_cookie) { + this['props'] = _.extend( + this['props'], + old_cookie['all'], + old_cookie['events'] + ); + } + } + + if (!config['cookie_name'] && config['name'] !== 'mixpanel') { + // special case to handle people with cookies of the form + // mp_TOKEN_INSTANCENAME from the first release of this library + old_cookie_name = 'mp_' + config['token'] + '_' + config['name']; + old_cookie = this.storage.parse(old_cookie_name); + + if (old_cookie) { + this.storage.remove(old_cookie_name); + this.storage.remove(old_cookie_name, true); + + // Save the prop values that were in the cookie from before - + // this should only happen once as we delete the old one. + this.register_once(old_cookie); + } + } + + if (this.storage === _.localStorage) { + old_cookie = _.cookie.parse(this.name); + + _.cookie.remove(this.name); + _.cookie.remove(this.name, true); + + if (old_cookie) { + this.register_once(old_cookie); + } + } +}; + +MixpanelPersistence.prototype.save = function() { + if (this.disabled) { return; } + this._expire_notification_campaigns(); + this.storage.set( + this.name, + _.JSONEncode(this['props']), + this.expire_days, + this.cross_subdomain, + this.secure + ); +}; + +MixpanelPersistence.prototype.remove = function() { + // remove both domain and subdomain cookies + this.storage.remove(this.name, false); + this.storage.remove(this.name, true); +}; + +// removes the storage entry and deletes all loaded data +// forced name for tests +MixpanelPersistence.prototype.clear = function() { + this.remove(); + this['props'] = {}; +}; + +/** + * @param {Object} props + * @param {*=} default_value + * @param {number=} days + */ +MixpanelPersistence.prototype.register_once = function(props, default_value, days) { + if (_.isObject(props)) { + if (typeof(default_value) === 'undefined') { default_value = 'None'; } + this.expire_days = (typeof(days) === 'undefined') ? this.default_expiry : days; + + _.each(props, function(val, prop) { + if (!this['props'].hasOwnProperty(prop) || this['props'][prop] === default_value) { + this['props'][prop] = val; + } + }, this); + + this.save(); + + return true; + } + return false; +}; + +/** + * @param {Object} props + * @param {number=} days + */ +MixpanelPersistence.prototype.register = function(props, days) { + if (_.isObject(props)) { + this.expire_days = (typeof(days) === 'undefined') ? this.default_expiry : days; + + _.extend(this['props'], props); + + this.save(); + + return true; + } + return false; +}; + +MixpanelPersistence.prototype.unregister = function(prop) { + if (prop in this['props']) { + delete this['props'][prop]; + this.save(); + } +}; + +MixpanelPersistence.prototype._expire_notification_campaigns = _.safewrap(function() { + var campaigns_shown = this['props'][CAMPAIGN_IDS_KEY], + EXPIRY_TIME = Config.DEBUG ? 60 * 1000 : 60 * 60 * 1000; // 1 minute (Config.DEBUG) / 1 hour (PDXN) + if (!campaigns_shown) { + return; + } + for (var campaign_id in campaigns_shown) { + if (1 * new Date() - campaigns_shown[campaign_id] > EXPIRY_TIME) { + delete campaigns_shown[campaign_id]; + } + } + if (_.isEmptyObject(campaigns_shown)) { + delete this['props'][CAMPAIGN_IDS_KEY]; + } +}); + +MixpanelPersistence.prototype.update_campaign_params = function() { + if (!this.campaign_params_saved) { + this.register_once(_.info.campaignParams()); + this.campaign_params_saved = true; + } +}; + +MixpanelPersistence.prototype.update_search_keyword = function(referrer) { + this.register(_.info.searchInfo(referrer)); +}; + +// EXPORTED METHOD, we test this directly. +MixpanelPersistence.prototype.update_referrer_info = function(referrer) { + // If referrer doesn't exist, we want to note the fact that it was type-in traffic. + this.register_once({ + '$initial_referrer': referrer || '$direct', + '$initial_referring_domain': _.info.referringDomain(referrer) || '$direct' + }, ''); +}; + +MixpanelPersistence.prototype.get_referrer_info = function() { + return _.strip_empty_properties({ + '$initial_referrer': this['props']['$initial_referrer'], + '$initial_referring_domain': this['props']['$initial_referring_domain'] + }); +}; + +// safely fills the passed in object with stored properties, +// does not override any properties defined in both +// returns the passed in object +MixpanelPersistence.prototype.safe_merge = function(props) { + _.each(this['props'], function(val, prop) { + if (!(prop in props)) { + props[prop] = val; + } + }); + + return props; +}; + +MixpanelPersistence.prototype.update_config = function(config) { + this.default_expiry = this.expire_days = config['cookie_expiration']; + this.set_disabled(config['disable_persistence']); + this.set_cross_subdomain(config['cross_subdomain_cookie']); + this.set_secure(config['secure_cookie']); +}; + +MixpanelPersistence.prototype.set_disabled = function(disabled) { + this.disabled = disabled; + if (this.disabled) { + this.remove(); + } else { + this.save(); + } +}; + +MixpanelPersistence.prototype.set_cross_subdomain = function(cross_subdomain) { + if (cross_subdomain !== this.cross_subdomain) { + this.cross_subdomain = cross_subdomain; + this.remove(); + this.save(); + } +}; + +MixpanelPersistence.prototype.get_cross_subdomain = function() { + return this.cross_subdomain; +}; + +MixpanelPersistence.prototype.set_secure = function(secure) { + if (secure !== this.secure) { + this.secure = secure ? true : false; + this.remove(); + this.save(); + } +}; + +MixpanelPersistence.prototype._add_to_people_queue = function(queue, data) { + var q_key = this._get_queue_key(queue), + q_data = data[queue], + set_q = this._get_or_create_queue(SET_ACTION), + set_once_q = this._get_or_create_queue(SET_ONCE_ACTION), + unset_q = this._get_or_create_queue(UNSET_ACTION), + add_q = this._get_or_create_queue(ADD_ACTION), + union_q = this._get_or_create_queue(UNION_ACTION), + append_q = this._get_or_create_queue(APPEND_ACTION, []); + + if (q_key === SET_QUEUE_KEY) { + // Update the set queue - we can override any existing values + _.extend(set_q, q_data); + // if there was a pending increment, override it + // with the set. + this._pop_from_people_queue(ADD_ACTION, q_data); + // if there was a pending union, override it + // with the set. + this._pop_from_people_queue(UNION_ACTION, q_data); + this._pop_from_people_queue(UNSET_ACTION, q_data); + } else if (q_key === SET_ONCE_QUEUE_KEY) { + // only queue the data if there is not already a set_once call for it. + _.each(q_data, function(v, k) { + if (!(k in set_once_q)) { + set_once_q[k] = v; + } + }); + this._pop_from_people_queue(UNSET_ACTION, q_data); + } else if (q_key === UNSET_QUEUE_KEY) { + _.each(q_data, function(prop) { + + // undo previously-queued actions on this key + _.each([set_q, set_once_q, add_q, union_q], function(enqueued_obj) { + if (prop in enqueued_obj) { + delete enqueued_obj[prop]; + } + }); + _.each(append_q, function(append_obj) { + if (prop in append_obj) { + delete append_obj[prop]; + } + }); + + unset_q[prop] = true; + + }); + } else if (q_key === ADD_QUEUE_KEY) { + _.each(q_data, function(v, k) { + // If it exists in the set queue, increment + // the value + if (k in set_q) { + set_q[k] += v; + } else { + // If it doesn't exist, update the add + // queue + if (!(k in add_q)) { + add_q[k] = 0; + } + add_q[k] += v; + } + }, this); + this._pop_from_people_queue(UNSET_ACTION, q_data); + } else if (q_key === UNION_QUEUE_KEY) { + _.each(q_data, function(v, k) { + if (_.isArray(v)) { + if (!(k in union_q)) { + union_q[k] = []; + } + // We may send duplicates, the server will dedup them. + union_q[k] = union_q[k].concat(v); + } + }); + this._pop_from_people_queue(UNSET_ACTION, q_data); + } else if (q_key === APPEND_QUEUE_KEY) { + append_q.push(q_data); + this._pop_from_people_queue(UNSET_ACTION, q_data); + } + + console$1.log('MIXPANEL PEOPLE REQUEST (QUEUED, PENDING IDENTIFY):'); + console$1.log(data); + + this.save(); +}; + +MixpanelPersistence.prototype._pop_from_people_queue = function(queue, data) { + var q = this._get_queue(queue); + if (!_.isUndefined(q)) { + _.each(data, function(v, k) { + delete q[k]; + }, this); + + this.save(); + } +}; + +MixpanelPersistence.prototype._get_queue_key = function(queue) { + if (queue === SET_ACTION) { + return SET_QUEUE_KEY; + } else if (queue === SET_ONCE_ACTION) { + return SET_ONCE_QUEUE_KEY; + } else if (queue === UNSET_ACTION) { + return UNSET_QUEUE_KEY; + } else if (queue === ADD_ACTION) { + return ADD_QUEUE_KEY; + } else if (queue === APPEND_ACTION) { + return APPEND_QUEUE_KEY; + } else if (queue === UNION_ACTION) { + return UNION_QUEUE_KEY; + } else { + console$1.error('Invalid queue:', queue); + } +}; + +MixpanelPersistence.prototype._get_queue = function(queue) { + return this['props'][this._get_queue_key(queue)]; +}; +MixpanelPersistence.prototype._get_or_create_queue = function(queue, default_val) { + var key = this._get_queue_key(queue); + default_val = _.isUndefined(default_val) ? {} : default_val; + + return this['props'][key] || (this['props'][key] = default_val); +}; + +MixpanelPersistence.prototype.set_event_timer = function(event_name, timestamp) { + var timers = this['props'][EVENT_TIMERS_KEY] || {}; + timers[event_name] = timestamp; + this['props'][EVENT_TIMERS_KEY] = timers; + this.save(); +}; + +MixpanelPersistence.prototype.remove_event_timer = function(event_name) { + var timers = this['props'][EVENT_TIMERS_KEY] || {}; + var timestamp = timers[event_name]; + if (!_.isUndefined(timestamp)) { + delete this['props'][EVENT_TIMERS_KEY][event_name]; + this.save(); + } + return timestamp; +}; + +/** + * Mixpanel Library Object + * @constructor + */ +var MixpanelLib = function() {}; + +/** + * Mixpanel People Object + * @constructor + */ +var MixpanelPeople = function() {}; + +var MPNotif; + +/** + * create_mplib(token:string, config:object, name:string) + * + * This function is used by the init method of MixpanelLib objects + * as well as the main initializer at the end of the JSLib (that + * initializes document.mixpanel as well as any additional instances + * declared before this file has loaded). + */ +var create_mplib = function(token, config, name) { + var instance, + target = (name === PRIMARY_INSTANCE_NAME) ? mixpanel_master : mixpanel_master[name]; + + if (target && init_type === INIT_MODULE) { + instance = target; + } else { + if (target && !_.isArray(target)) { + console$1.error('You have already initialized ' + name); + return; + } + instance = new MixpanelLib(); + } + + instance._init(token, config, name); + + instance['people'] = new MixpanelPeople(); + instance['people']._init(instance); + + // if any instance on the page has debug = true, we set the + // global debug to be true + Config.DEBUG = Config.DEBUG || instance.get_config('debug'); + + instance['__autotrack_enabled'] = instance.get_config('autotrack'); + if (instance.get_config('autotrack')) { + var num_buckets = 100; + var num_enabled_buckets = 100; + if (!autotrack.enabledForProject(instance.get_config('token'), num_buckets, num_enabled_buckets)) { + instance['__autotrack_enabled'] = false; + console$1.log('Not in active bucket: disabling Automatic Event Collection.'); + } else if (!autotrack.isBrowserSupported()) { + instance['__autotrack_enabled'] = false; + console$1.log('Disabling Automatic Event Collection because this browser is not supported'); + } else { + autotrack.init(instance); + } + } + + // if target is not defined, we called init after the lib already + // loaded, so there won't be an array of things to execute + if (!_.isUndefined(target) && _.isArray(target)) { + // Crunch through the people queue first - we queue this data up & + // flush on identify, so it's better to do all these operations first + instance._execute_array.call(instance['people'], target['people']); + instance._execute_array(target); + } + + return instance; +}; + +// Initialization methods + +/** + * This function initializes a new instance of the Mixpanel tracking object. + * All new instances are added to the main mixpanel object as sub properties (such as + * mixpanel.library_name) and also returned by this function. To define a + * second instance on the page, you would call: + * + * mixpanel.init('new token', { your: 'config' }, 'library_name'); + * + * and use it like so: + * + * mixpanel.library_name.track(...); + * + * @param {String} token Your Mixpanel API token + * @param {Object} [config] A dictionary of config options to override. See a list of default config options. + * @param {String} [name] The name for the new mixpanel instance that you want created + */ +MixpanelLib.prototype.init = function (token, config, name) { + if (_.isUndefined(name)) { + console$1.error('You must name your new library: init(token, config, name)'); + return; + } + if (name === PRIMARY_INSTANCE_NAME) { + console$1.error('You must initialize the main mixpanel object right after you include the Mixpanel js snippet'); + return; + } + + var instance = create_mplib(token, config, name); + mixpanel_master[name] = instance; + instance._loaded(); + + return instance; +}; + +// mixpanel._init(token:string, config:object, name:string) +// +// This function sets up the current instance of the mixpanel +// library. The difference between this method and the init(...) +// method is this one initializes the actual instance, whereas the +// init(...) method sets up a new library and calls _init on it. +// +MixpanelLib.prototype._init = function(token, config, name) { + this['__loaded'] = true; + this['config'] = {}; + + this.set_config(_.extend({}, DEFAULT_CONFIG, config, { + 'name': name, + 'token': token, + 'callback_fn': ((name === PRIMARY_INSTANCE_NAME) ? name : PRIMARY_INSTANCE_NAME + '.' + name) + '._jsc' + })); + + this['_jsc'] = function() {}; + + this.__dom_loaded_queue = []; + this.__request_queue = []; + this.__disabled_events = []; + this._flags = { + 'disable_all_events': false, + 'identify_called': false + }; + + this['persistence'] = this['cookie'] = new MixpanelPersistence(this['config']); + this._init_gdpr_persistence(); + + this.register_once({'distinct_id': _.UUID()}, ''); +}; + +// Private methods + +MixpanelLib.prototype._update_persistence = function() { + var disablePersistence = this.get_config('disable_persistence') || this.has_opted_out_tracking(); + if (this['persistence'].disabled !== disablePersistence) { + this['persistence'].set_disabled(disablePersistence); + } +}; + +MixpanelLib.prototype._loaded = function() { + this.get_config('loaded')(this); + + // this happens after so a user can call identify/name_tag in + // the loaded callback + if (this.get_config('track_pageview')) { + this.track_pageview(); + } +}; + +MixpanelLib.prototype._dom_loaded = function() { + _.each(this.__dom_loaded_queue, function(item) { + this._track_dom.apply(this, item); + }, this); + + if (!this.has_opted_out_tracking()) { + _.each(this.__request_queue, function(item) { + this._send_request.apply(this, item); + }, this); + } + + delete this.__dom_loaded_queue; + delete this.__request_queue; +}; + +MixpanelLib.prototype._track_dom = function(DomClass, args) { + if (this.get_config('img')) { + console$1.error('You can\'t use DOM tracking functions with img = true.'); + return false; + } + + if (!DOM_LOADED) { + this.__dom_loaded_queue.push([DomClass, args]); + return false; + } + + var dt = new DomClass().init(this); + return dt.track.apply(dt, args); +}; + +/** + * _prepare_callback() should be called by callers of _send_request for use + * as the callback argument. + * + * If there is no callback, this returns null. + * If we are going to make XHR/XDR requests, this returns a function. + * If we are going to use script tags, this returns a string to use as the + * callback GET param. + */ +MixpanelLib.prototype._prepare_callback = function(callback, data) { + if (_.isUndefined(callback)) { + return null; + } + + if (USE_XHR) { + var callback_function = function(response) { + callback(response, data); + }; + return callback_function; + } else { + // if the user gives us a callback, we store as a random + // property on this instances jsc function and update our + // callback string to reflect that. + var jsc = this['_jsc']; + var randomized_cb = '' + Math.floor(Math.random() * 100000000); + var callback_string = this.get_config('callback_fn') + '[' + randomized_cb + ']'; + jsc[randomized_cb] = function(response) { + delete jsc[randomized_cb]; + callback(response, data); + }; + return callback_string; + } +}; + +MixpanelLib.prototype._send_request = function(url, data, callback) { + if (ENQUEUE_REQUESTS) { + this.__request_queue.push(arguments); + return; + } + + // needed to correctly format responses + var verbose_mode = this.get_config('verbose'); + if (data['verbose']) { verbose_mode = true; } + + if (this.get_config('test')) { data['test'] = 1; } + if (verbose_mode) { data['verbose'] = 1; } + if (this.get_config('img')) { data['img'] = 1; } + if (!USE_XHR) { + if (callback) { + data['callback'] = callback; + } else if (verbose_mode || this.get_config('test')) { + // Verbose output (from verbose mode, or an error in test mode) is a json blob, + // which by itself is not valid javascript. Without a callback, this verbose output will + // cause an error when returned via jsonp, so we force a no-op callback param. + // See the ECMA script spec: http://www.ecma-international.org/ecma-262/5.1/#sec-12.4 + data['callback'] = '(function(){})'; + } + } + + data['ip'] = this.get_config('ip')?1:0; + data['_'] = new Date().getTime().toString(); + url += '?' + _.HTTPBuildQuery(data); + + if ('img' in data) { + var img = document$1.createElement('img'); + img.src = url; + document$1.body.appendChild(img); + } else if (USE_XHR) { + try { + var req = new XMLHttpRequest(); + req.open('GET', url, true); + + var headers = this.get_config('xhr_headers'); + _.each(headers, function(headerValue, headerName) { + req.setRequestHeader(headerName, headerValue); + }); + + // send the mp_optout cookie + // withCredentials cannot be modified until after calling .open on Android and Mobile Safari + req.withCredentials = true; + req.onreadystatechange = function () { + if (req.readyState === 4) { // XMLHttpRequest.DONE == 4, except in safari 4 + if (req.status === 200) { + if (callback) { + if (verbose_mode) { + var response; + try { + response = _.JSONDecode(req.responseText); + } catch (e) { + console$1.error(e); + return; + } + callback(response); + } else { + callback(Number(req.responseText)); + } + } + } else { + var error = 'Bad HTTP status: ' + req.status + ' ' + req.statusText; + console$1.error(error); + if (callback) { + if (verbose_mode) { + callback({status: 0, error: error}); + } else { + callback(0); + } + } + } + } + }; + req.send(null); + } catch (e) { + console$1.error(e); + } + } else { + var script = document$1.createElement('script'); + script.type = 'text/javascript'; + script.async = true; + script.defer = true; + script.src = url; + var s = document$1.getElementsByTagName('script')[0]; + s.parentNode.insertBefore(script, s); + } +}; + +/** + * _execute_array() deals with processing any mixpanel function + * calls that were called before the Mixpanel library were loaded + * (and are thus stored in an array so they can be called later) + * + * Note: we fire off all the mixpanel function calls && user defined + * functions BEFORE we fire off mixpanel tracking calls. This is so + * identify/register/set_config calls can properly modify early + * tracking calls. + * + * @param {Array} array + */ +MixpanelLib.prototype._execute_array = function(array) { + var fn_name, alias_calls = [], other_calls = [], tracking_calls = []; + _.each(array, function(item) { + if (item) { + fn_name = item[0]; + if (typeof(item) === 'function') { + item.call(this); + } else if (_.isArray(item) && fn_name === 'alias') { + alias_calls.push(item); + } else if (_.isArray(item) && fn_name.indexOf('track') !== -1 && typeof(this[fn_name]) === 'function') { + tracking_calls.push(item); + } else { + other_calls.push(item); + } + } + }, this); + + var execute = function(calls, context) { + _.each(calls, function(item) { + this[item[0]].apply(this, item.slice(1)); + }, context); + }; + + execute(alias_calls, this); + execute(other_calls, this); + execute(tracking_calls, this); +}; + +/** + * push() keeps the standard async-array-push + * behavior around after the lib is loaded. + * This is only useful for external integrations that + * do not wish to rely on our convenience methods + * (created in the snippet). + * + * ### Usage: + * mixpanel.push(['register', { a: 'b' }]); + * + * @param {Array} item A [function_name, args...] array to be executed + */ +MixpanelLib.prototype.push = function(item) { + this._execute_array([item]); +}; + +/** + * Disable events on the Mixpanel object. If passed no arguments, + * this function disables tracking of any event. If passed an + * array of event names, those events will be disabled, but other + * events will continue to be tracked. + * + * Note: this function does not stop other mixpanel functions from + * firing, such as register() or people.set(). + * + * @param {Array} [events] An array of event names to disable + */ +MixpanelLib.prototype.disable = function(events) { + if (typeof(events) === 'undefined') { + this._flags.disable_all_events = true; + } else { + this.__disabled_events = this.__disabled_events.concat(events); + } +}; + +/** + * Track an event. This is the most important and + * frequently used Mixpanel function. + * + * ### Usage: + * + * // track an event named 'Registered' + * mixpanel.track('Registered', {'Gender': 'Male', 'Age': 21}); + * + * To track link clicks or form submissions, see track_links() or track_forms(). + * + * @param {String} event_name The name of the event. This can be anything the user does - 'Button Click', 'Sign Up', 'Item Purchased', etc. + * @param {Object} [properties] A set of properties to include with the event you're sending. These describe the user who did the event or details about the event itself. + * @param {Function} [callback] If provided, the callback function will be called after tracking the event. + */ +MixpanelLib.prototype.track = addOptOutCheckMixpanelLib(function(event_name, properties, callback) { + if (typeof(callback) !== 'function') { + callback = function() {}; + } + + if (_.isUndefined(event_name)) { + console$1.error('No event name provided to mixpanel.track'); + return; + } + + if (this._event_is_disabled(event_name)) { + callback(0); + return; + } + + // set defaults + properties = properties || {}; + properties['token'] = this.get_config('token'); + + // set $duration if time_event was previously called for this event + var start_timestamp = this['persistence'].remove_event_timer(event_name); + if (!_.isUndefined(start_timestamp)) { + var duration_in_ms = new Date().getTime() - start_timestamp; + properties['$duration'] = parseFloat((duration_in_ms / 1000).toFixed(3)); + } + + // update persistence + this['persistence'].update_search_keyword(document$1.referrer); + + if (this.get_config('store_google')) { this['persistence'].update_campaign_params(); } + if (this.get_config('save_referrer')) { this['persistence'].update_referrer_info(document$1.referrer); } + + // note: extend writes to the first object, so lets make sure we + // don't write to the persistence properties object and info + // properties object by passing in a new object + + // update properties with pageview info and super-properties + properties = _.extend( + {}, + _.info.properties(), + this['persistence'].properties(), + properties + ); + + var property_blacklist = this.get_config('property_blacklist'); + if (_.isArray(property_blacklist)) { + _.each(property_blacklist, function(blacklisted_prop) { + delete properties[blacklisted_prop]; + }); + } else { + console$1.error('Invalid value for property_blacklist config: ' + property_blacklist); + } + + var data = { + 'event': event_name, + 'properties': properties + }; + + var truncated_data = _.truncate(data, 255); + var json_data = _.JSONEncode(truncated_data); + var encoded_data = _.base64Encode(json_data); + + console$1.log('MIXPANEL REQUEST:'); + console$1.log(truncated_data); + + this._send_request( + this.get_config('api_host') + '/track/', + { 'data': encoded_data }, + this._prepare_callback(callback, truncated_data) + ); + + return truncated_data; +}); + +/** + * Track a page view event, which is currently ignored by the server. + * This function is called by default on page load unless the + * track_pageview configuration variable is false. + * + * @param {String} [page] The url of the page to record. If you don't include this, it defaults to the current url. + * @api private + */ +MixpanelLib.prototype.track_pageview = function(page) { + if (_.isUndefined(page)) { + page = document$1.location.href; + } + this.track('mp_page_view', _.info.pageviewInfo(page)); +}; + +/** + * Track clicks on a set of document elements. Selector must be a + * valid query. Elements must exist on the page at the time track_links is called. + * + * ### Usage: + * + * // track click for link id #nav + * mixpanel.track_links('#nav', 'Clicked Nav Link'); + * + * ### Notes: + * + * This function will wait up to 300 ms for the Mixpanel + * servers to respond. If they have not responded by that time + * it will head to the link without ensuring that your event + * has been tracked. To configure this timeout please see the + * set_config() documentation below. + * + * If you pass a function in as the properties argument, the + * function will receive the DOMElement that triggered the + * event as an argument. You are expected to return an object + * from the function; any properties defined on this object + * will be sent to mixpanel as event properties. + * + * @type {Function} + * @param {Object|String} query A valid DOM query, element or jQuery-esque list + * @param {String} event_name The name of the event to track + * @param {Object|Function} [properties] A properties object or function that returns a dictionary of properties when passed a DOMElement + */ +MixpanelLib.prototype.track_links = function() { + return this._track_dom.call(this, LinkTracker, arguments); +}; + +/** + * Track form submissions. Selector must be a valid query. + * + * ### Usage: + * + * // track submission for form id 'register' + * mixpanel.track_forms('#register', 'Created Account'); + * + * ### Notes: + * + * This function will wait up to 300 ms for the mixpanel + * servers to respond, if they have not responded by that time + * it will head to the link without ensuring that your event + * has been tracked. To configure this timeout please see the + * set_config() documentation below. + * + * If you pass a function in as the properties argument, the + * function will receive the DOMElement that triggered the + * event as an argument. You are expected to return an object + * from the function; any properties defined on this object + * will be sent to mixpanel as event properties. + * + * @type {Function} + * @param {Object|String} query A valid DOM query, element or jQuery-esque list + * @param {String} event_name The name of the event to track + * @param {Object|Function} [properties] This can be a set of properties, or a function that returns a set of properties after being passed a DOMElement + */ +MixpanelLib.prototype.track_forms = function() { + return this._track_dom.call(this, FormTracker, arguments); +}; + +/** + * Time an event by including the time between this call and a + * later 'track' call for the same event in the properties sent + * with the event. + * + * ### Usage: + * + * // time an event named 'Registered' + * mixpanel.time_event('Registered'); + * mixpanel.track('Registered', {'Gender': 'Male', 'Age': 21}); + * + * When called for a particular event name, the next track call for that event + * name will include the elapsed time between the 'time_event' and 'track' + * calls. This value is stored as seconds in the '$duration' property. + * + * @param {String} event_name The name of the event. + */ +MixpanelLib.prototype.time_event = function(event_name) { + if (_.isUndefined(event_name)) { + console$1.error('No event name provided to mixpanel.time_event'); + return; + } + + if (this._event_is_disabled(event_name)) { + return; + } + + this['persistence'].set_event_timer(event_name, new Date().getTime()); +}; + +/** + * Register a set of super properties, which are included with all + * events. This will overwrite previous super property values. + * + * ### Usage: + * + * // register 'Gender' as a super property + * mixpanel.register({'Gender': 'Female'}); + * + * // register several super properties when a user signs up + * mixpanel.register({ + * 'Email': 'jdoe@example.com', + * 'Account Type': 'Free' + * }); + * + * @param {Object} properties An associative array of properties to store about the user + * @param {Number} [days] How many days since the user's last visit to store the super properties + */ +MixpanelLib.prototype.register = function(props, days) { + this['persistence'].register(props, days); +}; + +/** + * Register a set of super properties only once. This will not + * overwrite previous super property values, unlike register(). + * + * ### Usage: + * + * // register a super property for the first time only + * mixpanel.register_once({ + * 'First Login Date': new Date().toISOString() + * }); + * + * ### Notes: + * + * If default_value is specified, current super properties + * with that value will be overwritten. + * + * @param {Object} properties An associative array of properties to store about the user + * @param {*} [default_value] Value to override if already set in super properties (ex: 'False') Default: 'None' + * @param {Number} [days] How many days since the users last visit to store the super properties + */ +MixpanelLib.prototype.register_once = function(props, default_value, days) { + this['persistence'].register_once(props, default_value, days); +}; + +/** + * Delete a super property stored with the current user. + * + * @param {String} property The name of the super property to remove + */ +MixpanelLib.prototype.unregister = function(property) { + this['persistence'].unregister(property); +}; + +MixpanelLib.prototype._register_single = function(prop, value) { + var props = {}; + props[prop] = value; + this.register(props); +}; + +/** + * Identify a user with a unique ID instead of a Mixpanel + * randomly generated distinct_id. If the method is never called, + * then unique visitors will be identified by a UUID generated + * the first time they visit the site. + * + * ### Notes: + * + * You can call this function to overwrite a previously set + * unique ID for the current user. Mixpanel cannot translate + * between IDs at this time, so when you change a user's ID + * they will appear to be a new user. + * + * When used alone, mixpanel.identify will change the user's + * distinct_id to the unique ID provided. When used in tandem + * with mixpanel.alias, it will allow you to identify based on + * unique ID and map that back to the original, anonymous + * distinct_id given to the user upon her first arrival to your + * site (thus connecting anonymous pre-signup activity to + * post-signup activity). Though the two work together, do not + * call identify() at the same time as alias(). Calling the two + * at the same time can cause a race condition, so it is best + * practice to call identify on the original, anonymous ID + * right after you've aliased it. + * Learn more about how mixpanel.identify and mixpanel.alias can be used. + * + * @param {String} [unique_id] A string that uniquely identifies a user. If not provided, the distinct_id currently in the persistent store (cookie or localStorage) will be used. + */ +MixpanelLib.prototype.identify = function( + unique_id, _set_callback, _add_callback, _append_callback, _set_once_callback, _union_callback, _unset_callback +) { + // Optional Parameters + // _set_callback:function A callback to be run if and when the People set queue is flushed + // _add_callback:function A callback to be run if and when the People add queue is flushed + // _append_callback:function A callback to be run if and when the People append queue is flushed + // _set_once_callback:function A callback to be run if and when the People set_once queue is flushed + // _union_callback:function A callback to be run if and when the People union queue is flushed + // _unset_callback:function A callback to be run if and when the People unset queue is flushed + + // identify only changes the distinct id if it doesn't match either the existing or the alias; + // if it's new, blow away the alias as well. + if (unique_id !== this.get_distinct_id() && unique_id !== this.get_property(ALIAS_ID_KEY)) { + this.unregister(ALIAS_ID_KEY); + this._register_single('distinct_id', unique_id); + } + this._check_and_handle_notifications(this.get_distinct_id()); + this._flags.identify_called = true; + // Flush any queued up people requests + this['people']._flush(_set_callback, _add_callback, _append_callback, _set_once_callback, _union_callback, _unset_callback); +}; + +/** + * Clears super properties and generates a new random distinct_id for this instance. + * Useful for clearing data when a user logs out. + */ +MixpanelLib.prototype.reset = function() { + this['persistence'].clear(); + this._flags.identify_called = false; + this.register_once({'distinct_id': _.UUID()}, ''); +}; + +/** + * Returns the current distinct id of the user. This is either the id automatically + * generated by the library or the id that has been passed by a call to identify(). + * + * ### Notes: + * + * get_distinct_id() can only be called after the Mixpanel library has finished loading. + * init() has a loaded function available to handle this automatically. For example: + * + * // set distinct_id after the mixpanel library has loaded + * mixpanel.init('YOUR PROJECT TOKEN', { + * loaded: function(mixpanel) { + * distinct_id = mixpanel.get_distinct_id(); + * } + * }); + */ +MixpanelLib.prototype.get_distinct_id = function() { + return this.get_property('distinct_id'); +}; + +/** + * Create an alias, which Mixpanel will use to link two distinct_ids going forward (not retroactively). + * Multiple aliases can map to the same original ID, but not vice-versa. Aliases can also be chained - the + * following is a valid scenario: + * + * mixpanel.alias('new_id', 'existing_id'); + * ... + * mixpanel.alias('newer_id', 'new_id'); + * + * If the original ID is not passed in, we will use the current distinct_id - probably the auto-generated GUID. + * + * ### Notes: + * + * The best practice is to call alias() when a unique ID is first created for a user + * (e.g., when a user first registers for an account and provides an email address). + * alias() should never be called more than once for a given user, except to + * chain a newer ID to a previously new ID, as described above. + * + * @param {String} alias A unique identifier that you want to use for this user in the future. + * @param {String} [original] The current identifier being used for this user. + */ +MixpanelLib.prototype.alias = function(alias, original) { + // If the $people_distinct_id key exists in persistence, there has been a previous + // mixpanel.people.identify() call made for this user. It is VERY BAD to make an alias with + // this ID, as it will duplicate users. + if (alias === this.get_property(PEOPLE_DISTINCT_ID_KEY)) { + console$1.critical('Attempting to create alias for existing People user - aborting.'); + return -2; + } + + var _this = this; + if (_.isUndefined(original)) { + original = this.get_distinct_id(); + } + if (alias !== original) { + this._register_single(ALIAS_ID_KEY, alias); + return this.track('$create_alias', { 'alias': alias, 'distinct_id': original }, function() { + // Flush the people queue + _this.identify(alias); + }); + } else { + console$1.error('alias matches current distinct_id - skipping api call.'); + this.identify(alias); + return -1; + } +}; + +/** + * Provide a string to recognize the user by. The string passed to + * this method will appear in the Mixpanel Streams product rather + * than an automatically generated name. Name tags do not have to + * be unique. + * + * This value will only be included in Streams data. + * + * @param {String} name_tag A human readable name for the user + * @api private + */ +MixpanelLib.prototype.name_tag = function(name_tag) { + this._register_single('mp_name_tag', name_tag); +}; + +/** + * Update the configuration of a mixpanel library instance. + * + * The default config is: + * + * { + * // super properties cookie expiration (in days) + * cookie_expiration: 365 + * + * // super properties span subdomains + * cross_subdomain_cookie: true + * + * // debug mode + * debug: false + * + * // if this is true, the mixpanel cookie or localStorage entry + * // will be deleted, and no user persistence will take place + * disable_persistence: false + * + * // if this is true, Mixpanel will automatically determine + * // City, Region and Country data using the IP address of + * //the client + * ip: true + * + * // opt users out of tracking by this Mixpanel instance by default + * opt_out_tracking_by_default: false + * + * // persistence mechanism used by opt-in/opt-out methods - cookie + * // or localStorage - falls back to cookie if localStorage is unavailable + * opt_out_tracking_persistence_type: 'localStorage' + * + * // customize the name of cookie/localStorage set by opt-in/opt-out methods + * opt_out_tracking_cookie_prefix: null + * + * // type of persistent store for super properties (cookie/ + * // localStorage) if set to 'localStorage', any existing + * // mixpanel cookie value with the same persistence_name + * // will be transferred to localStorage and deleted + * persistence: 'cookie' + * + * // name for super properties persistent store + * persistence_name: '' + * + * // names of properties/superproperties which should never + * // be sent with track() calls + * property_blacklist: [] + * + * // if this is true, mixpanel cookies will be marked as + * // secure, meaning they will only be transmitted over https + * secure_cookie: false + * + * // the amount of time track_links will + * // wait for Mixpanel's servers to respond + * track_links_timeout: 300 + * + * // should we track a page view on page load + * track_pageview: true + * + * // if you set upgrade to be true, the library will check for + * // a cookie from our old js library and import super + * // properties from it, then the old cookie is deleted + * // The upgrade config option only works in the initialization, + * // so make sure you set it when you create the library. + * upgrade: false + * + * // extra HTTP request headers to set for each API request, in + * // the format {'Header-Name': value} + * xhr_headers: {} + * } + * + * + * @param {Object} config A dictionary of new configuration values to update + */ +MixpanelLib.prototype.set_config = function(config) { + if (_.isObject(config)) { + _.extend(this['config'], config); + + if (!this.get_config('persistence_name')) { + this['config']['persistence_name'] = this['config']['cookie_name']; + } + if (!this.get_config('disable_persistence')) { + this['config']['disable_persistence'] = this['config']['disable_cookie']; + } + + if (this['persistence']) { + this['persistence'].update_config(this['config']); + } + Config.DEBUG = Config.DEBUG || this.get_config('debug'); + } +}; + +/** + * returns the current config object for the library. + */ +MixpanelLib.prototype.get_config = function(prop_name) { + return this['config'][prop_name]; +}; + +/** + * Returns the value of the super property named property_name. If no such + * property is set, get_property() will return the undefined value. + * + * ### Notes: + * + * get_property() can only be called after the Mixpanel library has finished loading. + * init() has a loaded function available to handle this automatically. For example: + * + * // grab value for 'user_id' after the mixpanel library has loaded + * mixpanel.init('YOUR PROJECT TOKEN', { + * loaded: function(mixpanel) { + * user_id = mixpanel.get_property('user_id'); + * } + * }); + * + * @param {String} property_name The name of the super property you want to retrieve + */ +MixpanelLib.prototype.get_property = function(property_name) { + return this['persistence']['props'][property_name]; +}; + +MixpanelLib.prototype.toString = function() { + var name = this.get_config('name'); + if (name !== PRIMARY_INSTANCE_NAME) { + name = PRIMARY_INSTANCE_NAME + '.' + name; + } + return name; +}; + +MixpanelLib.prototype._event_is_disabled = function(event_name) { + return _.isBlockedUA(userAgent) || + this._flags.disable_all_events || + _.include(this.__disabled_events, event_name); +}; + +MixpanelLib.prototype._check_and_handle_notifications = addOptOutCheckMixpanelLib(function(distinct_id) { + if ( + !distinct_id || + this._flags.identify_called || + this.get_config('disable_notifications') + ) { + return; + } + + console$1.log('MIXPANEL NOTIFICATION CHECK'); + + var data = { + 'verbose': true, + 'version': '2', + 'lib': 'web', + 'token': this.get_config('token'), + 'distinct_id': distinct_id + }; + var self = this; + this._send_request( + this.get_config('api_host') + '/decide/', + data, + this._prepare_callback(function(r) { + if (r['notifications'] && r['notifications'].length > 0) { + self._show_notification.call(self, r['notifications'][0]); + } + }) + ); +}); + +MixpanelLib.prototype._show_notification = function(notification_data) { + var notification = new MPNotif(notification_data, this); + notification.show(); +}; + +// perform some housekeeping around GDPR persistence of opt-in/out state +MixpanelLib.prototype._init_gdpr_persistence = function() { + var is_localStorage_requested = this.get_config('opt_out_tracking_persistence_type') === 'localStorage'; + + // try to convert opt-in/out cookies to localStorage if possible + if (is_localStorage_requested && _.localStorage.is_supported()) { + if (!this.has_opted_in_tracking() && this.has_opted_in_tracking({'persistence_type': 'cookie'})) { + this.opt_in_tracking(); + } + if (!this.has_opted_out_tracking() && this.has_opted_out_tracking({'persistence_type': 'cookie'})) { + this.opt_out_tracking(); + } + this.clear_opt_in_out_tracking({'persistence_type': 'cookie'}); + } + + // check whether we should opt out by default and update persistence accordingly + if (this.get_config('opt_out_tracking_by_default') || _.cookie.get('mp_optout')) { + _.cookie.remove('mp_optout'); + this.opt_out_tracking(); + } + this._update_persistence(); +}; + +// call a base gdpr function after constructing the appropriate token and options args +MixpanelLib.prototype._call_gdpr_func = function(func, options) { + options = _.extend({ + 'track': _.bind(this.track, this), + 'persistence_type': this.get_config('opt_out_tracking_persistence_type'), + 'cookie_prefix': this.get_config('opt_out_tracking_cookie_prefix'), + 'cookie_expiration': this.get_config('cookie_expiration'), + 'cross_subdomain_cookie': this.get_config('cross_subdomain_cookie'), + 'secure_cookie': this.get_config('secure_cookie') + }, options); + + // check if localStorage can be used for recording opt out status, fall back to cookie if not + if (!_.localStorage.is_supported()) { + options['persistence_type'] = 'cookie'; + } + + return func(this.get_config('token'), { + track: options['track'], + trackEventName: options['track_event_name'], + trackProperties: options['track_properties'], + persistenceType: options['persistence_type'], + persistencePrefix: options['cookie_prefix'], + cookieExpiration: options['cookie_expiration'], + crossSubdomainCookie: options['cross_subdomain_cookie'], + secureCookie: options['secure_cookie'] + }); +}; + +/** + * Opt the user in to data tracking and cookies/localstorage for this Mixpanel instance + * + * ### Usage + * + * // opt user in + * mixpanel.opt_in_tracking(); + * + * // opt user in with specific event name, properties, cookie configuration + * mixpanel.opt_in_tracking({ + * track_event_name: 'User opted in', + * track_event_properties: { + * 'Email': 'jdoe@example.com' + * }, + * cookie_expiration: 30, + * secure_cookie: true + * }); + * + * @param {Object} [options] A dictionary of config options to override + * @param {function} [options.track] Function used for tracking a Mixpanel event to record the opt-in action (default is this Mixpanel instance's track method) + * @param {string} [options.track_event_name=$opt_in] Event name to be used for tracking the opt-in action + * @param {Object} [options.track_properties] Set of properties to be tracked along with the opt-in action + * @param {string} [options.persistence_type=localStorage] Persistence mechanism used - cookie or localStorage - falls back to cookie if localStorage is unavailable + * @param {string} [options.cookie_prefix=__mp_opt_in_out] Custom prefix to be used in the cookie/localstorage name + * @param {Number} [options.cookie_expiration] Number of days until the opt-in cookie expires (overrides value specified in this Mixpanel instance's config) + * @param {boolean} [options.cross_subdomain_cookie] Whether the opt-in cookie is set as cross-subdomain or not (overrides value specified in this Mixpanel instance's config) + * @param {boolean} [options.secure_cookie] Whether the opt-in cookie is set as secure or not (overrides value specified in this Mixpanel instance's config) + */ +MixpanelLib.prototype.opt_in_tracking = function(options) { + this._call_gdpr_func(optIn, options); + this._update_persistence(); +}; + +/** + * Opt the user out of data tracking and cookies/localstorage for this Mixpanel instance + * + * ### Usage + * + * // opt user out + * mixpanel.opt_out_tracking(); + * + * // opt user out with different cookie configuration from Mixpanel instance + * mixpanel.opt_out_tracking({ + * cookie_expiration: 30, + * secure_cookie: true + * }); + * + * @param {Object} [options] A dictionary of config options to override + * @param {boolean} [options.delete_user=true] If true, will delete the currently identified user's profile and clear all charges after opting the user out + * @param {string} [options.persistence_type=localStorage] Persistence mechanism used - cookie or localStorage - falls back to cookie if localStorage is unavailable + * @param {string} [options.cookie_prefix=__mp_opt_in_out] Custom prefix to be used in the cookie/localstorage name + * @param {Number} [options.cookie_expiration] Number of days until the opt-in cookie expires (overrides value specified in this Mixpanel instance's config) + * @param {boolean} [options.cross_subdomain_cookie] Whether the opt-in cookie is set as cross-subdomain or not (overrides value specified in this Mixpanel instance's config) + * @param {boolean} [options.secure_cookie] Whether the opt-in cookie is set as secure or not (overrides value specified in this Mixpanel instance's config) + */ +MixpanelLib.prototype.opt_out_tracking = function(options) { + // delete use and clear charges since these methods may be disabled by opt-out + options = _.extend({'delete_user': true}, options); + if (options['delete_user'] && this['people'] && this['people']._identify_called()) { + this['people'].delete_user(); + this['people'].clear_charges(); + } + + this._call_gdpr_func(optOut, options); + this._update_persistence(); +}; + +/** + * Check whether the user has opted in to data tracking and cookies/localstorage for this Mixpanel instance + * + * ### Usage + * + * var has_opted_in = mixpanel.has_opted_in_tracking(); + * // use has_opted_in value + * + * @param {Object} [options] A dictionary of config options to override + * @param {string} [options.persistence_type=localStorage] Persistence mechanism used - cookie or localStorage - falls back to cookie if localStorage is unavailable + * @param {string} [options.cookie_prefix=__mp_opt_in_out] Custom prefix to be used in the cookie/localstorage name + * @returns {boolean} current opt-in status + */ +MixpanelLib.prototype.has_opted_in_tracking = function(options) { + return this._call_gdpr_func(hasOptedIn, options); +}; + +/** + * Check whether the user has opted out of data tracking and cookies/localstorage for this Mixpanel instance + * + * ### Usage + * + * var has_opted_out = mixpanel.has_opted_out_tracking(); + * // use has_opted_out value + * + * @param {Object} [options] A dictionary of config options to override + * @param {string} [options.persistence_type=localStorage] Persistence mechanism used - cookie or localStorage - falls back to cookie if localStorage is unavailable + * @param {string} [options.cookie_prefix=__mp_opt_in_out] Custom prefix to be used in the cookie/localstorage name + * @returns {boolean} current opt-out status + */ +MixpanelLib.prototype.has_opted_out_tracking = function(options) { + return this._call_gdpr_func(hasOptedOut, options); +}; + +/** + * Clear the user's opt in/out status of data tracking and cookies/localstorage for this Mixpanel instance + * + * ### Usage + * + * // clear user's opt-in/out status + * mixpanel.clear_opt_in_out_tracking(); + * + * // clear user's opt-in/out status with specific cookie configuration - should match + * // configuration used when opt_in_tracking/opt_out_tracking methods were called. + * mixpanel.clear_opt_in_out_tracking({ + * cookie_expiration: 30, + * secure_cookie: true + * }); + * + * @param {Object} [options] A dictionary of config options to override + * @param {string} [options.persistence_type=localStorage] Persistence mechanism used - cookie or localStorage - falls back to cookie if localStorage is unavailable + * @param {string} [options.cookie_prefix=__mp_opt_in_out] Custom prefix to be used in the cookie/localstorage name + * @param {Number} [options.cookie_expiration] Number of days until the opt-in cookie expires (overrides value specified in this Mixpanel instance's config) + * @param {boolean} [options.cross_subdomain_cookie] Whether the opt-in cookie is set as cross-subdomain or not (overrides value specified in this Mixpanel instance's config) + * @param {boolean} [options.secure_cookie] Whether the opt-in cookie is set as secure or not (overrides value specified in this Mixpanel instance's config) + */ +MixpanelLib.prototype.clear_opt_in_out_tracking = function(options) { + this._call_gdpr_func(clearOptInOut, options); + this._update_persistence(); +}; + + +MixpanelPeople.prototype._init = function(mixpanel_instance) { + this._mixpanel = mixpanel_instance; +}; + +/* + * Set properties on a user record. + * + * ### Usage: + * + * mixpanel.people.set('gender', 'm'); + * + * // or set multiple properties at once + * mixpanel.people.set({ + * 'Company': 'Acme', + * 'Plan': 'Premium', + * 'Upgrade date': new Date() + * }); + * // properties can be strings, integers, dates, or lists + * + * @param {Object|String} prop If a string, this is the name of the property. If an object, this is an associative array of names and values. + * @param {*} [to] A value to set on the given property name + * @param {Function} [callback] If provided, the callback will be called after the tracking event + */ +MixpanelPeople.prototype.set = addOptOutCheckMixpanelPeople(function(prop, to, callback) { + var data = {}; + var $set = {}; + if (_.isObject(prop)) { + _.each(prop, function(v, k) { + if (!this._is_reserved_property(k)) { + $set[k] = v; + } + }, this); + callback = to; + } else { + $set[prop] = to; + } + + // make sure that the referrer info has been updated and saved + if (this._get_config('save_referrer')) { + this._mixpanel['persistence'].update_referrer_info(document$1.referrer); + } + + // update $set object with default people properties + $set = _.extend( + {}, + _.info.people_properties(), + this._mixpanel['persistence'].get_referrer_info(), + $set + ); + + data[SET_ACTION] = $set; + + return this._send_request(data, callback); +}); + +/* + * Set properties on a user record, only if they do not yet exist. + * This will not overwrite previous people property values, unlike + * people.set(). + * + * ### Usage: + * + * mixpanel.people.set_once('First Login Date', new Date()); + * + * // or set multiple properties at once + * mixpanel.people.set_once({ + * 'First Login Date': new Date(), + * 'Starting Plan': 'Premium' + * }); + * + * // properties can be strings, integers or dates + * + * @param {Object|String} prop If a string, this is the name of the property. If an object, this is an associative array of names and values. + * @param {*} [to] A value to set on the given property name + * @param {Function} [callback] If provided, the callback will be called after the tracking event + */ +MixpanelPeople.prototype.set_once = addOptOutCheckMixpanelPeople(function(prop, to, callback) { + var data = {}; + var $set_once = {}; + if (_.isObject(prop)) { + _.each(prop, function(v, k) { + if (!this._is_reserved_property(k)) { + $set_once[k] = v; + } + }, this); + callback = to; + } else { + $set_once[prop] = to; + } + data[SET_ONCE_ACTION] = $set_once; + return this._send_request(data, callback); +}); + +/* + * Unset properties on a user record (permanently removes the properties and their values from a profile). + * + * ### Usage: + * + * mixpanel.people.unset('gender'); + * + * // or unset multiple properties at once + * mixpanel.people.unset(['gender', 'Company']); + * + * @param {Array|String} prop If a string, this is the name of the property. If an array, this is a list of property names. + * @param {Function} [callback] If provided, the callback will be called after the tracking event + */ +MixpanelPeople.prototype.unset = function(prop, callback) { + var data = {}; + var $unset = []; + if (!_.isArray(prop)) { + prop = [prop]; + } + + _.each(prop, function(k) { + if (!this._is_reserved_property(k)) { + $unset.push(k); + } + }, this); + + data[UNSET_ACTION] = $unset; + + return this._send_request(data, callback); +}; + +/* + * Increment/decrement numeric people analytics properties. + * + * ### Usage: + * + * mixpanel.people.increment('page_views', 1); + * + * // or, for convenience, if you're just incrementing a counter by + * // 1, you can simply do + * mixpanel.people.increment('page_views'); + * + * // to decrement a counter, pass a negative number + * mixpanel.people.increment('credits_left', -1); + * + * // like mixpanel.people.set(), you can increment multiple + * // properties at once: + * mixpanel.people.increment({ + * counter1: 1, + * counter2: 6 + * }); + * + * @param {Object|String} prop If a string, this is the name of the property. If an object, this is an associative array of names and numeric values. + * @param {Number} [by] An amount to increment the given property + * @param {Function} [callback] If provided, the callback will be called after the tracking event + */ +MixpanelPeople.prototype.increment = addOptOutCheckMixpanelPeople(function(prop, by, callback) { + var data = {}; + var $add = {}; + if (_.isObject(prop)) { + _.each(prop, function(v, k) { + if (!this._is_reserved_property(k)) { + if (isNaN(parseFloat(v))) { + console$1.error('Invalid increment value passed to mixpanel.people.increment - must be a number'); + return; + } else { + $add[k] = v; + } + } + }, this); + callback = by; + } else { + // convenience: mixpanel.people.increment('property'); will + // increment 'property' by 1 + if (_.isUndefined(by)) { + by = 1; + } + $add[prop] = by; + } + data[ADD_ACTION] = $add; + + return this._send_request(data, callback); +}); + +/* + * Append a value to a list-valued people analytics property. + * + * ### Usage: + * + * // append a value to a list, creating it if needed + * mixpanel.people.append('pages_visited', 'homepage'); + * + * // like mixpanel.people.set(), you can append multiple + * // properties at once: + * mixpanel.people.append({ + * list1: 'bob', + * list2: 123 + * }); + * + * @param {Object|String} prop If a string, this is the name of the property. If an object, this is an associative array of names and values. + * @param {*} [value] An item to append to the list + * @param {Function} [callback] If provided, the callback will be called after the tracking event + */ +MixpanelPeople.prototype.append = addOptOutCheckMixpanelPeople(function(list_name, value, callback) { + var data = {}; + var $append = {}; + if (_.isObject(list_name)) { + _.each(list_name, function(v, k) { + if (!this._is_reserved_property(k)) { + $append[k] = v; + } + }, this); + callback = value; + } else { + $append[list_name] = value; + } + data[APPEND_ACTION] = $append; + + return this._send_request(data, callback); +}); + +/* + * Merge a given list with a list-valued people analytics property, + * excluding duplicate values. + * + * ### Usage: + * + * // merge a value to a list, creating it if needed + * mixpanel.people.union('pages_visited', 'homepage'); + * + * // like mixpanel.people.set(), you can append multiple + * // properties at once: + * mixpanel.people.union({ + * list1: 'bob', + * list2: 123 + * }); + * + * // like mixpanel.people.append(), you can append multiple + * // values to the same list: + * mixpanel.people.union({ + * list1: ['bob', 'billy'] + * }); + * + * @param {Object|String} prop If a string, this is the name of the property. If an object, this is an associative array of names and values. + * @param {*} [value] Value / values to merge with the given property + * @param {Function} [callback] If provided, the callback will be called after the tracking event + */ +MixpanelPeople.prototype.union = addOptOutCheckMixpanelPeople(function(list_name, values, callback) { + var data = {}; + var $union = {}; + if (_.isObject(list_name)) { + _.each(list_name, function(v, k) { + if (!this._is_reserved_property(k)) { + $union[k] = _.isArray(v) ? v : [v]; + } + }, this); + callback = values; + } else { + $union[list_name] = _.isArray(values) ? values : [values]; + } + data[UNION_ACTION] = $union; + + return this._send_request(data, callback); +}); + +/* + * Record that you have charged the current user a certain amount + * of money. Charges recorded with track_charge() will appear in the + * Mixpanel revenue report. + * + * ### Usage: + * + * // charge a user $50 + * mixpanel.people.track_charge(50); + * + * // charge a user $30.50 on the 2nd of january + * mixpanel.people.track_charge(30.50, { + * '$time': new Date('jan 1 2012') + * }); + * + * @param {Number} amount The amount of money charged to the current user + * @param {Object} [properties] An associative array of properties associated with the charge + * @param {Function} [callback] If provided, the callback will be called when the server responds + */ +MixpanelPeople.prototype.track_charge = addOptOutCheckMixpanelPeople(function(amount, properties, callback) { + if (!_.isNumber(amount)) { + amount = parseFloat(amount); + if (isNaN(amount)) { + console$1.error('Invalid value passed to mixpanel.people.track_charge - must be a number'); + return; + } + } + + return this.append('$transactions', _.extend({ + '$amount': amount + }, properties), callback); +}); + +/* + * Permanently clear all revenue report transactions from the + * current user's people analytics profile. + * + * ### Usage: + * + * mixpanel.people.clear_charges(); + * + * @param {Function} [callback] If provided, the callback will be called after the tracking event + */ +MixpanelPeople.prototype.clear_charges = function(callback) { + return this.set('$transactions', [], callback); +}; + +/* + * Permanently deletes the current people analytics profile from + * Mixpanel (using the current distinct_id). + * + * ### Usage: + * + * // remove the all data you have stored about the current user + * mixpanel.people.delete_user(); + * + */ +MixpanelPeople.prototype.delete_user = function() { + if (!this._identify_called()) { + console$1.error('mixpanel.people.delete_user() requires you to call identify() first'); + return; + } + var data = {'$delete': this._mixpanel.get_distinct_id()}; + return this._send_request(data); +}; + +MixpanelPeople.prototype.toString = function() { + return this._mixpanel.toString() + '.people'; +}; + +MixpanelPeople.prototype._send_request = function(data, callback) { + data['$token'] = this._get_config('token'); + data['$distinct_id'] = this._mixpanel.get_distinct_id(); + + var date_encoded_data = _.encodeDates(data); + var truncated_data = _.truncate(date_encoded_data, 255); + var json_data = _.JSONEncode(date_encoded_data); + var encoded_data = _.base64Encode(json_data); + + if (!this._identify_called()) { + this._enqueue(data); + if (!_.isUndefined(callback)) { + if (this._get_config('verbose')) { + callback({status: -1, error: null}); + } else { + callback(-1); + } + } + return truncated_data; + } + + console$1.log('MIXPANEL PEOPLE REQUEST:'); + console$1.log(truncated_data); + + this._mixpanel._send_request( + this._get_config('api_host') + '/engage/', + {'data': encoded_data}, + this._mixpanel._prepare_callback(callback, truncated_data) + ); + + return truncated_data; +}; + +MixpanelPeople.prototype._get_config = function(conf_var) { + return this._mixpanel.get_config(conf_var); +}; + +MixpanelPeople.prototype._identify_called = function() { + return this._mixpanel._flags.identify_called === true; +}; + +// Queue up engage operations if identify hasn't been called yet. +MixpanelPeople.prototype._enqueue = function(data) { + if (SET_ACTION in data) { + this._mixpanel['persistence']._add_to_people_queue(SET_ACTION, data); + } else if (SET_ONCE_ACTION in data) { + this._mixpanel['persistence']._add_to_people_queue(SET_ONCE_ACTION, data); + } else if (UNSET_ACTION in data) { + this._mixpanel['persistence']._add_to_people_queue(UNSET_ACTION, data); + } else if (ADD_ACTION in data) { + this._mixpanel['persistence']._add_to_people_queue(ADD_ACTION, data); + } else if (APPEND_ACTION in data) { + this._mixpanel['persistence']._add_to_people_queue(APPEND_ACTION, data); + } else if (UNION_ACTION in data) { + this._mixpanel['persistence']._add_to_people_queue(UNION_ACTION, data); + } else { + console$1.error('Invalid call to _enqueue():', data); + } +}; + +MixpanelPeople.prototype._flush_one_queue = function(action, action_method, callback, queue_to_params_fn) { + var _this = this; + var queued_data = _.extend({}, this._mixpanel['persistence']._get_queue(action)); + var action_params = queued_data; + + if (!_.isUndefined(queued_data) && _.isObject(queued_data) && !_.isEmptyObject(queued_data)) { + _this._mixpanel['persistence']._pop_from_people_queue(action, queued_data); + if (queue_to_params_fn) { + action_params = queue_to_params_fn(queued_data); + } + action_method.call(_this, action_params, function(response, data) { + // on bad response, we want to add it back to the queue + if (response === 0) { + _this._mixpanel['persistence']._add_to_people_queue(action, queued_data); + } + if (!_.isUndefined(callback)) { + callback(response, data); + } + }); + } +}; + +// Flush queued engage operations - order does not matter, +// and there are network level race conditions anyway +MixpanelPeople.prototype._flush = function( + _set_callback, _add_callback, _append_callback, _set_once_callback, _union_callback, _unset_callback +) { + var _this = this; + var $append_queue = this._mixpanel['persistence']._get_queue(APPEND_ACTION); + + this._flush_one_queue(SET_ACTION, this.set, _set_callback); + this._flush_one_queue(SET_ONCE_ACTION, this.set_once, _set_once_callback); + this._flush_one_queue(UNSET_ACTION, this.unset, _unset_callback, function(queue) { return _.keys(queue); }); + this._flush_one_queue(ADD_ACTION, this.increment, _add_callback); + this._flush_one_queue(UNION_ACTION, this.union, _union_callback); + + // we have to fire off each $append individually since there is + // no concat method server side + if (!_.isUndefined($append_queue) && _.isArray($append_queue) && $append_queue.length) { + var $append_item; + var callback = function(response, data) { + if (response === 0) { + _this._mixpanel['persistence']._add_to_people_queue(APPEND_ACTION, $append_item); + } + if (!_.isUndefined(_append_callback)) { + _append_callback(response, data); + } + }; + for (var i = $append_queue.length - 1; i >= 0; i--) { + $append_item = $append_queue.pop(); + _this.append($append_item, callback); + } + // Save the shortened append queue + _this._mixpanel['persistence'].save(); + } +}; + +MixpanelPeople.prototype._is_reserved_property = function(prop) { + return prop === '$distinct_id' || prop === '$token'; +}; + + +// Internal class for notification display +MixpanelLib._Notification = function(notif_data, mixpanel_instance) { + _.bind_instance_methods(this); + + this.mixpanel = mixpanel_instance; + this.persistence = this.mixpanel['persistence']; + + this.campaign_id = _.escapeHTML(notif_data['id']); + this.message_id = _.escapeHTML(notif_data['message_id']); + + this.body = (_.escapeHTML(notif_data['body']) || '').replace(/\n/g, '
'); + this.cta = _.escapeHTML(notif_data['cta']) || 'Close'; + this.notif_type = _.escapeHTML(notif_data['type']) || 'takeover'; + this.style = _.escapeHTML(notif_data['style']) || 'light'; + this.title = _.escapeHTML(notif_data['title']) || ''; + this.video_width = MPNotif.VIDEO_WIDTH; + this.video_height = MPNotif.VIDEO_HEIGHT; + + // These fields are url-sanitized in the backend already. + this.dest_url = notif_data['cta_url'] || null; + this.image_url = notif_data['image_url'] || null; + this.thumb_image_url = notif_data['thumb_image_url'] || null; + this.video_url = notif_data['video_url'] || null; + + this.clickthrough = true; + if (!this.dest_url) { + this.dest_url = '#dismiss'; + this.clickthrough = false; + } + + this.mini = this.notif_type === 'mini'; + if (!this.mini) { + this.notif_type = 'takeover'; + } + this.notif_width = !this.mini ? MPNotif.NOTIF_WIDTH : MPNotif.NOTIF_WIDTH_MINI; + + this._set_client_config(); + this.imgs_to_preload = this._init_image_html(); + this._init_video(); +}; + +MPNotif = MixpanelLib._Notification; + +MPNotif.ANIM_TIME = 200; +MPNotif.MARKUP_PREFIX = 'mixpanel-notification'; +MPNotif.BG_OPACITY = 0.6; +MPNotif.NOTIF_TOP = 25; +MPNotif.NOTIF_START_TOP = 200; +MPNotif.NOTIF_WIDTH = 388; +MPNotif.NOTIF_WIDTH_MINI = 420; +MPNotif.NOTIF_HEIGHT_MINI = 85; +MPNotif.THUMB_BORDER_SIZE = 5; +MPNotif.THUMB_IMG_SIZE = 60; +MPNotif.THUMB_OFFSET = Math.round(MPNotif.THUMB_IMG_SIZE / 2); +MPNotif.VIDEO_WIDTH = 595; +MPNotif.VIDEO_HEIGHT = 334; + +MPNotif.prototype.show = function() { + var self = this; + this._set_client_config(); + + // don't display until HTML body exists + if (!this.body_el) { + setTimeout(function() { self.show(); }, 300); + return; + } + + this._init_styles(); + this._init_notification_el(); + + // wait for any images to load before showing notification + this._preload_images(this._attach_and_animate); +}; + +MPNotif.prototype.dismiss = _.safewrap(function() { + if (!this.marked_as_shown) { + // unexpected condition: user interacted with notif even though we didn't consider it + // visible (see _mark_as_shown()); send tracking signals to mark delivery + this._mark_delivery({'invisible': true}); + } + + var exiting_el = this.showing_video ? this._get_el('video') : this._get_notification_display_el(); + if (this.use_transitions) { + this._remove_class('bg', 'visible'); + this._add_class(exiting_el, 'exiting'); + setTimeout(this._remove_notification_el, MPNotif.ANIM_TIME); + } else { + var notif_attr, notif_start, notif_goal; + if (this.mini) { + notif_attr = 'right'; + notif_start = 20; + notif_goal = -100; + } else { + notif_attr = 'top'; + notif_start = MPNotif.NOTIF_TOP; + notif_goal = MPNotif.NOTIF_START_TOP + MPNotif.NOTIF_TOP; + } + this._animate_els([ + { + el: this._get_el('bg'), + attr: 'opacity', + start: MPNotif.BG_OPACITY, + goal: 0.0 + }, + { + el: exiting_el, + attr: 'opacity', + start: 1.0, + goal: 0.0 + }, + { + el: exiting_el, + attr: notif_attr, + start: notif_start, + goal: notif_goal + } + ], MPNotif.ANIM_TIME, this._remove_notification_el); + } +}); + +MPNotif.prototype._add_class = _.safewrap(function(el, class_name) { + class_name = MPNotif.MARKUP_PREFIX + '-' + class_name; + if (typeof el === 'string') { + el = this._get_el(el); + } + if (!el.className) { + el.className = class_name; + } else if (!~(' ' + el.className + ' ').indexOf(' ' + class_name + ' ')) { + el.className += ' ' + class_name; + } +}); +MPNotif.prototype._remove_class = _.safewrap(function(el, class_name) { + class_name = MPNotif.MARKUP_PREFIX + '-' + class_name; + if (typeof el === 'string') { + el = this._get_el(el); + } + if (el.className) { + el.className = (' ' + el.className + ' ') + .replace(' ' + class_name + ' ', '') + .replace(/^[\s\xA0]+/, '') + .replace(/[\s\xA0]+$/, ''); + } +}); + +MPNotif.prototype._animate_els = _.safewrap(function(anims, mss, done_cb, start_time) { + var self = this, + in_progress = false, + ai, anim, + cur_time = 1 * new Date(), time_diff; + + start_time = start_time || cur_time; + time_diff = cur_time - start_time; + + for (ai = 0; ai < anims.length; ai++) { + anim = anims[ai]; + if (typeof anim.val === 'undefined') { + anim.val = anim.start; + } + if (anim.val !== anim.goal) { + in_progress = true; + var anim_diff = anim.goal - anim.start, + anim_dir = anim.goal >= anim.start ? 1 : -1; + anim.val = anim.start + anim_diff * time_diff / mss; + if (anim.attr !== 'opacity') { + anim.val = Math.round(anim.val); + } + if ((anim_dir > 0 && anim.val >= anim.goal) || (anim_dir < 0 && anim.val <= anim.goal)) { + anim.val = anim.goal; + } + } + } + if (!in_progress) { + if (done_cb) { + done_cb(); + } + return; + } + + for (ai = 0; ai < anims.length; ai++) { + anim = anims[ai]; + if (anim.el) { + var suffix = anim.attr === 'opacity' ? '' : 'px'; + anim.el.style[anim.attr] = String(anim.val) + suffix; + } + } + setTimeout(function() { self._animate_els(anims, mss, done_cb, start_time); }, 10); +}); + +MPNotif.prototype._attach_and_animate = _.safewrap(function() { + var self = this; + + // no possibility to double-display + if (this.shown || this._get_shown_campaigns()[this.campaign_id]) { + return; + } + this.shown = true; + + this.body_el.appendChild(this.notification_el); + setTimeout(function() { + var notif_el = self._get_notification_display_el(); + if (self.use_transitions) { + if (!self.mini) { + self._add_class('bg', 'visible'); + } + self._add_class(notif_el, 'visible'); + self._mark_as_shown(); + } else { + var notif_attr, notif_start, notif_goal; + if (self.mini) { + notif_attr = 'right'; + notif_start = -100; + notif_goal = 20; + } else { + notif_attr = 'top'; + notif_start = MPNotif.NOTIF_START_TOP + MPNotif.NOTIF_TOP; + notif_goal = MPNotif.NOTIF_TOP; + } + self._animate_els([ + { + el: self._get_el('bg'), + attr: 'opacity', + start: 0.0, + goal: MPNotif.BG_OPACITY + }, + { + el: notif_el, + attr: 'opacity', + start: 0.0, + goal: 1.0 + }, + { + el: notif_el, + attr: notif_attr, + start: notif_start, + goal: notif_goal + } + ], MPNotif.ANIM_TIME, self._mark_as_shown); + } + }, 100); + _.register_event(self._get_el('cancel'), 'click', function(e) { + e.preventDefault(); + self.dismiss(); + }); + var click_el = self._get_el('button') || + self._get_el('mini-content'); + _.register_event(click_el, 'click', function(e) { + e.preventDefault(); + if (self.show_video) { + self._track_event('$campaign_open', {'$resource_type': 'video'}); + self._switch_to_video(); + } else { + self.dismiss(); + if (self.clickthrough) { + self._track_event('$campaign_open', {'$resource_type': 'link'}, function() { + window$1.location.href = self.dest_url; + }); + } + } + }); +}); + +MPNotif.prototype._get_el = function(id) { + return document$1.getElementById(MPNotif.MARKUP_PREFIX + '-' + id); +}; + +MPNotif.prototype._get_notification_display_el = function() { + return this._get_el(this.notif_type); +}; + +MPNotif.prototype._get_shown_campaigns = function() { + return this.persistence['props'][CAMPAIGN_IDS_KEY] || (this.persistence['props'][CAMPAIGN_IDS_KEY] = {}); +}; + +MPNotif.prototype._browser_lte = function(browser, version) { + return this.browser_versions[browser] && this.browser_versions[browser] <= version; +}; + +MPNotif.prototype._init_image_html = function() { + var imgs_to_preload = []; + + if (!this.mini) { + if (this.image_url) { + imgs_to_preload.push(this.image_url); + this.img_html = ''; + } else { + this.img_html = ''; + } + if (this.thumb_image_url) { + imgs_to_preload.push(this.thumb_image_url); + this.thumb_img_html = + '
' + + '' + + '
'; + } else { + this.thumb_img_html = ''; + } + } else { + this.thumb_image_url = this.thumb_image_url || '//cdn.mxpnl.com/site_media/images/icons/notifications/mini-news-dark.png'; + imgs_to_preload.push(this.thumb_image_url); + } + + return imgs_to_preload; +}; + +MPNotif.prototype._init_notification_el = function() { + var notification_html = ''; + var video_src = ''; + var video_html = ''; + var cancel_html = '
' + + '
' + + '
'; + + this.notification_el = document$1.createElement('div'); + this.notification_el.id = MPNotif.MARKUP_PREFIX + '-wrapper'; + if (!this.mini) { + // TAKEOVER notification + var close_html = (this.clickthrough || this.show_video) ? '' : '
', + play_html = this.show_video ? '
' : ''; + if (this._browser_lte('ie', 7)) { + close_html = ''; + play_html = ''; + } + notification_html = + '
' + + this.thumb_img_html + + '
' + + cancel_html + + '
' + + this.img_html + + '
' + this.title + '
' + + '
' + this.body + '
' + + '
' + + 'POWERED BY MIXPANEL' + + '
' + + '
' + + '
' + + close_html + + '' + this.cta + '' + + play_html + + '
' + + '
' + + '
'; + } else { + // MINI notification + notification_html = + '
' + + '
' + + cancel_html + + '
' + + '
' + + '
' + + '
' + + '
' + + '
' + this.body + '
' + + '
' + + '
' + + '
' + + '
' + + '
'; + } + if (this.youtube_video) { + video_src = '//www.youtube.com/embed/' + this.youtube_video + + '?wmode=transparent&showinfo=0&modestbranding=0&rel=0&autoplay=1&loop=0&vq=hd1080'; + if (this.yt_custom) { + video_src += '&enablejsapi=1&html5=1&controls=0'; + video_html = + '
' + + '
' + + '
' + + '
' + + '
' + + '
' + + '
'; + } + } else if (this.vimeo_video) { + video_src = '//player.vimeo.com/video/' + this.vimeo_video + '?autoplay=1&title=0&byline=0&portrait=0'; + } + if (this.show_video) { + this.video_iframe = + ''; + video_html = + '
' + + '
' + + '
' + + video_html + + '
' + + '
'; + } + var main_html = video_html + notification_html; + if (this.flip_animate) { + main_html = + (this.mini ? notification_html : '') + + '
' + + (this.mini ? video_html : main_html) + + '
'; + } + + this.notification_el.innerHTML = + ('
' + + '
' + + '
' + + '
' + + main_html + + '
' + + '
' + + '
') + .replace(/class=\"/g, 'class="' + MPNotif.MARKUP_PREFIX + '-') + .replace(/id=\"/g, 'id="' + MPNotif.MARKUP_PREFIX + '-'); +}; + +MPNotif.prototype._init_styles = function() { + if (this.style === 'dark') { + this.style_vals = { + bg: '#1d1f25', + bg_actions: '#282b32', + bg_hover: '#3a4147', + bg_light: '#4a5157', + border_gray: '#32353c', + cancel_opacity: '0.4', + mini_hover: '#2a3137', + text_title: '#fff', + text_main: '#9498a3', + text_tagline: '#464851', + text_hover: '#ddd' + }; + } else { + this.style_vals = { + bg: '#fff', + bg_actions: '#e7eaee', + bg_hover: '#eceff3', + bg_light: '#f5f5f5', + border_gray: '#e4ecf2', + cancel_opacity: '1.0', + mini_hover: '#fafafa', + text_title: '#5c6578', + text_main: '#8b949b', + text_tagline: '#ced9e6', + text_hover: '#7c8598' + }; + } + var shadow = '0px 0px 35px 0px rgba(45, 49, 56, 0.7)', + video_shadow = shadow, + mini_shadow = shadow, + thumb_total_size = MPNotif.THUMB_IMG_SIZE + MPNotif.THUMB_BORDER_SIZE * 2, + anim_seconds = (MPNotif.ANIM_TIME / 1000) + 's'; + if (this.mini) { + shadow = 'none'; + } + + // don't display on small viewports + var notif_media_queries = {}, + min_width = MPNotif.NOTIF_WIDTH_MINI + 20; + notif_media_queries['@media only screen and (max-width: ' + (min_width - 1) + 'px)'] = { + '#overlay': { + 'display': 'none' + } + }; + var notif_styles = { + '.flipped': { + 'transform': 'rotateY(180deg)' + }, + '#overlay': { + 'position': 'fixed', + 'top': '0', + 'left': '0', + 'width': '100%', + 'height': '100%', + 'overflow': 'auto', + 'text-align': 'center', + 'z-index': '10000', + 'font-family': '"Helvetica", "Arial", sans-serif', + '-webkit-font-smoothing': 'antialiased', + '-moz-osx-font-smoothing': 'grayscale' + }, + '#overlay.mini': { + 'height': '0', + 'overflow': 'visible' + }, + '#overlay a': { + 'width': 'initial', + 'padding': '0', + 'text-decoration': 'none', + 'text-transform': 'none', + 'color': 'inherit' + }, + '#bgwrapper': { + 'position': 'relative', + 'width': '100%', + 'height': '100%' + }, + '#bg': { + 'position': 'fixed', + 'top': '0', + 'left': '0', + 'width': '100%', + 'height': '100%', + 'min-width': this.doc_width * 4 + 'px', + 'min-height': this.doc_height * 4 + 'px', + 'background-color': 'black', + 'opacity': '0.0', + '-ms-filter': 'progid:DXImageTransform.Microsoft.Alpha(Opacity=60)', // IE8 + 'filter': 'alpha(opacity=60)', // IE5-7 + 'transition': 'opacity ' + anim_seconds + }, + '#bg.visible': { + 'opacity': MPNotif.BG_OPACITY + }, + '.mini #bg': { + 'width': '0', + 'height': '0', + 'min-width': '0' + }, + '#flipcontainer': { + 'perspective': '1000px', + 'position': 'absolute', + 'width': '100%' + }, + '#flipper': { + 'position': 'relative', + 'transform-style': 'preserve-3d', + 'transition': '0.3s' + }, + '#takeover': { + 'position': 'absolute', + 'left': '50%', + 'width': MPNotif.NOTIF_WIDTH + 'px', + 'margin-left': Math.round(-MPNotif.NOTIF_WIDTH / 2) + 'px', + 'backface-visibility': 'hidden', + 'transform': 'rotateY(0deg)', + 'opacity': '0.0', + 'top': MPNotif.NOTIF_START_TOP + 'px', + 'transition': 'opacity ' + anim_seconds + ', top ' + anim_seconds + }, + '#takeover.visible': { + 'opacity': '1.0', + 'top': MPNotif.NOTIF_TOP + 'px' + }, + '#takeover.exiting': { + 'opacity': '0.0', + 'top': MPNotif.NOTIF_START_TOP + 'px' + }, + '#thumbspacer': { + 'height': MPNotif.THUMB_OFFSET + 'px' + }, + '#thumbborder-wrapper': { + 'position': 'absolute', + 'top': (-MPNotif.THUMB_BORDER_SIZE) + 'px', + 'left': (MPNotif.NOTIF_WIDTH / 2 - MPNotif.THUMB_OFFSET - MPNotif.THUMB_BORDER_SIZE) + 'px', + 'width': thumb_total_size + 'px', + 'height': (thumb_total_size / 2) + 'px', + 'overflow': 'hidden' + }, + '#thumbborder': { + 'position': 'absolute', + 'width': thumb_total_size + 'px', + 'height': thumb_total_size + 'px', + 'border-radius': thumb_total_size + 'px', + 'background-color': this.style_vals.bg_actions, + 'opacity': '0.5' + }, + '#thumbnail': { + 'position': 'absolute', + 'top': '0px', + 'left': (MPNotif.NOTIF_WIDTH / 2 - MPNotif.THUMB_OFFSET) + 'px', + 'width': MPNotif.THUMB_IMG_SIZE + 'px', + 'height': MPNotif.THUMB_IMG_SIZE + 'px', + 'overflow': 'hidden', + 'z-index': '100', + 'border-radius': MPNotif.THUMB_IMG_SIZE + 'px' + }, + '#mini': { + 'position': 'absolute', + 'right': '20px', + 'top': MPNotif.NOTIF_TOP + 'px', + 'width': this.notif_width + 'px', + 'height': MPNotif.NOTIF_HEIGHT_MINI * 2 + 'px', + 'margin-top': 20 - MPNotif.NOTIF_HEIGHT_MINI + 'px', + 'backface-visibility': 'hidden', + 'opacity': '0.0', + 'transform': 'rotateX(90deg)', + 'transition': 'opacity 0.3s, transform 0.3s, right 0.3s' + }, + '#mini.visible': { + 'opacity': '1.0', + 'transform': 'rotateX(0deg)' + }, + '#mini.exiting': { + 'opacity': '0.0', + 'right': '-150px' + }, + '#mainbox': { + 'border-radius': '4px', + 'box-shadow': shadow, + 'text-align': 'center', + 'background-color': this.style_vals.bg, + 'font-size': '14px', + 'color': this.style_vals.text_main + }, + '#mini #mainbox': { + 'height': MPNotif.NOTIF_HEIGHT_MINI + 'px', + 'margin-top': MPNotif.NOTIF_HEIGHT_MINI + 'px', + 'border-radius': '3px', + 'transition': 'background-color ' + anim_seconds + }, + '#mini-border': { + 'height': (MPNotif.NOTIF_HEIGHT_MINI + 6) + 'px', + 'width': (MPNotif.NOTIF_WIDTH_MINI + 6) + 'px', + 'position': 'absolute', + 'top': '-3px', + 'left': '-3px', + 'margin-top': MPNotif.NOTIF_HEIGHT_MINI + 'px', + 'border-radius': '6px', + 'opacity': '0.25', + 'background-color': '#fff', + 'z-index': '-1', + 'box-shadow': mini_shadow + }, + '#mini-icon': { + 'position': 'relative', + 'display': 'inline-block', + 'width': '75px', + 'height': MPNotif.NOTIF_HEIGHT_MINI + 'px', + 'border-radius': '3px 0 0 3px', + 'background-color': this.style_vals.bg_actions, + 'background': 'linear-gradient(135deg, ' + this.style_vals.bg_light + ' 0%, ' + this.style_vals.bg_actions + ' 100%)', + 'transition': 'background-color ' + anim_seconds + }, + '#mini:hover #mini-icon': { + 'background-color': this.style_vals.mini_hover + }, + '#mini:hover #mainbox': { + 'background-color': this.style_vals.mini_hover + }, + '#mini-icon-img': { + 'position': 'absolute', + 'background-image': 'url(' + this.thumb_image_url + ')', + 'width': '48px', + 'height': '48px', + 'top': '20px', + 'left': '12px' + }, + '#content': { + 'padding': '30px 20px 0px 20px' + }, + '#mini-content': { + 'text-align': 'left', + 'height': MPNotif.NOTIF_HEIGHT_MINI + 'px', + 'cursor': 'pointer' + }, + '#img': { + 'width': '328px', + 'margin-top': '30px', + 'border-radius': '5px' + }, + '#title': { + 'max-height': '600px', + 'overflow': 'hidden', + 'word-wrap': 'break-word', + 'padding': '25px 0px 20px 0px', + 'font-size': '19px', + 'font-weight': 'bold', + 'color': this.style_vals.text_title + }, + '#body': { + 'max-height': '600px', + 'margin-bottom': '25px', + 'overflow': 'hidden', + 'word-wrap': 'break-word', + 'line-height': '21px', + 'font-size': '15px', + 'font-weight': 'normal', + 'text-align': 'left' + }, + '#mini #body': { + 'display': 'inline-block', + 'max-width': '250px', + 'margin': '0 0 0 30px', + 'height': MPNotif.NOTIF_HEIGHT_MINI + 'px', + 'font-size': '16px', + 'letter-spacing': '0.8px', + 'color': this.style_vals.text_title + }, + '#mini #body-text': { + 'display': 'table', + 'height': MPNotif.NOTIF_HEIGHT_MINI + 'px' + }, + '#mini #body-text div': { + 'display': 'table-cell', + 'vertical-align': 'middle' + }, + '#tagline': { + 'margin-bottom': '15px', + 'font-size': '10px', + 'font-weight': '600', + 'letter-spacing': '0.8px', + 'color': '#ccd7e0', + 'text-align': 'left' + }, + '#tagline a': { + 'color': this.style_vals.text_tagline, + 'transition': 'color ' + anim_seconds + }, + '#tagline a:hover': { + 'color': this.style_vals.text_hover + }, + '#cancel': { + 'position': 'absolute', + 'right': '0', + 'width': '8px', + 'height': '8px', + 'padding': '10px', + 'border-radius': '20px', + 'margin': '12px 12px 0 0', + 'box-sizing': 'content-box', + 'cursor': 'pointer', + 'transition': 'background-color ' + anim_seconds + }, + '#mini #cancel': { + 'margin': '7px 7px 0 0' + }, + '#cancel-icon': { + 'width': '8px', + 'height': '8px', + 'overflow': 'hidden', + 'background-image': 'url(//cdn.mxpnl.com/site_media/images/icons/notifications/cancel-x.png)', + 'opacity': this.style_vals.cancel_opacity + }, + '#cancel:hover': { + 'background-color': this.style_vals.bg_hover + }, + '#button': { + 'display': 'block', + 'height': '60px', + 'line-height': '60px', + 'text-align': 'center', + 'background-color': this.style_vals.bg_actions, + 'border-radius': '0 0 4px 4px', + 'overflow': 'hidden', + 'cursor': 'pointer', + 'transition': 'background-color ' + anim_seconds + }, + '#button-close': { + 'display': 'inline-block', + 'width': '9px', + 'height': '60px', + 'margin-right': '8px', + 'vertical-align': 'top', + 'background-image': 'url(//cdn.mxpnl.com/site_media/images/icons/notifications/close-x-' + this.style + '.png)', + 'background-repeat': 'no-repeat', + 'background-position': '0px 25px' + }, + '#button-play': { + 'display': 'inline-block', + 'width': '30px', + 'height': '60px', + 'margin-left': '15px', + 'background-image': 'url(//cdn.mxpnl.com/site_media/images/icons/notifications/play-' + this.style + '-small.png)', + 'background-repeat': 'no-repeat', + 'background-position': '0px 15px' + }, + 'a#button-link': { + 'display': 'inline-block', + 'vertical-align': 'top', + 'text-align': 'center', + 'font-size': '17px', + 'font-weight': 'bold', + 'overflow': 'hidden', + 'word-wrap': 'break-word', + 'color': this.style_vals.text_title, + 'transition': 'color ' + anim_seconds + }, + '#button:hover': { + 'background-color': this.style_vals.bg_hover, + 'color': this.style_vals.text_hover + }, + '#button:hover a': { + 'color': this.style_vals.text_hover + }, + + '#video-noflip': { + 'position': 'relative', + 'top': (-this.video_height * 2) + 'px' + }, + '#video-flip': { + 'backface-visibility': 'hidden', + 'transform': 'rotateY(180deg)' + }, + '#video': { + 'position': 'absolute', + 'width': (this.video_width - 1) + 'px', + 'height': this.video_height + 'px', + 'top': MPNotif.NOTIF_TOP + 'px', + 'margin-top': '100px', + 'left': '50%', + 'margin-left': Math.round(-this.video_width / 2) + 'px', + 'overflow': 'hidden', + 'border-radius': '5px', + 'box-shadow': video_shadow, + 'transform': 'translateZ(1px)', // webkit rendering bug http://stackoverflow.com/questions/18167981/clickable-link-area-unexpectedly-smaller-after-css-transform + 'transition': 'opacity ' + anim_seconds + ', top ' + anim_seconds + }, + '#video.exiting': { + 'opacity': '0.0', + 'top': this.video_height + 'px' + }, + '#video-holder': { + 'position': 'absolute', + 'width': (this.video_width - 1) + 'px', + 'height': this.video_height + 'px', + 'overflow': 'hidden', + 'border-radius': '5px' + }, + '#video-frame': { + 'margin-left': '-1px', + 'width': this.video_width + 'px' + }, + '#video-controls': { + 'opacity': '0', + 'transition': 'opacity 0.5s' + }, + '#video:hover #video-controls': { + 'opacity': '1.0' + }, + '#video .video-progress-el': { + 'position': 'absolute', + 'bottom': '0', + 'height': '25px', + 'border-radius': '0 0 0 5px' + }, + '#video-progress': { + 'width': '90%' + }, + '#video-progress-total': { + 'width': '100%', + 'background-color': this.style_vals.bg, + 'opacity': '0.7' + }, + '#video-elapsed': { + 'width': '0', + 'background-color': '#6cb6f5', + 'opacity': '0.9' + }, + '#video #video-time': { + 'width': '10%', + 'right': '0', + 'font-size': '11px', + 'line-height': '25px', + 'color': this.style_vals.text_main, + 'background-color': '#666', + 'border-radius': '0 0 5px 0' + } + }; + + // IE hacks + if (this._browser_lte('ie', 8)) { + _.extend(notif_styles, { + '* html #overlay': { + 'position': 'absolute' + }, + '* html #bg': { + 'position': 'absolute' + }, + 'html, body': { + 'height': '100%' + } + }); + } + if (this._browser_lte('ie', 7)) { + _.extend(notif_styles, { + '#mini #body': { + 'display': 'inline', + 'zoom': '1', + 'border': '1px solid ' + this.style_vals.bg_hover + }, + '#mini #body-text': { + 'padding': '20px' + }, + '#mini #mini-icon': { + 'display': 'none' + } + }); + } + + // add vendor-prefixed style rules + var VENDOR_STYLES = ['backface-visibility', 'border-radius', 'box-shadow', 'opacity', + 'perspective', 'transform', 'transform-style', 'transition'], + VENDOR_PREFIXES = ['khtml', 'moz', 'ms', 'o', 'webkit']; + for (var selector in notif_styles) { + for (var si = 0; si < VENDOR_STYLES.length; si++) { + var prop = VENDOR_STYLES[si]; + if (prop in notif_styles[selector]) { + var val = notif_styles[selector][prop]; + for (var pi = 0; pi < VENDOR_PREFIXES.length; pi++) { + notif_styles[selector]['-' + VENDOR_PREFIXES[pi] + '-' + prop] = val; + } + } + } + } + + var inject_styles = function(styles, media_queries) { + var create_style_text = function(style_defs) { + var st = ''; + for (var selector in style_defs) { + var mp_selector = selector + .replace(/#/g, '#' + MPNotif.MARKUP_PREFIX + '-') + .replace(/\./g, '.' + MPNotif.MARKUP_PREFIX + '-'); + st += '\n' + mp_selector + ' {'; + var props = style_defs[selector]; + for (var k in props) { + st += k + ':' + props[k] + ';'; + } + st += '}'; + } + return st; + }; + var create_media_query_text = function(mq_defs) { + var mqt = ''; + for (var mq in mq_defs) { + mqt += '\n' + mq + ' {' + create_style_text(mq_defs[mq]) + '\n}'; + } + return mqt; + }; + + var style_text = create_style_text(styles) + create_media_query_text(media_queries), + head_el = document$1.head || document$1.getElementsByTagName('head')[0] || document$1.documentElement, + style_el = document$1.createElement('style'); + head_el.appendChild(style_el); + style_el.setAttribute('type', 'text/css'); + if (style_el.styleSheet) { // IE + style_el.styleSheet.cssText = style_text; + } else { + style_el.textContent = style_text; + } + }; + inject_styles(notif_styles, notif_media_queries); +}; + +MPNotif.prototype._init_video = _.safewrap(function() { + if (!this.video_url) { + return; + } + var self = this; + + // Youtube iframe API compatibility + self.yt_custom = 'postMessage' in window$1; + + self.dest_url = self.video_url; + var youtube_match = self.video_url.match( + // http://stackoverflow.com/questions/2936467/parse-youtube-video-id-using-preg-match + /(?:youtube(?:-nocookie)?\.com\/(?:[^\/]+\/.+\/|(?:v|e(?:mbed)?)\/|.*[?&]v=)|youtu\.be\/)([^"&?\/ ]{11})/i + ), + vimeo_match = self.video_url.match( + /vimeo\.com\/.*?(\d+)/i + ); + if (youtube_match) { + self.show_video = true; + self.youtube_video = youtube_match[1]; + + if (self.yt_custom) { + window$1['onYouTubeIframeAPIReady'] = function() { + if (self._get_el('video-frame')) { + self._yt_video_ready(); + } + }; + + // load Youtube iframe API; see https://developers.google.com/youtube/iframe_api_reference + var tag = document$1.createElement('script'); + tag.src = '//www.youtube.com/iframe_api'; + var firstScriptTag = document$1.getElementsByTagName('script')[0]; + firstScriptTag.parentNode.insertBefore(tag, firstScriptTag); + } + } else if (vimeo_match) { + self.show_video = true; + self.vimeo_video = vimeo_match[1]; + } + + // IE <= 7, FF <= 3: fall through to video link rather than embedded player + if (self._browser_lte('ie', 7) || self._browser_lte('firefox', 3)) { + self.show_video = false; + self.clickthrough = true; + } +}); + +MPNotif.prototype._mark_as_shown = _.safewrap(function() { + // click on background to dismiss + var self = this; + _.register_event(self._get_el('bg'), 'click', function() { + self.dismiss(); + }); + + var get_style = function(el, style_name) { + var styles = {}; + if (document$1.defaultView && document$1.defaultView.getComputedStyle) { + styles = document$1.defaultView.getComputedStyle(el, null); // FF3 requires both args + } else if (el.currentStyle) { // IE + styles = el.currentStyle; + } + return styles[style_name]; + }; + + if (this.campaign_id) { + var notif_el = this._get_el('overlay'); + if (notif_el && get_style(notif_el, 'visibility') !== 'hidden' && get_style(notif_el, 'display') !== 'none') { + this._mark_delivery(); + } + } +}); + +MPNotif.prototype._mark_delivery = _.safewrap(function(extra_props) { + if (!this.marked_as_shown) { + this.marked_as_shown = true; + + if (this.campaign_id) { + // mark notification shown (local cache) + this._get_shown_campaigns()[this.campaign_id] = 1 * new Date(); + this.persistence.save(); + } + + // track delivery + this._track_event('$campaign_delivery', extra_props); + + // mark notification shown (mixpanel property) + this.mixpanel['people']['append']({ + '$campaigns': this.campaign_id, + '$notifications': { + 'campaign_id': this.campaign_id, + 'message_id': this.message_id, + 'type': 'web', + 'time': new Date() + } + }); + } +}); + +MPNotif.prototype._preload_images = function(all_loaded_cb) { + var self = this; + if (this.imgs_to_preload.length === 0) { + all_loaded_cb(); + return; + } + + var preloaded_imgs = 0; + var img_objs = []; + var onload = function() { + preloaded_imgs++; + if (preloaded_imgs === self.imgs_to_preload.length && all_loaded_cb) { + all_loaded_cb(); + all_loaded_cb = null; + } + }; + for (var i = 0; i < this.imgs_to_preload.length; i++) { + var img = new Image(); + img.onload = onload; + img.src = this.imgs_to_preload[i]; + if (img.complete) { + onload(); + } + img_objs.push(img); + } + + // IE6/7 doesn't fire onload reliably + if (this._browser_lte('ie', 7)) { + setTimeout(function() { + var imgs_loaded = true; + for (i = 0; i < img_objs.length; i++) { + if (!img_objs[i].complete) { + imgs_loaded = false; + } + } + if (imgs_loaded && all_loaded_cb) { + all_loaded_cb(); + all_loaded_cb = null; + } + }, 500); + } +}; + +MPNotif.prototype._remove_notification_el = _.safewrap(function() { + window$1.clearInterval(this._video_progress_checker); + this.notification_el.style.visibility = 'hidden'; + this.body_el.removeChild(this.notification_el); +}); + +MPNotif.prototype._set_client_config = function() { + var get_browser_version = function(browser_ex) { + var match = navigator.userAgent.match(browser_ex); + return match && match[1]; + }; + this.browser_versions = {}; + this.browser_versions['chrome'] = get_browser_version(/Chrome\/(\d+)/); + this.browser_versions['firefox'] = get_browser_version(/Firefox\/(\d+)/); + this.browser_versions['ie'] = get_browser_version(/MSIE (\d+).+/); + if (!this.browser_versions['ie'] && !(window$1.ActiveXObject) && 'ActiveXObject' in window$1) { + this.browser_versions['ie'] = 11; + } + + this.body_el = document$1.body || document$1.getElementsByTagName('body')[0]; + if (this.body_el) { + this.doc_width = Math.max( + this.body_el.scrollWidth, document$1.documentElement.scrollWidth, + this.body_el.offsetWidth, document$1.documentElement.offsetWidth, + this.body_el.clientWidth, document$1.documentElement.clientWidth + ); + this.doc_height = Math.max( + this.body_el.scrollHeight, document$1.documentElement.scrollHeight, + this.body_el.offsetHeight, document$1.documentElement.offsetHeight, + this.body_el.clientHeight, document$1.documentElement.clientHeight + ); + } + + // detect CSS compatibility + var ie_ver = this.browser_versions['ie']; + var sample_styles = document$1.createElement('div').style, + is_css_compatible = function(rule) { + if (rule in sample_styles) { + return true; + } + if (!ie_ver) { + rule = rule[0].toUpperCase() + rule.slice(1); + var props = ['O' + rule, 'Webkit' + rule, 'Moz' + rule]; + for (var i = 0; i < props.length; i++) { + if (props[i] in sample_styles) { + return true; + } + } + } + return false; + }; + this.use_transitions = this.body_el && + is_css_compatible('transition') && + is_css_compatible('transform'); + this.flip_animate = (this.browser_versions['chrome'] >= 33 || this.browser_versions['firefox'] >= 15) && + this.body_el && + is_css_compatible('backfaceVisibility') && + is_css_compatible('perspective') && + is_css_compatible('transform'); +}; + +MPNotif.prototype._switch_to_video = _.safewrap(function() { + var self = this, + anims = [ + { + el: self._get_notification_display_el(), + attr: 'opacity', + start: 1.0, + goal: 0.0 + }, + { + el: self._get_notification_display_el(), + attr: 'top', + start: MPNotif.NOTIF_TOP, + goal: -500 + }, + { + el: self._get_el('video-noflip'), + attr: 'opacity', + start: 0.0, + goal: 1.0 + }, + { + el: self._get_el('video-noflip'), + attr: 'top', + start: -self.video_height * 2, + goal: 0 + } + ]; + + if (self.mini) { + var bg = self._get_el('bg'), + overlay = self._get_el('overlay'); + bg.style.width = '100%'; + bg.style.height = '100%'; + overlay.style.width = '100%'; + + self._add_class(self._get_notification_display_el(), 'exiting'); + self._add_class(bg, 'visible'); + + anims.push({ + el: self._get_el('bg'), + attr: 'opacity', + start: 0.0, + goal: MPNotif.BG_OPACITY + }); + } + + var video_el = self._get_el('video-holder'); + video_el.innerHTML = self.video_iframe; + + var video_ready = function() { + if (window$1['YT'] && window$1['YT']['loaded']) { + self._yt_video_ready(); + } + self.showing_video = true; + self._get_notification_display_el().style.visibility = 'hidden'; + }; + if (self.flip_animate) { + self._add_class('flipper', 'flipped'); + setTimeout(video_ready, MPNotif.ANIM_TIME); + } else { + self._animate_els(anims, MPNotif.ANIM_TIME, video_ready); + } +}); + +MPNotif.prototype._track_event = function(event_name, properties, cb) { + if (this.campaign_id) { + properties = properties || {}; + properties = _.extend(properties, { + 'campaign_id': this.campaign_id, + 'message_id': this.message_id, + 'message_type': 'web_inapp', + 'message_subtype': this.notif_type + }); + this.mixpanel['track'](event_name, properties, cb); + } else if (cb) { + cb.call(); + } +}; + +MPNotif.prototype._yt_video_ready = _.safewrap(function() { + var self = this; + if (self.video_inited) { + return; + } + self.video_inited = true; + + var progress_bar = self._get_el('video-elapsed'), + progress_time = self._get_el('video-time'), + progress_el = self._get_el('video-progress'); + + new window$1['YT']['Player'](MPNotif.MARKUP_PREFIX + '-video-frame', { + 'events': { + 'onReady': function(event) { + var ytplayer = event['target'], + video_duration = ytplayer['getDuration'](), + pad = function(i) { + return ('00' + i).slice(-2); + }, + update_video_time = function(current_time) { + var secs = Math.round(video_duration - current_time), + mins = Math.floor(secs / 60), + hours = Math.floor(mins / 60); + secs -= mins * 60; + mins -= hours * 60; + progress_time.innerHTML = '-' + (hours ? hours + ':' : '') + pad(mins) + ':' + pad(secs); + }; + update_video_time(0); + self._video_progress_checker = window$1.setInterval(function() { + var current_time = ytplayer['getCurrentTime'](); + progress_bar.style.width = (current_time / video_duration * 100) + '%'; + update_video_time(current_time); + }, 250); + _.register_event(progress_el, 'click', function(e) { + var clickx = Math.max(0, e.pageX - progress_el.getBoundingClientRect().left); + ytplayer['seekTo'](video_duration * clickx / progress_el.clientWidth, true); + }); + } + } + }); +}); + +// EXPORTS (for closure compiler) + +// MixpanelLib Exports +MixpanelLib.prototype['init'] = MixpanelLib.prototype.init; +MixpanelLib.prototype['reset'] = MixpanelLib.prototype.reset; +MixpanelLib.prototype['disable'] = MixpanelLib.prototype.disable; +MixpanelLib.prototype['time_event'] = MixpanelLib.prototype.time_event; +MixpanelLib.prototype['track'] = MixpanelLib.prototype.track; +MixpanelLib.prototype['track_links'] = MixpanelLib.prototype.track_links; +MixpanelLib.prototype['track_forms'] = MixpanelLib.prototype.track_forms; +MixpanelLib.prototype['track_pageview'] = MixpanelLib.prototype.track_pageview; +MixpanelLib.prototype['register'] = MixpanelLib.prototype.register; +MixpanelLib.prototype['register_once'] = MixpanelLib.prototype.register_once; +MixpanelLib.prototype['unregister'] = MixpanelLib.prototype.unregister; +MixpanelLib.prototype['identify'] = MixpanelLib.prototype.identify; +MixpanelLib.prototype['alias'] = MixpanelLib.prototype.alias; +MixpanelLib.prototype['name_tag'] = MixpanelLib.prototype.name_tag; +MixpanelLib.prototype['set_config'] = MixpanelLib.prototype.set_config; +MixpanelLib.prototype['get_config'] = MixpanelLib.prototype.get_config; +MixpanelLib.prototype['get_property'] = MixpanelLib.prototype.get_property; +MixpanelLib.prototype['get_distinct_id'] = MixpanelLib.prototype.get_distinct_id; +MixpanelLib.prototype['toString'] = MixpanelLib.prototype.toString; +MixpanelLib.prototype['_check_and_handle_notifications'] = MixpanelLib.prototype._check_and_handle_notifications; +MixpanelLib.prototype['_show_notification'] = MixpanelLib.prototype._show_notification; +MixpanelLib.prototype['opt_out_tracking'] = MixpanelLib.prototype.opt_out_tracking; +MixpanelLib.prototype['opt_in_tracking'] = MixpanelLib.prototype.opt_in_tracking; +MixpanelLib.prototype['has_opted_out_tracking'] = MixpanelLib.prototype.has_opted_out_tracking; +MixpanelLib.prototype['has_opted_in_tracking'] = MixpanelLib.prototype.has_opted_in_tracking; +MixpanelLib.prototype['clear_opt_in_out_tracking'] = MixpanelLib.prototype.clear_opt_in_out_tracking; + +// MixpanelPersistence Exports +MixpanelPersistence.prototype['properties'] = MixpanelPersistence.prototype.properties; +MixpanelPersistence.prototype['update_search_keyword'] = MixpanelPersistence.prototype.update_search_keyword; +MixpanelPersistence.prototype['update_referrer_info'] = MixpanelPersistence.prototype.update_referrer_info; +MixpanelPersistence.prototype['get_cross_subdomain'] = MixpanelPersistence.prototype.get_cross_subdomain; +MixpanelPersistence.prototype['clear'] = MixpanelPersistence.prototype.clear; + +// MixpanelPeople Exports +MixpanelPeople.prototype['set'] = MixpanelPeople.prototype.set; +MixpanelPeople.prototype['set_once'] = MixpanelPeople.prototype.set_once; +MixpanelPeople.prototype['unset'] = MixpanelPeople.prototype.unset; +MixpanelPeople.prototype['increment'] = MixpanelPeople.prototype.increment; +MixpanelPeople.prototype['append'] = MixpanelPeople.prototype.append; +MixpanelPeople.prototype['union'] = MixpanelPeople.prototype.union; +MixpanelPeople.prototype['track_charge'] = MixpanelPeople.prototype.track_charge; +MixpanelPeople.prototype['clear_charges'] = MixpanelPeople.prototype.clear_charges; +MixpanelPeople.prototype['delete_user'] = MixpanelPeople.prototype.delete_user; +MixpanelPeople.prototype['toString'] = MixpanelPeople.prototype.toString; + +_.safewrap_class(MixpanelLib, ['identify', '_check_and_handle_notifications', '_show_notification']); + +var instances = {}; +var extend_mp = function() { + // add all the sub mixpanel instances + _.each(instances, function(instance, name) { + if (name !== PRIMARY_INSTANCE_NAME) { mixpanel_master[name] = instance; } + }); + + // add private functions as _ + mixpanel_master['_'] = _; +}; + +var override_mp_init_func = function() { + // we override the snippets init function to handle the case where a + // user initializes the mixpanel library after the script loads & runs + mixpanel_master['init'] = function(token, config, name) { + if (name) { + // initialize a sub library + if (!mixpanel_master[name]) { + mixpanel_master[name] = instances[name] = create_mplib(token, config, name); + mixpanel_master[name]._loaded(); + } + return mixpanel_master[name]; + } else { + var instance = mixpanel_master; + + if (instances[PRIMARY_INSTANCE_NAME]) { + // main mixpanel lib already initialized + instance = instances[PRIMARY_INSTANCE_NAME]; + } else if (token) { + // intialize the main mixpanel lib + instance = create_mplib(token, config, PRIMARY_INSTANCE_NAME); + instance._loaded(); + instances[PRIMARY_INSTANCE_NAME] = instance; + } + + mixpanel_master = instance; + if (init_type === INIT_SNIPPET) { + window$1[PRIMARY_INSTANCE_NAME] = mixpanel_master; + } + extend_mp(); + } + }; +}; + +var add_dom_loaded_handler = function() { + // Cross browser DOM Loaded support + function dom_loaded_handler() { + // function flag since we only want to execute this once + if (dom_loaded_handler.done) { return; } + dom_loaded_handler.done = true; + + DOM_LOADED = true; + ENQUEUE_REQUESTS = false; + + _.each(instances, function(inst) { + inst._dom_loaded(); + }); + } + + function do_scroll_check() { + try { + document$1.documentElement.doScroll('left'); + } catch(e) { + setTimeout(do_scroll_check, 1); + return; + } + + dom_loaded_handler(); + } + + if (document$1.addEventListener) { + if (document$1.readyState === 'complete') { + // safari 4 can fire the DOMContentLoaded event before loading all + // external JS (including this file). you will see some copypasta + // on the internet that checks for 'complete' and 'loaded', but + // 'loaded' is an IE thing + dom_loaded_handler(); + } else { + document$1.addEventListener('DOMContentLoaded', dom_loaded_handler, false); + } + } else if (document$1.attachEvent) { + // IE + document$1.attachEvent('onreadystatechange', dom_loaded_handler); + + // check to make sure we arn't in a frame + var toplevel = false; + try { + toplevel = window$1.frameElement === null; + } catch(e) { + // noop + } + + if (document$1.documentElement.doScroll && toplevel) { + do_scroll_check(); + } + } + + // fallback handler, always will work + _.register_event(window$1, 'load', dom_loaded_handler, true); +}; + +function init_as_module() { + init_type = INIT_MODULE; + mixpanel_master = new MixpanelLib(); + + override_mp_init_func(); + mixpanel_master['init'](); + add_dom_loaded_handler(); + + return mixpanel_master; +} + +var mixpanel = init_as_module(); + +module.exports = mixpanel; +},{}],2:[function(require,module,exports){ +"use strict"; +var __importDefault = (this && this.__importDefault) || function (mod) { + return (mod && mod.__esModule) ? mod : { "default": mod }; +}; +Object.defineProperty(exports, "__esModule", { value: true }); +var log_event_handlers_1 = __importDefault(require("./log-event-handlers")); +var log_event_1 = __importDefault(require("./log-event")); +var adjust_channel_1 = __importDefault(require("./channels/adjust-channel")); +var mixpanel_channel_1 = __importDefault(require("./channels/mixpanel-channel")); +var channels; +(function (channels) { + channels.AdjustChannel = adjust_channel_1.default; + channels.MixpanelChannel = mixpanel_channel_1.default; +})(channels = exports.channels || (exports.channels = {})); +var BitAnalytics = /** @class */ (function () { + function BitAnalytics() { + } + BitAnalytics.initialize = function (os, appVersion, channelConfigs) { + if (typeof window === 'undefined') { + console.error('BitAnalytics can be used only in a web browser.'); + return; + } + BitAnalytics.LogEventHandlers = new log_event_handlers_1.default(os, appVersion, channelConfigs); + BitAnalytics.LogEvent = log_event_1.default; + }; + BitAnalytics.main = function () { + if (window) { + window.BitAnalytics = BitAnalytics; + } + }; + return BitAnalytics; +}()); +exports.default = BitAnalytics; +BitAnalytics.main(); + +},{"./channels/adjust-channel":5,"./channels/mixpanel-channel":7,"./log-event":10,"./log-event-handlers":9}],3:[function(require,module,exports){ +"use strict"; +var __importDefault = (this && this.__importDefault) || function (mod) { + return (mod && mod.__esModule) ? mod : { "default": mod }; +}; +Object.defineProperty(exports, "__esModule", { value: true }); +var mixpanel_channel_1 = __importDefault(require("./channels/mixpanel-channel")); +var firebase_channel_1 = __importDefault(require("./channels/firebase-channel")); +var adjust_channel_1 = __importDefault(require("./channels/adjust-channel")); +var ChannelFactory = /** @class */ (function () { + function ChannelFactory() { + } + ChannelFactory.createChannel = function (name, config) { + // Check if the channel is available + if (ChannelFactory.classDictionary[name] == undefined) { + throw new DOMException(name + ' is not available.'); + } + else { + // Create a channel + var channel = Object.create(ChannelFactory.classDictionary[name].prototype); + channel.constructor.apply(channel, [name, config]); + channel = channel; + console.log(channel); + return channel; + } + }; + ChannelFactory.classDictionary = { + 'mixpanel': mixpanel_channel_1.default, + 'firebase': firebase_channel_1.default, + 'adjust': adjust_channel_1.default + }; + return ChannelFactory; +}()); +exports.default = ChannelFactory; + +},{"./channels/adjust-channel":5,"./channels/firebase-channel":6,"./channels/mixpanel-channel":7}],4:[function(require,module,exports){ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +var Channel = /** @class */ (function () { + function Channel(name) { + this.isReady = false; + this.queue = new Array(); + this.name = name; + } + /** + * + * Public methods + * + */ + Channel.prototype.getName = function () { + return this.name; + }; + /** + * + * Protected methods + * + */ + Channel.prototype.flush = function () { + this.queue.forEach(function (f) { + f(); + }); + this.queue = new Array(); + }; + Channel.prototype.enqueue = function (f) { + this.queue.push(f); + }; + return Channel; +}()); +exports.default = Channel; + +},{}],5:[function(require,module,exports){ +"use strict"; +var __extends = (this && this.__extends) || (function () { + var extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + return function (d, b) { + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); + }; +})(); +var __importDefault = (this && this.__importDefault) || function (mod) { + return (mod && mod.__esModule) ? mod : { "default": mod }; +}; +Object.defineProperty(exports, "__esModule", { value: true }); +require('../lib/adjust'); +var channel_1 = __importDefault(require("../channel")); +var AdjustChannel = /** @class */ (function (_super) { + __extends(AdjustChannel, _super); + function AdjustChannel(name, config) { + var _this = _super.call(this, name) || this; + _this.device_ids = { + "gps_adid": "3ea5fac8-cf01-47d5-8aec-9a1354f5e84a" + }; + _this.eventTypes = { + "wallet_created": "nd3dg5" + }; + if (!config.token) { + throw new DOMException('Config incorrect.'); + } + if (Adjust) { + _this.adjust = new Adjust("au1onbhgg5q8", "sandbox", "android"); + //this.adjust.trackSession(this.device_ids); + _this.isReady = true; + console.log('Adjust initialised.'); + } + else { + console.log('Adjust missing.'); + } + return _this; + } + AdjustChannel.prototype.postEvent = function (name, params) { + //var result = this.mixpanelInstance.track(logEvent.name); + if (this.isReady) { + this.adjust.trackEvent('nd3dg5', this.device_ids); + } + }; + return AdjustChannel; +}(channel_1.default)); +exports.default = AdjustChannel; + +},{"../channel":4,"../lib/adjust":8}],6:[function(require,module,exports){ +"use strict"; +var __extends = (this && this.__extends) || (function () { + var extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + return function (d, b) { + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); + }; +})(); +var __importDefault = (this && this.__importDefault) || function (mod) { + return (mod && mod.__esModule) ? mod : { "default": mod }; +}; +Object.defineProperty(exports, "__esModule", { value: true }); +var channel_1 = __importDefault(require("../channel")); +var FirebaseChannel = /** @class */ (function (_super) { + __extends(FirebaseChannel, _super); + function FirebaseChannel(name, config) { + var _this = _super.call(this, name) || this; + /** + * Firebase available only on ios and android + */ + if (config['os'] != 'android' && config['os'] != 'ios') { + throw new DOMException('Firebase is not supported on ' + config['os']); + } + if (!window.FirebasePlugin) { + throw new DOMException('Firebase cordova plugin is not installed correctly.'); + } + _this.firebaseInstance = window.FirebasePlugin; + _this.isReady = true; + return _this; + } + FirebaseChannel.prototype.postEvent = function (name, params) { + var _this = this; + if (!this.isReady) { + this.enqueue(function () { _this.postEvent(name, params); }); + } + else { + this.firebaseInstance.logEvent(name, params); + } + }; + return FirebaseChannel; +}(channel_1.default)); +exports.default = FirebaseChannel; + +},{"../channel":4}],7:[function(require,module,exports){ +"use strict"; +var __extends = (this && this.__extends) || (function () { + var extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + return function (d, b) { + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); + }; +})(); +var __importDefault = (this && this.__importDefault) || function (mod) { + return (mod && mod.__esModule) ? mod : { "default": mod }; +}; +Object.defineProperty(exports, "__esModule", { value: true }); +var channel_1 = __importDefault(require("../channel")); +var mixpanel = require('mixpanel-browser'); +var MixpanelChannel = /** @class */ (function (_super) { + __extends(MixpanelChannel, _super); + function MixpanelChannel(name, config) { + var _this = _super.call(this, name) || this; + if (!config.token) { + throw new DOMException('Config incorrect.'); + } + _this.mixpanelInstance = mixpanel; + mixpanel.init(config.token, config.config); + return _this; + } + MixpanelChannel.prototype.postEvent = function (name, params) { + var result = this.mixpanelInstance.track(name); + }; + return MixpanelChannel; +}(channel_1.default)); +exports.default = MixpanelChannel; + +},{"../channel":4,"mixpanel-browser":1}],8:[function(require,module,exports){ +"use strict"; +(function (window) { + var sendRequest = function (method, url, data, success_cb, error_cb) { + var req = new XMLHttpRequest(); + req.open(method, url, !0); + req.setRequestHeader("Client-SDK", "js4.0.0"); + req.onreadystatechange = function () { if (req.readyState == 4) { + if (req.status >= 200 && req.status < 400) { + !!success_cb && success_cb(req.responseText); + } + else if (!!error_cb) { + !!error_cb && error_cb(new Error("Server responded with HTTP " + req.status), xhr); + } + } }; + if (!!error_cb) { + req.onerror = error_cb; + } + req.send(data); + }; + var encodeQueryString = function (params) { + var pairs = []; + for (var k in params) { + if (!params.hasOwnProperty(k)) { + continue; + } + pairs.push(encodeURIComponent(k) + "=" + encodeURIComponent(params[k])); + } + return pairs.join("&"); + }; + var cloneObj = function (obj) { + var copy = {}; + if (typeof (obj) != "object" || !obj) { + return copy; + } + for (var k in obj) { + if (!obj.hasOwnProperty(k)) { + continue; + } + copy[k] = obj[k]; + } + return copy; + }; + if (!'withCredentials' in new XMLHttpRequest()) { + sendRequest = function () { }; + } + window.Adjust = function (app_token, environment, os_name) { this.trackSession = function (device_ids) { var params = cloneObj(device_ids); params.app_token = app_token; params.os_name = os_name; params.environment = environment; sendRequest("GET", "https://app.adjust.com/session?" + encodeQueryString(params)); }; this.trackEvent = function (event_token, device_ids) { var params = cloneObj(device_ids); params.app_token = app_token; params.event_token = event_token; params.os_name = os_name; params.environment = environment; sendRequest("GET", "https://app.adjust.com/event?" + encodeQueryString(params)); }; }; +})(window); + +},{}],9:[function(require,module,exports){ +"use strict"; +var __importDefault = (this && this.__importDefault) || function (mod) { + return (mod && mod.__esModule) ? mod : { "default": mod }; +}; +Object.defineProperty(exports, "__esModule", { value: true }); +var channel_factory_1 = __importDefault(require("./channel-factory")); +var LogEventHandlers = /** @class */ (function () { + function LogEventHandlers(os, appVersion, channelConfigs) { + this.os = os; + this.appVersion = appVersion; + this.channels = []; + this.isReady = false; // Ready once all channels are ready or one channel is ready? + this.initialize(channelConfigs); + LogEventHandlers.instance = this; + } + /** + * + * Public methods + * + */ + LogEventHandlers.sharedInstance = function () { + if (LogEventHandlers.instance) { + return LogEventHandlers.instance; + } + else { + throw new DOMException('LogEventHandlers need to be initialized'); + } + }; + LogEventHandlers.prototype.initialize = function (channelConfigs) { + var _this = this; + // Get the channel names by the keys + var channelNames = Object.keys(channelConfigs); + // Iterate to init the several channels given in the config + channelNames.map(function (channelName) { + var channelConfig = channelConfigs[channelName]; + // OS shared to check the availability of this channel on this OS. + channelConfig['os'] = _this.os; + try { + var channel = channel_factory_1.default.createChannel(channelName, channelConfig); + _this.channels.push(channel); + } + catch (error) { + console.log(error.name + ': ' + error.message); + } + }); + }; + LogEventHandlers.prototype.postEvent = function (logEvent) { + var _this = this; + /** + * 0 is shared params + * 1 is first channel + * 2 is second channel + * ... + */ + var logEventParams = logEvent.getParams(); + // params + var params = { + 'os': this.os, + 'appVersion': this.appVersion + }; + // Concat the shared params + if (logEventParams.length > 0) { + // concat specific params needed + params = Object.assign({}, logEventParams[0], params); + } + // Post event depending of the channel + logEvent.getChannelNames().map(function (channelName, i) { + var channel = _this.getChannelByName(channelName); + if (channel) { + // Real index (first param is shared by all channels) + var index = i + 1; + // concat if needed + if (logEventParams.length > index) { + // concat specific params needed + params = Object.assign({}, logEventParams[index], params); + } + channel.postEvent(logEvent.getName(), params); + console.log('LogEvent "' + logEvent.getName() + '" sent to ' + channelName + '.'); + } + else { + // Channel not available + console.log('LogEvent "' + logEvent.getName() + '" cannot send to ' + channelName + ', this channel is not available.'); + } + }); + }; + /** + * + * Private methods + * + */ + LogEventHandlers.prototype.getChannelByName = function (channelName) { + console.log(channelName); + console.log(this.channels); + var channels = this.channels.filter(function (channel) { return channel.getName() == channelName; }); + if (channels.length > 0) { + return channels[0]; + } + else { + return undefined; + } + }; + return LogEventHandlers; +}()); +exports.default = LogEventHandlers; + +},{"./channel-factory":3}],10:[function(require,module,exports){ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +var LogEvent = /** @class */ (function () { + function LogEvent(name, params, channelNames) { + if (channelNames.length == 0) { + throw new DOMException('Minimum one channel is needed.'); + } + this.name = name; + this.params = params; + this.channelNames = channelNames; + } + /** + * + * Public methods + * + */ + LogEvent.prototype.getName = function () { + return this.name; + }; + LogEvent.prototype.getParams = function () { + return this.params; + }; + LogEvent.prototype.getChannelNames = function () { + return this.channelNames; + }; + return LogEvent; +}()); +exports.default = LogEvent; + +},{}]},{},[2])(2) +}); diff --git a/src/js/routes.js b/src/js/routes.js index 4e72246ba..dabebdf65 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -1211,7 +1211,11 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr .run(function($rootScope, $state, $location, $log, $timeout, startupService, ionicToast, fingerprintService, $ionicHistory, $ionicPlatform, $window, appConfigService, lodash, platformInfo, profileService, uxLanguage, gettextCatalog, openURLService, storageService, scannerService, configService, emailService, /* plugins START HERE => */ buydotbitcoindotcomService, glideraService, amazonService, bitpayCardService, applicationService, mercadoLibreService, rateService) { $ionicPlatform.ready(function() { - + + // Init BitAnalytics + var os = platformInfo.isAndroid ? 'android' : platformInfo.isIOS ? 'ios' : 'desktop'; + window.BitAnalytics.initialize(os, $window.fullVersion, {"firebase": {}}); + // Init language uxLanguage.init(function (lang) { diff --git a/www/index.html b/www/index.html index 47dc27d2a..a4ab55678 100644 --- a/www/index.html +++ b/www/index.html @@ -11,7 +11,7 @@ - Bitcoin.com Wallet + Bitcoin.com Wallet - Bitcoin.com Wallet @@ -31,6 +31,7 @@ + From 658a91e9ccbda784a1ab0d9d8c2276ba15b6d09e Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 10 Jul 2018 09:54:49 +0200 Subject: [PATCH 047/386] round gravatar --- src/sass/views/tab-send-v2.scss | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/sass/views/tab-send-v2.scss b/src/sass/views/tab-send-v2.scss index e9905fc17..a44973285 100644 --- a/src/sass/views/tab-send-v2.scss +++ b/src/sass/views/tab-send-v2.scss @@ -223,6 +223,9 @@ margin: 4px; border-radius: 6px; box-shadow: 0px 2px 1px 0 #C1C1C1; + .gravatar { + border-radius: 30px; + } } } From 94e6dd7dac86c96c3b320eec3afa1b72a81c1731 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 10 Jul 2018 11:08:03 +0200 Subject: [PATCH 048/386] clipboard features --- src/js/controllers/tab-send-v2.js | 20 +++++++++++++++----- src/sass/views/tab-send-v2.scss | 17 +++++++++++------ www/views/tab-send-v2.html | 2 +- 3 files changed, 27 insertions(+), 12 deletions(-) diff --git a/src/js/controllers/tab-send-v2.js b/src/js/controllers/tab-send-v2.js index 624acb5bb..5c75957c4 100644 --- a/src/js/controllers/tab-send-v2.js +++ b/src/js/controllers/tab-send-v2.js @@ -2,6 +2,7 @@ angular.module('copayApp.controllers').controller('tabSendV2Controller', function($scope, $rootScope, $log, $timeout, $ionicScrollDelegate, addressbookService, profileService, lodash, $state, walletService, incomingData, popupService, platformInfo, bwcError, gettextCatalog, scannerService, configService, bitcoinCashJsService, $ionicNavBarDelegate, clipboardService) { var clipboardHasAddress = false; + var clipboardHasContent = false; $scope.addContact = function() { $state.go('tabs.settings').then(function() { @@ -12,19 +13,28 @@ angular.module('copayApp.controllers').controller('tabSendV2Controller', functio }; $scope.pasteClipboard = function() { - clipboardService.readFromClipboard(function(text) { - $scope.formData.search = text; - $scope.findContact($scope.formData.search); - }); - } + if ($scope.clipboardHasAddress || $scope.clipboardHasContent) { + clipboardService.readFromClipboard(function(text) { + $scope.formData.search = text; + $scope.findContact($scope.formData.search); + }); + } + }; $scope.$on("$ionicView.enter", function(event, data) { clipboardService.readFromClipboard(function(text) { + if (text.length > 200) { + text = text.substring(0, 200); + } + $scope.clipboardHasAddress = false; + $scope.clipboardHasContent = false; if ((text.indexOf('bitcoincash:') === 0 || text[0] === 'C' || text[0] === 'H' || text[0] === 'p' || text[0] === 'q') && text.replace('bitcoincash:', '').length === 42) { // CashAddr $scope.clipboardHasAddress = true; } else if ((text[0] === "1" || text[0] === "3" || text.substring(0, 3) === "bc1") && text.length >= 26 && text.length <= 35) { // Legacy Addresses $scope.clipboardHasAddress = true; + } else if (text.length > 1) { + $scope.clipboardHasContent = true; } }); diff --git a/src/sass/views/tab-send-v2.scss b/src/sass/views/tab-send-v2.scss index a44973285..630828ae0 100644 --- a/src/sass/views/tab-send-v2.scss +++ b/src/sass/views/tab-send-v2.scss @@ -62,7 +62,10 @@ display: inline-block; margin-bottom: 4px; } - &.contains-address { + &.contains-address, &.contains-content { + .address { + display: none; + } background: #FAB915; color: #FFF !important; border: 0; @@ -70,11 +73,13 @@ .icon { background: url(../img/icon-clipboard-paste-white.svg); } - .address { - display: inline; - } - .non-address { - display: none; + &.contains-address { + .address { + display: inline; + } + .non-address { + display: none; + } } } } diff --git a/www/views/tab-send-v2.html b/www/views/tab-send-v2.html index b42784957..510633a3a 100644 --- a/www/views/tab-send-v2.html +++ b/www/views/tab-send-v2.html @@ -15,7 +15,7 @@
- -
-
- -
-
-
- -
-
-
-
- -
-
-
- Send Bitcoin faster! -
-
-
-

Save frequently used addresses and send them Bitcoin in just one tap

-
- -
-
-
- -
-
-
- Your Bitcoin wallet is empty -
-
-
-

To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address.

-

You can receive bitcoin from any wallet or service.

-
-
To get started, you'll need to create a bitcoin wallet and get some - bitcoin. -
-
- - - -
-
-
-
-
-
-
- -
-
Contacts
-
Saved frequently used addresses
- - - -
- -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 838c04299..a3a0b99d4 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -3,15 +3,57 @@ {{'Send' | translate}} -
-
-
Recipient
-
- -
- - +
+
+
+ +
+
+
+
+
+ +
+
+ +
+
+
+ +
+
+
+
+ +
+
+
+ Send Bitcoin faster! +
+
+
+

Save frequently used addresses and send them Bitcoin in just one tap

+
+
@@ -19,72 +61,83 @@
-
-
- - - -
- Start sending bitcoin + Your Bitcoin wallet is empty
- To get started, buy bitcoin or share your address. You can receive bitcoin from any wallet or service. - To get started, you'll need to create a bitcoin wallet and get some bitcoin. -
- - - +
+

To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address.

+

You can receive bitcoin from any wallet or service.

+
+
To get started, you'll need to create a bitcoin wallet and get some + bitcoin. +
+
+ + + +
+
+
+
+
+
+
+ +
+
Contacts
+
Saved frequently used addresses
+ + + +
+
- - -
-
- Transfer to Wallet - - -
- -
+ + + + + + + + + + + + + + + + + + + + + From 39cb416c300f2b692f37c67564fbdde72da14d55 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 10 Jul 2018 11:12:43 +0200 Subject: [PATCH 050/386] changed route and tab --- src/js/routes.js | 9 --------- www/views/tabs.html | 2 +- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/src/js/routes.js b/src/js/routes.js index 2399a2db9..4e72246ba 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -270,15 +270,6 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } } }) - .state('tabs.send2', { - url: '/send2', - views: { - 'tab-send': { - controller: 'tabSendV2Controller', - templateUrl: 'views/tab-send-v2.html', - } - } - }) .state('tabs.settings', { url: '/settings', views: { diff --git a/www/views/tabs.html b/www/views/tabs.html index 19c33aad9..69cf93309 100644 --- a/www/views/tabs.html +++ b/www/views/tabs.html @@ -12,7 +12,7 @@ - + From 5070a0042c15abbe55b494d04a1a1faf55399692 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 10 Jul 2018 11:15:17 +0200 Subject: [PATCH 051/386] small refactor --- src/js/controllers/tab-send.js | 2 +- src/sass/views/views.scss | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 5c75957c4..a4c4a7152 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('tabSendV2Controller', function($scope, $rootScope, $log, $timeout, $ionicScrollDelegate, addressbookService, profileService, lodash, $state, walletService, incomingData, popupService, platformInfo, bwcError, gettextCatalog, scannerService, configService, bitcoinCashJsService, $ionicNavBarDelegate, clipboardService) { +angular.module('copayApp.controllers').controller('tabSendController', function($scope, $rootScope, $log, $timeout, $ionicScrollDelegate, addressbookService, profileService, lodash, $state, walletService, incomingData, popupService, platformInfo, bwcError, gettextCatalog, scannerService, configService, bitcoinCashJsService, $ionicNavBarDelegate, clipboardService) { var clipboardHasAddress = false; var clipboardHasContent = false; diff --git a/src/sass/views/views.scss b/src/sass/views/views.scss index 5367ac5aa..37754970f 100644 --- a/src/sass/views/views.scss +++ b/src/sass/views/views.scss @@ -8,7 +8,6 @@ @import "tab-receive"; @import "tab-scan"; @import "tab-send"; -@import "tab-send-v2"; @import "tab-settings"; @import "wallet-colors"; @import "walletBalance"; From e6da12c17e894c0072c4de53f68527eeedfc146b Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 10 Jul 2018 14:27:51 +0200 Subject: [PATCH 052/386] tab-send --- src/js/controllers/tab-send.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 5c75957c4..a4c4a7152 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('tabSendV2Controller', function($scope, $rootScope, $log, $timeout, $ionicScrollDelegate, addressbookService, profileService, lodash, $state, walletService, incomingData, popupService, platformInfo, bwcError, gettextCatalog, scannerService, configService, bitcoinCashJsService, $ionicNavBarDelegate, clipboardService) { +angular.module('copayApp.controllers').controller('tabSendController', function($scope, $rootScope, $log, $timeout, $ionicScrollDelegate, addressbookService, profileService, lodash, $state, walletService, incomingData, popupService, platformInfo, bwcError, gettextCatalog, scannerService, configService, bitcoinCashJsService, $ionicNavBarDelegate, clipboardService) { var clipboardHasAddress = false; var clipboardHasContent = false; From 7cc806b00c1fbdc7e23d7f34b46bf2fc84a0b58c Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 10 Jul 2018 15:11:17 +0200 Subject: [PATCH 053/386] Filter contacts on "starting with" instead of "contains" and some refactors --- src/js/controllers/tab-send.js | 104 +++++++++------------------------ www/views/tab-send.html | 3 - 2 files changed, 29 insertions(+), 78 deletions(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index a4c4a7152..f9a58e94c 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -3,6 +3,7 @@ angular.module('copayApp.controllers').controller('tabSendController', function($scope, $rootScope, $log, $timeout, $ionicScrollDelegate, addressbookService, profileService, lodash, $state, walletService, incomingData, popupService, platformInfo, bwcError, gettextCatalog, scannerService, configService, bitcoinCashJsService, $ionicNavBarDelegate, clipboardService) { var clipboardHasAddress = false; var clipboardHasContent = false; + var originalList; $scope.addContact = function() { $state.go('tabs.settings').then(function() { @@ -50,27 +51,26 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }); }); + $scope.findContact = function(search) { + if (incomingData.redir(search)) { + return; + } + if (!search || search.length < 1) { + $scope.list = originalList; + $timeout(function() { + $scope.$apply(); + }); + return; + } + var result = lodash.filter(originalList, function(item) { + var val = item.name; + return lodash.startsWith(val.toLowerCase(), search.toLowerCase()); + }); - - - - - - - - - - - - var originalList; - var CONTACTS_SHOW_LIMIT; - var currentContactsPage; - - $scope.sectionDisplay = { - transferToWallet: false + $scope.list = result; }; var hasWallets = function() { @@ -80,6 +80,8 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.hasWallets = lodash.isEmpty($scope.wallets) ? false : true; }; + + // THIS is ONLY to show the 'buy bitcoins' message // does not has any other function. @@ -138,12 +140,12 @@ angular.module('copayApp.controllers').controller('tabSendController', function( var walletList = []; lodash.each(walletsToTransfer, function(v) { - var displayBalanceAsFiat = - // BD got v.status as undefined here once during development, just - // after creating a new wallet. - v.status && - v.status.alternativeBalanceAvailable && - config.wallet.settings.priceDisplay === 'fiat'; + var displayBalanceAsFiat = + // BD got v.status as undefined here once during development, just + // after creating a new wallet. + v.status && + v.status.alternativeBalanceAvailable && + config.wallet.settings.priceDisplay === 'fiat'; walletList.push({ color: v.color, @@ -152,7 +154,7 @@ angular.module('copayApp.controllers').controller('tabSendController', function( coin: v.coin, network: v.network, balanceString: displayBalanceAsFiat ? - v.status.totalBalanceAlternative + ' ' + v.status.alternativeIsoCode : + v.status.totalBalanceAlternative + ' ' + v.status.alternativeIsoCode : v.cachedBalance, getAddress: function(cb) { walletService.getAddress(v, false, cb); @@ -181,16 +183,14 @@ angular.module('copayApp.controllers').controller('tabSendController', function( recipientType: 'contact', coin: v.coin, displayCoin: (v.coin == 'bch' - ? (config.bitcoinCashAlias || defaults.bitcoinCashAlias) - : (config.bitcoinAlias || defaults.bitcoinAlias)).toUpperCase(), + ? (config.bitcoinCashAlias || defaults.bitcoinCashAlias) + : (config.bitcoinAlias || defaults.bitcoinAlias)).toUpperCase(), getAddress: function(cb) { return cb(null, k); }, }); }); - var contacts = completeContacts.slice(0, (currentContactsPage + 1) * CONTACTS_SHOW_LIMIT); - $scope.contactsShowMore = completeContacts.length > contacts.length; - originalList = originalList.concat(contacts); + originalList = completeContacts; return cb(); }); }; @@ -203,28 +203,6 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }, 10); }; - $scope.openScanner = function() { - var isWindowsPhoneApp = platformInfo.isCordova && platformInfo.isWP; - - if (!isWindowsPhoneApp) { - $state.go('tabs.scan'); - return; - } - - scannerService.useOldScanner(function(err, contents) { - if (err) { - popupService.showAlert(gettextCatalog.getString('Error'), err); - return; - } - incomingData.redir(contents); - }); - }; - - $scope.showMore = function() { - currentContactsPage++; - updateWalletsList(); - }; - $scope.searchInFocus = function() { $scope.searchFocus = true; }; @@ -235,28 +213,6 @@ angular.module('copayApp.controllers').controller('tabSendController', function( } }; - $scope.findContact = function(search) { - - if (incomingData.redir(search)) { - return; - } - - if (!search || search.length < 2) { - $scope.list = originalList; - $timeout(function() { - $scope.$apply(); - }); - return; - } - - var result = lodash.filter(originalList, function(item) { - var val = item.name; - return lodash.includes(val.toLowerCase(), search.toLowerCase()); - }); - - $scope.list = result; - }; - $scope.goToAmount = function(item) { $timeout(function() { item.getAddress(function(err, addr) { @@ -304,8 +260,6 @@ angular.module('copayApp.controllers').controller('tabSendController', function( search: null }; originalList = []; - CONTACTS_SHOW_LIMIT = 10; - currentContactsPage = 0; hasWallets(); }); }); diff --git a/www/views/tab-send.html b/www/views/tab-send.html index a3a0b99d4..3346ebf71 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -109,9 +109,6 @@

-
- Show more -
From 41a2a3c97123566d2367082d7fe598706c92076c Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 11 Jul 2018 14:36:22 +0200 Subject: [PATCH 054/386] scrollable contact view + better quality contact icons --- src/sass/views/tab-send.scss | 26 +++++++++++++++++++------- www/views/tab-send.html | 6 +++--- 2 files changed, 22 insertions(+), 10 deletions(-) diff --git a/src/sass/views/tab-send.scss b/src/sass/views/tab-send.scss index aabb76cda..f2d0dd1dd 100644 --- a/src/sass/views/tab-send.scss +++ b/src/sass/views/tab-send.scss @@ -1,5 +1,18 @@ #tab-send { @extend .deflash-blue; + + &-header{ + position: absolute; + height: 300px; + width: 100%; + } + &-contacts { + position: absolute; + top: 300px; + height: calc(100vh - 300px - 50px - 44px); + overflow: scroll; + } + .input { width: 100%; input { @@ -31,10 +44,9 @@ background: #DEDEDE; bottom: 0; content: ''; - margin: 20px 6px 0px; + margin: 10px 6px 0px; } - margin: 18px 0 0; - padding: 9px; + padding: 18px 9px 9px 9px; background-color: #f2f2f2; border-radius: 3px; border: none; @@ -171,8 +183,6 @@ .list { .item { font-weight: 600; - padding-top: 12px; - padding-bottom: 12px; p { font-weight: normal; } @@ -181,8 +191,8 @@ } color: #444; //border-top: none; - padding-top: 1.5rem; - padding-bottom: 1.5rem; + padding-top: 0.6rem; + padding-bottom: 0.6rem;; .big-icon-svg { left: 5px; & > .bg { @@ -230,6 +240,8 @@ box-shadow: 0px 2px 1px 0 #C1C1C1; .gravatar { border-radius: 30px; + height: 40px; + width: 40px; } } diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 3346ebf71..98bdae6f5 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -3,7 +3,7 @@ {{'Send' | translate}} -
+
@@ -86,7 +86,7 @@
-
+
@@ -101,7 +101,7 @@ - + {{item.name}}

From be32f53668a5d39094d81a46f315465542376b5f Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 11 Jul 2018 17:31:58 +0200 Subject: [PATCH 055/386] Wallet 2 wallet transfer --- src/js/controllers/tab-send.js | 83 +++++++++++++--------------------- www/views/tab-send.html | 34 ++++---------- 2 files changed, 41 insertions(+), 76 deletions(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index f9a58e94c..5c9ee4f5d 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -45,12 +45,42 @@ angular.module('copayApp.controllers').controller('tabSendController', function( return; } updateHasFunds(); - updateWalletsList(); updateContactsList(function() { updateList(); }); }); + var walletToWalletFrom = false; + var walletToWalletTo = false; + + $scope.onWalletSelect = function(wallet) { + if (!$scope.walletToWalletFrom) { + $scope.walletToWalletFrom = wallet; + $scope.walletSelectorTitle = gettextCatalog.getString('Send to'); + $timeout(function(){ + $scope.showWallets = true; + }, 200); + + } else { + $scope.walletToWalletTo = wallet; + walletService.getAddress($scope.walletToWalletFrom, true, function(err, addr) { + return $state.transitionTo('tabs.send.amount', { + displayAddress: $scope.walletToWalletFrom.coin === 'bch' ? bitcoinCashJsService.translateAddresses(addr).cashaddr : addr, + fromWalletId: $scope.walletToWalletFrom.walletId, + toAddress: addr, + coin: $scope.walletToWalletFrom.coin + }); + }); + + } + }; + + $scope.showWalletSelector = function() { + $scope.walletToWalletFrom = false; + $scope.walletSelectorTitle = gettextCatalog.getString('Send from'); + $scope.showWallets = true; + }; + $scope.findContact = function(search) { if (incomingData.redir(search)) { @@ -80,11 +110,6 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.hasWallets = lodash.isEmpty($scope.wallets) ? false : true; }; - - - // THIS is ONLY to show the 'buy bitcoins' message - // does not has any other function. - var updateHasFunds = function() { if ($rootScope.everHasFunds) { @@ -119,52 +144,6 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }); }; - var updateWalletsList = function() { - var config = configService.getSync(); - var networkResult = lodash.countBy($scope.wallets, 'network'); - - $scope.showTransferCard = $scope.hasWallets && (networkResult.livenet > 1 || networkResult.testnet > 1); - - if ($scope.showTransferCard) { - var walletsToTransfer = $scope.wallets; - if (!(networkResult.livenet > 1)) { - walletsToTransfer = lodash.filter(walletsToTransfer, function(item) { - return item.network == 'testnet'; - }); - } - if (!(networkResult.testnet > 1)) { - walletsToTransfer = lodash.filter(walletsToTransfer, function(item) { - return item.network == 'livenet'; - }); - } - - var walletList = []; - lodash.each(walletsToTransfer, function(v) { - var displayBalanceAsFiat = - // BD got v.status as undefined here once during development, just - // after creating a new wallet. - v.status && - v.status.alternativeBalanceAvailable && - config.wallet.settings.priceDisplay === 'fiat'; - - walletList.push({ - color: v.color, - name: v.name, - recipientType: 'wallet', - coin: v.coin, - network: v.network, - balanceString: displayBalanceAsFiat ? - v.status.totalBalanceAlternative + ' ' + v.status.alternativeIsoCode : - v.cachedBalance, - getAddress: function(cb) { - walletService.getAddress(v, false, cb); - }, - }); - }); - originalList = originalList.concat(walletList); - } - } - var updateContactsList = function(cb) { var config = configService.getSync(); var defaults = configService.getDefaults(); diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 98bdae6f5..a2174e1fa 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -22,7 +22,7 @@

- @@ -113,28 +113,14 @@
- - - - - - - - - - - - - - - - - - - - - - - + + From d8785f7928698c62f6253bb53cccc80d2b72a06f Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 11 Jul 2018 17:34:32 +0200 Subject: [PATCH 056/386] remove hide titles --- www/views/tab-send.html | 1 - 1 file changed, 1 deletion(-) diff --git a/www/views/tab-send.html b/www/views/tab-send.html index a2174e1fa..e11d9c8ef 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -116,7 +116,6 @@ Date: Thu, 12 Jul 2018 15:25:11 +0200 Subject: [PATCH 057/386] Wallet to wallet flow --- src/js/controllers/tab-send.js | 39 ++++++++++++++++++++------ src/js/directives/walletSelector.js | 2 ++ www/views/includes/walletSelector.html | 2 +- www/views/tab-send.html | 20 ++++++++++++- 4 files changed, 52 insertions(+), 11 deletions(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 5c9ee4f5d..66ac10b14 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -4,6 +4,8 @@ angular.module('copayApp.controllers').controller('tabSendController', function( var clipboardHasAddress = false; var clipboardHasContent = false; var originalList; + $scope.displayBalanceAsFiat = true; + $scope.walletSelectorTitleForce = true; $scope.addContact = function() { $state.go('tabs.settings').then(function() { @@ -50,22 +52,25 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }); }); + var wallets; + var walletsBch; + var walletsBtc; var walletToWalletFrom = false; - var walletToWalletTo = false; $scope.onWalletSelect = function(wallet) { if (!$scope.walletToWalletFrom) { $scope.walletToWalletFrom = wallet; - $scope.walletSelectorTitle = gettextCatalog.getString('Send to'); - $timeout(function(){ - $scope.showWallets = true; - }, 200); - + if (wallet.coin === 'bch') { + $scope.showWalletsBch = true; + } else if (wallet.coin === 'btc') { + $scope.showWalletsBtc = true; + } + $scope.walletSelectorTitleTo = gettextCatalog.getString('Send to'); } else { - $scope.walletToWalletTo = wallet; - walletService.getAddress($scope.walletToWalletFrom, true, function(err, addr) { + walletService.getAddress(wallet, true, function(err, addr) { return $state.transitionTo('tabs.send.amount', { displayAddress: $scope.walletToWalletFrom.coin === 'bch' ? bitcoinCashJsService.translateAddresses(addr).cashaddr : addr, + recipientType: 'wallet', fromWalletId: $scope.walletToWalletFrom.walletId, toAddress: addr, coin: $scope.walletToWalletFrom.coin @@ -77,7 +82,7 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.showWalletSelector = function() { $scope.walletToWalletFrom = false; - $scope.walletSelectorTitle = gettextCatalog.getString('Send from'); + $scope.walletSelectorTitleFrom = gettextCatalog.getString('Send from'); $scope.showWallets = true; }; @@ -107,6 +112,14 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.wallets = profileService.getWallets({ onlyComplete: true }); + $scope.walletsBch = profileService.getWallets({ + onlyComplete: true, + coin: 'bch' + }); + $scope.walletsBtc = profileService.getWallets({ + onlyComplete: true, + coin: 'btc' + }); $scope.hasWallets = lodash.isEmpty($scope.wallets) ? false : true; }; @@ -234,11 +247,19 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }; $scope.$on("$ionicView.beforeEnter", function(event, data) { + $scope.showWalletsBch = $scope.showWalletsBtc = $scope.showWallets = false; + $scope.checkingBalance = true; $scope.formData = { search: null }; originalList = []; hasWallets(); + + configService.whenAvailable(function(_config) { + $scope.displayBalanceAsFiat = _config.wallet.settings.priceDisplay === 'fiat'; + config = _config; + }); + }); }); diff --git a/src/js/directives/walletSelector.js b/src/js/directives/walletSelector.js index 79053f812..dabd1fbcd 100644 --- a/src/js/directives/walletSelector.js +++ b/src/js/directives/walletSelector.js @@ -8,6 +8,7 @@ angular.module('copayApp.directives') transclude: true, scope: { title: '=walletSelectorTitle', + forceTitle: '=walletSelectorForceTitle', show: '=walletSelectorShow', wallets: '=walletSelectorWallets', selectedWallet: '=walletSelectorSelectedWallet', @@ -15,6 +16,7 @@ angular.module('copayApp.directives') displayBalanceAsFiat : '=walletSelectorDisplayBalanceAsFiat' }, link: function(scope, element, attrs) { + console.log(scope, element, attrs); scope.hide = function() { scope.show = false; }; diff --git a/www/views/includes/walletSelector.html b/www/views/includes/walletSelector.html index 136aa4694..97dfeb552 100644 --- a/www/views/includes/walletSelector.html +++ b/www/views/includes/walletSelector.html @@ -5,7 +5,7 @@ ng-init="wallet.coin == 'btc' ? walletsBtc.push(wallet) : walletsBch.push(wallet)"> -
{{title}}
+
{{title}}
Bitcoin Cash (BCH)
diff --git a/www/views/tab-send.html b/www/views/tab-send.html index e11d9c8ef..c261ad06d 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -115,11 +115,29 @@
+ + + + + From 554d40d08f6d0fb1af66567dc78fccc9f6e9b372 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 12 Jul 2018 15:25:42 +0200 Subject: [PATCH 058/386] config variable --- src/js/controllers/tab-send.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 66ac10b14..f1f1d6116 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -258,7 +258,6 @@ angular.module('copayApp.controllers').controller('tabSendController', function( configService.whenAvailable(function(_config) { $scope.displayBalanceAsFiat = _config.wallet.settings.priceDisplay === 'fiat'; - config = _config; }); }); From a3ef304e09890edbc7242773bbe28145947820a4 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 12 Jul 2018 17:40:31 +0200 Subject: [PATCH 059/386] wallet to wallet back-button --- src/js/controllers/tab-send.js | 7 +++++++ src/js/directives/walletSelector.js | 4 ++++ www/views/tab-send.html | 2 ++ 3 files changed, 13 insertions(+) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index f1f1d6116..a90effe7b 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -7,6 +7,13 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.displayBalanceAsFiat = true; $scope.walletSelectorTitleForce = true; + + + $scope.walletHide = function() { + console.log("wallet HIDE"); + alert('test'); + }; + $scope.addContact = function() { $state.go('tabs.settings').then(function() { $state.go('tabs.addressbook').then(function() { diff --git a/src/js/directives/walletSelector.js b/src/js/directives/walletSelector.js index dabd1fbcd..8a96a0805 100644 --- a/src/js/directives/walletSelector.js +++ b/src/js/directives/walletSelector.js @@ -13,12 +13,16 @@ angular.module('copayApp.directives') wallets: '=walletSelectorWallets', selectedWallet: '=walletSelectorSelectedWallet', onSelect: '=walletSelectorOnSelect', + onHide: '=walletSelectorOnHide', displayBalanceAsFiat : '=walletSelectorDisplayBalanceAsFiat' }, link: function(scope, element, attrs) { console.log(scope, element, attrs); scope.hide = function() { scope.show = false; + if (typeof scope.onHide === "function") { + scope.onHide() + } }; scope.selectWallet = function(wallet) { $timeout(function() { diff --git a/www/views/tab-send.html b/www/views/tab-send.html index c261ad06d..28ba48a50 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -124,6 +124,7 @@ wallet-selector-display-balance-as-fiat="displayBalanceAsFiat">
Date: Fri, 13 Jul 2018 15:03:57 +1200 Subject: [PATCH 060/386] Shows "Empty case" send screen after sending all funds from wallets. --- src/js/controllers/tab-send.js | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index a90effe7b..00328d5db 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -132,11 +132,6 @@ angular.module('copayApp.controllers').controller('tabSendController', function( var updateHasFunds = function() { - if ($rootScope.everHasFunds) { - $scope.hasFunds = true; - return; - } - $scope.hasFunds = false; var index = 0; lodash.each($scope.wallets, function(w) { @@ -151,10 +146,9 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.hasFunds = true; } else if (status.availableBalanceSat > 0) { $scope.hasFunds = true; - $rootScope.everHasFunds = true; } - if (index == $scope.wallets.length) { + if (index === $scope.wallets.length) { $scope.checkingBalance = false; $timeout(function() { $scope.$apply(); From eff8442f695d1ebfcbd3e89d320791d3bf1f4987 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 13 Jul 2018 15:36:34 +1200 Subject: [PATCH 061/386] "Show my address" button can now be clicked. --- www/views/tab-send.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 28ba48a50..3fabea47a 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -86,9 +86,9 @@
-
+
-
+
Contacts
From 2121155dd00252565732d76a0186e67f47617845 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 13 Jul 2018 17:18:41 +1200 Subject: [PATCH 062/386] When pasting from clipboard using the button on send screen, the text now appears the first time. --- src/js/controllers/tab-send.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 00328d5db..bcaaaef5c 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -25,7 +25,9 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.pasteClipboard = function() { if ($scope.clipboardHasAddress || $scope.clipboardHasContent) { clipboardService.readFromClipboard(function(text) { - $scope.formData.search = text; + $scope.$apply(function() { + $scope.formData.search = text; + }); $scope.findContact($scope.formData.search); }); } From 658c58c59fbdf1a0b4e8e37f5740caa2d3eb073b Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 13 Jul 2018 17:50:50 +1200 Subject: [PATCH 063/386] In Send screen, contacts positioned below buttons. --- src/sass/views/tab-send.scss | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/sass/views/tab-send.scss b/src/sass/views/tab-send.scss index f2d0dd1dd..717ebff89 100644 --- a/src/sass/views/tab-send.scss +++ b/src/sass/views/tab-send.scss @@ -2,13 +2,10 @@ @extend .deflash-blue; &-header{ - position: absolute; height: 300px; width: 100%; } &-contacts { - position: absolute; - top: 300px; height: calc(100vh - 300px - 50px - 44px); overflow: scroll; } From 4e1ddfe88388d334ebc8582b0417a4cd0e47d59f Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 13 Jul 2018 16:15:04 +0900 Subject: [PATCH 064/386] Integration BitAnalytics --- bitanalytics/bitanalytics-0.1.0.js | 563 +++++++++++++++++++---- src/js/routes.js | 63 ++- www/index.html | 5 +- www/views/includes/community.html | 6 +- www/views/includes/homeIntegrations.html | 9 +- www/views/includes/nextSteps.html | 4 +- www/views/includes/services.html | 2 +- www/views/tab-home.html | 2 +- www/views/tab-send.html | 2 +- www/views/tabs.html | 11 +- 10 files changed, 555 insertions(+), 112 deletions(-) diff --git a/bitanalytics/bitanalytics-0.1.0.js b/bitanalytics/bitanalytics-0.1.0.js index c1907d7a5..cf85b3c14 100644 --- a/bitanalytics/bitanalytics-0.1.0.js +++ b/bitanalytics/bitanalytics-0.1.0.js @@ -6069,10 +6069,225 @@ var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); +var click_action_1 = __importDefault(require("./actions/click-action")); +var ActionFactory = /** @class */ (function () { + function ActionFactory() { + } + ActionFactory.createAction = function (type, config) { + // Check if the action is available + if (ActionFactory.classDictionary[type] == undefined) { + throw new Error('[BitAnalytics] ' + type + ' is not available.'); + } + else { + // Create a action + var action = Object.create(ActionFactory.classDictionary[type].prototype); + action.constructor.apply(action, [config]); + action = action; + return action; + } + }; + ActionFactory.classDictionary = { + 'click': click_action_1.default + }; + return ActionFactory; +}()); +exports.default = ActionFactory; + +},{"./actions/click-action":5}],3:[function(require,module,exports){ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +var ActionHandlers = /** @class */ (function () { + function ActionHandlers() { + this.actions = []; + var self = this; + var callback = function () { + if (self.timeout) { + clearTimeout(self.timeout); + } + self.timeout = setTimeout(function () { + console.log('[BitAnalytics] Content modified, refreshing trackers'); + self.refreshTrackers(); + self.timeout = undefined; + }, 300); + }; + if (MutationObserver) { + var targetNode = document.getElementsByTagName('body'); + var config = { attributes: true, childList: true, subtree: true }; + // Create an observer instance linked to the callback function + var observer = new MutationObserver(callback); + // Start observing the target node for configured mutations + observer.observe(targetNode[0], config); + } + else { + window.addEventListener("DOMSubtreeModified", callback); + } + } + /** + * + * Public methods + * + */ + ActionHandlers.prototype.refreshTrackers = function () { + this.actions.map(function (action) { + try { + action.stopTracking(); + } + catch (err) { + console.log(err); + } + try { + action.startTracking(); + } + catch (err) { + console.log(err); + } + }); + }; + ActionHandlers.prototype.trackAction = function (action) { + this.actions.push(action); + }; + return ActionHandlers; +}()); +exports.default = ActionHandlers; + +},{}],4:[function(require,module,exports){ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +var Action = /** @class */ (function () { + function Action(config) { + if (!config.name) { + throw new Error('[BitAnalytics] Action should have a name config : { name : ... }'); + } + this.name = config.name; + this.isTracking = false; + } + return Action; +}()); +exports.default = Action; + +},{}],5:[function(require,module,exports){ +"use strict"; +var __extends = (this && this.__extends) || (function () { + var extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + return function (d, b) { + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); + }; +})(); +var __importDefault = (this && this.__importDefault) || function (mod) { + return (mod && mod.__esModule) ? mod : { "default": mod }; +}; +Object.defineProperty(exports, "__esModule", { value: true }); +var action_1 = __importDefault(require("../action")); +var log_event_handlers_1 = __importDefault(require("../log-event-handlers")); +var log_event_1 = __importDefault(require("../log-event")); +var ClickAction = /** @class */ (function (_super) { + __extends(ClickAction, _super); + function ClickAction(config) { + var _this = _super.call(this, config) || this; + _this.params = []; + if (!config.class || !config.channels) { + throw new Error('[BitAnalytics] ClickAction should have a config like this : { class : ..., channels: ... }'); + } + if (config.params) { + _this.params = config.params; + } + _this.class = config.class; + _this.channels = config.channels; + var self = _this; + _this.listener = function (event) { + /*console.log('on click'); + console.log(event.target.id); + console.log(event.target.outerHTML); + console.log(event.target.outerText);*/ + var params = {}; + var target = _this.searchTarget(event.srcElement); + // If I found my element, that should happen 100% + if (target) { + self.params.map(function (param) { + var value = target[param]; + if (value) { + params[param] = value; + } + else { + var item = target.attributes.getNamedItem(param); + if (item) { + params[param] = item.value; + } + } + }); + } + var logEvent = new log_event_1.default(self.name, [params], self.channels); + log_event_handlers_1.default.sharedInstance().postEvent(logEvent); + }; + _this.isTracking = false; + return _this; + } + /** + * + * Private methods + * + */ + ClickAction.prototype.searchTarget = function (element) { + if (element && element.classList && element.classList.contains(this.class)) { + return element; + } + else if (element.parentElement) { + return this.searchTarget(element.parentElement); + } + else { + return undefined; + } + }; + /** + * + * Public methods + * + */ + ClickAction.prototype.startTracking = function () { + if (this.isTracking) { + throw new Error('[BitAnalytics] The tacking is already started'); + } + this.isTracking = true; + var elements = document.getElementsByClassName(this.class); + // Add event listener to all the elements found + for (var i = 0; i < elements.length; i++) { + var element = elements[i]; + console.log('init ' + this.name); + element.addEventListener('click', this.listener); + } + }; + ClickAction.prototype.stopTracking = function () { + if (!this.isTracking) { + throw new Error('[BitAnalytics] The tacking is already stopped'); + } + var elements = document.getElementsByClassName(this.class); + // Add event listener to all the elements found + for (var i = 0; i < elements.length; i++) { + var element = elements[i]; + element.removeEventListener('click', this.listener); + } + this.isTracking = false; + }; + return ClickAction; +}(action_1.default)); +exports.default = ClickAction; + +},{"../action":4,"../log-event":15,"../log-event-handlers":14}],6:[function(require,module,exports){ +"use strict"; +var __importDefault = (this && this.__importDefault) || function (mod) { + return (mod && mod.__esModule) ? mod : { "default": mod }; +}; +Object.defineProperty(exports, "__esModule", { value: true }); var log_event_handlers_1 = __importDefault(require("./log-event-handlers")); var log_event_1 = __importDefault(require("./log-event")); +var action_factory_1 = __importDefault(require("./action-factory")); var adjust_channel_1 = __importDefault(require("./channels/adjust-channel")); var mixpanel_channel_1 = __importDefault(require("./channels/mixpanel-channel")); +var action_handlers_1 = __importDefault(require("./action-handlers")); var channels; (function (channels) { channels.AdjustChannel = adjust_channel_1.default; @@ -6082,12 +6297,13 @@ var BitAnalytics = /** @class */ (function () { function BitAnalytics() { } BitAnalytics.initialize = function (os, appVersion, channelConfigs) { - if (typeof window === 'undefined') { - console.error('BitAnalytics can be used only in a web browser.'); - return; + if (window == undefined) { + console.error('[BitAnalytics] BitAnalytics cannot be integrated in window.'); } BitAnalytics.LogEventHandlers = new log_event_handlers_1.default(os, appVersion, channelConfigs); + BitAnalytics.ActionHandlers = new action_handlers_1.default(); BitAnalytics.LogEvent = log_event_1.default; + BitAnalytics.ActionFactory = action_factory_1.default; }; BitAnalytics.main = function () { if (window) { @@ -6099,42 +6315,43 @@ var BitAnalytics = /** @class */ (function () { exports.default = BitAnalytics; BitAnalytics.main(); -},{"./channels/adjust-channel":5,"./channels/mixpanel-channel":7,"./log-event":10,"./log-event-handlers":9}],3:[function(require,module,exports){ +},{"./action-factory":2,"./action-handlers":3,"./channels/adjust-channel":9,"./channels/mixpanel-channel":12,"./log-event":15,"./log-event-handlers":14}],7:[function(require,module,exports){ "use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); -var mixpanel_channel_1 = __importDefault(require("./channels/mixpanel-channel")); -var firebase_channel_1 = __importDefault(require("./channels/firebase-channel")); var adjust_channel_1 = __importDefault(require("./channels/adjust-channel")); +var firebase_channel_1 = __importDefault(require("./channels/firebase-channel")); +var ga_channel_1 = __importDefault(require("./channels/ga-channel")); +var mixpanel_channel_1 = __importDefault(require("./channels/mixpanel-channel")); var ChannelFactory = /** @class */ (function () { function ChannelFactory() { } ChannelFactory.createChannel = function (name, config) { // Check if the channel is available if (ChannelFactory.classDictionary[name] == undefined) { - throw new DOMException(name + ' is not available.'); + throw new Error('[BitAnalytics] ' + name + ' is not available.'); } else { // Create a channel var channel = Object.create(ChannelFactory.classDictionary[name].prototype); channel.constructor.apply(channel, [name, config]); channel = channel; - console.log(channel); return channel; } }; ChannelFactory.classDictionary = { - 'mixpanel': mixpanel_channel_1.default, + 'adjust': adjust_channel_1.default, 'firebase': firebase_channel_1.default, - 'adjust': adjust_channel_1.default + 'ga': ga_channel_1.default, + 'mixpanel': mixpanel_channel_1.default }; return ChannelFactory; }()); exports.default = ChannelFactory; -},{"./channels/adjust-channel":5,"./channels/firebase-channel":6,"./channels/mixpanel-channel":7}],4:[function(require,module,exports){ +},{"./channels/adjust-channel":9,"./channels/firebase-channel":10,"./channels/ga-channel":11,"./channels/mixpanel-channel":12}],8:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var Channel = /** @class */ (function () { @@ -6143,14 +6360,6 @@ var Channel = /** @class */ (function () { this.queue = new Array(); this.name = name; } - /** - * - * Public methods - * - */ - Channel.prototype.getName = function () { - return this.name; - }; /** * * Protected methods @@ -6169,7 +6378,7 @@ var Channel = /** @class */ (function () { }()); exports.default = Channel; -},{}],5:[function(require,module,exports){ +},{}],9:[function(require,module,exports){ "use strict"; var __extends = (this && this.__extends) || (function () { var extendStatics = Object.setPrototypeOf || @@ -6185,43 +6394,119 @@ var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); -require('../lib/adjust'); var channel_1 = __importDefault(require("../channel")); +// Loading Adjust websdk +require('../external-libs/adjust'); var AdjustChannel = /** @class */ (function (_super) { __extends(AdjustChannel, _super); function AdjustChannel(name, config) { var _this = _super.call(this, name) || this; - _this.device_ids = { - "gps_adid": "3ea5fac8-cf01-47d5-8aec-9a1354f5e84a" - }; - _this.eventTypes = { - "wallet_created": "nd3dg5" - }; if (!config.token) { - throw new DOMException('Config incorrect.'); + throw new Error('[BitAnalytics] Adjust config is missing token.'); } - if (Adjust) { - _this.adjust = new Adjust("au1onbhgg5q8", "sandbox", "android"); - //this.adjust.trackSession(this.device_ids); - _this.isReady = true; - console.log('Adjust initialised.'); + if (!config.eventTypes) { + throw new Error('[BitAnalytics] Adjust config is missing event types.'); } - else { - console.log('Adjust missing.'); + if (!Adjust) { + throw new Error('[BitAnalytics] Adjust cordova plugin is not installed correctly.'); } + _this.eventTypes = config.eventTypes; + var os = _this.adjustedOs(config.os); + _this.advertisingId = _this.getAdvertisingId(os); + console.log('Advertising ID for adjust: ' + _this.advertisingId); + // TODO: Different initialisation for Cordova. + var sessionParams = { + app_version: config.appVersion, + app_version_short: config.appVersion, + os_name: os + }; + _this.addAdvertisingId(os, sessionParams); + var environment = config.environment || 'production'; + _this.adjustInstance = new Adjust(config.token, environment, os); + _this.adjustInstance.trackSession(sessionParams); + _this.isReady = true; return _this; } + /** + * + * Public methods + * + */ AdjustChannel.prototype.postEvent = function (name, params) { - //var result = this.mixpanelInstance.track(logEvent.name); if (this.isReady) { - this.adjust.trackEvent('nd3dg5', this.device_ids); + var eventType = this.eventTypes[name]; + // Each event needs to be added on adjust, and config for adjust. + if (!eventType) { + throw new Error('This event name does not exist on Adjust.'); + } + params.os = this.adjustedOs(params.os); + this.addAdvertisingId(params.os, params); + this.adjustInstance.trackEvent(eventType, params); } }; + /** + * + * Private methods + * + */ + AdjustChannel.prototype.addAdvertisingId = function (os, params) { + if (os === 'ios') { + params.idfa = this.advertisingId; + } + else if (os === 'android') { + params.gps_adid = this.advertisingId; + } + else { + params.win_hwid = this.advertisingId; + params.win_naid = this.advertisingId; + params.win_adid = this.advertisingId; + } + }; + // Desktop version will pretend to be Windows + AdjustChannel.prototype.adjustedOs = function (os) { + if (os === 'ios' || os === 'android') { + return os; + } + else { + return 'wstore'; + } + }; + AdjustChannel.prototype.generateRandomGuid = function () { + return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) { + var r = Math.random() * 16 | 0, v = c == 'x' ? r : (r & 0x3 | 0x8); + return v.toString(16); + }); + }; + // Example: 107e8ea14329d4a2194ebbb6dc0c0fd7 + AdjustChannel.prototype.generateWindowsAdvertisingId = function () { + var id = ''; + for (var i = 0; i < 32; i++) { + id += Math.floor(Math.random() * 16).toString(16); + } + return id; + }; + // https://docs.adjust.com/en/event-tracking/ + AdjustChannel.prototype.getAdvertisingId = function (os) { + var adid = localStorage.getItem('adid'); + if (!adid) { + if (os === 'ios') { + adid = this.generateRandomGuid().toUpperCase(); + } + else if (os === 'android') { + adid = this.generateRandomGuid(); + } + else { + adid = this.generateWindowsAdvertisingId(); + } + localStorage.setItem('adid', adid); + } + return adid; + }; return AdjustChannel; }(channel_1.default)); exports.default = AdjustChannel; -},{"../channel":4,"../lib/adjust":8}],6:[function(require,module,exports){ +},{"../channel":8,"../external-libs/adjust":13}],10:[function(require,module,exports){ "use strict"; var __extends = (this && this.__extends) || (function () { var extendStatics = Object.setPrototypeOf || @@ -6245,16 +6530,21 @@ var FirebaseChannel = /** @class */ (function (_super) { /** * Firebase available only on ios and android */ - if (config['os'] != 'android' && config['os'] != 'ios') { - throw new DOMException('Firebase is not supported on ' + config['os']); + if (config.os != 'android' && config.os != 'ios') { + throw new Error('[BitAnalytics] Firebase is not supported on ' + config.os); } if (!window.FirebasePlugin) { - throw new DOMException('Firebase cordova plugin is not installed correctly.'); + throw new Error('[BitAnalytics] Firebase cordova plugin is not installed correctly.'); } _this.firebaseInstance = window.FirebasePlugin; _this.isReady = true; return _this; } + /** + * + * Public methods + * + */ FirebaseChannel.prototype.postEvent = function (name, params) { var _this = this; if (!this.isReady) { @@ -6268,7 +6558,90 @@ var FirebaseChannel = /** @class */ (function (_super) { }(channel_1.default)); exports.default = FirebaseChannel; -},{"../channel":4}],7:[function(require,module,exports){ +},{"../channel":8}],11:[function(require,module,exports){ +"use strict"; +var __extends = (this && this.__extends) || (function () { + var extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + return function (d, b) { + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); + }; +})(); +var __importDefault = (this && this.__importDefault) || function (mod) { + return (mod && mod.__esModule) ? mod : { "default": mod }; +}; +Object.defineProperty(exports, "__esModule", { value: true }); +var channel_1 = __importDefault(require("../channel")); +var GoogleAnalyticsChannel = /** @class */ (function (_super) { + __extends(GoogleAnalyticsChannel, _super); + function GoogleAnalyticsChannel(name, config) { + var _this = _super.call(this, name) || this; + _this.dataLayer = null; + _this.gaInstance = null; + _this.trackingId = ''; + _this.eventLabels = ['id']; + if (!config.trackingId) { + throw new Error('[BitAnalytics] Google Analytics config is missing tracking ID.'); + } + if (config.eventLabels) { + _this.eventLabels = config.eventLabels; + } + _this.trackingId = config.trackingId; + _this.setUpGa(); + return _this; + } + /** + * + * Public methods + * + */ + GoogleAnalyticsChannel.prototype.postEvent = function (name, params) { + // Default Google Analytics Events + // https://developers.google.com/analytics/devguides/collection/gtagjs/events + // Useful to convert to these, or start with these? + if (this.isReady) { + params.event_category = name; + for (var _i = 0, _a = this.eventLabels; _i < _a.length; _i++) { + var eventLabel = _a[_i]; + if (params[eventLabel]) { + params.event_label = params[eventLabel]; + break; + } + } + this.gtag('event', name, params); + } + }; + /** + * + * Private methods + * + */ + /** + * Mimics function in the tracking snippet + */ + GoogleAnalyticsChannel.prototype.gtag = function () { + var args = []; + for (var _i = 0; _i < arguments.length; _i++) { + args[_i] = arguments[_i]; + } + console.log(arguments); + window.dataLayer.push(arguments); + }; + GoogleAnalyticsChannel.prototype.setUpGa = function () { + // From what GA recommends to insert into page + window.dataLayer = window.dataLayer || []; + this.gtag('js', new Date()); + this.gtag('config', this.trackingId); + this.isReady = true; + }; + return GoogleAnalyticsChannel; +}(channel_1.default)); +exports.default = GoogleAnalyticsChannel; + +},{"../channel":8}],12:[function(require,module,exports){ "use strict"; var __extends = (this && this.__extends) || (function () { var extendStatics = Object.setPrototypeOf || @@ -6291,12 +6664,17 @@ var MixpanelChannel = /** @class */ (function (_super) { function MixpanelChannel(name, config) { var _this = _super.call(this, name) || this; if (!config.token) { - throw new DOMException('Config incorrect.'); + throw new DOMException('[BitAnalytics] Config incorrect.'); } _this.mixpanelInstance = mixpanel; mixpanel.init(config.token, config.config); return _this; } + /** + * + * Public methods + * + */ MixpanelChannel.prototype.postEvent = function (name, params) { var result = this.mixpanelInstance.track(name); }; @@ -6304,7 +6682,7 @@ var MixpanelChannel = /** @class */ (function (_super) { }(channel_1.default)); exports.default = MixpanelChannel; -},{"../channel":4,"mixpanel-browser":1}],8:[function(require,module,exports){ +},{"../channel":8,"mixpanel-browser":1}],13:[function(require,module,exports){ "use strict"; (function (window) { var sendRequest = function (method, url, data, success_cb, error_cb) { @@ -6353,7 +6731,7 @@ exports.default = MixpanelChannel; window.Adjust = function (app_token, environment, os_name) { this.trackSession = function (device_ids) { var params = cloneObj(device_ids); params.app_token = app_token; params.os_name = os_name; params.environment = environment; sendRequest("GET", "https://app.adjust.com/session?" + encodeQueryString(params)); }; this.trackEvent = function (event_token, device_ids) { var params = cloneObj(device_ids); params.app_token = app_token; params.event_token = event_token; params.os_name = os_name; params.environment = environment; sendRequest("GET", "https://app.adjust.com/event?" + encodeQueryString(params)); }; }; })(window); -},{}],9:[function(require,module,exports){ +},{}],14:[function(require,module,exports){ "use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; @@ -6366,7 +6744,7 @@ var LogEventHandlers = /** @class */ (function () { this.appVersion = appVersion; this.channels = []; this.isReady = false; // Ready once all channels are ready or one channel is ready? - this.initialize(channelConfigs); + this.initializeChannels(channelConfigs); LogEventHandlers.instance = this; } /** @@ -6379,27 +6757,9 @@ var LogEventHandlers = /** @class */ (function () { return LogEventHandlers.instance; } else { - throw new DOMException('LogEventHandlers need to be initialized'); + throw new Error('[BitAnalytics] LogEventHandlers need to be initialized'); } }; - LogEventHandlers.prototype.initialize = function (channelConfigs) { - var _this = this; - // Get the channel names by the keys - var channelNames = Object.keys(channelConfigs); - // Iterate to init the several channels given in the config - channelNames.map(function (channelName) { - var channelConfig = channelConfigs[channelName]; - // OS shared to check the availability of this channel on this OS. - channelConfig['os'] = _this.os; - try { - var channel = channel_factory_1.default.createChannel(channelName, channelConfig); - _this.channels.push(channel); - } - catch (error) { - console.log(error.name + ': ' + error.message); - } - }); - }; LogEventHandlers.prototype.postEvent = function (logEvent) { var _this = this; /** @@ -6408,7 +6768,7 @@ var LogEventHandlers = /** @class */ (function () { * 2 is second channel * ... */ - var logEventParams = logEvent.getParams(); + var logEventParams = logEvent.params; // params var params = { 'os': this.os, @@ -6417,10 +6777,10 @@ var LogEventHandlers = /** @class */ (function () { // Concat the shared params if (logEventParams.length > 0) { // concat specific params needed - params = Object.assign({}, logEventParams[0], params); + params = this.concatObject(logEventParams[0], params); } // Post event depending of the channel - logEvent.getChannelNames().map(function (channelName, i) { + logEvent.channelNames.map(function (channelName, i) { var channel = _this.getChannelByName(channelName); if (channel) { // Real index (first param is shared by all channels) @@ -6428,14 +6788,21 @@ var LogEventHandlers = /** @class */ (function () { // concat if needed if (logEventParams.length > index) { // concat specific params needed - params = Object.assign({}, logEventParams[index], params); + params = _this.concatObject(logEventParams[index], params); + } + console.log('[BitAnalytics] Params: ' + JSON.stringify(params)); + try { + channel.postEvent(logEvent.name, params); + console.log('[BitAnalytics] LogEvent "' + logEvent.name + '" sent to ' + channelName + '.'); + } + catch (e) { + console.error('[BitAnalytics] LogEvent "' + logEvent.name + '" failed to send with "' + channelName + '. '); + console.log(e); } - channel.postEvent(logEvent.getName(), params); - console.log('LogEvent "' + logEvent.getName() + '" sent to ' + channelName + '.'); } else { // Channel not available - console.log('LogEvent "' + logEvent.getName() + '" cannot send to ' + channelName + ', this channel is not available.'); + console.log('[BitAnalytics] LogEvent "' + logEvent.name + '" cannot send to ' + channelName + ', this channel is not available.'); } }); }; @@ -6444,10 +6811,17 @@ var LogEventHandlers = /** @class */ (function () { * Private methods * */ + LogEventHandlers.prototype.concatObject = function (from, to) { + var keys = Object.keys(from); + keys.map(function (key) { + if (!to[key]) { + to[key] = from[key]; + } + }); + return to; + }; LogEventHandlers.prototype.getChannelByName = function (channelName) { - console.log(channelName); - console.log(this.channels); - var channels = this.channels.filter(function (channel) { return channel.getName() == channelName; }); + var channels = this.channels.filter(function (channel) { return channel.name == channelName; }); if (channels.length > 0) { return channels[0]; } @@ -6455,39 +6829,44 @@ var LogEventHandlers = /** @class */ (function () { return undefined; } }; + LogEventHandlers.prototype.initializeChannels = function (channelConfigs) { + var _this = this; + // Get the channel names by the keys + var channelNames = Object.keys(channelConfigs); + // Iterate to init the several channels given in the config + channelNames.map(function (channelName) { + var channelConfig = channelConfigs[channelName]; + // OS shared to check the availability of this channel on this OS. + channelConfig.os = _this.os; + channelConfig.appVersion = _this.appVersion; + try { + var channel = channel_factory_1.default.createChannel(channelName, channelConfig); + _this.channels.push(channel); + } + catch (error) { + console.log('[BitAnalytics] ' + error.name + ': ' + error.message); + } + }); + }; return LogEventHandlers; }()); exports.default = LogEventHandlers; -},{"./channel-factory":3}],10:[function(require,module,exports){ +},{"./channel-factory":7}],15:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var LogEvent = /** @class */ (function () { function LogEvent(name, params, channelNames) { if (channelNames.length == 0) { - throw new DOMException('Minimum one channel is needed.'); + throw new Error('[BitAnalytics] Minimum one channel is needed.'); } this.name = name; this.params = params; this.channelNames = channelNames; } - /** - * - * Public methods - * - */ - LogEvent.prototype.getName = function () { - return this.name; - }; - LogEvent.prototype.getParams = function () { - return this.params; - }; - LogEvent.prototype.getChannelNames = function () { - return this.channelNames; - }; return LogEvent; }()); exports.default = LogEvent; -},{}]},{},[2])(2) +},{}]},{},[6])(6) }); diff --git a/src/js/routes.js b/src/js/routes.js index dabebdf65..ee7abba58 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -1214,8 +1214,65 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr // Init BitAnalytics var os = platformInfo.isAndroid ? 'android' : platformInfo.isIOS ? 'ios' : 'desktop'; - window.BitAnalytics.initialize(os, $window.fullVersion, {"firebase": {}}); - + window.BitAnalytics.initialize(os, $window.fullVersion, {"firebase": {}, + "ga": { + "trackingId": "UA-59964190-23", + "eventLabels": ["id", "icon-off"] + }, + "adjust": { + "token": "au1onbhgg5q8", + "environment" : "production", + "eventTypes": { + "banner_click": "sc5i8u", + "buy_bitcoin_click": "t1vcdz", + "transfer_success": "f68evo", + "wallet_created": "nd3dg5", + "wallet_opened": "4n39l7" + } + } + }); + + var channel = "ga"; + if (platformInfo.isNW) { + channel = "ga"; + } + + // Send a log to test + var log = new window.BitAnalytics.LogEvent("wallet_opened", [], [channel, "adjust"]); + window.BitAnalytics.LogEventHandlers.postEvent(log); + + var actionBanner = new window.BitAnalytics.ActionFactory.createAction('click', { + name: 'banner_click', + class: 'track_banner_click', + params: ['href-banner', 'id'], + channels: [channel, 'adjust'] + }); + window.BitAnalytics.ActionHandlers.trackAction(actionBanner); + + var actionBuyBitcoin = new window.BitAnalytics.ActionFactory.createAction('click', { + name: 'buy_bitcoin_click', + class: 'track_buy_bitcoin_click', + params: ['href', 'id'], + channels: [channel, 'adjust'] + }); + window.BitAnalytics.ActionHandlers.trackAction(actionBuyBitcoin); + + var actionLinkClickOut = new window.BitAnalytics.ActionFactory.createAction('click', { + name: 'link_click_out', + class: 'track_link_click_out', + params: ['href', 'id'], + channels: [channel] + }); + window.BitAnalytics.ActionHandlers.trackAction(actionLinkClickOut); + + var actionTabOpen = new window.BitAnalytics.ActionFactory.createAction('click', { + name: 'tab_open', + class: 'track_tab_open', + params: ['href', 'title', 'icon-off'], + channels: [channel] + }); + window.BitAnalytics.ActionHandlers.trackAction(actionTabOpen); + // Init language uxLanguage.init(function (lang) { @@ -1385,7 +1442,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } win.menu = nativeMenuBar; } - + $rootScope.$on('$stateChangeStart', function(event, toState, toParams, fromState, fromParams) { if (document.body.classList.contains('keyboard-open')) { document.body.classList.remove('keyboard-open'); diff --git a/www/index.html b/www/index.html index a4ab55678..4c73317e3 100644 --- a/www/index.html +++ b/www/index.html @@ -12,7 +12,8 @@ Bitcoin.com Wallet - Bitcoin.com Wallet - + + @@ -30,7 +31,7 @@ - + diff --git a/www/views/includes/community.html b/www/views/includes/community.html index a8c021745..86841a77c 100644 --- a/www/views/includes/community.html +++ b/www/views/includes/community.html @@ -6,14 +6,14 @@
- +
diff --git a/www/views/tab-home.html b/www/views/tab-home.html index 4d494e9ec..97dd2bd16 100644 --- a/www/views/tab-home.html +++ b/www/views/tab-home.html @@ -92,7 +92,7 @@
- + diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 838c04299..ab40e7e42 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -32,7 +32,7 @@ To get started, buy bitcoin or share your address. You can receive bitcoin from any wallet or service. To get started, you'll need to create a bitcoin wallet and get some bitcoin.
- +
diff --git a/www/views/tabs.html b/www/views/tabs.html index 69cf93309..3c2683a13 100644 --- a/www/views/tabs.html +++ b/www/views/tabs.html @@ -1,22 +1,21 @@ - - + - + - + - + - + From 8abaf184aaa3ca3599420f63e1f9b74bdb624933 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 13 Jul 2018 17:19:31 +0900 Subject: [PATCH 065/386] 458 - Add Statistic --- src/js/controllers/addressbookAdd.js | 10 ++++++++++ src/js/controllers/confirm.js | 13 +++++++++++++ src/js/controllers/preferencesNotifications.js | 9 +++++++++ src/js/controllers/tab-receive.js | 10 ++++++++++ src/js/controllers/walletDetails.js | 7 +++++++ src/js/routes.js | 2 +- src/js/services/profileService.js | 9 +++++++++ 7 files changed, 59 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/addressbookAdd.js b/src/js/controllers/addressbookAdd.js index a57839aa1..dcdb43b9f 100644 --- a/src/js/controllers/addressbookAdd.js +++ b/src/js/controllers/addressbookAdd.js @@ -35,6 +35,16 @@ angular.module('copayApp.controllers').controller('addressbookAddController', fu var translated = bitcoinCashJsService.readAddress(addressbook.address); addressbook.address = translated.legacy; } + + var channel = "firebase"; + if (platformInfo.isNW) { + channel = "ga"; + } + var log = new window.BitAnalytics.LogEvent("contact_created", [{ + "coin": $scope.addressbookEntry.coin + }], [channel]); + window.BitAnalytics.LogEventHandlers.postEvent(log); + $timeout(function() { addressbookService.add(addressbook, function(err, ab) { if (err) { diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index f1fab5b02..03af26fd1 100644 --- a/src/js/controllers/confirm.js +++ b/src/js/controllers/confirm.js @@ -643,6 +643,19 @@ angular.module('copayApp.controllers').controller('confirmController', function( soundService.play('misc/payment_sent.mp3'); } + var channel = "firebase"; + if (platformInfo.isNW) { + channel = "ga"; + } + var log = new window.BitAnalytics.LogEvent("transfer_success", [{ + "coin": $scope.wallet.coin, + "type": "outgoing", + "amount": $scope.amount, + "fees": $scope.fee + }], [channel, "adjust"]); + window.BitAnalytics.LogEventHandlers.postEvent(log); + + // Should be removed firebaseEventsService.logEvent('sent_bitcoin', { coin: $scope.wallet.coin }); $timeout(function() { $scope.$digest(); diff --git a/src/js/controllers/preferencesNotifications.js b/src/js/controllers/preferencesNotifications.js index 7351a9f23..edfb983b5 100644 --- a/src/js/controllers/preferencesNotifications.js +++ b/src/js/controllers/preferencesNotifications.js @@ -75,6 +75,15 @@ angular.module('copayApp.controllers').controller('preferencesNotificationsContr }; emailService.updateEmail(opts); + + var channel = "firebase"; + if (platformInfo.isNW) { + channel = "ga"; + } + var log = new window.BitAnalytics.LogEvent("settings_email_notification_toggle", [{ + "toggle": $scope.emailNotifications.value + }], [channel]); + window.BitAnalytics.LogEventHandlers.postEvent(log); }; $scope.soundNotificationsChange = function() { diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index 629e59b51..6c11c2dbd 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -143,6 +143,16 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi } $scope.paymentReceivedCoin = $scope.wallet.coin; + var channel = "firebase"; + if (platformInfo.isNW) { + channel = "ga"; + } + var log = new window.BitAnalytics.LogEvent("transfer_success", [{ + "coin": $scope.wallet.coin, + "type": "incoming" + }], [channel, "adjust"]); + window.BitAnalytics.LogEventHandlers.postEvent(log); + if ($state.current.name === "tabs.receive") { soundService.play('misc/payment_received.mp3'); } diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index 88ee871ff..24237f6c9 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -12,6 +12,13 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun $scope.isAndroid = platformInfo.isAndroid; $scope.isIOS = platformInfo.isIOS; + var channel = "firebase"; + if (platformInfo.isNW) { + channel = "ga"; + } + var log = new window.BitAnalytics.LogEvent("wallet_details_open", [], [channel]); + window.BitAnalytics.LogEventHandlers.postEvent(log); + $scope.amountIsCollapsible = !$scope.isAndroid; $scope.openExternalLink = function(url, target) { diff --git a/src/js/routes.js b/src/js/routes.js index ee7abba58..63b436a85 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -1232,7 +1232,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }); - var channel = "ga"; + var channel = "firebase"; if (platformInfo.isNW) { channel = "ga"; } diff --git a/src/js/services/profileService.js b/src/js/services/profileService.js index 25f2a6852..4f8710c28 100644 --- a/src/js/services/profileService.js +++ b/src/js/services/profileService.js @@ -427,6 +427,15 @@ angular.module('copayApp.services') }, function(err, secret) { if (err) return bwcError.cb(err, gettextCatalog.getString('Error creating wallet'), cb); + var channel = "firebase"; + if (platformInfo.isNW) { + channel = "ga"; + } + var log = new window.BitAnalytics.LogEvent("wallet_created", [{ + "coin": opts.coin + }], [channel]); + window.BitAnalytics.LogEventHandlers.postEvent(log); + return cb(null, walletClient, secret); }); }); From 1150e843d75900f4c2a2db11eba9458f5669a528 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 13 Jul 2018 17:50:21 +0900 Subject: [PATCH 066/386] 474 - Link updated --- src/js/services/bitcoincomService.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/js/services/bitcoincomService.js b/src/js/services/bitcoincomService.js index 681ed8f4d..d7883b68e 100644 --- a/src/js/services/bitcoincomService.js +++ b/src/js/services/bitcoincomService.js @@ -20,28 +20,28 @@ angular.module('copayApp.services').factory('bitcoincomService', function($http, name: 'games', title: 'Bitcoin Cash Games', icon: 'icon-games', - href: 'http://cashgames.bitcoin.com' + href: 'https://cashgames.bitcoin.com/?utm_source=WalletApp&utm_medium=iOS&utm_campaign=CashGames' }; var newsItem = { name: 'news', title: 'News', icon: 'icon-news', - href: 'http://news.bitcoin.com' + href: 'https://news.bitcoin.com/?utm_source=WalletApp&utm_medium=iOS&utm_campaign=News' }; var poolItem = { name: 'pool', title: 'Mining Pool', icon: 'icon-mining', - href: 'http://pool.bitcoin.com' + href: 'https://pool.bitcoin.com/?utm_source=WalletApp&utm_medium=iOS&utm_campaign=Pool' }; var toolsItem = { name: 'tools', title: 'Tools', icon: 'icon-tools', - href: 'http://tools.bitcoin.com' + href: 'https://tools.bitcoin.com/?utm_source=WalletApp&utm_medium=iOS&utm_campaign=Tools' }; var priceChartItem = { @@ -55,7 +55,7 @@ angular.module('copayApp.services').factory('bitcoincomService', function($http, name: 'faucet', title: 'Free Bitcoin Cash', icon: 'icon-faucet', - href: 'https://free.bitcoin.com/' + href: 'https://free.bitcoin.com/?utm_source=WalletApp&utm_medium=iOS&utm_campaign=Faucet' }; var _getBitPay = function(endpoint) { From 63c64bce0ee795070fc4e427f5897f692c554ce3 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 13 Jul 2018 17:53:18 +0900 Subject: [PATCH 067/386] 474 - Link changed --- www/views/buyBitcoindotcom.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/views/buyBitcoindotcom.html b/www/views/buyBitcoindotcom.html index 2c8ef36f1..a8a7889e3 100644 --- a/www/views/buyBitcoindotcom.html +++ b/www/views/buyBitcoindotcom.html @@ -15,7 +15,7 @@
- +
From aed9657714d4bce025ebc9ed8eb96b60912b48e9 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 13 Jul 2018 21:02:57 +1200 Subject: [PATCH 068/386] Removed extraneous .com in email subject line. --- src/js/controllers/tab-settings.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/controllers/tab-settings.js b/src/js/controllers/tab-settings.js index 7106aa743..4d0636d53 100644 --- a/src/js/controllers/tab-settings.js +++ b/src/js/controllers/tab-settings.js @@ -46,7 +46,7 @@ angular.module('copayApp.controllers').controller('tabSettingsController', funct }; $scope.sendFeedback = function() { - var mailToLink = 'mailto:wallet@bitcoin.com?subject=Feedback%20for%20Bitcoin.com%20Wallet.com'; + var mailToLink = 'mailto:wallet@bitcoin.com?subject=Feedback%20for%20Bitcoin.com%20Wallet'; if (platformInfo.isNW) { nw.Shell.openExternal(mailToLink); } else if (platformInfo.isCordova) { From 04b5a5103e268f894726071aad47a8b8d2d81bf8 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 13 Jul 2018 21:36:35 +1200 Subject: [PATCH 069/386] Fixed up last merge by removing feedbackService parameter. --- src/js/controllers/tab-home.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/controllers/tab-home.js b/src/js/controllers/tab-home.js index 43021d7e2..a04820ebd 100644 --- a/src/js/controllers/tab-home.js +++ b/src/js/controllers/tab-home.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.controllers').controller('tabHomeController', - function($rootScope, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, bannerService, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, storageService, txpModalService, appConfigService, startupService, addressbookService, feedbackService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { + function($rootScope, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, bannerService, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, storageService, txpModalService, appConfigService, startupService, addressbookService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { var wallet; var listeners = []; var notifications = []; From 02e22517cbde7a17980dd5ccff7cbf7de949b91b Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 13 Jul 2018 11:44:24 +0200 Subject: [PATCH 070/386] scrollable contacts fix --- src/js/controllers/tab-send.js | 1 + src/sass/views/tab-send.scss | 5 ++++- www/views/tab-send.html | 3 +-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index bcaaaef5c..e0806816b 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -250,6 +250,7 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }; $scope.$on("$ionicView.beforeEnter", function(event, data) { + $scope.isIOS = platformInfo.isIOS && platformInfo.isCordova; $scope.showWalletsBch = $scope.showWalletsBtc = $scope.showWallets = false; $scope.checkingBalance = true; diff --git a/src/sass/views/tab-send.scss b/src/sass/views/tab-send.scss index 717ebff89..89c2fc2c4 100644 --- a/src/sass/views/tab-send.scss +++ b/src/sass/views/tab-send.scss @@ -6,7 +6,10 @@ width: 100%; } &-contacts { - height: calc(100vh - 300px - 50px - 44px); + height: calc(100vh - 300px /* button container */ - 50px /* bottom-tab-menu */ - 44px /* header top */); + &.ios { + height: calc(100vh - 300px - 50px - 44px - 20pt); // Remove the notification-bar height on iOS + } overflow: scroll; } diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 3fabea47a..4d9506592 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -86,10 +86,9 @@
-
+
-
Contacts
Saved frequently used addresses
From ca7cd448101c3e9ff6d06d1d9d14de8d4d963c55 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 13 Jul 2018 12:46:06 +0200 Subject: [PATCH 071/386] iPhone SE styles --- src/sass/views/tab-send.scss | 27 ++++++++++++++++++++++++--- 1 file changed, 24 insertions(+), 3 deletions(-) diff --git a/src/sass/views/tab-send.scss b/src/sass/views/tab-send.scss index 89c2fc2c4..a4025156f 100644 --- a/src/sass/views/tab-send.scss +++ b/src/sass/views/tab-send.scss @@ -6,9 +6,9 @@ width: 100%; } &-contacts { - height: calc(100vh - 300px /* button container */ - 50px /* bottom-tab-menu */ - 44px /* header top */); + height: calc(100vh - 300px - 50px - 44px); /* screen size - button container - bottom-tab-menu - header top */ &.ios { - height: calc(100vh - 300px - 50px - 44px - 20pt); // Remove the notification-bar height on iOS + height: calc(100vh - 300px - 50px - 44px - 18px); // Remove the notification-bar height on iOS } overflow: scroll; } @@ -235,7 +235,8 @@ } .card.contacts { - margin: 4px; + margin: 4px 4px 16px 4px; + border-radius: 6px; box-shadow: 0px 2px 1px 0 #C1C1C1; .gravatar { @@ -245,4 +246,24 @@ } } + + ///* iPhone 5/SE and other small screen devices */ + @media only screen and (min-device-width : 320px) and (max-device-width : 568px) { + .send-wrapper .buttons .button-qr { + height: 60px; + span { + font-size: 16px; + } + } + #tab-send-header { + height: 270px; + } + #tab-send-contacts { + height: calc(100vh - 270px - 50px - 44px); /* screen size - button container - bottom-tab-menu - header top */ + &.ios { + height: calc(100vh - 270px - 50px - 44px - 18px); // Remove the notification-bar height on iOS + } + } + } + } From c515a080e5061bada67d2d6f41809b3bf03a3979 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 13 Jul 2018 13:01:30 +0200 Subject: [PATCH 072/386] translations + fixed the tags for those --- i18n/po/template.pot | 69 +++++++++++++++++++++++++++++++++++++++-- www/views/tab-send.html | 28 ++++++----------- 2 files changed, 77 insertions(+), 20 deletions(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index 66a2e7ca8..12a9c1f5c 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -610,10 +610,14 @@ msgstr "" msgid "Connection reset by peer" msgstr "" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "" @@ -814,7 +818,7 @@ msgstr "" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "" @@ -2582,9 +2586,70 @@ msgid "Send by email" msgstr "" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "" + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "" + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "" + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "" diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 4d9506592..6bd32398d 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -46,8 +46,8 @@ Send Bitcoin faster!
-
-

Save frequently used addresses and send them Bitcoin in just one tap

+
+

Save frequently used addresses and send them Bitcoin in just one tap

-
-

To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address.

-

You can receive bitcoin from any wallet or service.

-
-
To get started, you'll need to create a bitcoin wallet and get some - bitcoin. +
+

To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address.

+

You can receive bitcoin from any wallet or service.

+
To get started, you'll need to create a bitcoin wallet and get some bitcoin.
- - - + + +
@@ -91,7 +83,7 @@
Contacts
-
Saved frequently used addresses
+
Saved frequently used addresses
From 501e8ce7384e251d940e55fcb8cb65bcb57790bc Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 13 Jul 2018 14:02:48 +0200 Subject: [PATCH 073/386] Only show "from"-wallets with balance --- src/js/controllers/tab-send.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index e0806816b..c13a27f7e 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -119,7 +119,8 @@ angular.module('copayApp.controllers').controller('tabSendController', function( var hasWallets = function() { $scope.wallets = profileService.getWallets({ - onlyComplete: true + onlyComplete: true, + hasFunds: true }); $scope.walletsBch = profileService.getWallets({ onlyComplete: true, From 358ae5842cf243d58e351eef868f84bd40909c40 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 13 Jul 2018 14:16:15 +0200 Subject: [PATCH 074/386] Clipboard empty message + translations --- i18n/po/template.pot | 8 ++++++++ src/js/controllers/tab-send.js | 14 ++++++-------- 2 files changed, 14 insertions(+), 8 deletions(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index 12a9c1f5c..a23e5dbae 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -2528,6 +2528,14 @@ msgstr "" msgid "Search or enter bitcoin address" msgstr "" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "" diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index c13a27f7e..3c73c229c 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -1,19 +1,12 @@ 'use strict'; -angular.module('copayApp.controllers').controller('tabSendController', function($scope, $rootScope, $log, $timeout, $ionicScrollDelegate, addressbookService, profileService, lodash, $state, walletService, incomingData, popupService, platformInfo, bwcError, gettextCatalog, scannerService, configService, bitcoinCashJsService, $ionicNavBarDelegate, clipboardService) { +angular.module('copayApp.controllers').controller('tabSendController', function($scope, $rootScope, $log, $timeout, $ionicScrollDelegate, addressbookService, profileService, lodash, $state, walletService, incomingData, popupService, platformInfo, bwcError, gettextCatalog, scannerService, configService, bitcoinCashJsService, $ionicPopup, $ionicNavBarDelegate, clipboardService) { var clipboardHasAddress = false; var clipboardHasContent = false; var originalList; $scope.displayBalanceAsFiat = true; $scope.walletSelectorTitleForce = true; - - - $scope.walletHide = function() { - console.log("wallet HIDE"); - alert('test'); - }; - $scope.addContact = function() { $state.go('tabs.settings').then(function() { $state.go('tabs.addressbook').then(function() { @@ -30,6 +23,11 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }); $scope.findContact($scope.formData.search); }); + } else { + $ionicPopup.alert({ + title: gettextCatalog.getString('Clipboard'), + template: gettextCatalog.getString('Your Clipboard is empty') + }); } }; From d801e287fd41c211bfdff70a81684e11ea88cd9b Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 13 Jul 2018 14:23:09 +0200 Subject: [PATCH 075/386] Only copy address to clipboard after click "generate new address" --- src/js/controllers/tab-receive.js | 14 ++++++++------ www/views/tab-receive.html | 2 +- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index 629e59b51..249cf8e5a 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -24,7 +24,7 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi }); }; - $scope.setAddress = function(newAddr) { + $scope.setAddress = function(newAddr, copyAddress) { $scope.addr = null; if (!$scope.wallet || $scope.generatingAddress || !$scope.wallet.isComplete()) return; $scope.generatingAddress = true; @@ -58,11 +58,13 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi paymentSubscriptionObj.addr = $scope.addr } - try { - clipboardService.copyToClipboard($scope.wallet.coin == 'bch' && $scope.bchAddressType.type == 'cashaddr' ? 'bitcoincash:' + $scope.addr : $scope.addr); - } catch (error) { - $log.debug("Error copying to clipboard:"); - $log.debug(error); + if (copyAddress === true) { + try { + clipboardService.copyToClipboard($scope.wallet.coin == 'bch' && $scope.bchAddressType.type == 'cashaddr' ? 'bitcoincash:' + $scope.addr : $scope.addr); + } catch (error) { + $log.debug("Error copying to clipboard:"); + $log.debug(error); + } } // create subscription var msg = JSON.stringify(paymentSubscriptionObj); diff --git a/www/views/tab-receive.html b/www/views/tab-receive.html index 28f0e51ad..046a19ba8 100644 --- a/www/views/tab-receive.html +++ b/www/views/tab-receive.html @@ -48,7 +48,7 @@
-
From 00b4ee5849f09a13cd8ee8b3c0cfd913199ee0ec Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 13 Jul 2018 14:54:26 +0200 Subject: [PATCH 076/386] wallet empty/no wallet fixes --- src/js/controllers/tab-send.js | 5 ++++- www/views/tab-send.html | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 3c73c229c..2ddad8dad 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -116,10 +116,13 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }; var hasWallets = function() { - $scope.wallets = profileService.getWallets({ + $scope.walletsWithFunds = profileService.getWallets({ onlyComplete: true, hasFunds: true }); + $scope.wallets = profileService.getWallets({ + onlyComplete: true, + }); $scope.walletsBch = profileService.getWallets({ onlyComplete: true, coin: 'bch' diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 6bd32398d..05230af06 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -108,7 +108,7 @@ Date: Mon, 16 Jul 2018 12:40:17 +1200 Subject: [PATCH 077/386] BitAnalytics with Firebase parameter name fix. --- bitanalytics/bitanalytics-0.1.0.js | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/bitanalytics/bitanalytics-0.1.0.js b/bitanalytics/bitanalytics-0.1.0.js index cf85b3c14..db149e481 100644 --- a/bitanalytics/bitanalytics-0.1.0.js +++ b/bitanalytics/bitanalytics-0.1.0.js @@ -6547,13 +6547,26 @@ var FirebaseChannel = /** @class */ (function (_super) { */ FirebaseChannel.prototype.postEvent = function (name, params) { var _this = this; + var sanitizedParams = this.sanitizeParams(params); if (!this.isReady) { - this.enqueue(function () { _this.postEvent(name, params); }); + this.enqueue(function () { _this.postEvent(name, sanitizedParams); }); } else { - this.firebaseInstance.logEvent(name, params); + this.firebaseInstance.logEvent(name, sanitizedParams); } }; + // [Firebase/Analytics][I-ACS013002] Event parameter name must contain only letters, numbers, or underscores + FirebaseChannel.prototype.sanitizeParams = function (params) { + var keys = Object.keys(params); + var keysLength = keys.length; + var sanitized = {}; + for (var i = 0; i < keysLength; i++) { + var key = keys[i]; + var cleanKey = key.replace('-', '_').replace(/[\W]+/g, ''); + sanitized[cleanKey] = params[key]; + } + return sanitized; + }; return FirebaseChannel; }(channel_1.default)); exports.default = FirebaseChannel; From 415b79c12e209ad99228b5c9b2d2cb80a93da9b0 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 16 Jul 2018 14:20:40 +0900 Subject: [PATCH 078/386] 474 - Fix os in the link --- src/js/services/bitcoincomService.js | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/js/services/bitcoincomService.js b/src/js/services/bitcoincomService.js index d7883b68e..b404031b1 100644 --- a/src/js/services/bitcoincomService.js +++ b/src/js/services/bitcoincomService.js @@ -1,12 +1,13 @@ 'use strict'; -angular.module('copayApp.services').factory('bitcoincomService', function($http, $log, lodash, moment, storageService, configService, platformInfo, nextStepsService, homeIntegrationsService) { +angular.module('copayApp.services').factory('bitcoincomService', function(platformInfo, nextStepsService) { var root = {}; var credentials = {}; /* * Development: 'testnet' * Production: 'livenet' - */ + */ + var os = platformInfo.isAndroid ? 'android' : platformInfo.isIOS ? 'ios' : 'desktop'; credentials.NETWORK = 'livenet'; //credentials.NETWORK = 'testnet'; @@ -20,28 +21,28 @@ angular.module('copayApp.services').factory('bitcoincomService', function($http, name: 'games', title: 'Bitcoin Cash Games', icon: 'icon-games', - href: 'https://cashgames.bitcoin.com/?utm_source=WalletApp&utm_medium=iOS&utm_campaign=CashGames' + href: 'https://cashgames.bitcoin.com/?utm_source=WalletApp&utm_medium=' + os + '&utm_campaign=CashGames' }; var newsItem = { name: 'news', title: 'News', icon: 'icon-news', - href: 'https://news.bitcoin.com/?utm_source=WalletApp&utm_medium=iOS&utm_campaign=News' + href: 'https://news.bitcoin.com/?utm_source=WalletApp&utm_medium=' + os + '&utm_campaign=News' }; var poolItem = { name: 'pool', title: 'Mining Pool', icon: 'icon-mining', - href: 'https://pool.bitcoin.com/?utm_source=WalletApp&utm_medium=iOS&utm_campaign=Pool' + href: 'https://pool.bitcoin.com/?utm_source=WalletApp&utm_medium=' + os + '&utm_campaign=Pool' }; var toolsItem = { name: 'tools', title: 'Tools', icon: 'icon-tools', - href: 'https://tools.bitcoin.com/?utm_source=WalletApp&utm_medium=iOS&utm_campaign=Tools' + href: 'https://tools.bitcoin.com/?utm_source=WalletApp&utm_medium=' + os + '&utm_campaign=Tools' }; var priceChartItem = { @@ -55,7 +56,7 @@ angular.module('copayApp.services').factory('bitcoincomService', function($http, name: 'faucet', title: 'Free Bitcoin Cash', icon: 'icon-faucet', - href: 'https://free.bitcoin.com/?utm_source=WalletApp&utm_medium=iOS&utm_campaign=Faucet' + href: 'https://free.bitcoin.com/?utm_source=WalletApp&utm_medium=' + os + '&utm_campaign=Faucet' }; var _getBitPay = function(endpoint) { From ea3cee4ebfe5bb7b3c8b09fd7c8e7f6c28714977 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 16 Jul 2018 14:40:02 +0900 Subject: [PATCH 079/386] 474 - Fix link --- src/js/controllers/buyBitcoindotcom.js | 4 +++- www/views/buyBitcoindotcom.html | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/buyBitcoindotcom.js b/src/js/controllers/buyBitcoindotcom.js index 741898c34..64766eede 100644 --- a/src/js/controllers/buyBitcoindotcom.js +++ b/src/js/controllers/buyBitcoindotcom.js @@ -1,7 +1,9 @@ 'use strict'; angular.module('copayApp.controllers').controller('buyBitcoindotcomController', - function($scope, $timeout, $ionicModal, $log, $state, $ionicHistory, lodash, bitcoincomService, externalLinkService, popupService) { + function($scope, platformInfo, externalLinkService) { + + $scope.os = platformInfo.isAndroid ? 'android' : platformInfo.isIOS ? 'ios' : 'desktop'; $scope.openExternalLink = function(url) { externalLinkService.open(url); diff --git a/www/views/buyBitcoindotcom.html b/www/views/buyBitcoindotcom.html index a8a7889e3..f0f8e27e3 100644 --- a/www/views/buyBitcoindotcom.html +++ b/www/views/buyBitcoindotcom.html @@ -15,7 +15,7 @@
- +
From 85e910dc467bc1d408b481fdd8fb0c63057e5b84 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 16 Jul 2018 17:55:21 +1200 Subject: [PATCH 080/386] Make the Cash Games link work again. --- src/js/services/bitcoincomService.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/services/bitcoincomService.js b/src/js/services/bitcoincomService.js index b404031b1..051123111 100644 --- a/src/js/services/bitcoincomService.js +++ b/src/js/services/bitcoincomService.js @@ -21,7 +21,7 @@ angular.module('copayApp.services').factory('bitcoincomService', function(platfo name: 'games', title: 'Bitcoin Cash Games', icon: 'icon-games', - href: 'https://cashgames.bitcoin.com/?utm_source=WalletApp&utm_medium=' + os + '&utm_campaign=CashGames' + href: 'https://cashgames.bitcoin.com' }; var newsItem = { From a4f0f887660e720c859bf470024b02df181abfa8 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 16 Jul 2018 15:52:33 +0900 Subject: [PATCH 081/386] Fix addressbookAdd --- src/js/controllers/addressbookAdd.js | 2 +- src/js/controllers/tab-send.js | 6 +----- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/src/js/controllers/addressbookAdd.js b/src/js/controllers/addressbookAdd.js index dcdb43b9f..9529d943e 100644 --- a/src/js/controllers/addressbookAdd.js +++ b/src/js/controllers/addressbookAdd.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('addressbookAddController', function($scope, $state, $stateParams, $timeout, $ionicHistory, gettextCatalog, addressbookService, popupService, configService, bitcoinCashJsService) { +angular.module('copayApp.controllers').controller('addressbookAddController', function($scope, $state, $stateParams, $timeout, $ionicHistory, gettextCatalog, addressbookService, popupService, configService, bitcoinCashJsService, platformInfo) { var config = configService.getSync(); var defaults = configService.getDefaults(); diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 2ddad8dad..2bfbee665 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -8,11 +8,7 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.walletSelectorTitleForce = true; $scope.addContact = function() { - $state.go('tabs.settings').then(function() { - $state.go('tabs.addressbook').then(function() { - $state.go('tabs.addressbook.add'); - }); - }); + $state.go('tabs.send.addressbook'); }; $scope.pasteClipboard = function() { From 236a93d69d9780b94ec04173d021f7c7806b630c Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 16 Jul 2018 17:21:15 +0200 Subject: [PATCH 082/386] share transaction after sending on mobile + share explorer url on desktop. --- i18n/po/template.pot | 1 + src/js/controllers/confirm.js | 14 ++++++- src/js/directives/slideToAcceptSuccess.js | 11 ++++-- .../views/includes/slideToAcceptSuccess.scss | 38 +++++++++++++------ www/img/icon-share-white.svg | 17 +++++++++ www/views/confirm.html | 1 + www/views/includes/slideToAcceptSuccess.html | 7 +++- 7 files changed, 71 insertions(+), 18 deletions(-) create mode 100644 www/img/icon-share-white.svg diff --git a/i18n/po/template.pot b/i18n/po/template.pot index 66a2e7ca8..2ee53ec78 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -648,6 +648,7 @@ msgstr "" #: src/js/controllers/copayers.js:79 #: src/js/controllers/export.js:193 +#: src/js/controllers/confirm.js:41 #: www/views/includes/copyToClipboard.html:4 msgid "Copied to clipboard" msgstr "" diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index 03af26fd1..c8c889263 100644 --- a/src/js/controllers/confirm.js +++ b/src/js/controllers/confirm.js @@ -1,11 +1,12 @@ 'use strict'; -angular.module('copayApp.controllers').controller('confirmController', function($rootScope, $scope, $interval, $filter, $timeout, $ionicScrollDelegate, gettextCatalog, walletService, platformInfo, lodash, configService, $stateParams, $window, $state, $log, profileService, bitcore, bitcoreCash, txFormatService, ongoingProcess, $ionicModal, popupService, $ionicHistory, $ionicConfig, payproService, feeService, bwcError, txConfirmNotification, externalLinkService, firebaseEventsService, soundService) { +angular.module('copayApp.controllers').controller('confirmController', function($rootScope, $scope, $interval, $filter, $timeout, $ionicScrollDelegate, ionicToast, gettextCatalog, walletService, platformInfo, lodash, configService, $stateParams, $window, $state, $log, profileService, bitcore, bitcoreCash, txFormatService, ongoingProcess, $ionicModal, popupService, $ionicHistory, $ionicConfig, payproService, feeService, bwcError, txConfirmNotification, externalLinkService, firebaseEventsService, soundService, clipboardService) { var countDown = null; var FEE_TOO_HIGH_LIMIT_PER = 15; var tx = {}; + var lastTxId = ""; // Config Related values var config = configService.getSync(); @@ -31,6 +32,16 @@ angular.module('copayApp.controllers').controller('confirmController', function( }, 10); } + $scope.shareTransaction = function() { + var explorerTxUrl = 'https://explorer.bitcoin.com/'+tx.coin+'/tx/'+lastTxId; + if (platformInfo.isCordova) { + var text = 'Take a look at this Bitcoin transaction here: '+explorerTxUrl; + window.plugins.socialsharing.share(text, null, null, null); + } else { + ionicToast.show(gettextCatalog.getString('Copied to clipboard'), 'bottom', false, 3000); + clipboardService.copyToClipboard(explorerTxUrl); + } + }; $scope.showWalletSelector = function() { $scope.walletSelector = true; @@ -612,6 +623,7 @@ angular.module('copayApp.controllers').controller('confirmController', function( txConfirmNotification.subscribe(wallet, { txid: txp.txid }); + lastTxId = txp.txid; } }, onSendStatusChange); }; diff --git a/src/js/directives/slideToAcceptSuccess.js b/src/js/directives/slideToAcceptSuccess.js index fbd588bfe..ec6321b95 100644 --- a/src/js/directives/slideToAcceptSuccess.js +++ b/src/js/directives/slideToAcceptSuccess.js @@ -9,12 +9,12 @@ angular.module('copayApp.directives') scope: { isShown: '=slideSuccessShow', onConfirm: '&slideSuccessOnConfirm', - hideOnConfirm: '=slideSuccessHideOnConfirm' + hideOnConfirm: '=slideSuccessHideOnConfirm', + onShare: '=slideSuccessOnShare', }, link: function(scope, element, attrs) { - - scope.isWindowsPhoneApp = platformInfo.isCordova && platformInfo.isWP; - + scope.isCordova = platformInfo.isCordova; + scope.hasShareFunction = typeof scope.onShare === 'function'; var elm = element[0]; elm.style.display = 'none'; scope.$watch('isShown', function() { @@ -32,6 +32,9 @@ angular.module('copayApp.directives') elm.style.display = 'none'; } }; + scope.onShareButtonClick = function() { + scope.onShare(); + } } }; }); diff --git a/src/sass/views/includes/slideToAcceptSuccess.scss b/src/sass/views/includes/slideToAcceptSuccess.scss index 68312c7a4..724363b0d 100644 --- a/src/sass/views/includes/slideToAcceptSuccess.scss +++ b/src/sass/views/includes/slideToAcceptSuccess.scss @@ -12,12 +12,6 @@ slide-to-accept-success { .slide-success { $duration: 400ms; - &__windows-background { - background: $v-success-bg-color; - height: 100%; - width: 100%; - position: fixed; - } &__background { $start-radius: 5; $scale-factor: 20; @@ -40,9 +34,11 @@ slide-to-accept-success { &__content { position: relative; z-index: 1; - margin-top: -20vh; + margin-top: -10vh; > img { + width: 45vw; + max-width: 166px; margin-bottom: 1.8rem; -webkit-transform: translateY(5rem); transform: translateY(5rem); @@ -59,7 +55,7 @@ slide-to-accept-success { &__header { color: #FFFFFF; - font-size: 26px; + font-size: 29px; -webkit-transform: translateY(5rem); transform: translateY(5rem); opacity: 0; @@ -72,6 +68,26 @@ slide-to-accept-success { opacity: 1; } } + &__share { + transition: transform $duration ease, opacity $duration ease; + transition-delay: 1000ms; + opacity: 0; + margin-top: 15vh; + span { + color: #FFF; + font-size: 22px; + height: 28px; + } + img { + height: 28px; + width: auto; + vertical-align: bottom; + margin-right: 4px; + } + &.reveal { + opacity: 0.79; + } + } } &__footer { @@ -98,11 +114,11 @@ slide-to-accept-success { &__btn { display: block; color: #FFFFFF; - font-size: 18px; + font-size: 22px; font-weight: 600; letter-spacing: 2.86px; - padding: 1rem 0 1.1rem; - border-top: 1px solid rgba(255, 255, 255, .45); + padding: 2rem 0 2.1rem; + border-top: 1px solid rgba(255, 255, 255, 0.25); cursor: pointer; } } diff --git a/www/img/icon-share-white.svg b/www/img/icon-share-white.svg new file mode 100644 index 000000000..eeb3e7b6b --- /dev/null +++ b/www/img/icon-share-white.svg @@ -0,0 +1,17 @@ + + + + + + + + + + diff --git a/www/views/confirm.html b/www/views/confirm.html index e54837f34..afc8f9e40 100644 --- a/www/views/confirm.html +++ b/www/views/confirm.html @@ -120,6 +120,7 @@ Payment Sent Proposal Created diff --git a/www/views/includes/slideToAcceptSuccess.html b/www/views/includes/slideToAcceptSuccess.html index 923eab25c..ed4ebfa77 100644 --- a/www/views/includes/slideToAcceptSuccess.html +++ b/www/views/includes/slideToAcceptSuccess.html @@ -1,13 +1,16 @@
+ ng-class="{'fill-screen': fillScreen}">
- +
Payment Sent
+
+
+
+
+ Receive +
+
+
+
+ Buy Bitcoin +
+
+ Send +
+
+
+
From cc907251f75493d0ab0f5536a1fd9f924e56322b Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 18 Jul 2018 17:20:59 +1200 Subject: [PATCH 097/386] Removing unused services, and making string translatable. --- i18n/po/template.pot | 4 ++++ src/js/controllers/amount.js | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index a23e5dbae..45a4fbd44 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -3699,3 +3699,7 @@ msgstr "" #: www/views/includes/walletInfo.html:18 msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "" + +#: src/js/controllers/amount.js:49 +msgid "Address doesn\'t contain currency information, please make sure you are sending the correct currency." +msgstr "" \ No newline at end of file diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 52695e829..1c91baf97 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('amountController', function($scope, $filter, $timeout, $ionicModal, $ionicScrollDelegate, $ionicHistory, storageService, walletService, gettextCatalog, platformInfo, lodash, configService, rateService, $stateParams, $window, $state, $log, txFormatService, ongoingProcess, popupService, bwcError, payproService, profileService, bitcore, amazonService, nodeWebkitService) { +angular.module('copayApp.controllers').controller('amountController', function($scope, $filter, $timeout, $ionicModal, $ionicScrollDelegate, $ionicHistory, walletService, gettextCatalog, platformInfo, lodash, configService, rateService, $stateParams, $window, $state, $log, txFormatService, ongoingProcess, popupService, profileService, nodeWebkitService) { var _id; var unitToSatoshi; @@ -46,7 +46,7 @@ angular.module('copayApp.controllers').controller('amountController', function($ if (data.stateParams.noPrefix) { $scope.showWarningMessage = data.stateParams.noPrefix != 0; if ($scope.showWarningMessage) { - var message = 'Address doesn\'t contain currency information, please make sure you are sending the correct currency.'; + var message = gettextCatalog.getString('Address doesn\'t contain currency information, please make sure you are sending the correct currency.'); popupService.showAlert('', message, function() {}, 'Ok'); } } From 0db57f997a6d8e374544a445ce050be5734a1508 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 18 Jul 2018 18:24:49 +1200 Subject: [PATCH 098/386] First successful test, instantiating an amountController. --- src/js/controllers/amount.spec.js | 55 ++++++++++++++++++++ src/js/services/secureStorageService.spec.js | 6 +-- src/js/services/storageService.spec.js | 4 +- test/karma.conf.js | 2 + 4 files changed, 62 insertions(+), 5 deletions(-) create mode 100644 src/js/controllers/amount.spec.js diff --git a/src/js/controllers/amount.spec.js b/src/js/controllers/amount.spec.js new file mode 100644 index 000000000..1e5342cd9 --- /dev/null +++ b/src/js/controllers/amount.spec.js @@ -0,0 +1,55 @@ +fdescribe('amountController', function(){ + var $controller, + $rootScope, + platformInfo, + $stateParams; + + + + beforeEach(function(){ + module('ngLodash'); + module('copayApp.controllers'); + + platformInfo = { + isChromeApp: false, + isAndroid: false, + isIos: true + }; + + $stateParams = {}; + + inject(function(_$controller_, _$rootScope_){ + // The injector unwraps the underscores (_) from around the parameter names when matching + $controller = _$controller_; + $rootScope = _$rootScope_; + }); + + + + }); + + it('something', function() { + var $scope = $rootScope.$new(); + var amountController = $controller('amountController', { + configService: {}, + gettextCatalog: {}, + $ionicHistory: {}, + $ionicModal: {}, + $ionicScrollDelegate: {}, + nodeWebkitService: {}, + ongoingProcess: {}, + platformInfo: platformInfo, + profileService: {}, + popupService: {}, + rateService: {}, + $scope: $scope, + $state: {}, + $stateParams: $stateParams, + txFormatService: {}, + walletService: {} + }); + + expect(true).toBe(true); + }); + +}); \ No newline at end of file diff --git a/src/js/services/secureStorageService.spec.js b/src/js/services/secureStorageService.spec.js index abfa5d947..8d2842a6a 100644 --- a/src/js/services/secureStorageService.spec.js +++ b/src/js/services/secureStorageService.spec.js @@ -1,4 +1,4 @@ -describe('secureStorageService in browser', function(){ +xdescribe('secureStorageService in browser', function(){ var localStorage, sss; @@ -100,7 +100,7 @@ describe('secureStorageService in browser', function(){ }); -describe('secureStorageService on desktop', function(){ +xdescribe('secureStorageService on desktop', function(){ var desktopSss, sss; @@ -202,7 +202,7 @@ describe('secureStorageService on desktop', function(){ }); -describe('secureStorageService on mobile', function(){ +xdescribe('secureStorageService on mobile', function(){ var mobileSss, sss; diff --git a/src/js/services/storageService.spec.js b/src/js/services/storageService.spec.js index 493678b97..cc3ad285d 100644 --- a/src/js/services/storageService.spec.js +++ b/src/js/services/storageService.spec.js @@ -414,7 +414,7 @@ xdescribe('storageService on desktop', function(){ }); -describe('storageService on desktop using local storage', function(){ +xdescribe('storageService on desktop using local storage', function(){ var appConfig, localStorageServiceMock, log, @@ -614,7 +614,7 @@ describe('storageService on desktop using local storage', function(){ }); -describe('storageService on mobile', function(){ +xdescribe('storageService on mobile', function(){ var appConfig, expectedOldProfileSavedToSecure, expectedOldProfileMergedWithSecure, diff --git a/test/karma.conf.js b/test/karma.conf.js index 002d40c91..b4f64af73 100644 --- a/test/karma.conf.js +++ b/test/karma.conf.js @@ -17,6 +17,8 @@ module.exports = function(config) { files: [ 'node_modules/angular/angular.js', + 'bitanalytics/bitanalytics-0.1.0.js', + // From Gruntfile.js 'bower_components/qrcode-generator/js/qrcode.js', 'bower_components/qrcode-generator/js/qrcode_UTF8.js', From 8725adb959f38d971cfecf05bbd067b6baf3186b Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 18 Jul 2018 09:02:52 +0200 Subject: [PATCH 099/386] sent-successful svg --- www/img/icon-sent-successful.svg | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 www/img/icon-sent-successful.svg diff --git a/www/img/icon-sent-successful.svg b/www/img/icon-sent-successful.svg new file mode 100644 index 000000000..070357ddf --- /dev/null +++ b/www/img/icon-sent-successful.svg @@ -0,0 +1,10 @@ + + + + + + From 3df28360819870a3ab62a858f9866f1407aafe8a Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 18 Jul 2018 20:26:20 +1200 Subject: [PATCH 100/386] Successful test with amountController, using beforeEnter. --- src/js/controllers/amount.spec.js | 62 +++++++++++++++++++++++++++---- 1 file changed, 54 insertions(+), 8 deletions(-) diff --git a/src/js/controllers/amount.spec.js b/src/js/controllers/amount.spec.js index 1e5342cd9..ed64da836 100644 --- a/src/js/controllers/amount.spec.js +++ b/src/js/controllers/amount.spec.js @@ -1,7 +1,12 @@ -fdescribe('amountController', function(){ - var $controller, +describe('amountController', function(){ + var configCache, + configService, + $controller, + $ionicHistory, $rootScope, platformInfo, + profileService, + rateService, $stateParams; @@ -10,12 +15,34 @@ fdescribe('amountController', function(){ module('ngLodash'); module('copayApp.controllers'); + configCache = { + wallet: { + settings: { + + } + } + }; + + + configService = jasmine.createSpyObj(['getDefaults','getSync']); + configService.getDefaults.and.returnValue({ + bitcoinCashAlias: 'bch', + bitcoinAlias: 'btc' + }); + configService.getSync.and.returnValue(configCache); + + $ionicHistory = jasmine.createSpyObj(['backView']); + platformInfo = { isChromeApp: false, isAndroid: false, isIos: true }; + profileService = jasmine.createSpyObj(['getWallets']); + + rateService = jasmine.createSpyObj(['fromFiat', 'whenAvailable']); + $stateParams = {}; inject(function(_$controller_, _$rootScope_){ @@ -28,20 +55,30 @@ fdescribe('amountController', function(){ }); - it('something', function() { + it('receives fromWalletId and toAddress.', function() { + + var backView = { + stateName: 'ignoreme' + }; + $ionicHistory.backView.and.returnValue(backView); + profileService.getWallets.and.returnValue([{}]); + rateService.fromFiat.and.returnValue(12); // satoshis or coins? + var $scope = $rootScope.$new(); + + var amountController = $controller('amountController', { - configService: {}, + configService: configService, gettextCatalog: {}, - $ionicHistory: {}, + $ionicHistory: $ionicHistory, $ionicModal: {}, $ionicScrollDelegate: {}, nodeWebkitService: {}, ongoingProcess: {}, platformInfo: platformInfo, - profileService: {}, + profileService: profileService, popupService: {}, - rateService: {}, + rateService: rateService, $scope: $scope, $state: {}, $stateParams: $stateParams, @@ -49,7 +86,16 @@ fdescribe('amountController', function(){ walletService: {} }); - expect(true).toBe(true); + var data = { + stateParams: { + fromWalletId: 'fd56c1e7-e3ac-4fd9-8afc-27b9c1b3718b', + toAddress: 'qrup46avn8t466xxwlzs4qelht7cnwvesv2e29wf7s' + } + }; + $scope.$emit('$ionicView.beforeEnter', data); + + expect($scope.fromWalletId).toBe('fd56c1e7-e3ac-4fd9-8afc-27b9c1b3718b'); + expect($scope.toAddress).toBe('qrup46avn8t466xxwlzs4qelht7cnwvesv2e29wf7s'); }); }); \ No newline at end of file From 8a0575d238690d7dec073b8adcbc120fe0923693 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Wed, 18 Jul 2018 16:41:52 +0800 Subject: [PATCH 101/386] Add empty view and controller for review transaction route --- src/js/controllers/review.js | 5 + src/js/routes.js | 12 + www/css/main.css | 1162 ++++++++++++++++++---------------- www/index.html | 7 +- www/views/review.html | 45 ++ 5 files changed, 670 insertions(+), 561 deletions(-) create mode 100644 src/js/controllers/review.js create mode 100644 www/views/review.html diff --git a/src/js/controllers/review.js b/src/js/controllers/review.js new file mode 100644 index 000000000..1effff0ba --- /dev/null +++ b/src/js/controllers/review.js @@ -0,0 +1,5 @@ +'use strict'; + +angular.module('copayApp.controllers').controller('reviewController', function($rootScope, $scope, $interval, $filter, $timeout, $ionicScrollDelegate, gettextCatalog, walletService, platformInfo, lodash, configService, $stateParams, $window, $state, $log, profileService, bitcore, bitcoreCash, txFormatService, ongoingProcess, $ionicModal, popupService, $ionicHistory, $ionicConfig, payproService, feeService, bwcError, txConfirmNotification, externalLinkService, firebaseEventsService, soundService) { + +}); diff --git a/src/js/routes.js b/src/js/routes.js index 8277314e5..79b88e2f7 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -316,6 +316,18 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } } }) + .state('tabs.send.review', { + url: '/review', + views: { + 'tab-send@tabs': { + controller: 'reviewController', + templateUrl: 'views/review.html' + } + }, + params: { + paypro: null + } + }) /* * diff --git a/www/css/main.css b/www/css/main.css index b4e67edac..a87bc4be9 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -9970,7 +9970,7 @@ ion-nav-bar.hide { .card { margin: 20px 14px; } -ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm:before, ion-view#copayers-invitation:before, ion-view#tab-home:before, ion-view#tab-receive:before, ion-view#tab-send:before, ion-view.settings:before, ion-view#bitpayCard:before, ion-view#bitpayCard-intro:before, ion-view#view-address-book:before, ion-view#addresses:before, ion-view#send-feedback:before, ion-view#choose-fee-level:before, ion-view#txp-details:before, ion-view#coinbase:before, ion-view#glidera:before, ion-view#amazon:before, ion-view#mercadolibre:before, ion-view#custom-amount:before { +ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm:before, ion-view#copayers-invitation:before, ion-view#tab-home:before, ion-view#tab-receive:before, ion-view#tab-send:before, ion-view.settings:before, ion-view#bitpayCard:before, ion-view#bitpayCard-intro:before, ion-view#view-address-book:before, ion-view#addresses:before, ion-view#choose-fee-level:before, ion-view#txp-details:before, ion-view#coinbase:before, ion-view#glidera:before, ion-view#amazon:before, ion-view#mercadolibre:before, ion-view#custom-amount:before { content: " "; display: block; position: absolute; @@ -9980,7 +9980,7 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm height: 44px; background-color: #fab915; } -.platform-ios.platform-cordova:not(.fullscreen) ion-view.deflash-blue:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-amount:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-confirm:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#copayers-invitation:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-home:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-receive:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-send:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view.settings:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#bitpayCard:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#bitpayCard-intro:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-address-book:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#addresses:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#send-feedback:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#choose-fee-level:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#txp-details:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#coinbase:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#glidera:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#amazon:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#mercadolibre:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#custom-amount:before { +.platform-ios.platform-cordova:not(.fullscreen) ion-view.deflash-blue:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-amount:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-confirm:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#copayers-invitation:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-home:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-receive:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-send:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view.settings:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#bitpayCard:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#bitpayCard-intro:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-address-book:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#addresses:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#choose-fee-level:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#txp-details:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#coinbase:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#glidera:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#amazon:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#mercadolibre:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#custom-amount:before { height: 64px; } .just-a-hint, .icon.bp-arrow-right, .icon.bp-arrow-down, .icon.bp-arrow-up { @@ -10071,10 +10071,12 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm .loading .spinner svg { margin-top: 0; } -.button.button-primary.button-standard, .button.button-secondary.button-standard, .button.button-light.button-standard, .button.button-assertive.button-standard, +.button.button-primary.button-standard, .button.button-secondary.button-standard, .button.button-light.button-standard, .button.button-white.button-standard, .button.button-green.button-standard, .button.button-assertive.button-standard, .onboarding .button.button-primary.button-standard, .onboarding .button.button-secondary.button-standard, .onboarding .button.button-light.button-standard, +.onboarding .button.button-white.button-standard, +.onboarding .button.button-green.button-standard, .onboarding .button.button-assertive.button-standard { width: 85%; max-width: 300px; @@ -10118,10 +10120,12 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm box-shadow: none; color: #fff; } -.button.button-primary.button-standard + .button-standard, .button.button-secondary.button-standard + .button-standard, .button.button-light.button-standard + .button-standard, .button.button-assertive.button-standard + .button-standard, +.button.button-primary.button-standard + .button-standard, .button.button-secondary.button-standard + .button-standard, .button.button-light.button-standard + .button-standard, .button.button-white.button-standard + .button-standard, .button.button-green.button-standard + .button-standard, .button.button-assertive.button-standard + .button-standard, .onboarding .button.button-primary.button-standard + .button-standard, .onboarding .button.button-secondary.button-standard + .button-standard, .onboarding .button.button-light.button-standard + .button-standard, +.onboarding .button.button-white.button-standard + .button-standard, +.onboarding .button.button-green.button-standard + .button-standard, .onboarding .button.button-assertive.button-standard + .button-standard { margin-top: 1rem; } @@ -10183,8 +10187,67 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm font-size: 0.7em !important; display: inline !important; } -.button.button-full { - display: block; } +.button { + border-radius: 6px; } + .button.button-full { + display: block; } + .button-green { + border-color: #FFF; + background-color: #719561; + color: #FFF; + border: 0px; + box-shadow: 0 2px 11px 0 #C1C1C1; } + .button-green:hover { + color: #FFF; + text-decoration: none; } + .button-green.active, .button-green.activated { + border-color: #FFF; + background-color: #606060; } + .button-green.button-clear { + border-color: transparent; + background: none; + box-shadow: none; + color: #FFF; } + .button-green.button-icon { + border-color: transparent; + background: none; } + .button-green.button-outline { + border-color: #C1C1C1; + background: transparent; + color: #C1C1C1; } + .button-green.button-outline.active, .button-green.button-outline.activated { + background-color: #C1C1C1; + box-shadow: none; + color: #fff; } + .button-white { + border-color: #C1C1C1; + background-color: #FFF; + color: #606060; + box-shadow: 0 2px 11px 0 #C1C1C1; } + .button-white:hover { + color: #606060; + text-decoration: none; } + .button-white.active, .button-white.activated { + border-color: #FFF; + background-color: #C1C1C1; } + .button-white.button-clear { + border-color: transparent; + background: none; + box-shadow: none; + color: #FFF; } + .button-white.button-icon { + border-color: transparent; + background: none; } + .button-white.button-outline { + border-color: #C1C1C1; + background: transparent; + color: #C1C1C1; } + .button-white.button-outline.active, .button-white.button-outline.activated { + background-color: #C1C1C1; + box-shadow: none; + color: #fff; } + .button-white.activated { + color: #FFF; } .button-clear { background: none !important; } @@ -10197,6 +10260,22 @@ textarea.d-block { display: block; width: 100%; } +qrcode { + position: relative; } + qrcode.qr-overlay::before { + content: ""; + background-size: 100% 100%; + display: block; + left: 88px; + margin-top: 88px; + width: 44px; + height: 44px; + position: absolute; } + qrcode.qr-overlay--bch::before { + background-image: url("../img/qr-overlay-bch.png"); } + qrcode.qr-overlay--btc::before { + background-image: url("../img/qr-overlay-btc.png"); } + .center-block { float: none; margin: 0 auto; } @@ -10237,6 +10316,10 @@ textarea.d-block { font-weight: 700; } #tab-home .card > .item-heading .icon, #tab-home .list > .item-heading .icon, #tab-send .card > .item-heading .icon, #tab-send .list > .item-heading .icon { color: #667; } + #tab-home .card > .item-heading .subtitle, #tab-home .list > .item-heading .subtitle, #tab-send .card > .item-heading .subtitle, #tab-send .list > .item-heading .subtitle { + color: #667; + font-size: 12px; + font-weight: 300; } #view-add .item { margin-bottom: 10px; @@ -10260,349 +10343,345 @@ textarea.d-block { #view-add .bg.join { padding: 10px; } -#view-amount .recipient-label { - font-size: 14px; - padding-bottom: 0; - color: #667; } - -#view-amount .item-no-bottom-border + .item { - border-top: 0; } - -#view-amount .icon-bitpay-card { - background-image: url("../img/icon-bitpay.svg"); } - -#view-amount .icon-amazon { - background-image: url("../img/icon-amazon.svg"); } - -@media (max-width: 480px) { - #view-amount .bitcoin-address { - font-size: 13px; - padding-left: 48px; } - #view-amount .bitcoin-address .icon { - left: 8px; - font-size: 24px; } - #view-amount .bitcoin-address .big-icon-svg { - left: 5px; } - #view-amount .bitcoin-address .big-icon-svg > .bg { - width: 30px; - height: 30px; - box-shadow: none; } } - -@media (max-width: 320px) { - #view-amount .bitcoin-address > span:last-child { - margin-left: -2px; } } - -#view-amount .send-gravatar { - left: 11px; - position: absolute; - top: 10px; } - -#view-amount .amount span input { - display: inline; - width: 120px; } - -#view-amount .amount-pane-recipient { - position: absolute; - top: 95px; - bottom: 0; - width: 100%; - background-color: #fff; - padding: 0 16px; } - #view-amount .amount-pane-recipient .amount-bar { - padding: 24px 0; - font-size: 18px; } - @media (max-height: 480px) { - #view-amount .amount-pane-recipient .amount-bar { - padding: 0px; } } - @media (max-width: 320px) { - #view-amount .amount-pane-recipient .amount-bar { - padding: 0px; } } - #view-amount .amount-pane-recipient .amount-bar .title { - float: left; - padding-top: 10px; - color: #445; - font-weight: bold; } +#view-amount { + background: #494949; } + #view-amount .recipient-label { + font-size: 14px; + padding-bottom: 0; + color: #667; } + #view-amount .item-no-bottom-border + .item { + border-top: 0; } + #view-amount .icon-bitpay-card { + background-image: url("../img/icon-bitpay.svg"); } + #view-amount .icon-amazon { + background-image: url("../img/icon-amazon.svg"); } + @media (max-width: 480px) { + #view-amount .bitcoin-address { + font-size: 13px; + padding-left: 48px; } + #view-amount .bitcoin-address .icon { + left: 8px; + font-size: 24px; } + #view-amount .bitcoin-address .big-icon-svg { + left: 5px; } + #view-amount .bitcoin-address .big-icon-svg > .bg { + width: 30px; + height: 30px; + box-shadow: none; } } + @media (max-width: 320px) { + #view-amount .bitcoin-address > span:last-child { + margin-left: -2px; } } + #view-amount .send-gravatar { + left: 11px; + position: absolute; + top: 10px; } + #view-amount .amount span input { + display: inline; + width: 120px; } + #view-amount .amount-pane-recipient { + position: absolute; + top: 95px; + bottom: 0; + width: 100%; + background-color: #fff; + padding: 0 16px; } + #view-amount .amount-pane-recipient .amount-bar { + padding: 24px 0; + font-size: 18px; } @media (max-height: 480px) { - #view-amount .amount-pane-recipient .amount-bar .title { + #view-amount .amount-pane-recipient .amount-bar { padding: 0px; } } - @media (max-height: 480px) { - #view-amount .amount-pane-recipient .amount-bar { - padding-top: 3px; } } - #view-amount .amount-pane-recipient .amount { - display: flex; - flex-direction: column; - justify-content: center; - flex-grow: 1; - position: absolute; - bottom: 254px; - top: 66px; } - #view-amount .amount-pane-recipient .amount .light { - color: #9b9bab; } - @media (max-height: 480px) { - #view-amount .amount-pane-recipient .amount { - top: 45px; } } - @media (max-width: 320px) { - #view-amount .amount-pane-recipient .amount { - bottom: 276px; - top: 60px; } - #view-amount .amount-pane-recipient .amount > div { - display: inline-block; } - #view-amount .amount-pane-recipient .amount > div:first-child { - display: inherit; } } - -#view-amount .amount-pane-no-recipient { - position: absolute; - top: 0; - bottom: 0; - width: 100%; - background-color: #fff; - padding: 0 16px; } - #view-amount .amount-pane-no-recipient .amount-bar { - padding: 24px 0; - font-size: 18px; } - #view-amount .amount-pane-no-recipient .amount-bar .title { - padding-top: 10px; - color: #445; - font-weight: bold; } - #view-amount .amount-pane-no-recipient .amount-bar .title .limits { - margin-top: 10px; - color: #9b9bab; - font-size: 12px; } - #view-amount .amount-pane-no-recipient .amount-bar .title .select { - margin: 10px 1px; } - #view-amount .amount-pane-no-recipient .amount { - display: flex; - flex-direction: column; - justify-content: center; - flex-grow: 1; - position: absolute; - bottom: 254px; - top: 66px; } - #view-amount .amount-pane-no-recipient .amount .light { - color: #9b9bab; } - -#view-amount .amount { - padding-top: 10px; - padding-bottom: 10px; } - #view-amount .amount .icon-toggle { - font-size: 1.2em; - width: auto; - margin: 0.8em auto; - border: 1px solid #f2f2f2; - color: #445; - border-radius: 3px; - padding: 0 10px; - cursor: pointer; } - @media (max-height: 280px) { - #view-amount .amount .icon-toggle { - margin: 0.1em auto; } } - #view-amount .amount__editable--minimize { - font-size: 22px; } - #view-amount .amount__editable--standard { - font-size: 42px; } - @media (max-height: 480px) { - #view-amount .amount__editable--standard { - font-size: 26px; - padding-top: 10px; } } - #view-amount .amount__editable--placeholder { - color: #9b9bab; } - #view-amount .amount__number { - color: #445; } - #view-amount .amount__currency-toggle { - border: 1px solid #f2f2f2; - color: #445; - border-radius: 3px; - padding: 0 10px; - cursor: pointer; - font-size: .6em; - position: relative; - top: -3px; - line-height: 1; } - @media (max-width: 320px) { - #view-amount .amount__currency-toggle { - line-height: 30px; - height: 30px; } } - #view-amount .amount__currency-toggle-mobile { - border: 1px solid #f2f2f2; - color: #445; - border-radius: 3px; - cursor: pointer; - position: relative; - line-height: 1; } - @media (max-width: 320px) { - #view-amount .amount__currency-toggle-mobile { - line-height: 30px; - height: 30px; } } - #view-amount .amount__results--minimize { - font-size: 12px; } - #view-amount .amount__results--standard { - font-size: 18px; - padding: 10px 0; } - #view-amount .amount__results--placeholder { - color: #9b9bab; } - #view-amount .amount__result { - color: #9b9bab; - font-size: .9em; - line-height: 1; } - @media (max-height: 480px) { - #view-amount .amount__result { - margin-bottom: 0; } } - #view-amount .amount__result-equiv { - color: #667; - font-size: 1.2em; } - @media (max-height: 480px) { - #view-amount .amount__result-equiv { - margin-top: 0; - font-size: 16px; } } - -#view-amount .scroll-content { - display: flex; - flex-direction: column; } - #view-amount .scroll-content .send-amount { - flex: 1 1 auto; - display: flex; - flex-direction: column; - justify-content: center; } - #view-amount .scroll-content .send-amount .send-amount-tool { - flex: 0 1 auto; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input { - text-align: center; - position: relative; - padding: 10px 30px; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .text-selectable { - -webkit-user-select: text; - -moz-user-select: text; - -ms-user-select: text; - user-select: text; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - font-size: 1.8em; } - @media (min-width: 375px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - font-size: 2.1em; } } - @media (min-width: 414px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - font-size: 2.4em; } } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { - font-size: 1.6em; } - @media (min-width: 375px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { - font-size: 1.8em; } } - @media (min-width: 414px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { - font-size: 2em; } } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { - font-size: 0.9em; } - @media (min-width: 375px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { - font-size: 1.3em; } } - @media (min-width: 414px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { - font-size: 1.4em; } } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input { - border: 0; - padding: 0; - white-space: normal; - background: none; - line-height: 1; - box-sizing: content-box; - display: inline-block; - vertical-align: middle; - margin: 0; - height: 1em; - margin-right: 5px; - font-family: 'ProximaNova'; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - display: inline-block; - vertical-align: middle; - line-height: 1em; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit { - font-weight: bold; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - margin-right: 5px; - word-break: break-all; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .switch-currencies { - position: absolute; - right: 0; - top: 50%; - transform: translate(0, -50%); - padding: 15px; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .switch-currencies img { - width: 18px; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions { - margin-top: 15px; - display: flex; - align-items: center; - justify-content: center; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button { - flex: 1 1 auto; - line-height: 1.2em; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button + .button { - margin-left: 10px; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button span { - display: flex; - align-items: center; - justify-content: center; } - #view-amount .scroll-content .button.no-margin { - margin: 0; } - #view-amount .scroll-content .notification-warning { - display: block; - padding: .75rem 1.25rem; - color: #856404; - background-color: #fff3cd; - border: 1px solid #ffeeba; - line-height: 1.4em; - margin-bottom: 20px; } - #view-amount .scroll-content .keypad-container { - position: relative; } - #view-amount .scroll-content .keypad-container .keypad { - text-align: center; - font-size: 18px; - font-weight: lighter; - position: absolute; - bottom: 0; - width: 100%; - color: #667; } - @media (min-height: 667px) { - #view-amount .scroll-content .keypad-container .keypad { - font-size: 24px; } } - #view-amount .scroll-content .keypad-container .keypad .row { - padding: 0 !important; - margin: 0 !important; } - #view-amount .scroll-content .keypad-container .keypad .col { - line-height: 38px; } - @media (min-height: 667px) { - #view-amount .scroll-content .keypad-container .keypad .col { - line-height: 45px; } } - #view-amount .scroll-content .keypad-container .keypad .row:last-child .col { - padding-bottom: 10px; } - #view-amount .scroll-content .keypad-container .keypad .operator { - background-color: #f2f2f2; - font-weight: normal; - cursor: pointer; } - #view-amount .scroll-content .keypad-container .keypad .operator:active { - background-color: #9b9bab; } - #view-amount .scroll-content .keypad-container .keypad .operator-send { - font-weight: bolder; - color: #fff; - background-color: #494949; - font-size: 36px; - cursor: pointer; } - #view-amount .scroll-content .keypad-container .keypad .operator-send:active { - background-color: #eaeaea; } - #view-amount .scroll-content .keypad-container .keypad .digit { - cursor: pointer; - border-top: 1px solid #f2f2f2; - border-left: 1px solid #f2f2f2; - transition: all 0.1s ease; } - #view-amount .scroll-content .keypad-container .keypad .digit:active { - background-color: #f2f2f2; } + @media (max-width: 320px) { + #view-amount .amount-pane-recipient .amount-bar { + padding: 0px; } } + #view-amount .amount-pane-recipient .amount-bar .title { + float: left; + padding-top: 10px; + color: #445; + font-weight: bold; } + @media (max-height: 480px) { + #view-amount .amount-pane-recipient .amount-bar .title { + padding: 0px; } } @media (max-height: 480px) { - #view-amount .scroll-content .keypad-container .keypad { - font-size: 12px; } } + #view-amount .amount-pane-recipient .amount-bar { + padding-top: 3px; } } + #view-amount .amount-pane-recipient .amount { + display: flex; + flex-direction: column; + justify-content: center; + flex-grow: 1; + position: absolute; + bottom: 254px; + top: 66px; } + #view-amount .amount-pane-recipient .amount .light { + color: #9b9bab; } + @media (max-height: 480px) { + #view-amount .amount-pane-recipient .amount { + top: 45px; } } + @media (max-width: 320px) { + #view-amount .amount-pane-recipient .amount { + bottom: 276px; + top: 60px; } + #view-amount .amount-pane-recipient .amount > div { + display: inline-block; } + #view-amount .amount-pane-recipient .amount > div:first-child { + display: inherit; } } + #view-amount .amount-pane-no-recipient { + position: absolute; + top: 0; + bottom: 0; + width: 100%; + background-color: #fff; + padding: 0 16px; } + #view-amount .amount-pane-no-recipient .amount-bar { + padding: 24px 0; + font-size: 18px; } + #view-amount .amount-pane-no-recipient .amount-bar .title { + padding-top: 10px; + color: #445; + font-weight: bold; } + #view-amount .amount-pane-no-recipient .amount-bar .title .limits { + margin-top: 10px; + color: #9b9bab; + font-size: 12px; } + #view-amount .amount-pane-no-recipient .amount-bar .title .select { + margin: 10px 1px; } + #view-amount .amount-pane-no-recipient .amount { + display: flex; + flex-direction: column; + justify-content: center; + flex-grow: 1; + position: absolute; + bottom: 254px; + top: 66px; } + #view-amount .amount-pane-no-recipient .amount .light { + color: #9b9bab; } + #view-amount .amount { + padding-top: 10px; + padding-bottom: 10px; } + #view-amount .amount .icon-toggle { + font-size: 1.2em; + width: auto; + margin: 0.8em auto; + border: 1px solid #f2f2f2; + color: #445; + border-radius: 3px; + padding: 0 10px; + cursor: pointer; } + @media (max-height: 280px) { + #view-amount .amount .icon-toggle { + margin: 0.1em auto; } } + #view-amount .amount__editable--minimize { + font-size: 22px; } + #view-amount .amount__editable--standard { + font-size: 42px; } + @media (max-height: 480px) { + #view-amount .amount__editable--standard { + font-size: 26px; + padding-top: 10px; } } + #view-amount .amount__editable--placeholder { + color: #9b9bab; } + #view-amount .amount__number { + color: #445; } + #view-amount .amount__currency-toggle { + border: 1px solid #f2f2f2; + color: #445; + border-radius: 3px; + padding: 0 10px; + cursor: pointer; + font-size: .6em; + position: relative; + top: -3px; + line-height: 1; } + @media (max-width: 320px) { + #view-amount .amount__currency-toggle { + line-height: 30px; + height: 30px; } } + #view-amount .amount__currency-toggle-mobile { + border: 1px solid #f2f2f2; + color: #445; + border-radius: 3px; + cursor: pointer; + position: relative; + line-height: 1; } + @media (max-width: 320px) { + #view-amount .amount__currency-toggle-mobile { + line-height: 30px; + height: 30px; } } + #view-amount .amount__results--minimize { + font-size: 12px; } + #view-amount .amount__results--standard { + font-size: 18px; + padding: 10px 0; } + #view-amount .amount__results--placeholder { + color: #9b9bab; } + #view-amount .amount__result { + color: #9b9bab; + font-size: .9em; + line-height: 1; } + @media (max-height: 480px) { + #view-amount .amount__result { + margin-bottom: 0; } } + #view-amount .amount__result-equiv { + color: #667; + font-size: 1.2em; } + @media (max-height: 480px) { + #view-amount .amount__result-equiv { + margin-top: 0; + font-size: 16px; } } + #view-amount .scroll-content { + display: flex; + flex-direction: column; } + #view-amount .scroll-content .send-amount { + flex: 1 1 auto; + display: flex; + flex-direction: column; + justify-content: center; } + #view-amount .scroll-content .send-amount .send-amount-tool { + flex: 0 1 auto; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input { + text-align: center; + position: relative; + padding: 10px 30px; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .text-selectable { + -webkit-user-select: text; + -moz-user-select: text; + -ms-user-select: text; + user-select: text; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + font-size: 1.8em; } + @media (min-width: 375px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + font-size: 2.1em; } } + @media (min-width: 414px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + font-size: 2.4em; } } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { + font-size: 1.6em; } + @media (min-width: 375px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { + font-size: 1.8em; } } + @media (min-width: 414px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { + font-size: 2em; } } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { + font-size: 0.9em; } + @media (min-width: 375px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { + font-size: 1.3em; } } + @media (min-width: 414px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { + font-size: 1.4em; } } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input { + border: 0; + padding: 0; + white-space: normal; + background: none; + line-height: 1; + box-sizing: content-box; + display: inline-block; + vertical-align: middle; + margin: 0; + height: 1em; + margin-right: 5px; + font-family: 'ProximaNova'; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + display: inline-block; + vertical-align: middle; + line-height: 1em; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit { + font-weight: bold; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + margin-right: 5px; + word-break: break-all; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .switch-currencies { + position: absolute; + right: 0; + top: 50%; + transform: translate(0, -50%); + padding: 15px; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .switch-currencies img { + width: 18px; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions { + margin-top: 15px; + display: flex; + align-items: center; + justify-content: center; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button { + flex: 1 1 auto; + line-height: 1.2em; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button + .button { + margin-left: 10px; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button span { + display: flex; + align-items: center; + justify-content: center; } + #view-amount .scroll-content .button.no-margin { + margin: 0; } + #view-amount .scroll-content .notification-warning { + display: block; + padding: .75rem 1.25rem; + color: #856404; + background-color: #fff3cd; + border: 1px solid #ffeeba; + line-height: 1.4em; + margin-bottom: 20px; } + #view-amount .scroll-content .keypad-container { + position: relative; } + #view-amount .scroll-content .keypad-container .keypad { + text-align: center; + font-size: 18px; + font-weight: lighter; + position: absolute; + bottom: 0; + width: 100%; + color: #667; } + @media (min-height: 667px) { + #view-amount .scroll-content .keypad-container .keypad { + font-size: 24px; } } + #view-amount .scroll-content .keypad-container .keypad .row { + padding: 0 !important; + margin: 0 !important; } + #view-amount .scroll-content .keypad-container .keypad .col { + line-height: 38px; } + @media (min-height: 667px) { + #view-amount .scroll-content .keypad-container .keypad .col { + line-height: 45px; } } + #view-amount .scroll-content .keypad-container .keypad .row:last-child .col { + padding-bottom: 10px; } + #view-amount .scroll-content .keypad-container .keypad .operator { + background-color: #f2f2f2; + font-weight: normal; + cursor: pointer; } + #view-amount .scroll-content .keypad-container .keypad .operator:active { + background-color: #9b9bab; } + #view-amount .scroll-content .keypad-container .keypad .operator-send { + font-weight: bolder; + color: #fff; + background-color: #494949; + font-size: 36px; + cursor: pointer; } + #view-amount .scroll-content .keypad-container .keypad .operator-send:active { + background-color: #eaeaea; } + #view-amount .scroll-content .keypad-container .keypad .digit { + cursor: pointer; + border-top: 1px solid #f2f2f2; + border-left: 1px solid #f2f2f2; + transition: all 0.1s ease; } + #view-amount .scroll-content .keypad-container .keypad .digit:active { + background-color: #f2f2f2; } + @media (max-height: 480px) { + #view-amount .scroll-content .keypad-container .keypad { + font-size: 12px; } } + #view-amount ion-content { + margin-bottom: constant(safe-area-inset-bottom); + /* iOS 11.0 */ + margin-bottom: env(safe-area-inset-bottom); + /* iOS 11.2 */ } #view-confirm { - background-color: #ffffff; } + background-color: #494949; } #view-confirm .item-note { float: none; } #view-confirm .item-note .fee-rate { @@ -10622,6 +10701,13 @@ textarea.d-block { margin-top: -3px; } #view-confirm .toggle { cursor: pointer; } + #view-confirm ion-content { + background-color: #ffffff; } + #view-confirm slide-to-accept, #view-confirm slide-to-accept-success { + margin-bottom: constant(safe-area-inset-bottom); + /* iOS 11.0 */ + margin-bottom: env(safe-area-inset-bottom); + /* iOS 11.2 */ } #copayers-invitation .button-share { color: #fff; @@ -10728,6 +10814,8 @@ textarea.d-block { #tab-home .card-banner { padding: 0; } + #tab-home .card-banner svg { + margin: 40px auto 40px; } #tab-home .card-banner__img { width: 100%; display: block; } @@ -10951,123 +11039,154 @@ textarea.d-block { #cordova-plugin-qrscanner-still, #cordova-plugin-qrscanner-video-preview { background-color: #fab915 !important; } -#tab-send .input input { - width: 100%; - height: auto; } +#tab-send-header { + height: 300px; + width: 100%; } -#tab-send .input.item { - height: 55px; } +#tab-send-contacts { + height: calc(100vh - 300px - 50px - 44px); + /* screen size - button container - bottom-tab-menu - header top */ + overflow: scroll; } + #tab-send-contacts.ios { + height: calc(100vh - 300px - 50px - 44px - 18px); } -#tab-send .input i.left { - padding-left: 15px; } +#tab-send .input { + width: 100%; } + #tab-send .input input { + width: 100%; + height: 57px; + background: #FFF; + border: 1px #D9D9D9 solid; } + #tab-send .input input::placeholder { + color: #DCDCDC; } + #tab-send .input i.left { + padding-left: 15px; } + #tab-send .input i.qr { + cursor: pointer; + cursor: hand; + padding-right: 5px; } -#tab-send .input i.qr { - cursor: pointer; - cursor: hand; - padding-right: 5px; } - -#tab-send .qr-scan-icon { - cursor: pointer; - cursor: hand; - border-left: 1px solid #e4e4e4; - padding-left: 10px; } - -#tab-send .qr-icon { - line-height: 20px; } - -#tab-send .zero-state-cta { - padding-bottom: 3vh; - left: 0; } - -#tab-send .send-heading { - font-size: 14px; - font-weight: bold; - padding: 0 0 16px 0; - border: none; } - -#tab-send .send-header-wrapper { - padding: 10px; - background-color: white; - box-shadow: 0px 5px 10px 0px #cccccc; } - -#tab-send .search-wrapper { +#tab-send .send-wrapper { + padding: 18px 9px 9px 9px; background-color: #f2f2f2; border-radius: 3px; border: none; } - #tab-send .search-wrapper .svg#Bitcoin_Symbol { - width: 14px; } - #tab-send .search-wrapper .svg#Bitcoin_Symbol .st0 { - fill: #cccccc; } - #tab-send .search-wrapper.focus { - background: none; } - #tab-send .search-wrapper.focus .svg#Bitcoin_Symbol { - display: none; } - #tab-send .search-wrapper.focus .search-input { - padding-left: 30px; } - #tab-send .search-wrapper.focus .search-input:focus::-webkit-input-placeholder { - opacity: 0; } - -#tab-send .abs-v-center { - position: absolute; - top: 50%; - transform: translateY(-50%); } + #tab-send .send-wrapper:after { + display: block; + position: relative; + height: 1px; + background: #DEDEDE; + bottom: 0; + content: ''; + margin: 10px 6px 0px; } + #tab-send .send-wrapper.focus .search-input { + padding-left: 30px; } + #tab-send .send-wrapper.focus .search-input:focus::-webkit-input-placeholder { + opacity: 0; } + #tab-send .send-wrapper .buttons { + margin: auto; + margin-top: 18px; } + #tab-send .send-wrapper .buttons .button { + height: 60px; + line-height: 16px; + margin-right: 0px; + width: 95%; + max-width: none; + padding: 2px; } + #tab-send .send-wrapper .buttons .button-clipboard-paste { + margin-left: 0; } + #tab-send .send-wrapper .buttons .button-clipboard-paste .address { + display: none; } + #tab-send .send-wrapper .buttons .button-clipboard-paste .icon { + background: url(../img/icon-clipboard-paste.svg); + width: 15px; + height: 19px; + display: inline-block; + margin-bottom: 4px; } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content { + background: #FAB915; + color: #FFF !important; + border: 0; + box-shadow: 0 2px 11px 0 #C1C1C1; } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address .address, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content .address { + display: none; } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address .icon, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content .icon { + background: url(../img/icon-clipboard-paste-white.svg); } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address.contains-address .address, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content.contains-address .address { + display: inline; } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address.contains-address .non-address, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content.contains-address .non-address { + display: none; } + #tab-send .send-wrapper .buttons .button span { + font-size: 14px; } + #tab-send .send-wrapper .buttons .button img { + height: 16px; + width: auto; + margin: 2px 0 4px; } + #tab-send .send-wrapper .buttons .button-qr { + font-weight: bold; + max-width: none; + width: 100%; + height: 95px; + margin-top: 20px; } + #tab-send .send-wrapper .buttons .button-qr img { + vertical-align: middle; + margin-right: 12px; + width: 43px; + height: 43px; } + #tab-send .send-wrapper .buttons .button-qr span { + font-size: 19px; } #tab-send .search-input { background-color: transparent; padding-left: 30px; } -#tab-send .separator-left { - border-left: 1px solid #d9d9df; - padding-left: 10px; - height: 70%; } - -#tab-send .bitcoin-address { - border-top: none; - padding-bottom: .5rem; } - @media (max-width: 480px) { - #tab-send .bitcoin-address input { - font-size: 14px; } } - #tab-send .bitcoin-address .icon { - line-height: 31px; - padding-top: 2px; - padding-bottom: 1px; } - -#tab-send .show-more { - text-align: center; - padding: 20px; - font-size: 16px; - color: #387ef5; - font-weight: bold; } - #tab-send .sendTip { + padding-top: 5vh; text-align: center; } - #tab-send .sendTip > .item-heading { - margin-top: 10px; - background: 0 none; } - #tab-send .sendTip img { - content: url("../img/app/tab-icons/ico-send-selected.svg"); } #tab-send .sendTip .item { border-style: none; } #tab-send .sendTip > .title { font-size: 20px; - font-weight: bold; color: #445; margin: 20px 10px; } #tab-send .sendTip > .subtitle { font-size: 1rem; line-height: 1.5em; font-weight: 300; - color: #445; + color: #6F6F70; margin: 20px 1em 2.5em; } #tab-send .sendTip .big-icon-svg .bg.green { padding: 0 10px; box-shadow: none; } + #tab-send .sendTip .buttons { + margin-top: 18px; } + #tab-send .sendTip .buttons .button { + font-weight: bold; + font-size: 19px; } + #tab-send .sendTip .button-first-contact img { + height: 19px; + width: 19px; + margin-right: 6px; + vertical-align: sub; } + +#tab-send .item-heading { + line-height: 16px; + font-size: 14px; + font-weight: bold; } + #tab-send .item-heading .subtitle { + color: #B5B2B2; + font-size: 12px; + font-weight: 300; } #tab-send .list .item { + font-weight: 600; color: #444; - border-top: none; - padding-top: 1.5rem; - padding-bottom: 1.5rem; } + padding-top: 0.6rem; + padding-bottom: 0.6rem; } + #tab-send .list .item p { + font-weight: normal; } + #tab-send .list .item.item-icon-left { + padding-left: 64px; } #tab-send .list .item .big-icon-svg { left: 5px; } #tab-send .list .item .big-icon-svg > .bg { @@ -11077,7 +11196,7 @@ textarea.d-block { #tab-send .list .item:before { display: block; position: absolute; - width: 80%; + width: 100%; height: 1px; background: rgba(221, 221, 221, 0.3); top: 0; @@ -11096,6 +11215,28 @@ textarea.d-block { #tab-send .scroll { height: 100%; } +#tab-send .card.contacts { + margin: 4px 4px 16px 4px; + border-radius: 6px; + box-shadow: 0px 2px 1px 0 #C1C1C1; } + #tab-send .card.contacts .gravatar { + border-radius: 30px; + height: 40px; + width: 40px; } + +@media only screen and (min-device-width: 320px) and (max-device-width: 568px) { + #tab-send .send-wrapper .buttons .button-qr { + height: 60px; } + #tab-send .send-wrapper .buttons .button-qr span { + font-size: 16px; } + #tab-send #tab-send-header { + height: 270px; } + #tab-send #tab-send-contacts { + height: calc(100vh - 270px - 50px - 44px); + /* screen size - button container - bottom-tab-menu - header top */ } + #tab-send #tab-send-contacts.ios { + height: calc(100vh - 270px - 50px - 44px - 18px); } } + .settings .icon-bitpay { background-image: url("../img/icon-bitpay.svg"); } @@ -11604,7 +11745,8 @@ textarea.d-block { fill: white; } #walletDetails .bp-content { position: relative; - height: 100%; } + height: 100%; + height: calc(100% - env(safe-area-inset-bottom) * 2); } #walletDetails .bp-content.status-bar { margin-top: 20px; } #walletDetails .bar-header { @@ -11618,7 +11760,8 @@ textarea.d-block { background-color: inherit !important; } #walletDetails ion-content { padding-top: 0; - top: 0; } + top: 0; + margin-bottom: 16px; } #walletDetails ion-content.collapsible { margin-top: 210px; } #walletDetails ion-content .scroll { @@ -12211,7 +12354,6 @@ a.item { position: relative; height: 70px; border-color: #fab915; - background-color: #fab915; padding-top: 20px; margin-bottom: 50px; text-align: center; } @@ -13013,74 +13155,13 @@ a.item { .onboarding-illustration-backup-warning { background-image: url(../img/app/backup-warning.svg); } -#rate-card .item-heading { - font-weight: 700; } - -#rate-card .row { - border: none; } - -#rate-card .item-icon-right { - margin: 0; } - -#rate-card .feedback-flow-button { - margin-bottom: 20px; } - -#rate-card .icon-svg > img { - height: 1.8rem; - margin-bottom: 5px; } - -#send-feedback { - background-color: #ffffff; } - #send-feedback .row { - border: none; } - #send-feedback .skip { - color: rgba(255, 255, 255, 0.3); } - #send-feedback .feedback-heading { - padding-top: 20px; } - #send-feedback .feedback-title { - padding-left: 10px; - font-size: 20px; - font-weight: bold; - color: #445; } - #send-feedback .rating { - text-align: right; - padding-right: 15px; } - #send-feedback .comment { - padding: 0 20px 20px; - font-size: 1rem; - line-height: 1.5em; - font-weight: 300; - color: #445; } - #send-feedback .user-feedback { - border-top: 1px solid #f2f2f2; - border-bottom: 1px solid #f2f2f2; - padding: 20px; - width: 100%; - margin-bottom: 20px; - -webkit-appearance: none; } - #send-feedback .send-feedback-star { - height: 1rem; - margin-left: 5px; } - #send-feedback .form-fade-in { - opacity: 0; - animation-name: fadeIn; - animation-duration: .5s; - animation-fill-mode: forwards; - animation-timing-function: ease-in; } - -@keyframes fadeIn { - from { - opacity: 0; } - to { - opacity: 1; } } - -#complete { +#share-app { background-color: #fff; } - #complete .complete-layout { + #share-app .share-app-layout { display: flex; flex-direction: column; height: 100%; } - #complete .complete-layout__expand { + #share-app .share-app-layout__expand { display: flex; flex-direction: column; flex-grow: 1; @@ -13089,36 +13170,27 @@ a.item { text-align: center; opacity: 0; transition: opacity .3s; } - #complete .complete-layout__expand.fade-in { + #share-app .share-app-layout__expand.fade-in { opacity: 1; } - #complete .share-the-love-illustration { + #share-app .share-the-love-illustration { width: 5rem; margin: 1rem; } - #complete .send-feedback-illustration { - height: 16rem; - margin: 1rem; } - #complete .feedback-title { - font-size: 20px; - font-weight: bold; - color: #445; - margin: 20px 10px; - text-align: center; } - #complete .subtitle { + #share-app .subtitle { padding: 10px 30px 20px; text-align: center; color: #667; } - #complete .icon-svg > img { + #share-app .icon-svg > img { height: 16rem; width: 16rem; margin: 10px; } - #complete .socialsharing-icon { + #share-app .socialsharing-icon { display: inline-block; width: 60px; } - #complete .addressbook-icon-svg { + #share-app .addressbook-icon-svg { display: inline-block; width: 50px; height: 50px; } - #complete .share-buttons { + #share-app .share-buttons { padding: 50px 10px 30px; background-color: #f2f2f2; text-align: center; @@ -13130,7 +13202,7 @@ a.item { animation-fill-mode: forwards; animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1); animation-delay: .2s; } - #complete .share-buttons__action { + #share-app .share-buttons__action { display: inline-block; color: #667; font-size: .9rem; @@ -13148,38 +13220,6 @@ a.item { transform: translateY(0); opacity: 1; } } -#rate-app { - background-color: #ffffff; - text-align: center; } - #rate-app .skip-rating { - color: #445; - position: absolute; - top: 5px; - right: 10px; - padding: 15px; } - #rate-app .icon-svg > img { - width: 80px; - height: 80px; - margin-top: 15px; } - #rate-app .feedback-title { - font-size: 20px; - font-weight: bold; - color: #445; - margin: 80px 50px 10px; - text-align: center; } - #rate-app .share-the-love-illustration { - width: 5rem; - margin: 1rem; } - #rate-app .subtitle { - padding: 10px 30px 20px 40px; - color: #667; } - #rate-app .rate-buttons { - bottom: 0; - width: 100%; - position: absolute; - background-color: #f2f2f2; - padding: 30px 0 15px; } - action-sheet .bp-action-sheet__sheet { background: #fff; width: calc(100% + 1px); @@ -13800,7 +13840,11 @@ slide-to-accept-success { transform: translateY(5rem); opacity: 0; transition: transform 400ms ease, opacity 400ms ease; - transition-delay: 250ms; } + transition-delay: 250ms; + margin-bottom: constant(safe-area-inset-bottom); + /* iOS 11.0 */ + margin-bottom: env(safe-area-inset-bottom); + /* iOS 11.2 */ } slide-to-accept-success .slide-success__footer.reveal { -webkit-transform: translateY(0); transform: translateY(0); @@ -13858,16 +13902,16 @@ slide-to-accept-success { line-height: 30px; } #txp-details .head .amount-label .amount, #view-confirm .head .amount-label .amount { - font-size: 38px; - margin-bottom: .5rem; } - #txp-details .head .amount-label .amount > .unit, - #view-confirm .head .amount-label .amount > .unit { - font-family: "Roboto-Light"; } + font-size: 16px; + color: #9B9B9B; + font-family: "Roboto-Light"; } #txp-details .head .amount-label .alternative, #view-confirm .head .amount-label .alternative { - font-size: 16px; - font-family: "Roboto-Light"; - color: #9B9B9B; } + font-size: 38px; + margin-bottom: .5rem; } + #txp-details .head .amount-label .alternative > .unit, + #view-confirm .head .amount-label .alternative > .unit { + font-family: "Roboto-Light"; } #txp-details .item, #view-confirm .item { border-color: #EFEFEF; } @@ -14155,6 +14199,10 @@ wallet-selector .subheader { font-weight: bold; padding-bottom: 10px; border-bottom: 1px solid #EFEFEF; } + wallet-selector .subheader .subtitle { + color: #667; + font-size: 12px; + font-weight: 300; } wallet-selector .subheader .wallet-coin-logo { vertical-align: middle; margin-right: 5px; } diff --git a/www/index.html b/www/index.html index 4c73317e3..ecc2d923c 100644 --- a/www/index.html +++ b/www/index.html @@ -11,9 +11,8 @@ - Bitcoin.com Wallet - Bitcoin.com Wallet - - + Bitcoin.com Wallet + @@ -31,7 +30,7 @@ - + diff --git a/www/views/review.html b/www/views/review.html new file mode 100644 index 000000000..d68eca05b --- /dev/null +++ b/www/views/review.html @@ -0,0 +1,45 @@ + + + + {{'Review'|translate}} + + + + + + + Review + + + {{buttonText}} + + + {{buttonText}} + + + Payment Sent + Proposal Created + Transaction Created + + + + + + From 155ea281d8ede8cc8c619a339aa4d389684e5431 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Wed, 18 Jul 2018 17:24:13 +0800 Subject: [PATCH 102/386] Adds header component --- src/sass/components/components.scss | 1 + src/sass/components/header.scss | 36 +++++++++++++++++++++++++++++ src/sass/main.scss | 1 + www/css/main.css | 24 +++++++++++++++++++ www/views/review.html | 8 ++++++- 5 files changed, 69 insertions(+), 1 deletion(-) create mode 100644 src/sass/components/components.scss create mode 100644 src/sass/components/header.scss diff --git a/src/sass/components/components.scss b/src/sass/components/components.scss new file mode 100644 index 000000000..833f565dd --- /dev/null +++ b/src/sass/components/components.scss @@ -0,0 +1 @@ +@import "header"; diff --git a/src/sass/components/header.scss b/src/sass/components/header.scss new file mode 100644 index 000000000..1c178dd07 --- /dev/null +++ b/src/sass/components/header.scss @@ -0,0 +1,36 @@ +.header { + padding: 29px 12px 65px; + background-color: #FAB915; + color: #FFFFFF; + + .title { + font-size: 18px; + font-weight: 400; + line-height: 1em; + color: #FFFFFF; + text-align: center; + + + .content { + margin-top: 23px; + } + } + + .content { + text-align: center; + + p { + margin: 0; + line-height: 1em; + font-size: 18px; + + &.large { + font-size: 29px; + font-weight: 600; + } + + + p { + margin-top: 8px; + } + } + } +} \ No newline at end of file diff --git a/src/sass/main.scss b/src/sass/main.scss index 7b3e46291..516656449 100644 --- a/src/sass/main.scss +++ b/src/sass/main.scss @@ -9,4 +9,5 @@ @import "mixins/mixins"; @import "views/views"; @import "directives/directives"; +@import "components/components"; @import "shame"; diff --git a/www/css/main.css b/www/css/main.css index a87bc4be9..2e2726888 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -15066,6 +15066,30 @@ log-options #check-bar .checkbox-icon { border-radius: 3px; display: inline-block; } +.header { + padding: 29px 12px 65px; + background-color: #FAB915; + color: #FFFFFF; } + .header .title { + font-size: 18px; + font-weight: 400; + line-height: 1em; + color: #FFFFFF; + text-align: center; } + .header .title + .content { + margin-top: 23px; } + .header .content { + text-align: center; } + .header .content p { + margin: 0; + line-height: 1em; + font-size: 18px; } + .header .content p.large { + font-size: 29px; + font-weight: 600; } + .header .content p + p { + margin-top: 8px; } + /* This is for rules that don't yet have a home. * Our goal is to delete this file. Search the regex: /class=".*CLASS.*?"/ */ diff --git a/www/views/review.html b/www/views/review.html index d68eca05b..cc57c79b8 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -8,7 +8,13 @@ - Review +
+

You are sending

+
+

13.98 USD

+

0.014 BCH

+
+
Date: Wed, 18 Jul 2018 11:29:03 +0200 Subject: [PATCH 103/386] price display translation --- i18n/po/template.pot | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index a23e5dbae..df01cecec 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -197,6 +197,10 @@ msgstr "" msgid "Alternative Currency" msgstr "" +#: www/views/tab-settings.html:75 +msgid "Price Display" +msgstr "" + #: src/js/controllers/buyAmazon.js:98 msgid "Amazon.com is not available at this moment. Please try back later." msgstr "" From b8bab036e6e2b7f1008e050ea762e9a65a6e7613 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 18 Jul 2018 11:54:41 +0200 Subject: [PATCH 104/386] wallet to wallet transfer views + css --- .../controllers/walletToWalletController.js | 14 ++++++ src/js/routes.js | 9 ++++ src/sass/views/views.scss | 1 + src/sass/views/wallet-to-wallet-transfer.scss | 18 ++++++++ www/views/tab-send.html | 2 +- www/views/wallet-to-wallet-transfer.html | 43 +++++++++++++++++++ 6 files changed, 86 insertions(+), 1 deletion(-) create mode 100644 src/js/controllers/walletToWalletController.js create mode 100644 src/sass/views/wallet-to-wallet-transfer.scss create mode 100644 www/views/wallet-to-wallet-transfer.html diff --git a/src/js/controllers/walletToWalletController.js b/src/js/controllers/walletToWalletController.js new file mode 100644 index 000000000..7cb467b67 --- /dev/null +++ b/src/js/controllers/walletToWalletController.js @@ -0,0 +1,14 @@ +'use strict'; + +angular.module('copayApp.controllers').controller('walletToWalletController', function($scope, $rootScope, $log, profileService, configService) { + + $scope.$on("$ionicView.enter", function(event, data) { + $scope.walletsBch = profileService.getWallets({coin: 'bch'}); + $scope.walletsBtc = profileService.getWallets({coin: 'btc'}); + configService.whenAvailable(function(config) { + $scope.selectedPriceDisplay = config.wallet.settings.priceDisplay; + }); + }); + + +}); \ No newline at end of file diff --git a/src/js/routes.js b/src/js/routes.js index 8277314e5..72397d872 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -295,6 +295,15 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } } }) + .state('tabs.send.wallet-to-wallet', { + url: '/wallet-to-wallet', + views: { + 'tab-send@tabs': { + controller: 'walletToWalletController', + templateUrl: 'views/wallet-to-wallet-transfer.html' + } + } + }) .state('tabs.send.confirm', { url: '/confirm/:recipientType/:toAddress/:toName/:toAmount/:toEmail/:toColor/:description/:coin/:useSendMax/:fromWalletId/:displayAddress/:requiredFeeRate', views: { diff --git a/src/sass/views/views.scss b/src/sass/views/views.scss index d4ed735ed..538787901 100644 --- a/src/sass/views/views.scss +++ b/src/sass/views/views.scss @@ -8,6 +8,7 @@ @import "tab-receive"; @import "tab-scan"; @import "tab-send"; +@import "wallet-to-wallet-transfer"; @import "tab-settings"; @import "wallet-colors"; @import "walletBalance"; diff --git a/src/sass/views/wallet-to-wallet-transfer.scss b/src/sass/views/wallet-to-wallet-transfer.scss new file mode 100644 index 000000000..e909258cf --- /dev/null +++ b/src/sass/views/wallet-to-wallet-transfer.scss @@ -0,0 +1,18 @@ +#wallet-to-wallet-transfer { + .header, .list { + font-size: 12px; + margin: 20px 14px; + + .title { + font-size: 20px; + font-weight: bold; + color: $v-dark-gray; + } + .subtitle { + font-size: 12px; + line-height: 1.5em; + font-weight: 300; + color: $v-dark-gray; + } + } +} \ No newline at end of file diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 8b39808db..b5d556214 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -22,7 +22,7 @@
- diff --git a/www/views/wallet-to-wallet-transfer.html b/www/views/wallet-to-wallet-transfer.html new file mode 100644 index 000000000..2eb2bcb11 --- /dev/null +++ b/www/views/wallet-to-wallet-transfer.html @@ -0,0 +1,43 @@ + + + {{'Wallet to wallet transfer' | translate}} + + +
+
+ Choose your origin wallet +
+
+ This is where the Bitcoin will be taken out from. +
+
+
+
+
Bitcoin Cash (BCH)
+
Instant transactions with low fees
+ +
+
+ + + +
+
+ +
+
+
Bitcoin Core (BTC)
+ +
+
+ + + +
+
+
+
\ No newline at end of file From 450b80b03fd6ab9701a481b383cedeadd658cdd4 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 18 Jul 2018 16:30:54 +0200 Subject: [PATCH 105/386] send/receive buttons on walletDetails + currencySymbolService --- src/js/controllers/walletDetails.js | 24 ++- src/js/services/currencySymbolService.js | 194 +++++++++++++++++++++++ src/sass/shame.scss | 4 + src/sass/views/walletDetails.scss | 24 ++- www/views/tab-home.html | 26 +-- www/views/walletDetails.html | 42 +++-- 6 files changed, 280 insertions(+), 34 deletions(-) create mode 100644 src/js/services/currencySymbolService.js diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index 24237f6c9..24e4a5a20 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('walletDetailsController', function($scope, $rootScope, $interval, $timeout, $filter, $log, $ionicModal, $ionicPopover, $state, $stateParams, $ionicHistory, profileService, lodash, configService, platformInfo, walletService, txpModalService, externalLinkService, popupService, addressbookService, storageService, $ionicScrollDelegate, $window, bwcError, gettextCatalog, timeService, feeService, appConfigService, rateService) { +angular.module('copayApp.controllers').controller('walletDetailsController', function($scope, $rootScope, $interval, $timeout, $filter, $log, $ionicModal, $ionicPopover, $state, $stateParams, $ionicHistory, profileService, lodash, configService, currencySymbolService, platformInfo, walletService, txpModalService, externalLinkService, popupService, addressbookService, storageService, $ionicScrollDelegate, $window, bwcError, gettextCatalog, timeService, feeService, appConfigService, rateService) { var HISTORY_SHOW_LIMIT = 10; var currentTxHistoryPage = 0; @@ -12,6 +12,13 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun $scope.isAndroid = platformInfo.isAndroid; $scope.isIOS = platformInfo.isIOS; + $scope.currencySymbols = { + 'EUR': '€', + 'GBP': '£', + 'USD': '$', + 'YEN' : '' + }; + var channel = "firebase"; if (platformInfo.isNW) { channel = "ga"; @@ -256,6 +263,11 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun return !tx.confirmations || tx.confirmations === 0; }; + $scope.currencySymbol = function(code) { + var symbol = currencySymbolService.getCurrencySymbol(code); + return symbol?symbol:""; + }; + $scope.showMore = function() { $timeout(function() { currentTxHistoryPage++; @@ -315,16 +327,16 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun } scrollPos = scrollPos || 0; - var amountHeight = 210 - scrollPos; + var amountHeight = 230 - scrollPos; if (amountHeight < 80) { amountHeight = 80; } var contentMargin = amountHeight; - if (contentMargin > 210) { - contentMargin = 210; + if (contentMargin > 230) { + contentMargin = 230; } - var amountScale = (amountHeight / 210); + var amountScale = (amountHeight / 230); if (amountScale < 0.5) { amountScale = 0.5; } @@ -342,7 +354,7 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun top = TOP_BALANCE_BUTTON; } - var amountTop = ((amountScale - 0.7) / 0.7) * top; + var amountTop = ((amountScale - 0.85) / 0.85) * top; if (amountTop < -10) { amountTop = -10; } diff --git a/src/js/services/currencySymbolService.js b/src/js/services/currencySymbolService.js new file mode 100644 index 000000000..b4cf0c2ac --- /dev/null +++ b/src/js/services/currencySymbolService.js @@ -0,0 +1,194 @@ +'use strict'; + +angular.module('copayApp.services').factory('currencySymbolService', function($log) { + var root = {}; + root.currencySymbols = { + 'AED': 'د.إ', + 'AFN': '؋', + 'ALL': 'L', + 'AMD': '֏', + 'ANG': 'ƒ', + 'AOA': 'Kz', + 'ARS': '$', + 'AUD': '$', + 'AWG': 'ƒ', + 'AZN': '₼', + 'BAM': 'KM', + 'BBD': '$', + 'BDT': '৳', + 'BGN': 'лв', + 'BHD': '.د.ب', + 'BIF': 'FBu', + 'BMD': '$', + 'BND': '$', + 'BOB': '$b', + 'BRL': 'R$', + 'BSD': '$', + 'BTC': '฿', + 'BTN': 'Nu.', + 'BWP': 'P', + 'BYR': 'Br', + 'BYN': 'Br', + 'BZD': 'BZ$', + 'CAD': '$', + 'CDF': 'FC', + 'CHF': 'CHF', + 'CLP': '$', + 'CNY': '¥', + 'COP': '$', + 'CRC': '₡', + 'CUC': '$', + 'CUP': '₱', + 'CVE': '$', + 'CZK': 'Kč', + 'DJF': 'Fdj', + 'DKK': 'kr', + 'DOP': 'RD$', + 'DZD': 'دج', + 'EEK': 'kr', + 'EGP': '£', + 'ERN': 'Nfk', + 'ETB': 'Br', + 'ETH': 'Ξ', + 'EUR': '€', + 'FJD': '$', + 'FKP': '£', + 'GBP': '£', + 'GEL': '₾', + 'GGP': '£', + 'GHC': '₵', + 'GHS': 'GH₵', + 'GIP': '£', + 'GMD': 'D', + 'GNF': 'FG', + 'GTQ': 'Q', + 'GYD': '$', + 'HKD': '$', + 'HNL': 'L', + 'HRK': 'kn', + 'HTG': 'G', + 'HUF': 'Ft', + 'IDR': 'Rp', + 'ILS': '₪', + 'IMP': '£', + 'INR': '₹', + 'IQD': 'ع.د', + 'IRR': '﷼', + 'ISK': 'kr', + 'JEP': '£', + 'JMD': 'J$', + 'JOD': 'JD', + 'JPY': '¥', + 'KES': 'KSh', + 'KGS': 'лв', + 'KHR': '៛', + 'KMF': 'CF', + 'KPW': '₩', + 'KRW': '₩', + 'KWD': 'KD', + 'KYD': '$', + 'KZT': 'лв', + 'LAK': '₭', + 'LBP': '£', + 'LKR': '₨', + 'LRD': '$', + 'LSL': 'M', + 'LTC': 'Ł', + 'LTL': 'Lt', + 'LVL': 'Ls', + 'LYD': 'LD', + 'MAD': 'MAD', + 'MDL': 'lei', + 'MGA': 'Ar', + 'MKD': 'ден', + 'MMK': 'K', + 'MNT': '₮', + 'MOP': 'MOP$', + 'MRO': 'UM', + 'MRU': 'UM', + 'MUR': '₨', + 'MVR': 'Rf', + 'MWK': 'MK', + 'MXN': '$', + 'MYR': 'RM', + 'MZN': 'MT', + 'NAD': '$', + 'NGN': '₦', + 'NIO': 'C$', + 'NOK': 'kr', + 'NPR': '₨', + 'NZD': '$', + 'OMR': '﷼', + 'PAB': 'B/.', + 'PEN': 'S/.', + 'PGK': 'K', + 'PHP': '₱', + 'PKR': '₨', + 'PLN': 'zł', + 'PYG': 'Gs', + 'QAR': '﷼', + 'RMB': '¥', + 'RON': 'lei', + 'RSD': 'Дин.', + 'RUB': '₽', + 'RWF': 'R₣', + 'SAR': '﷼', + 'SBD': '$', + 'SCR': '₨', + 'SDG': 'ج.س.', + 'SEK': 'kr', + 'SGD': '$', + 'SHP': '£', + 'SLL': 'Le', + 'SOS': 'S', + 'SRD': '$', + 'SSP': '£', + 'STD': 'Db', + 'STN': 'Db', + 'SVC': '$', + 'SYP': '£', + 'SZL': 'E', + 'THB': '฿', + 'TJS': 'SM', + 'TMT': 'T', + 'TND': 'د.ت', + 'TOP': 'T$', + 'TRL': '₤', + 'TRY': '₺', + 'TTD': 'TT$', + 'TVD': '$', + 'TWD': 'NT$', + 'TZS': 'TSh', + 'UAH': '₴', + 'UGX': 'USh', + 'USD': '$', + 'UYU': '$U', + 'UZS': 'лв', + 'VEF': 'Bs', + 'VND': '₫', + 'VUV': 'VT', + 'WST': 'WS$', + 'XAF': 'FCFA', + 'XBT': 'Ƀ', + 'XCD': '$', + 'XOF': 'CFA', + 'XPF': '₣', + 'YER': '﷼', + 'ZAR': 'R', + 'ZWD': 'Z$' + }; + + root.getCurrencySymbol = function(code) { + code = code.toUpperCase(); + + if (root.currencySymbols[code]) { + $log.debug("Currency symbol for "+code+" found"); + return root.currencySymbols[code]; + } + $log.debug("Currency symbol for "+code+" not found"); + return false; + }; + + return root; + +}); \ No newline at end of file diff --git a/src/sass/shame.scss b/src/sass/shame.scss index 07ac2dedf..5a17c5f1f 100644 --- a/src/sass/shame.scss +++ b/src/sass/shame.scss @@ -233,6 +233,10 @@ input[type=number] { font-size: 24px; } +.size-25 { + font-size: 25px; +} + .size-28 { font-size: 28px; } diff --git a/src/sass/views/walletDetails.scss b/src/sass/views/walletDetails.scss index 9e651f871..2d1aa1343 100644 --- a/src/sass/views/walletDetails.scss +++ b/src/sass/views/walletDetails.scss @@ -153,7 +153,7 @@ ion-content { &.collapsible { - margin-top: 210px; + margin-top: 230px; } padding-top: 0; @@ -190,12 +190,32 @@ transform: translateY(100px); } } + + .buttons { + margin-bottom: 0; + margin-top: 6px; + >.col { + padding: 5px 10px; + margin-bottom: 0; + } + .button { + border: 2px solid; + border-radius: 47px; + padding: 0 15px 0 15px; + text-align: center; + width: 100%; + font-size: 19px; + font-weight: bolder; + min-height: 45px; + line-height: 45px; + } + } } .amount { width: 100%; text-align: center; color: #fff; - height: 210px; + height: 230px; padding-top: 40px; display: block; align-items: center; diff --git a/www/views/tab-home.html b/www/views/tab-home.html index 85b7692f7..618f2e128 100644 --- a/www/views/tab-home.html +++ b/www/views/tab-home.html @@ -23,20 +23,22 @@
-
-
- Receive -
-
-
-
- Buy Bitcoin -
-
- Send -
+
+
+ Receive
+
+
+ Buy Bitcoin +
+
+ Send +
+
+
diff --git a/www/views/walletDetails.html b/www/views/walletDetails.html index 0f9e4961c..820930a95 100644 --- a/www/views/walletDetails.html +++ b/www/views/walletDetails.html @@ -34,7 +34,7 @@ on-hold="hideToggle()" ng-style="{'transform': amountScale}" ng-class="{amount__balance: amountIsCollapsible}"> - {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}} + {{currencySymbol(status.alternativeIsoCode)}} {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}}
- {{status.totalBalanceStr}} + {{status.totalBalanceStr}}
- {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}} + {{currencySymbol(status.alternativeIsoCode)}} {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}}
@@ -86,11 +86,25 @@   - {{status.spendableBalanceAlternative}} {{status.alternativeIsoCode}} + {{currencySymbol(status.alternativeIsoCode)}} {{status.spendableBalanceAlternative}} {{status.alternativeIsoCode}}
- +
+
+
+ Receive +
+
+
+
+ Buy Bitcoin +
+
+ Send +
+
+
@@ -127,12 +141,12 @@ on-hold="hideToggle()" ng-style="{'transform': amountScale}" ng-class="{amount__balance: amountIsCollapsible}"> - {{status.totalBalanceStr}} + {{status.totalBalanceStr}}
- {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}} + {{currencySymbol(status.alternativeIsoCode)}} {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}}
@@ -142,9 +156,9 @@ on-hold="hideToggle()" ng-style="{'transform': amountScale}" ng-class="{amount__balance: amountIsCollapsible}"> - {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}} + {{currencySymbol(status.alternativeIsoCode)}} {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}}
{{status.totalBalanceStr}} @@ -156,7 +170,7 @@ ng-show="!updateStatusError && wallet.balanceHidden && !wallet.scanning" on-hold="hideToggle()"> [Balance Hidden] -
+
Tap and hold to show
@@ -166,7 +180,7 @@ class="amount__balance" ng-show="!updateStatusError && wallet.scanning"> [Scanning Funds] -
+
Please wait
@@ -180,7 +194,7 @@   - {{status.spendableBalanceAlternative}} {{status.alternativeIsoCode}} + {{currencySymbol(status.alternativeIsoCode)}} {{status.spendableBalanceAlternative}} {{status.alternativeIsoCode}}
@@ -189,7 +203,7 @@
From 46906352e5c1d4bab852192e14af7b2cbdc77c60 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 18 Jul 2018 16:47:15 +0200 Subject: [PATCH 106/386] remove "add wallet" buttons --- www/views/wallet-to-wallet-transfer.html | 2 -- 1 file changed, 2 deletions(-) diff --git a/www/views/wallet-to-wallet-transfer.html b/www/views/wallet-to-wallet-transfer.html index 2eb2bcb11..68a61fe2d 100644 --- a/www/views/wallet-to-wallet-transfer.html +++ b/www/views/wallet-to-wallet-transfer.html @@ -15,7 +15,6 @@
Bitcoin Cash (BCH)
Instant transactions with low fees
-
Date: Wed, 18 Jul 2018 16:48:57 +0200 Subject: [PATCH 107/386] wallet selection stub --- src/js/controllers/walletToWalletController.js | 3 +++ www/views/wallet-to-wallet-transfer.html | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/walletToWalletController.js b/src/js/controllers/walletToWalletController.js index 7cb467b67..77d2218e6 100644 --- a/src/js/controllers/walletToWalletController.js +++ b/src/js/controllers/walletToWalletController.js @@ -10,5 +10,8 @@ angular.module('copayApp.controllers').controller('walletToWalletController', fu }); }); + $scope.useWallet = function(wallet) { + // Do something with selected wallet + }; }); \ No newline at end of file diff --git a/www/views/wallet-to-wallet-transfer.html b/www/views/wallet-to-wallet-transfer.html index 68a61fe2d..f172f40da 100644 --- a/www/views/wallet-to-wallet-transfer.html +++ b/www/views/wallet-to-wallet-transfer.html @@ -19,7 +19,7 @@ From 3cedfa5146d0e732f66eb21ef48ada651f625286 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 19 Jul 2018 12:19:08 +1200 Subject: [PATCH 108/386] Added $scope.fundsAreInsufficient for triggering UI. --- src/js/controllers/amount.js | 52 +++++++++++++++++++++++++++++++----- 1 file changed, 46 insertions(+), 6 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 1c91baf97..3d8422447 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -7,6 +7,8 @@ angular.module('copayApp.controllers').controller('amountController', function($ var satToUnit; var unitDecimals; var satToBtc; + var spendableAmountInSatoshis = null; + var SMALL_FONT_SIZE_LIMIT = 10; var LENGTH_EXPRESSION_LIMIT = 19; var LENGTH_BEFORE_COMMA_EXPRESSION_LIMIT = 8; @@ -22,6 +24,10 @@ angular.module('copayApp.controllers').controller('amountController', function($ $scope.amountModel = { amount: 0 }; + // Use insufficient for logic, as when the amount is invalid, funds being + // either sufficent or insufficient doesn't make sense. + $scope.fundsAreInsufficient = false; + $scope.isChromeApp = platformInfo.isChromeApp; $scope.isAndroid = platformInfo.isAndroid; $scope.isIos = platformInfo.isIOS; @@ -134,6 +140,12 @@ angular.module('copayApp.controllers').controller('amountController', function($ }); altUnitIndex = 0; + + if ($scope.fromWalletId) { + var fromWallet = profileService.getWallet($scope.fromWalletId); + console.log('got fromWallet.'); + updateSpendableAmountInSatoshisFromWallet(fromWallet); + } }; // Go to... @@ -387,24 +399,41 @@ angular.module('copayApp.controllers').controller('amountController', function($ var a = fromFiat(result); if (a) { - $scope.alternativeAmount = txFormatService.formatAmount(a * unitToSatoshi, true); - $scope.allowSend = lodash.isNumber(a) && a > 0 + var amountInSatoshis = a * unitToSatoshi; + $scope.fundsAreInsufficient = !!$scope.fromWalletId + && spendableAmountInSatoshis !== null + && spendableAmountInSatoshis < amountInSatoshis; + + $scope.alternativeAmount = txFormatService.formatAmount(amountInSatoshis, true); + $scope.allowSend = lodash.isNumber(a) + && a > 0 && (!$scope.shapeshiftOrderId - || (a >= $scope.minShapeshiftAmount && a <= $scope.maxShapeshiftAmount)); + || (a >= $scope.minShapeshiftAmount && a <= $scope.maxShapeshiftAmount)) + && !$scope.fundsAreInsufficient; } else { if (result) { $scope.alternativeAmount = 'N/A'; } else { $scope.alternativeAmount = null; } + $scope.fundsAreInsufficient = false; $scope.allowSend = false; } } else { + $scope.fundsAreInsufficient = !!$scope.fromWalletId + && spendableAmountInSatoshis !== null + && spendableAmountInSatoshis < result * unitToSatoshi; + $scope.alternativeAmount = $filter('formatFiatAmount')(toFiat(result)); - $scope.allowSend = lodash.isNumber(result) && result > 0 + $scope.allowSend = lodash.isNumber(result) + && result > 0 && (!$scope.shapeshiftOrderId - || (result >= $scope.minShapeshiftAmount && result <= $scope.maxShapeshiftAmount)); + || (result >= $scope.minShapeshiftAmount && result <= $scope.maxShapeshiftAmount)) + && !$scope.fundsAreInsufficient; } + + } else { + $scope.fundsAreInsufficient = false; } }; @@ -584,6 +613,7 @@ angular.module('copayApp.controllers').controller('amountController', function($ $timeout(function() { $scope.$apply(); }); + rateService.updateRates(); }); } @@ -632,5 +662,15 @@ angular.module('copayApp.controllers').controller('amountController', function($ updateUnitUI(); $scope.close(); }); - }; + }; + + function updateSpendableAmountInSatoshisFromWallet(wallet) { + if (wallet.status) { + spendableAmountInSatoshis = wallet.status.spendableAmount; + } else if (fromWallet.cachedStatus) { + spendableAmountInSatoshis = wallet.cachedStatus.spendableAmount; + } else { + spendableAmountInSatoshis = null; + } + } }); From 61f1603bbffb90bd7661a31990821af9b77a1e13 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 19 Jul 2018 12:52:37 +1200 Subject: [PATCH 109/386] Added $scope.availableFunds. --- src/js/controllers/amount.js | 51 +++++++++++++++++++++++++++--------- 1 file changed, 39 insertions(+), 12 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 3d8422447..1ea8f3104 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -3,11 +3,14 @@ angular.module('copayApp.controllers').controller('amountController', function($scope, $filter, $timeout, $ionicModal, $ionicScrollDelegate, $ionicHistory, walletService, gettextCatalog, platformInfo, lodash, configService, rateService, $stateParams, $window, $state, $log, txFormatService, ongoingProcess, popupService, profileService, nodeWebkitService) { var _id; + var availableFundsInCrypto = ''; + var availableFundsInFiat = ''; + var availableSatoshis = null; var unitToSatoshi; var satToUnit; var unitDecimals; var satToBtc; - var spendableAmountInSatoshis = null; + var SMALL_FONT_SIZE_LIMIT = 10; var LENGTH_EXPRESSION_LIMIT = 19; @@ -23,6 +26,8 @@ angular.module('copayApp.controllers').controller('amountController', function($ var fixedUnit; $scope.amountModel = { amount: 0 }; + $scope.availableFunds = ''; + // Use insufficient for logic, as when the amount is invalid, funds being // either sufficent or insufficient doesn't make sense. @@ -143,8 +148,7 @@ angular.module('copayApp.controllers').controller('amountController', function($ if ($scope.fromWalletId) { var fromWallet = profileService.getWallet($scope.fromWalletId); - console.log('got fromWallet.'); - updateSpendableAmountInSatoshisFromWallet(fromWallet); + updateAvailableFundsFromWallet(fromWallet); } }; @@ -281,12 +285,15 @@ angular.module('copayApp.controllers').controller('amountController', function($ if (availableUnits[unitIndex].isFiat) { altUnitIndex = altUnitIndex == 0 && availableUnits.length > 2 ? 1 : 0; + $scope.availableFunds = availableFundsInFiat || availableFundsInCrypto; } else { altUnitIndex = lodash.findIndex(availableUnits, { isFiat: true }); + $scope.availableFunds = availableFundsInCrypto; } + console.log('availableFunds: ' + $scope.availableFunds); updateUnitUI(); }; @@ -401,8 +408,8 @@ angular.module('copayApp.controllers').controller('amountController', function($ if (a) { var amountInSatoshis = a * unitToSatoshi; $scope.fundsAreInsufficient = !!$scope.fromWalletId - && spendableAmountInSatoshis !== null - && spendableAmountInSatoshis < amountInSatoshis; + && availableSatoshis !== null + && availableSatoshis < amountInSatoshis; $scope.alternativeAmount = txFormatService.formatAmount(amountInSatoshis, true); $scope.allowSend = lodash.isNumber(a) @@ -421,8 +428,8 @@ angular.module('copayApp.controllers').controller('amountController', function($ } } else { $scope.fundsAreInsufficient = !!$scope.fromWalletId - && spendableAmountInSatoshis !== null - && spendableAmountInSatoshis < result * unitToSatoshi; + && availableSatoshis !== null + && availableSatoshis < result * unitToSatoshi; $scope.alternativeAmount = $filter('formatFiatAmount')(toFiat(result)); $scope.allowSend = lodash.isNumber(result) @@ -664,13 +671,33 @@ angular.module('copayApp.controllers').controller('amountController', function($ }); }; - function updateSpendableAmountInSatoshisFromWallet(wallet) { + function updateAvailableFundsFromWallet(wallet) { if (wallet.status) { - spendableAmountInSatoshis = wallet.status.spendableAmount; - } else if (fromWallet.cachedStatus) { - spendableAmountInSatoshis = wallet.cachedStatus.spendableAmount; + availableFundsInCrypto = wallet.status.spendableBalanceStr; + availableSatoshis = wallet.status.spendableAmount; + if (wallet.status.alternativeBalanceAvailable) { + availableFundsInFiat = wallet.status.spendableBalanceAlternative + ' ' + wallet.status.alternativeIsoCode; + } else { + availableFundsInFiat = ''; + } + + } else if (wallet.cachedStatus) { + + if (wallet.cachedStatus.alternativeBalanceAvailable) { + availableFundsInFiat = wallet.cachedStatus.spendableBalanceAlternative + ' ' + wallet.cachedStatus.alternativeIsoCode; + } else { + availableFundsInFiat = ''; + } + availableFundsInCrypto = wallet.cachedStatus.spendableBalanceStr; + availableSatoshis = wallet.cachedStatus.spendableAmount; + } else { - spendableAmountInSatoshis = null; + + availableFundsInFiat = ''; + availableFundsInCrypto = ''; + availableSatoshis = null; } + + } }); From 9e7566b171fb7c46876b1a2adcb9bb705170147f Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 19 Jul 2018 12:58:17 +1200 Subject: [PATCH 110/386] Removing log statements. --- src/js/controllers/amount.js | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 1ea8f3104..92d54c281 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -293,7 +293,6 @@ angular.module('copayApp.controllers').controller('amountController', function($ $scope.availableFunds = availableFundsInCrypto; } - console.log('availableFunds: ' + $scope.availableFunds); updateUnitUI(); }; @@ -697,7 +696,5 @@ angular.module('copayApp.controllers').controller('amountController', function($ availableFundsInCrypto = ''; availableSatoshis = null; } - - } }); From d2d1511e61ed4cad15add697488d7d9c37ff766b Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 19 Jul 2018 13:03:29 +1200 Subject: [PATCH 111/386] Added some additional validation checks on wallet status. --- src/js/controllers/amount.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 92d54c281..7684aaac6 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -671,7 +671,7 @@ angular.module('copayApp.controllers').controller('amountController', function($ }; function updateAvailableFundsFromWallet(wallet) { - if (wallet.status) { + if (wallet.status && wallet.status.isValid) { availableFundsInCrypto = wallet.status.spendableBalanceStr; availableSatoshis = wallet.status.spendableAmount; if (wallet.status.alternativeBalanceAvailable) { @@ -680,7 +680,7 @@ angular.module('copayApp.controllers').controller('amountController', function($ availableFundsInFiat = ''; } - } else if (wallet.cachedStatus) { + } else if (wallet.cachedStatus && wallet.status.isValid) { if (wallet.cachedStatus.alternativeBalanceAvailable) { availableFundsInFiat = wallet.cachedStatus.spendableBalanceAlternative + ' ' + wallet.cachedStatus.alternativeIsoCode; From 19bec8a09aac2079abc632db721a1f4cdeaf5632 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 19 Jul 2018 15:34:53 +1200 Subject: [PATCH 112/386] Fixed update of available funds text. --- src/js/controllers/amount.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 7684aaac6..40a5f63ce 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -696,5 +696,12 @@ angular.module('copayApp.controllers').controller('amountController', function($ availableFundsInCrypto = ''; availableSatoshis = null; } + + if (availableUnits[unitIndex].isFiat) { + $scope.availableFunds = availableFundsInFiat || availableFundsInCrypto; + } else { + $scope.availableFunds = availableFundsInCrypto; + } + } }); From 0076ff26e6c637a553991ea0d109cb72dcccb1b0 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 19 Jul 2018 16:24:24 +1200 Subject: [PATCH 113/386] Currency of available funds changes when the currency of the amount is changed. --- src/js/controllers/amount.js | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 40a5f63ce..c705dc24b 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -665,11 +665,31 @@ angular.module('copayApp.controllers').controller('amountController', function($ availableUnits[altUnitIndex].name = newAltCurrency.isoCode; availableUnits[altUnitIndex].shortName = newAltCurrency.isoCode; fiatCode = newAltCurrency.isoCode; + updateAvailableFiatIfNeeded(); updateUnitUI(); $scope.close(); }); }; + + function updateAvailableFiatIfNeeded() { + if ($scope.fromWalletId && availableSatoshis !== null) { + availableFundsInFiat = ''; + $scope.availableFunds = availableFundsInCrypto; + var coin = availableUnits[altUnitIndex].isFiat ? availableUnits[unitIndex].id : availableUnits[altUnitIndex].id; + txFormatService.formatAlternativeStr(coin, availableSatoshis, function formatCallback(formatted){ + if (formatted) { + availableFundsInFiat = formatted; + if (availableUnits[unitIndex].isFiat) { + $scope.availableFunds = availableFundsInFiat; + } else { + $scope.availableFunds = availableFundsInCrypto; + } + } + }); + } + } + function updateAvailableFundsFromWallet(wallet) { if (wallet.status && wallet.status.isValid) { availableFundsInCrypto = wallet.status.spendableBalanceStr; From 0a96ae0dbedb9b421114283c6f847af2a4024dd2 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 19 Jul 2018 17:06:53 +1200 Subject: [PATCH 114/386] Added $scope.isRequestingSpecifcAmount. --- src/js/controllers/amount.js | 4 ++++ www/index.html | 7 +++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 52695e829..f4e789436 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -26,6 +26,8 @@ angular.module('copayApp.controllers').controller('amountController', function($ $scope.isAndroid = platformInfo.isAndroid; $scope.isIos = platformInfo.isIOS; + $scope.isRequestingSpecificAmount = false; + $scope.$on('$ionicView.leave', function() { angular.element($window).off('keydown'); }); @@ -51,6 +53,8 @@ angular.module('copayApp.controllers').controller('amountController', function($ } } + $scope.isRequestingSpecificAmount = !!data.stateParams.id; + var config = configService.getSync().wallet.settings; function setAvailableUnits() { diff --git a/www/index.html b/www/index.html index 4c73317e3..ecc2d923c 100644 --- a/www/index.html +++ b/www/index.html @@ -11,9 +11,8 @@ - Bitcoin.com Wallet - Bitcoin.com Wallet - - + Bitcoin.com Wallet + @@ -31,7 +30,7 @@ - + From 4f4bee27f1c53eef16b541542bae2c8fac586fe5 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 19 Jul 2018 09:59:56 +0200 Subject: [PATCH 115/386] Options also translatable --- i18n/po/template.pot | 10 ++++++++++ src/js/controllers/tab-settings.js | 2 +- www/views/preferencesPriceDisplay.html | 6 +++--- 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index df01cecec..aed2220fd 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -201,6 +201,16 @@ msgstr "" msgid "Price Display" msgstr "" +#: src/js/controllers/tab-settings.js:19 +#: www/views/preferencesPriceDisplay.html:12 +msgid "Fiat" +msgstr "" + +#: src/js/controllers/tab-settings.js:19 +#: www/views/preferencesPriceDisplay.html:15 +msgid "Cryptocurrency" +msgstr "" + #: src/js/controllers/buyAmazon.js:98 msgid "Amazon.com is not available at this moment. Please try back later." msgstr "" diff --git a/src/js/controllers/tab-settings.js b/src/js/controllers/tab-settings.js index 4d0636d53..494d63cc5 100644 --- a/src/js/controllers/tab-settings.js +++ b/src/js/controllers/tab-settings.js @@ -16,7 +16,7 @@ angular.module('copayApp.controllers').controller('tabSettingsController', funct isoCode: config.wallet.settings.alternativeIsoCode }; - $scope.selectedPriceDisplay = config.wallet.settings.priceDisplay; + $scope.selectedPriceDisplay = config.wallet.settings.priceDisplay === 'crypto' ? gettextCatalog.getString('Cryptocurrency') : gettextCatalog.getString('Fiat'); // TODO move this to a generic service bitpayAccountService.getAccounts(function(err, data) { diff --git a/www/views/preferencesPriceDisplay.html b/www/views/preferencesPriceDisplay.html index a4c12d273..31a9eb9b9 100644 --- a/www/views/preferencesPriceDisplay.html +++ b/www/views/preferencesPriceDisplay.html @@ -1,7 +1,7 @@ - {{'Price display'|translate}} + {{'Price Display'|translate}} @@ -9,10 +9,10 @@
- fiat + Fiat - cryptocurrency + Cryptocurrency
From 54478a4848619d538f694f04eabf862e8b19397f Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 19 Jul 2018 10:23:10 +0200 Subject: [PATCH 116/386] translation + faster transition --- i18n/po/template.pot | 4 ++++ src/sass/views/includes/slideToAcceptSuccess.scss | 2 +- www/views/includes/slideToAcceptSuccess.html | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index 4bab9ff2e..33616a9c5 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -2159,6 +2159,10 @@ msgstr "" msgid "Payment Sent" msgstr "" +#: www/views/includes/slideToAcceptSuccess.html:12 +msgid "Share this transaction" +msgstr "" + #: www/views/modals/txp-details.html:32 msgid "Payment accepted, but not yet broadcasted" msgstr "" diff --git a/src/sass/views/includes/slideToAcceptSuccess.scss b/src/sass/views/includes/slideToAcceptSuccess.scss index 724363b0d..f64dd6154 100644 --- a/src/sass/views/includes/slideToAcceptSuccess.scss +++ b/src/sass/views/includes/slideToAcceptSuccess.scss @@ -70,7 +70,7 @@ slide-to-accept-success { } &__share { transition: transform $duration ease, opacity $duration ease; - transition-delay: 1000ms; + transition-delay: 600ms; opacity: 0; margin-top: 15vh; span { diff --git a/www/views/includes/slideToAcceptSuccess.html b/www/views/includes/slideToAcceptSuccess.html index ed4ebfa77..9995001ae 100644 --- a/www/views/includes/slideToAcceptSuccess.html +++ b/www/views/includes/slideToAcceptSuccess.html @@ -9,7 +9,7 @@ Payment Sent
From a2f6277e7eaca60b0bb90139ccc35abefda4bf9c Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Thu, 19 Jul 2018 17:41:02 +0800 Subject: [PATCH 117/386] Added content-frame, item and ion-content components, added dummy wallet interfaces --- src/sass/components/components.scss | 3 ++ src/sass/components/content-frame.scss | 11 ++++++ src/sass/components/ion-content.scss | 13 ++++++ src/sass/components/item.scss | 39 ++++++++++++++++++ src/sass/icons.scss | 7 ++++ src/sass/views/review.scss | 8 ++++ src/sass/views/views.scss | 1 + www/css/main.css | 55 ++++++++++++++++++++++++++ www/views/review.html | 44 ++++++++++++++++++++- 9 files changed, 179 insertions(+), 2 deletions(-) create mode 100644 src/sass/components/content-frame.scss create mode 100644 src/sass/components/ion-content.scss create mode 100644 src/sass/components/item.scss create mode 100644 src/sass/views/review.scss diff --git a/src/sass/components/components.scss b/src/sass/components/components.scss index 833f565dd..fa0d9008b 100644 --- a/src/sass/components/components.scss +++ b/src/sass/components/components.scss @@ -1 +1,4 @@ @import "header"; +@import "content-frame"; +@import "item"; +@import "ion-content"; diff --git a/src/sass/components/content-frame.scss b/src/sass/components/content-frame.scss new file mode 100644 index 000000000..1c6831271 --- /dev/null +++ b/src/sass/components/content-frame.scss @@ -0,0 +1,11 @@ +.content-frame { + &.negative-top { + margin-top: -20px; + + .card { + &:first-child { + margin-top: 0; + } + } + } +} \ No newline at end of file diff --git a/src/sass/components/ion-content.scss b/src/sass/components/ion-content.scss new file mode 100644 index 000000000..7be47c9ab --- /dev/null +++ b/src/sass/components/ion-content.scss @@ -0,0 +1,13 @@ +/* +* Extends Ionic v1 ion-content +*/ + +ion-content { + &.bg-neutral { + background-color: #F2F2F2; + } + + &.padded-bottom-cta { + bottom: 92px; + } +} \ No newline at end of file diff --git a/src/sass/components/item.scss b/src/sass/components/item.scss new file mode 100644 index 000000000..0d8ece804 --- /dev/null +++ b/src/sass/components/item.scss @@ -0,0 +1,39 @@ +/* +* Extends Ionic v1 item +*/ + +.item { + &.item-compact { + padding: 11px 13px; + } + &.item-gutterless { + padding: 0; + } + + .item-content { + &.item-content-compact { + min-height: 69px; + padding: 13px 11px 13px 68px; + + > img, + > i { + &:first-child { + position: absolute; + max-width: 40px; + max-height: 40px; + width: 100%; + height: 100%; + border-radius: 50%; + left: 13px; + top: 50%; + padding: 0; + transform: translate(0,-50%); + } + } + } + + .highlight { + color: #FAB915; + } + } +} \ No newline at end of file diff --git a/src/sass/icons.scss b/src/sass/icons.scss index 7d14f8886..ee270408f 100644 --- a/src/sass/icons.scss +++ b/src/sass/icons.scss @@ -88,6 +88,13 @@ background-image: url('../img/icon-faucet.svg'); background-size: 70%; } + + &.icon-wallet { + background-color: #FAB915; + background-image: url('../img/icon-wallet.svg'); + border: none; + box-shadow: 0 0 0 1px rgba(0,0,0,0.3) inset; + } } } diff --git a/src/sass/views/review.scss b/src/sass/views/review.scss new file mode 100644 index 000000000..e1d4ebd07 --- /dev/null +++ b/src/sass/views/review.scss @@ -0,0 +1,8 @@ +#view-review { + background-color: #494949; + + slide-to-accept, slide-to-accept-success { + margin-bottom: constant(safe-area-inset-bottom); /* iOS 11.0 */ + margin-bottom: env(safe-area-inset-bottom); /* iOS 11.2 */ + } +} \ No newline at end of file diff --git a/src/sass/views/views.scss b/src/sass/views/views.scss index d4ed735ed..1e54062f9 100644 --- a/src/sass/views/views.scss +++ b/src/sass/views/views.scss @@ -48,3 +48,4 @@ @import "includes/logOptions"; @import "includes/checkBar"; @import "cashScan"; +@import "review"; diff --git a/www/css/main.css b/www/css/main.css index 2e2726888..7b40c47c7 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -10037,6 +10037,11 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm .big-icon-svg.theme-circle > .bg.icon-faucet { background-image: url("../img/icon-faucet.svg"); background-size: 70%; } + .big-icon-svg.theme-circle > .bg.icon-wallet { + background-color: #FAB915; + background-image: url("../img/icon-wallet.svg"); + border: none; + box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.3) inset; } .big-icon-svg.theme-circle-services > .bg { border: 1px solid #191919; } .big-icon-svg.theme-circle-community > .bg { @@ -15062,6 +15067,14 @@ log-options #check-bar .checkbox-icon { #cash-scan a { cursor: pointer; } +#view-review { + background-color: #494949; } + #view-review slide-to-accept, #view-review slide-to-accept-success { + margin-bottom: constant(safe-area-inset-bottom); + /* iOS 11.0 */ + margin-bottom: env(safe-area-inset-bottom); + /* iOS 11.2 */ } + .gravatar { border-radius: 3px; display: inline-block; } @@ -15090,6 +15103,48 @@ log-options #check-bar .checkbox-icon { .header .content p + p { margin-top: 8px; } +.content-frame.negative-top { + margin-top: -20px; } + .content-frame.negative-top .card:first-child { + margin-top: 0; } + +/* +* Extends Ionic v1 item +*/ +.item.item-compact { + padding: 11px 13px; } + +.item.item-gutterless { + padding: 0; } + +.item .item-content.item-content-compact { + min-height: 69px; + padding: 13px 11px 13px 68px; } + .item .item-content.item-content-compact > img:first-child, + .item .item-content.item-content-compact > i:first-child { + position: absolute; + max-width: 40px; + max-height: 40px; + width: 100%; + height: 100%; + border-radius: 50%; + left: 13px; + top: 50%; + padding: 0; + transform: translate(0, -50%); } + +.item .item-content .highlight { + color: #FAB915; } + +/* +* Extends Ionic v1 ion-content +*/ +ion-content.bg-neutral { + background-color: #F2F2F2; } + +ion-content.padded-bottom-cta { + bottom: 92px; } + /* This is for rules that don't yet have a home. * Our goal is to delete this file. Search the regex: /class=".*CLASS.*?"/ */ diff --git a/www/views/review.html b/www/views/review.html index cc57c79b8..563ddf6d6 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -1,4 +1,4 @@ - + {{'Review'|translate}} @@ -7,7 +7,7 @@ - +

You are sending

@@ -15,6 +15,46 @@

0.014 BCH

+ +
+
+
From:
+
+
+ +
+
+

Personal Wallet (BCH)

+

128.67

+
+
+
+
+
From:
+
+
+ +
+
+

Personal Wallet (BTC)

+

128.67

+
+
+
+
+
To:
+
+
+ +

Satoshi Nakamoto

+

128.67

+
+
+
+
Date: Thu, 19 Jul 2018 13:10:25 +0200 Subject: [PATCH 118/386] wallet Details buttons --- src/js/controllers/walletDetails.js | 2 ++ src/sass/views/walletDetails.scss | 16 ++++++++-------- www/views/walletDetails.html | 2 +- 3 files changed, 11 insertions(+), 9 deletions(-) diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index 24e4a5a20..b3fea717e 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -365,6 +365,8 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun var t = amountTop; $scope.altAmountOpacity = (amountHeight - 100) / 80; + + $scope.buttonsOpacity = (amountHeight - 150)/80; $window.requestAnimationFrame(function() { $scope.amountHeight = amountHeight + 'px'; $scope.contentMargin = contentMargin + 'px'; diff --git a/src/sass/views/walletDetails.scss b/src/sass/views/walletDetails.scss index 2d1aa1343..6be9e6cf2 100644 --- a/src/sass/views/walletDetails.scss +++ b/src/sass/views/walletDetails.scss @@ -147,13 +147,13 @@ background-color: transparent; } } - .nav-bar-block, .bar { - background-color: inherit !important; - } + //.nav-bar-block, .bar { + //background-color: inherit !important; + //} ion-content { &.collapsible { - margin-top: 230px; + margin-top: 210px; } padding-top: 0; @@ -193,7 +193,7 @@ .buttons { margin-bottom: 0; - margin-top: 6px; + margin-top: 30px; >.col { padding: 5px 10px; margin-bottom: 0; @@ -206,8 +206,8 @@ width: 100%; font-size: 19px; font-weight: bolder; - min-height: 45px; - line-height: 45px; + min-height: 40px; + line-height: 40px; } } } @@ -215,7 +215,7 @@ width: 100%; text-align: center; color: #fff; - height: 230px; + height: 210px; padding-top: 40px; display: block; align-items: center; diff --git a/www/views/walletDetails.html b/www/views/walletDetails.html index 820930a95..e2c0f7342 100644 --- a/www/views/walletDetails.html +++ b/www/views/walletDetails.html @@ -90,7 +90,7 @@
-
+
Receive From 700d2c8a2398e4a38b476030e5b693756a7b23db Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 19 Jul 2018 13:19:56 +0200 Subject: [PATCH 119/386] currency symbol --- src/js/services/currencySymbolService.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/js/services/currencySymbolService.js b/src/js/services/currencySymbolService.js index b4cf0c2ac..14565a1a5 100644 --- a/src/js/services/currencySymbolService.js +++ b/src/js/services/currencySymbolService.js @@ -179,10 +179,11 @@ angular.module('copayApp.services').factory('currencySymbolService', function($l }; root.getCurrencySymbol = function(code) { + if (!code) + return false; code = code.toUpperCase(); if (root.currencySymbols[code]) { - $log.debug("Currency symbol for "+code+" found"); return root.currencySymbols[code]; } $log.debug("Currency symbol for "+code+" not found"); From 442f6ba4dffc247696975e884265964ad5e54448 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 19 Jul 2018 13:20:38 +0200 Subject: [PATCH 120/386] currency symbol --- src/js/services/currencySymbolService.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/js/services/currencySymbolService.js b/src/js/services/currencySymbolService.js index 14565a1a5..029cd9eb2 100644 --- a/src/js/services/currencySymbolService.js +++ b/src/js/services/currencySymbolService.js @@ -179,8 +179,8 @@ angular.module('copayApp.services').factory('currencySymbolService', function($l }; root.getCurrencySymbol = function(code) { - if (!code) - return false; + if (!code) return false; + code = code.toUpperCase(); if (root.currencySymbols[code]) { From 22e93b823c4f508f88e12ebe31894e976061df45 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Thu, 19 Jul 2018 20:21:58 +0800 Subject: [PATCH 121/386] Adds address component --- src/sass/components/address.scss | 27 ++++++++++++++++++++++++ src/sass/components/components.scss | 1 + src/sass/components/item.scss | 13 ++++++++++-- www/css/main.css | 32 ++++++++++++++++++++++++++--- www/views/review.html | 9 +++++--- 5 files changed, 74 insertions(+), 8 deletions(-) create mode 100644 src/sass/components/address.scss diff --git a/src/sass/components/address.scss b/src/sass/components/address.scss new file mode 100644 index 000000000..2848deb82 --- /dev/null +++ b/src/sass/components/address.scss @@ -0,0 +1,27 @@ +.address { + background-color: #F8F8F8; + border: 0.5px solid #EDEBEB; + border-radius: 3px; + padding: 9px; + text-align: center; + font-size: 14px; + overflow: hidden; + text-overflow: ellipsis; + + &.expanded { + white-space: pre-wrap; + word-break: break-all; + } + + .prefix { + color: #000000; + } + + .mid { + color: #919191; + } + + .suffix { + color: #000000; + } +} \ No newline at end of file diff --git a/src/sass/components/components.scss b/src/sass/components/components.scss index fa0d9008b..b547defad 100644 --- a/src/sass/components/components.scss +++ b/src/sass/components/components.scss @@ -2,3 +2,4 @@ @import "content-frame"; @import "item"; @import "ion-content"; +@import "address"; diff --git a/src/sass/components/item.scss b/src/sass/components/item.scss index 0d8ece804..bb75ae8e0 100644 --- a/src/sass/components/item.scss +++ b/src/sass/components/item.scss @@ -11,7 +11,7 @@ } .item-content { - &.item-content-compact { + &.item-content-avatar { min-height: 69px; padding: 13px 11px 13px 68px; @@ -32,8 +32,17 @@ } } + &.item-content-compact { + min-height: 0; + padding: 13px 11px; + } + .highlight { - color: #FAB915; + color: #FAB915 + } + + + .item-content { + padding-top: 0; } } } \ No newline at end of file diff --git a/www/css/main.css b/www/css/main.css index 7b40c47c7..4f9410e68 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -15117,11 +15117,11 @@ log-options #check-bar .checkbox-icon { .item.item-gutterless { padding: 0; } -.item .item-content.item-content-compact { +.item .item-content.item-content-avatar { min-height: 69px; padding: 13px 11px 13px 68px; } - .item .item-content.item-content-compact > img:first-child, - .item .item-content.item-content-compact > i:first-child { + .item .item-content.item-content-avatar > img:first-child, + .item .item-content.item-content-avatar > i:first-child { position: absolute; max-width: 40px; max-height: 40px; @@ -15133,9 +15133,16 @@ log-options #check-bar .checkbox-icon { padding: 0; transform: translate(0, -50%); } +.item .item-content.item-content-compact { + min-height: 0; + padding: 13px 11px; } + .item .item-content .highlight { color: #FAB915; } +.item .item-content + .item-content { + padding-top: 0; } + /* * Extends Ionic v1 ion-content */ @@ -15145,6 +15152,25 @@ ion-content.bg-neutral { ion-content.padded-bottom-cta { bottom: 92px; } +.address { + background-color: #F8F8F8; + border: 0.5px solid #EDEBEB; + border-radius: 3px; + padding: 9px; + text-align: center; + font-size: 14px; + overflow: hidden; + text-overflow: ellipsis; } + .address.expanded { + white-space: pre-wrap; + word-break: break-all; } + .address .prefix { + color: #000000; } + .address .mid { + color: #919191; } + .address .suffix { + color: #000000; } + /* This is for rules that don't yet have a home. * Our goal is to delete this file. Search the regex: /class=".*CLASS.*?"/ */ diff --git a/www/views/review.html b/www/views/review.html index 563ddf6d6..9df212be9 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -20,7 +20,7 @@
From:
-
+
From:
-
+
@@ -47,11 +47,14 @@
To:
-
+

Satoshi Nakamoto

128.67

+
+
qz9cqq5pryv9hnqwa8q8mccmynk9uf4vlu5nxerpzmc
+
From 8ddfffd56b4dca5458545e5421cb467cdeb45be4 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 19 Jul 2018 15:21:27 +0200 Subject: [PATCH 122/386] amount on custom amount screen --- src/js/controllers/customAmount.js | 10 ++++++- src/sass/views/custom-amount.scss | 43 +++++++++++++++++++++++------- www/views/customAmount.html | 34 ++++++++++++++++++----- 3 files changed, 69 insertions(+), 18 deletions(-) diff --git a/src/js/controllers/customAmount.js b/src/js/controllers/customAmount.js index f6b96c22c..86bfa250f 100644 --- a/src/js/controllers/customAmount.js +++ b/src/js/controllers/customAmount.js @@ -64,6 +64,14 @@ angular.module('copayApp.controllers').controller('customAmountController', func var currency = parsedAmount.currency; $scope.amountUnitStr = parsedAmount.amountUnitStr; + configService.whenAvailable(function (config) { + $scope.selectedPriceDisplay = config.wallet.settings.priceDisplay; + + $timeout(function () { + $scope.$apply(); + }); + }); + if (currency != 'BTC' && currency != 'BCH') { // Convert to BTC or BCH var config = configService.getSync().wallet.settings; @@ -71,7 +79,7 @@ angular.module('copayApp.controllers').controller('customAmountController', func var btcParsedAmount = txFormatService.parseAmount($scope.wallet.coin, amountUnit, $scope.wallet.coin); $scope.amountBtc = btcParsedAmount.amount; - $scope.altAmountStr = btcParsedAmount.amountUnitStr; + $scope.altAmountStr = btcParsedAmount.amountUnitStr.toUpperCase(); } else { $scope.amountBtc = amount; // BTC or BCH $scope.altAmountStr = txFormatService.formatAlternativeStr($scope.wallet.coin, parsedAmount.amountSat); diff --git a/src/sass/views/custom-amount.scss b/src/sass/views/custom-amount.scss index b9bf65459..17973101d 100644 --- a/src/sass/views/custom-amount.scss +++ b/src/sass/views/custom-amount.scss @@ -26,16 +26,10 @@ height: 100%; .qr-code { text-align: center; - margin-top: 24vh; - margin-bottom: 7vh; - @media(max-height: 800px) { - margin-top: 18vh; - } - @media(max-height: 700px) { - margin-top: 14vh; - } - @media(max-height: 600px) { - margin-top: 8vh; + margin-top: 6px; + qrcode canvas { + height: 30vh; + max-height: 220px; } } .info { @@ -91,5 +85,34 @@ .address-types { text-align: center; } + + .amount { + margin-top: 20vh; + margin-bottom: 4vh; + @media(max-height: 800px) { + margin-top: 12vh; + margin-bottom: 6vh; + } + @media(max-height: 700px) { + margin-top: 10vh; + margin-bottom: 4vh; + } + @media(max-height: 600px) { + margin-top: 6vh; + margin-bottom: 2vh; + + } + width: 100%; + text-align: center; + //padding-top: 30px; + display: block; + align-items: center; + justify-content: center; + + &-alternative { + line-height: 36px; + } + } + } } diff --git a/www/views/customAmount.html b/www/views/customAmount.html index a4f2d57c9..73f107d82 100644 --- a/www/views/customAmount.html +++ b/www/views/customAmount.html @@ -11,7 +11,7 @@
-
-
-
+
Address {{address}} From 95faffa7698347a323cbaa53cdafa0c0dea25929 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 19 Jul 2018 15:30:29 +0200 Subject: [PATCH 123/386] remove bold font style --- www/views/customAmount.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/www/views/customAmount.html b/www/views/customAmount.html index 73f107d82..cac2bbc7d 100644 --- a/www/views/customAmount.html +++ b/www/views/customAmount.html @@ -34,13 +34,13 @@
- {{amountUnitStr}} + {{amountUnitStr}}
{{altAmountStr}}
- {{altAmountStr}} + {{altAmountStr}}
{{amountUnitStr}}
From 00ca5cded6f082052f6edbb34a0fc54cf6e211e5 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 19 Jul 2018 15:41:06 +0200 Subject: [PATCH 124/386] uppercase pipes --- src/js/controllers/customAmount.js | 2 +- www/views/customAmount.html | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/js/controllers/customAmount.js b/src/js/controllers/customAmount.js index 86bfa250f..a3916a2d4 100644 --- a/src/js/controllers/customAmount.js +++ b/src/js/controllers/customAmount.js @@ -79,7 +79,7 @@ angular.module('copayApp.controllers').controller('customAmountController', func var btcParsedAmount = txFormatService.parseAmount($scope.wallet.coin, amountUnit, $scope.wallet.coin); $scope.amountBtc = btcParsedAmount.amount; - $scope.altAmountStr = btcParsedAmount.amountUnitStr.toUpperCase(); + $scope.altAmountStr = btcParsedAmount.amountUnitStr; } else { $scope.amountBtc = amount; // BTC or BCH $scope.altAmountStr = txFormatService.formatAlternativeStr($scope.wallet.coin, parsedAmount.amountSat); diff --git a/www/views/customAmount.html b/www/views/customAmount.html index cac2bbc7d..849487735 100644 --- a/www/views/customAmount.html +++ b/www/views/customAmount.html @@ -36,11 +36,11 @@
{{amountUnitStr}}
- {{altAmountStr}} + {{altAmountStr | uppercase}}
- {{altAmountStr}} + {{altAmountStr | uppercase}}
{{amountUnitStr}}
@@ -80,7 +80,7 @@
Amount - {{amountUnitStr}} - {{altAmountStr}} + {{amountUnitStr}} - {{altAmountStr | uppercase}}
From a0b4f10ca9a91f91389752efcc7ef8bc9041ceab Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 19 Jul 2018 15:43:32 +0200 Subject: [PATCH 125/386] reverted IDE spacings --- www/views/customAmount.html | 20 +++++++------------- 1 file changed, 7 insertions(+), 13 deletions(-) diff --git a/www/views/customAmount.html b/www/views/customAmount.html index 849487735..a71a60202 100644 --- a/www/views/customAmount.html +++ b/www/views/customAmount.html @@ -11,7 +11,7 @@
-
-
-
+
Address {{address}} From c3cded5cb06ca88e32b50d5b33dbf583e450fbba Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 19 Jul 2018 15:50:09 +0200 Subject: [PATCH 126/386] wallet to wallet (sub)title --- src/js/controllers/walletToWalletController.js | 4 ++++ www/views/wallet-to-wallet-transfer.html | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/walletToWalletController.js b/src/js/controllers/walletToWalletController.js index 77d2218e6..eaf8f7700 100644 --- a/src/js/controllers/walletToWalletController.js +++ b/src/js/controllers/walletToWalletController.js @@ -2,6 +2,10 @@ angular.module('copayApp.controllers').controller('walletToWalletController', function($scope, $rootScope, $log, profileService, configService) { + // TODO: change according to which screen this is, origin/destination + $scope.headerTitle = gettextCatalog.getString('Choose your origin wallet'); + $scope.headerSubtitle = gettextCatalog.getString('This is where the Bitcoin will be taken out from.'); + $scope.$on("$ionicView.enter", function(event, data) { $scope.walletsBch = profileService.getWallets({coin: 'bch'}); $scope.walletsBtc = profileService.getWallets({coin: 'btc'}); diff --git a/www/views/wallet-to-wallet-transfer.html b/www/views/wallet-to-wallet-transfer.html index f172f40da..87ae6f6ed 100644 --- a/www/views/wallet-to-wallet-transfer.html +++ b/www/views/wallet-to-wallet-transfer.html @@ -5,10 +5,10 @@
- Choose your origin wallet + {{headerTitle}}
- This is where the Bitcoin will be taken out from. + {{headerSubtitle}}
From 3952df634324176ccdbdb7652ac1992a48264dea Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 19 Jul 2018 17:07:30 +0200 Subject: [PATCH 127/386] forked the cordova media plugin to remove unused permissions --- app-template/config-template.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app-template/config-template.xml b/app-template/config-template.xml index 1c7f5a30a..2f8e3db04 100644 --- a/app-template/config-template.xml +++ b/app-template/config-template.xml @@ -72,7 +72,7 @@ - + From cb82aa7253bf55bea89d5eebedda69b9809686d0 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 19 Jul 2018 17:11:24 +0200 Subject: [PATCH 128/386] OSX clipboard bugfix --- src/js/services/clipboardService.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/js/services/clipboardService.js b/src/js/services/clipboardService.js index ff28cd2e7..c53a1b764 100644 --- a/src/js/services/clipboardService.js +++ b/src/js/services/clipboardService.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.services').factory('clipboardService', function ($http, $log, platformInfo, nodeWebkitService, gettextCatalog, ionicToast, clipboard) { +angular.module('copayApp.services').factory('clipboardService', function ($http, $log, $timeout, platformInfo,nodeWebkitService, gettextCatalog, ionicToast, clipboard) { var root = {}; root.copyToClipboard = function (data) { @@ -26,7 +26,9 @@ angular.module('copayApp.services').factory('clipboardService', function ($http, cb(text); }) } else if (platformInfo.isNW) { - cb(nodeWebkitService.readFromClipboard()); + $timeout(function() { + cb(nodeWebkitService.readFromClipboard()); + },0); } else { navigator.clipboard.readText() .then(text => { From 1d5e116fa92f96bf99ab576d910de61e058f193f Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 19 Jul 2018 17:13:19 +0200 Subject: [PATCH 129/386] spacing --- src/js/services/clipboardService.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/services/clipboardService.js b/src/js/services/clipboardService.js index 2420d45e9..b9851d626 100644 --- a/src/js/services/clipboardService.js +++ b/src/js/services/clipboardService.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.services').factory('clipboardService', function ($http, $log, $timeout, platformInfo,nodeWebkitService, gettextCatalog, ionicToast, clipboard) { +angular.module('copayApp.services').factory('clipboardService', function ($http, $log, $timeout, platformInfo, nodeWebkitService, gettextCatalog, ionicToast, clipboard) { var root = {}; root.copyToClipboard = function (data) { From da853bcbf685f0bcec66a108bea5b2ecf3772730 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 20 Jul 2018 18:15:25 +1200 Subject: [PATCH 130/386] Placeholders for buttons. --- www/views/shapeshift.html | 2 ++ 1 file changed, 2 insertions(+) diff --git a/www/views/shapeshift.html b/www/views/shapeshift.html index 27be00fbd..48664ebba 100644 --- a/www/views/shapeshift.html +++ b/www/views/shapeshift.html @@ -13,6 +13,8 @@
No available wallets to convert between. + +
From 6efd338f87c94913ad5c745aba5eb6108ed1f1be Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Fri, 20 Jul 2018 15:56:39 +0800 Subject: [PATCH 131/386] Adds action-minor component --- src/sass/components/action-minor.scss | 23 +++++++++++++++++++++++ src/sass/components/components.scss | 1 + www/css/main.css | 15 +++++++++++++++ www/img/icon-bookmark.svg | 3 +++ www/views/review.html | 4 ++++ 5 files changed, 46 insertions(+) create mode 100644 src/sass/components/action-minor.scss create mode 100644 www/img/icon-bookmark.svg diff --git a/src/sass/components/action-minor.scss b/src/sass/components/action-minor.scss new file mode 100644 index 000000000..74fbe5639 --- /dev/null +++ b/src/sass/components/action-minor.scss @@ -0,0 +1,23 @@ +.action-minor { + margin: 20px 14px; + font-size: 14px; + + &.mt-negative { + margin-top: -10px; + } + + &.right { + text-align: right; + } + + > .action-icon { + width: 15px; + height: 15px; + vertical-align: middle; + margin-right: 3px; + } + + > .action-text { + vertical-align: middle; + } +} \ No newline at end of file diff --git a/src/sass/components/components.scss b/src/sass/components/components.scss index b547defad..c0224e56f 100644 --- a/src/sass/components/components.scss +++ b/src/sass/components/components.scss @@ -3,3 +3,4 @@ @import "item"; @import "ion-content"; @import "address"; +@import "action-minor"; diff --git a/www/css/main.css b/www/css/main.css index 4f9410e68..b34db534e 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -15171,6 +15171,21 @@ ion-content.padded-bottom-cta { .address .suffix { color: #000000; } +.action-minor { + margin: 20px 14px; + font-size: 14px; } + .action-minor.mt-negative { + margin-top: -10px; } + .action-minor.right { + text-align: right; } + .action-minor > .action-icon { + width: 15px; + height: 15px; + vertical-align: middle; + margin-right: 3px; } + .action-minor > .action-text { + vertical-align: middle; } + /* This is for rules that don't yet have a home. * Our goal is to delete this file. Search the regex: /class=".*CLASS.*?"/ */ diff --git a/www/img/icon-bookmark.svg b/www/img/icon-bookmark.svg new file mode 100644 index 000000000..b1ad892fd --- /dev/null +++ b/www/img/icon-bookmark.svg @@ -0,0 +1,3 @@ + + + diff --git a/www/views/review.html b/www/views/review.html index 9df212be9..2bef9a95e 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -57,6 +57,10 @@
+
+ + Add a personal note +
Date: Fri, 20 Jul 2018 10:06:59 +0200 Subject: [PATCH 132/386] currency format service + remove bottom amount in request amount screen --- src/js/services/txFormatService.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/services/txFormatService.js b/src/js/services/txFormatService.js index ebcb3886a..1932ebd2a 100644 --- a/src/js/services/txFormatService.js +++ b/src/js/services/txFormatService.js @@ -201,7 +201,7 @@ angular.module('copayApp.services').factory('txFormatService', function($filter, var alternativeIsoCode = config.alternativeIsoCode; // If fiat currency - if (currency != 'BCH' && currency != 'BTC' && currency != 'sat') { + if (currency && currency.toUpperCase() != 'BCH' && currency.toUpperCase() != 'BTC' && currency != 'sat') { amountUnitStr = $filter('formatFiatAmount')(amount) + ' ' + currency; amountSat = rateService.fromFiat(amount, currency, coin).toFixed(0); } else if (currency == 'sat') { From 1153830d05724322aa89444273c70a23e072ba77 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 20 Jul 2018 10:41:09 +0200 Subject: [PATCH 133/386] custom amount screen --- www/views/customAmount.html | 6 ------ 1 file changed, 6 deletions(-) diff --git a/www/views/customAmount.html b/www/views/customAmount.html index a71a60202..d6a474d1a 100644 --- a/www/views/customAmount.html +++ b/www/views/customAmount.html @@ -71,12 +71,6 @@ {{address}}
-
- Amount - - {{amountUnitStr}} - {{altAmountStr | uppercase}} - -
From 893dbe5c6fa4a8fad918adda1e036c8a95656700 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 23 Jul 2018 14:20:46 +0200 Subject: [PATCH 134/386] "has no funds" case --- .../controllers/walletToWalletController.js | 24 ++++--- src/js/services/profileService.js | 7 ++ src/sass/views/wallet-to-wallet-transfer.scss | 69 ++++++++++++++++--- www/views/wallet-to-wallet-transfer.html | 24 +++++-- 4 files changed, 103 insertions(+), 21 deletions(-) diff --git a/src/js/controllers/walletToWalletController.js b/src/js/controllers/walletToWalletController.js index eaf8f7700..e12b78837 100644 --- a/src/js/controllers/walletToWalletController.js +++ b/src/js/controllers/walletToWalletController.js @@ -1,14 +1,23 @@ 'use strict'; -angular.module('copayApp.controllers').controller('walletToWalletController', function($scope, $rootScope, $log, profileService, configService) { - - // TODO: change according to which screen this is, origin/destination - $scope.headerTitle = gettextCatalog.getString('Choose your origin wallet'); - $scope.headerSubtitle = gettextCatalog.getString('This is where the Bitcoin will be taken out from.'); +angular.module('copayApp.controllers').controller('walletToWalletController', function($scope, $rootScope, $log, configService, gettextCatalog, profileService) { $scope.$on("$ionicView.enter", function(event, data) { - $scope.walletsBch = profileService.getWallets({coin: 'bch'}); - $scope.walletsBtc = profileService.getWallets({coin: 'btc'}); + $scope.type = 'origin'; + $scope.coin = 'bch'; + $scope.walletsEmpty = []; + $scope.isPaymentRequest = true; + + if ($scope.type === 'origin') { + $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send from'); + $scope.walletsEmpty = profileService.getWallets({coin: $scope.coin, hasNoFunds: true}); + } else if ($scope.type === 'destination') { + $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send to'); + } + + $scope.walletsBch = profileService.getWallets({coin: 'bch', hasFunds: $scope.type==='origin'}); + $scope.walletsBtc = profileService.getWallets({coin: 'btc', hasFunds: $scope.type==='origin'}); + configService.whenAvailable(function(config) { $scope.selectedPriceDisplay = config.wallet.settings.priceDisplay; }); @@ -17,5 +26,4 @@ angular.module('copayApp.controllers').controller('walletToWalletController', fu $scope.useWallet = function(wallet) { // Do something with selected wallet }; - }); \ No newline at end of file diff --git a/src/js/services/profileService.js b/src/js/services/profileService.js index 4f8710c28..c86d263f2 100644 --- a/src/js/services/profileService.js +++ b/src/js/services/profileService.js @@ -847,6 +847,13 @@ angular.module('copayApp.services') }); } + if (opts.hasNoFunds) { + ret = lodash.filter(ret, function(w) { + if (!w.status) return; + return (w.status.availableBalanceSat === 0); + }); + } + if (opts.minAmount) { ret = lodash.filter(ret, function(w) { if (!w.status) return; diff --git a/src/sass/views/wallet-to-wallet-transfer.scss b/src/sass/views/wallet-to-wallet-transfer.scss index e909258cf..7328a2891 100644 --- a/src/sass/views/wallet-to-wallet-transfer.scss +++ b/src/sass/views/wallet-to-wallet-transfer.scss @@ -1,18 +1,71 @@ #wallet-to-wallet-transfer { - .header, .list { + .header--request { + padding: 30px 24px; + width: 100%; + height: 139px; + background-color: #fff; + &__title { + width: 46px; + height: 20px; + font-size: 16px; + font-weight: 600; + letter-spacing: -0.4px; + color: #000000; + } + &__amount { + font-size: 29px; + font-weight: 600; + letter-spacing: -0.7px; + color: #000000; + margin: 11px 0 2px; + } + &__amount-alt { + opacity: 0.45; + font-size: 16px; + font-weight: 600; + letter-spacing: -0.4px; + color: #000000; + } + } + .wallets-header { font-size: 12px; - margin: 20px 14px; + margin: 20px 14px 0px; .title { - font-size: 20px; + font-size: 16px; font-weight: bold; color: $v-dark-gray; + margin-bottom: -12px; } - .subtitle { - font-size: 12px; - line-height: 1.5em; - font-weight: 300; - color: $v-dark-gray; + } + .card { + font-size: 12px; + margin: 20px 14px 0px; + + .item-heading { + font-weight: 600; + } + + &-insufficient { + .wallet { + opacity: 0.4; + + } + .item-heading { + font-size: 12px; + >div { + display: inline-block; + vertical-align: text-bottom; + } + } + &__dot { + display: inline-block; + width: 16px; + height: 16px; + background-color: #ec5959; + border-radius: 8px; + margin: 2px 6px 2px 2px; + } } } } \ No newline at end of file diff --git a/www/views/wallet-to-wallet-transfer.html b/www/views/wallet-to-wallet-transfer.html index 87ae6f6ed..2055e4845 100644 --- a/www/views/wallet-to-wallet-transfer.html +++ b/www/views/wallet-to-wallet-transfer.html @@ -3,13 +3,15 @@ {{'Wallet to wallet transfer' | translate}} -
+
+
Paying
+
$37.42 USD
+
0.04580000 BCH
+
+
{{headerTitle}}
-
- {{headerSubtitle}} -
@@ -25,7 +27,7 @@
-
+
Bitcoin Core (BTC)
@@ -37,5 +39,17 @@
+ +
+
+
Insufficient funds
+
+
+ + + +
+
\ No newline at end of file From 7aecd2306f64188e45be5f4a65a491a08f9f70c1 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 23 Jul 2018 14:48:25 +0200 Subject: [PATCH 135/386] comments & show wallets --- src/js/controllers/walletToWalletController.js | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/src/js/controllers/walletToWalletController.js b/src/js/controllers/walletToWalletController.js index e12b78837..d83f93ddb 100644 --- a/src/js/controllers/walletToWalletController.js +++ b/src/js/controllers/walletToWalletController.js @@ -3,10 +3,10 @@ angular.module('copayApp.controllers').controller('walletToWalletController', function($scope, $rootScope, $log, configService, gettextCatalog, profileService) { $scope.$on("$ionicView.enter", function(event, data) { - $scope.type = 'origin'; - $scope.coin = 'bch'; + $scope.type = 'origin'; // origin || destination + $scope.coin = false; // Wallets to show (for destination screen) $scope.walletsEmpty = []; - $scope.isPaymentRequest = true; + $scope.isPaymentRequest = true; // Show price-header if ($scope.type === 'origin') { $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send from'); @@ -15,8 +15,12 @@ angular.module('copayApp.controllers').controller('walletToWalletController', fu $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send to'); } - $scope.walletsBch = profileService.getWallets({coin: 'bch', hasFunds: $scope.type==='origin'}); - $scope.walletsBtc = profileService.getWallets({coin: 'btc', hasFunds: $scope.type==='origin'}); + if (!$scope.coin || $scope.coin === 'bch') { + $scope.walletsBch = profileService.getWallets({coin: 'bch', hasFunds: $scope.type==='origin'}); + } + if (!$scope.coin || $scope.coin === 'btc') { + $scope.walletsBtc = profileService.getWallets({coin: 'btc', hasFunds: $scope.type === 'origin'}); + } configService.whenAvailable(function(config) { $scope.selectedPriceDisplay = config.wallet.settings.priceDisplay; From 3604ee3c3cc66a9233ed2c8af5091563f605565e Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 23 Jul 2018 16:58:32 +0200 Subject: [PATCH 136/386] routes, renames and flow --- src/js/controllers/sendFlowController.js | 69 ++++++++++++++++++ src/js/controllers/tab-send.js | 73 +++++++++---------- .../controllers/walletToWalletController.js | 33 --------- src/js/routes.js | 22 +++++- src/js/services/incomingData.js | 6 +- src/sass/views/views.scss | 2 +- ...er.scss => wallet-origin-destination.scss} | 2 +- www/views/tab-send.html | 54 +++++++------- ...er.html => wallet-origin-destination.html} | 4 +- 9 files changed, 160 insertions(+), 105 deletions(-) create mode 100644 src/js/controllers/sendFlowController.js delete mode 100644 src/js/controllers/walletToWalletController.js rename src/sass/views/{wallet-to-wallet-transfer.scss => wallet-origin-destination.scss} (97%) rename www/views/{wallet-to-wallet-transfer.html => wallet-origin-destination.html} (96%) diff --git a/src/js/controllers/sendFlowController.js b/src/js/controllers/sendFlowController.js new file mode 100644 index 000000000..ec29d7b50 --- /dev/null +++ b/src/js/controllers/sendFlowController.js @@ -0,0 +1,69 @@ +'use strict'; + +angular.module('copayApp.controllers').controller('sendFlowController', function($scope, $rootScope, $state, $stateParams, $log, configService, gettextCatalog, profileService) { + + var unitToSatoshi; + var satToUnit; + var unitDecimals; + var satToBtc; + + $scope.$on("$ionicView.beforeEnter", function(event, data) { + var config = configService.getSync().wallet.settings; + + $scope.specificAmount = $scope.specificAlternativeAmount = ''; + unitToSatoshi = config.unitToSatoshi; + satToUnit = 1 / unitToSatoshi; + satToBtc = 1 / 100000000; + unitDecimals = config.unitDecimals; + + // in SAT ALWAYS + if ($stateParams.toAmount) { + $scope.requestAmount = (($stateParams.toAmount) * satToUnit).toFixed(unitDecimals); + $scope.isPaymentRequest = true; + } + + console.log(data, $stateParams); + + $scope.params = $stateParams; + }); + + $scope.$on("$ionicView.enter", function(event, data) { + console.log(data, $stateParams); + $scope.type = data.stateParams.fromWalletId ? 'destination' : 'origin'; // origin || destination + $scope.coin = false; // Wallets to show (for destination screen) + $scope.walletsEmpty = []; + // Show price-header + + if ($scope.type === 'origin') { + $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send from'); + $scope.walletsEmpty = profileService.getWallets({coin: $scope.coin, hasNoFunds: true}); + } else if ($scope.type === 'destination') { + + $scope.fromWallet = profileService.getWallet(data.stateParams.fromWalletId); + $scope.coin = $scope.fromWallet.coin; + + $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send to'); + } + + if (!$scope.coin || $scope.coin === 'bch') { + $scope.walletsBch = profileService.getWallets({coin: 'bch', hasFunds: $scope.type==='origin'}); + } + if (!$scope.coin || $scope.coin === 'btc') { + $scope.walletsBtc = profileService.getWallets({coin: 'btc', hasFunds: $scope.type === 'origin'}); + } + + configService.whenAvailable(function(config) { + $scope.selectedPriceDisplay = config.wallet.settings.priceDisplay; + }); + }); + + $scope.useWallet = function(wallet) { + if ($scope.type === 'origin') { + $scope.params['fromWalletId'] = wallet.id; + $state.transitionTo('tabs.send.destination', $scope.params); + } else { + $scope.params['toWalletId'] = wallet.id; + $state.transitionTo('tabs.send.amount', $scope.params); + } + }; +}); \ No newline at end of file diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 99265457d..8e0ae6b92 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -54,42 +54,42 @@ angular.module('copayApp.controllers').controller('tabSendController', function( updateList(); }); }); - - var wallets; - var walletsBch; - var walletsBtc; - var walletToWalletFrom = false; - - $scope.onWalletSelect = function(wallet) { - if (!$scope.walletToWalletFrom) { - $scope.walletToWalletFrom = wallet; - if (wallet.coin === 'bch') { - $scope.showWalletsBch = true; - } else if (wallet.coin === 'btc') { - $scope.showWalletsBtc = true; - } - $scope.walletSelectorTitleTo = gettextCatalog.getString('Send to'); - } else { - $ionicLoading.show(); - walletService.getAddress(wallet, true, function(err, addr) { - $ionicLoading.hide(); - return $state.transitionTo('tabs.send.amount', { - displayAddress: $scope.walletToWalletFrom.coin === 'bch' ? bitcoinCashJsService.translateAddresses(addr).cashaddr : addr, - recipientType: 'wallet', - fromWalletId: $scope.walletToWalletFrom.id, - toAddress: addr, - coin: $scope.walletToWalletFrom.coin - }); - }); - - } - }; - - $scope.showWalletSelector = function() { - $scope.walletToWalletFrom = false; - $scope.walletSelectorTitleFrom = gettextCatalog.getString('Send from'); - $scope.showWallets = true; - }; + // + // var wallets; + // var walletsBch; + // var walletsBtc; + // var walletToWalletFrom = false; + // + // $scope.onWalletSelect = function(wallet) { + // if (!$scope.walletToWalletFrom) { + // $scope.walletToWalletFrom = wallet; + // if (wallet.coin === 'bch') { + // $scope.showWalletsBch = true; + // } else if (wallet.coin === 'btc') { + // $scope.showWalletsBtc = true; + // } + // $scope.walletSelectorTitleTo = gettextCatalog.getString('Send to'); + // } else { + // $ionicLoading.show(); + // walletService.getAddress(wallet, true, function(err, addr) { + // $ionicLoading.hide(); + // return $state.transitionTo('tabs.send.amount', { + // displayAddress: $scope.walletToWalletFrom.coin === 'bch' ? bitcoinCashJsService.translateAddresses(addr).cashaddr : addr, + // recipientType: 'wallet', + // fromWalletId: $scope.walletToWalletFrom.id, + // toAddress: addr, + // coin: $scope.walletToWalletFrom.coin + // }); + // }); + // + // } + // }; + // + // $scope.showWalletSelector = function() { + // $scope.walletToWalletFrom = false; + // $scope.walletSelectorTitleFrom = gettextCatalog.getString('Send from'); + // $scope.showWallets = true; + // }; $scope.findContact = function(search) { @@ -133,7 +133,6 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }; var updateHasFunds = function() { - $scope.hasFunds = false; var index = 0; lodash.each($scope.wallets, function(w) { diff --git a/src/js/controllers/walletToWalletController.js b/src/js/controllers/walletToWalletController.js deleted file mode 100644 index d83f93ddb..000000000 --- a/src/js/controllers/walletToWalletController.js +++ /dev/null @@ -1,33 +0,0 @@ -'use strict'; - -angular.module('copayApp.controllers').controller('walletToWalletController', function($scope, $rootScope, $log, configService, gettextCatalog, profileService) { - - $scope.$on("$ionicView.enter", function(event, data) { - $scope.type = 'origin'; // origin || destination - $scope.coin = false; // Wallets to show (for destination screen) - $scope.walletsEmpty = []; - $scope.isPaymentRequest = true; // Show price-header - - if ($scope.type === 'origin') { - $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send from'); - $scope.walletsEmpty = profileService.getWallets({coin: $scope.coin, hasNoFunds: true}); - } else if ($scope.type === 'destination') { - $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send to'); - } - - if (!$scope.coin || $scope.coin === 'bch') { - $scope.walletsBch = profileService.getWallets({coin: 'bch', hasFunds: $scope.type==='origin'}); - } - if (!$scope.coin || $scope.coin === 'btc') { - $scope.walletsBtc = profileService.getWallets({coin: 'btc', hasFunds: $scope.type === 'origin'}); - } - - configService.whenAvailable(function(config) { - $scope.selectedPriceDisplay = config.wallet.settings.priceDisplay; - }); - }); - - $scope.useWallet = function(wallet) { - // Do something with selected wallet - }; -}); \ No newline at end of file diff --git a/src/js/routes.js b/src/js/routes.js index 72397d872..29273d444 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -270,6 +270,24 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } } }) + .state('tabs.send.origin', { + url: '/origin/:thirdParty/:amount/:toAddress/:toWalletId', + views: { + 'tab-send@tabs': { + controller: 'sendFlowController', + templateUrl: 'views/wallet-origin-destination.html', + } + } + }) + .state('tabs.send.destination', { + url: '/destination/:fromWalletId/:thirdParty/:amount', + views: { + 'tab-send@tabs': { + controller: 'sendFlowController', + templateUrl: 'views/wallet-origin-destination.html', + } + } + }) .state('tabs.settings', { url: '/settings', views: { @@ -299,7 +317,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr url: '/wallet-to-wallet', views: { 'tab-send@tabs': { - controller: 'walletToWalletController', + controller: 'sendFlowController', templateUrl: 'views/wallet-to-wallet-transfer.html' } } @@ -1273,7 +1291,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr if (screen.width < 768 && platformInfo.isCordova) screen.lockOrientation('portrait'); - if (ionic.Platform.isAndroid() && StatusBar) { + if (ionic.Platform.isAndroid() && platformInfo.isCordova && StatusBar) { StatusBar.backgroundColorByHexString('#000000'); } diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index 1bb87b49c..fc3d37d47 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -83,7 +83,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat // Timeout is required to enable the "Back" button $timeout(function() { if (amount) { - $state.transitionTo('tabs.send.confirm', { + $state.transitionTo('tabs.send.origin', { toAmount: amount, toAddress: addr, displayAddress: originalAddress ? originalAddress : addr, @@ -102,8 +102,10 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat params['minShapeshiftAmount'] = shapeshiftData.minAmount; params['maxShapeshiftAmount'] = shapeshiftData.maxAmount; params['shapeshiftOrderId'] = shapeshiftData.orderId; + $state.transitionTo('tabs.send.amount', params); + } else { + $state.transitionTo('tabs.send.origin', params); } - $state.transitionTo('tabs.send.amount', params); } }, 100); } diff --git a/src/sass/views/views.scss b/src/sass/views/views.scss index 538787901..e1a122dbb 100644 --- a/src/sass/views/views.scss +++ b/src/sass/views/views.scss @@ -8,7 +8,7 @@ @import "tab-receive"; @import "tab-scan"; @import "tab-send"; -@import "wallet-to-wallet-transfer"; +@import "wallet-origin-destination"; @import "tab-settings"; @import "wallet-colors"; @import "walletBalance"; diff --git a/src/sass/views/wallet-to-wallet-transfer.scss b/src/sass/views/wallet-origin-destination.scss similarity index 97% rename from src/sass/views/wallet-to-wallet-transfer.scss rename to src/sass/views/wallet-origin-destination.scss index 7328a2891..94fbe8e4b 100644 --- a/src/sass/views/wallet-to-wallet-transfer.scss +++ b/src/sass/views/wallet-origin-destination.scss @@ -1,4 +1,4 @@ -#wallet-to-wallet-transfer { +#wallet-origin-destination { .header--request { padding: 30px 24px; width: 100%; diff --git a/www/views/tab-send.html b/www/views/tab-send.html index b5d556214..a1e8a778f 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -105,31 +105,31 @@
- - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/www/views/wallet-to-wallet-transfer.html b/www/views/wallet-origin-destination.html similarity index 96% rename from www/views/wallet-to-wallet-transfer.html rename to www/views/wallet-origin-destination.html index 2055e4845..66f5852ad 100644 --- a/www/views/wallet-to-wallet-transfer.html +++ b/www/views/wallet-origin-destination.html @@ -1,4 +1,4 @@ - + {{'Wallet to wallet transfer' | translate}} @@ -6,7 +6,7 @@
Paying
$37.42 USD
-
0.04580000 BCH
+
0.04580000 BCH {{requestAmount}}
From ac91282c13ac419f15513106df9eb1f52adc114c Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 23 Jul 2018 12:02:04 -0700 Subject: [PATCH 137/386] Indicative change for view. --- www/views/amount.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/views/amount.html b/www/views/amount.html index af4e9d55c..8361dcd73 100644 --- a/www/views/amount.html +++ b/www/views/amount.html @@ -27,7 +27,7 @@
-
-
- +
From 4b18e4b1c3ac8fce0ec76a7b922880cfeb8fb381 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Tue, 24 Jul 2018 15:27:21 +0800 Subject: [PATCH 140/386] Adds expand-content component, update various UI measurements --- src/sass/components/action-minor.scss | 5 +- src/sass/components/card.scss | 5 ++ src/sass/components/components.scss | 7 +- src/sass/components/content-frame.scss | 2 +- src/sass/components/expand-content.scss | 26 ++++++++ src/sass/components/header.scss | 2 +- src/sass/directives/directives.scss | 1 + src/sass/directives/elastic.scss | 4 ++ www/css/main.css | 88 ++++++++++++++++--------- www/img/icon-bookmark.svg | 10 ++- www/views/review.html | 42 ++++++------ 11 files changed, 133 insertions(+), 59 deletions(-) create mode 100644 src/sass/components/card.scss create mode 100644 src/sass/components/expand-content.scss create mode 100644 src/sass/directives/elastic.scss diff --git a/src/sass/components/action-minor.scss b/src/sass/components/action-minor.scss index 74fbe5639..f158fe845 100644 --- a/src/sass/components/action-minor.scss +++ b/src/sass/components/action-minor.scss @@ -3,10 +3,10 @@ font-size: 14px; &.mt-negative { - margin-top: -10px; + margin-top: 0; } - &.right { + &.text-right { text-align: right; } @@ -19,5 +19,6 @@ > .action-text { vertical-align: middle; + color: #444444; } } \ No newline at end of file diff --git a/src/sass/components/card.scss b/src/sass/components/card.scss new file mode 100644 index 000000000..6df235ab8 --- /dev/null +++ b/src/sass/components/card.scss @@ -0,0 +1,5 @@ +.card { + &.card-gutter-compact { + margin: 10px 12px; + } +} \ No newline at end of file diff --git a/src/sass/components/components.scss b/src/sass/components/components.scss index c0224e56f..180279125 100644 --- a/src/sass/components/components.scss +++ b/src/sass/components/components.scss @@ -1,6 +1,9 @@ -@import "header"; -@import "content-frame"; @import "item"; @import "ion-content"; +@import "card"; + +@import "header"; +@import "content-frame"; @import "address"; @import "action-minor"; +@import "expand-content"; diff --git a/src/sass/components/content-frame.scss b/src/sass/components/content-frame.scss index 1c6831271..5766b246b 100644 --- a/src/sass/components/content-frame.scss +++ b/src/sass/components/content-frame.scss @@ -1,6 +1,6 @@ .content-frame { &.negative-top { - margin-top: -20px; + margin-top: -40px; .card { &:first-child { diff --git a/src/sass/components/expand-content.scss b/src/sass/components/expand-content.scss new file mode 100644 index 000000000..934a2beec --- /dev/null +++ b/src/sass/components/expand-content.scss @@ -0,0 +1,26 @@ +.expand-content-frame { + position: relative; + + .expand-content-trigger { + position: absolute; + top: 0; + transition: opacity 0.3s ease; + right: 0; + + &.expand-content-revealed { + opacity: 0; + } + } + + .expand-content { + opacity: 0; + transform-origin: 100% 0%; + transform: scale(0,0); + transition: opacity 0.3s ease, transform 0.3s ease; + + &.expand-content-revealed { + opacity: 1; + transform: scale(1,1); + } + } +} \ No newline at end of file diff --git a/src/sass/components/header.scss b/src/sass/components/header.scss index 1c178dd07..fad1f1812 100644 --- a/src/sass/components/header.scss +++ b/src/sass/components/header.scss @@ -1,5 +1,5 @@ .header { - padding: 29px 12px 65px; + padding: 29px 12px 61px; background-color: #FAB915; color: #FFFFFF; diff --git a/src/sass/directives/directives.scss b/src/sass/directives/directives.scss index 9159d3f23..954b86c3a 100644 --- a/src/sass/directives/directives.scss +++ b/src/sass/directives/directives.scss @@ -1 +1,2 @@ @import "gravatar"; +@import "elastic"; \ No newline at end of file diff --git a/src/sass/directives/elastic.scss b/src/sass/directives/elastic.scss new file mode 100644 index 000000000..8e8aba4fa --- /dev/null +++ b/src/sass/directives/elastic.scss @@ -0,0 +1,4 @@ +.elastic { + width: 100%; + font-size: 14px; +} \ No newline at end of file diff --git a/www/css/main.css b/www/css/main.css index b34db534e..df8779400 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -15079,34 +15079,9 @@ log-options #check-bar .checkbox-icon { border-radius: 3px; display: inline-block; } -.header { - padding: 29px 12px 65px; - background-color: #FAB915; - color: #FFFFFF; } - .header .title { - font-size: 18px; - font-weight: 400; - line-height: 1em; - color: #FFFFFF; - text-align: center; } - .header .title + .content { - margin-top: 23px; } - .header .content { - text-align: center; } - .header .content p { - margin: 0; - line-height: 1em; - font-size: 18px; } - .header .content p.large { - font-size: 29px; - font-weight: 600; } - .header .content p + p { - margin-top: 8px; } - -.content-frame.negative-top { - margin-top: -20px; } - .content-frame.negative-top .card:first-child { - margin-top: 0; } +.elastic { + width: 100%; + font-size: 14px; } /* * Extends Ionic v1 item @@ -15152,6 +15127,38 @@ ion-content.bg-neutral { ion-content.padded-bottom-cta { bottom: 92px; } +.card.card-gutter-compact { + margin: 10px 12px; } + +.header { + padding: 29px 12px 61px; + background-color: #FAB915; + color: #FFFFFF; } + .header .title { + font-size: 18px; + font-weight: 400; + line-height: 1em; + color: #FFFFFF; + text-align: center; } + .header .title + .content { + margin-top: 23px; } + .header .content { + text-align: center; } + .header .content p { + margin: 0; + line-height: 1em; + font-size: 18px; } + .header .content p.large { + font-size: 29px; + font-weight: 600; } + .header .content p + p { + margin-top: 8px; } + +.content-frame.negative-top { + margin-top: -40px; } + .content-frame.negative-top .card:first-child { + margin-top: 0; } + .address { background-color: #F8F8F8; border: 0.5px solid #EDEBEB; @@ -15175,8 +15182,8 @@ ion-content.padded-bottom-cta { margin: 20px 14px; font-size: 14px; } .action-minor.mt-negative { - margin-top: -10px; } - .action-minor.right { + margin-top: 0; } + .action-minor.text-right { text-align: right; } .action-minor > .action-icon { width: 15px; @@ -15184,7 +15191,26 @@ ion-content.padded-bottom-cta { vertical-align: middle; margin-right: 3px; } .action-minor > .action-text { - vertical-align: middle; } + vertical-align: middle; + color: #444444; } + +.expand-content-frame { + position: relative; } + .expand-content-frame .expand-content-trigger { + position: absolute; + top: 0; + transition: opacity 0.3s ease; + right: 0; } + .expand-content-frame .expand-content-trigger.expand-content-revealed { + opacity: 0; } + .expand-content-frame .expand-content { + opacity: 0; + transform-origin: 100% 0%; + transform: scale(0, 0); + transition: opacity 0.3s ease, transform 0.3s ease; } + .expand-content-frame .expand-content.expand-content-revealed { + opacity: 1; + transform: scale(1, 1); } /* This is for rules that don't yet have a home. * Our goal is to delete this file. Search the regex: /class=".*CLASS.*?"/ diff --git a/www/img/icon-bookmark.svg b/www/img/icon-bookmark.svg index b1ad892fd..5db1f9047 100644 --- a/www/img/icon-bookmark.svg +++ b/www/img/icon-bookmark.svg @@ -1,3 +1,11 @@ - + + + + diff --git a/www/views/review.html b/www/views/review.html index 2bef9a95e..9de1a403e 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -7,9 +7,9 @@ - +
-

You are sending

13.98 USD

0.014 BCH

@@ -17,7 +17,7 @@
-
+
From:
@@ -31,21 +31,8 @@
-
-
From:
-
-
- -
-
-

Personal Wallet (BTC)

-

128.67

-
-
-
-
-
To:
+
+
To:
@@ -57,9 +44,22 @@
-
- - Add a personal note +
+
+ + Add a personal note +
+
+
Personal Note:
+
+
+ +
+
+
From fd4adbfb57be5d678a5319c9e17f4e2c75b771b4 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 24 Jul 2018 14:24:22 +0200 Subject: [PATCH 141/386] wallet to wallet case worked out. Also fixed routes and some css --- src/js/controllers/amount.js | 27 +-- src/js/controllers/confirm.js | 174 +++++++++--------- src/js/controllers/sendFlowController.js | 31 ++-- src/js/routes.js | 42 ++--- src/js/services/incomingData.js | 4 +- src/sass/views/wallet-origin-destination.scss | 5 +- 6 files changed, 152 insertions(+), 131 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 52695e829..c8383a510 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -31,7 +31,6 @@ angular.module('copayApp.controllers').controller('amountController', function($ }); $scope.$on("$ionicView.beforeEnter", function(event, data) { - initCurrencies(); if (data.stateParams.shapeshiftOrderId && data.stateParams.shapeshiftOrderId.length > 0) { @@ -42,6 +41,7 @@ angular.module('copayApp.controllers').controller('amountController', function($ // To get the wallet from with the new flow $scope.fromWalletId = data.stateParams.fromWalletId; + $scope.toWalletId = data.stateParams.toWalletId; if (data.stateParams.noPrefix) { $scope.showWarningMessage = data.stateParams.noPrefix != 0; @@ -156,10 +156,10 @@ angular.module('copayApp.controllers').controller('amountController', function($ $scope.toEmail = data.stateParams.toEmail; $scope.toColor = data.stateParams.toColor; - if (!$scope.nextStep && !data.stateParams.toAddress) { - $log.error('Bad params at amount') - throw ('bad params'); - } + // if (!$scope.nextStep && !data.stateParams.toAddress) { + // $log.error('Bad params at amount') + // throw ('bad params'); + // } var reNr = /^[1234567890\.]$/; var reOp = /^[\*\+\-\/]$/; @@ -198,8 +198,8 @@ angular.module('copayApp.controllers').controller('amountController', function($ $scope.resetAmount(); // in SAT ALWAYS - if ($stateParams.toAmount) { - $scope.amountModel.amount = (($stateParams.toAmount) * satToUnit).toFixed(unitDecimals); + if ($stateParams.amount) { + $scope.amountModel.amount = (($stateParams.amount) * satToUnit).toFixed(unitDecimals); } $scope.processAmount(); @@ -461,7 +461,8 @@ angular.module('copayApp.controllers').controller('amountController', function($ currency: unit.id.toUpperCase(), coin: coin, useSendMax: $scope.useSendMax, - fromWalletId: $scope.fromWalletId + fromWalletId: $scope.fromWalletId, + toWalletId: $scope.toWalletId }); } else { var amount = _amount; @@ -474,7 +475,7 @@ angular.module('copayApp.controllers').controller('amountController', function($ var confirmData = { recipientType: $scope.recipientType, - toAmount: amount, + amount: amount, toAddress: $scope.toAddress, displayAddress: $scope.displayAddress || $scope.toAddress, toName: $scope.toName, @@ -482,14 +483,14 @@ angular.module('copayApp.controllers').controller('amountController', function($ toColor: $scope.toColor, coin: coin, useSendMax: $scope.useSendMax, - fromWalletId: $scope.fromWalletId + fromWalletId: $scope.fromWalletId, + toWalletId: $scope.toWalletId }; if ($scope.shapeshiftOrderId) { var shapeshiftOrderUrl = 'https://www.shapeshift.io/#/status/'; shapeshiftOrderUrl += $scope.shapeshiftOrderId; confirmData.description = shapeshiftOrderUrl; - confirmData.fromWalletId = $scope.fromWalletId; if (confirmData.useSendMax) { var wallet = lodash.find(profileService.getWallets({ coin: coin }), @@ -500,10 +501,10 @@ angular.module('copayApp.controllers').controller('amountController', function($ var balance = parseFloat(wallet.cachedBalance.substring(0, wallet.cachedBalance.length-4)); if (balance < $scope.minShapeshiftAmount * 1.04) { confirmData.useSendMax = false; - confirmData.toAmount = $scope.minShapeshiftAmount * unitToSatoshi; + confirmData.amount = $scope.minShapeshiftAmount * unitToSatoshi; } else if (balance > $scope.maxShapeshiftAmount) { confirmData.useSendMax = false; - confirmData.toAmount = $scope.maxShapeshiftAmount * unitToSatoshi * 0.99; + confirmData.amount = $scope.maxShapeshiftAmount * unitToSatoshi * 0.99; } } } diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index 03af26fd1..74b86e623 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, $stateParams, $window, $state, $log, profileService, bitcore, bitcoreCash, txFormatService, ongoingProcess, $ionicModal, popupService, $ionicHistory, $ionicConfig, payproService, feeService, bwcError, txConfirmNotification, externalLinkService, firebaseEventsService, soundService) { +angular.module('copayApp.controllers').controller('confirmController', function($rootScope, $scope, $interval, $filter, $timeout, $ionicScrollDelegate, $ionicLoading, gettextCatalog, walletService, platformInfo, lodash, configService, $stateParams, $window, $state, $log, profileService, bitcore, bitcoreCash, txFormatService, ongoingProcess, $ionicModal, popupService, $ionicHistory, $ionicConfig, payproService, feeService, bwcError, txConfirmNotification, externalLinkService, firebaseEventsService, soundService) { var countDown = null; var FEE_TOO_HIGH_LIMIT_PER = 15; @@ -68,82 +68,95 @@ angular.module('copayApp.controllers').controller('confirmController', function( }); }; + var setWalletSelector = function(coin, network, minAmount, cb) { + + // no min amount? (sendMax) => look for no empty wallets + minAmount = minAmount || 1; + + $scope.wallets = profileService.getWallets({ + onlyComplete: true, + network: network, + coin: coin + }); + + if (tx.fromWalletId) { + $scope.wallets = lodash.filter($scope.wallets, function (w) { + return w.id == tx.fromWalletId; + }); + } + + + if (!$scope.wallets || !$scope.wallets.length) { + setNoWallet(gettextCatalog.getString('No wallets available'), true); + return cb(); + } + + var filteredWallets = []; + var index = 0; + var walletsUpdated = 0; + + lodash.each($scope.wallets, function (w) { + walletService.getStatus(w, {}, function (err, status) { + if (err || !status) { + $log.error(err); + } else { + walletsUpdated++; + w.status = status; + + if (!status.availableBalanceSat) + $log.debug('No balance available in: ' + w.name); + + if (status.availableBalanceSat > minAmount) { + filteredWallets.push(w); + } + } + + if (++index == $scope.wallets.length) { + if (!walletsUpdated) + return cb('Could not update any wallet'); + + if (lodash.isEmpty(filteredWallets)) { + setNoWallet(gettextCatalog.getString('Insufficient confirmed funds'), true); + } + $scope.wallets = lodash.clone(filteredWallets); + return cb(); + } + }); + }); + }; $scope.$on("$ionicView.beforeEnter", function(event, data) { - - function setWalletSelector(coin, network, minAmount, cb) { - - // no min amount? (sendMax) => look for no empty wallets - minAmount = minAmount || 1; - - $scope.wallets = profileService.getWallets({ - onlyComplete: true, - network: network, - coin: coin - }); - - if (tx.fromWalletId) { - $scope.wallets = lodash.filter($scope.wallets, function(w) { - return w.id == tx.fromWalletId; - }); - } - - - - if (!$scope.wallets || !$scope.wallets.length) { - setNoWallet(gettextCatalog.getString('No wallets available'), true); - return cb(); - } - - var filteredWallets = []; - var index = 0; - var walletsUpdated = 0; - - lodash.each($scope.wallets, function(w) { - walletService.getStatus(w, {}, function(err, status) { - if (err || !status) { - $log.error(err); - } else { - walletsUpdated++; - w.status = status; - - if (!status.availableBalanceSat) - $log.debug('No balance available in: ' + w.name); - - if (status.availableBalanceSat > minAmount) { - filteredWallets.push(w); - } - } - - if (++index == $scope.wallets.length) { - if (!walletsUpdated) - return cb('Could not update any wallet'); - - if (lodash.isEmpty(filteredWallets)) { - setNoWallet(gettextCatalog.getString('Insufficient confirmed funds'), true); - } - $scope.wallets = lodash.clone(filteredWallets); - return cb(); - } - }); - }); - }; - // Setup $scope var B = data.stateParams.coin == 'bch' ? bitcoreCash : bitcore; var networkName; + $scope.fromWallet = profileService.getWallet(data.stateParams.fromWalletId); + $scope.recipientType = null; + try { - networkName = (new B.Address(data.stateParams.toAddress)).network.name; - } catch(e) { + if (data.stateParams.toWalletId) { + $scope.recipientType = 'wallet'; // set type to wallet-to-wallet + $ionicLoading.show(); + var wallet = profileService.getWallet(data.stateParams.toWalletId); + walletService.getAddress(wallet, true, function (err, addr) { + $ionicLoading.hide(); + data.stateParams.toAddress = addr; + networkName = (new B.Address(data.stateParams.toAddress)).network.name; + vanityTx(networkName, data); + }); + } else if (data.stateParams.toAddress) { + networkName = (new B.Address(data.stateParams.toAddress)).network.name; + vanityTx(networkName, data); + } + } catch (e) { var message = gettextCatalog.getString('Invalid address'); var backText = gettextCatalog.getString('Go back'); var learnText = gettextCatalog.getString('Learn more'); - popupService.showConfirm(null, message, backText, learnText, function(back) { + popupService.showConfirm(null, message, backText, learnText, function (back) { $ionicHistory.nextViewOptions({ disableAnimate: true, historyRoot: true }); - $state.go('tabs.send').then(function() { + $state.go('tabs.send').then(function () { $ionicHistory.clearHistory(); if (!back) { var url = 'https://support.bitpay.com/hc/en-us/articles/115004671663'; @@ -153,27 +166,24 @@ angular.module('copayApp.controllers').controller('confirmController', function( }); return; } - + }); + var vanityTx = function(networkName, data) { // Grab stateParams tx = { - toAmount: parseInt(data.stateParams.toAmount), + amount: parseInt(data.stateParams.amount), sendMax: data.stateParams.useSendMax == 'true' ? true : false, fromWalletId: data.stateParams.fromWalletId, toAddress: data.stateParams.toAddress, - displayAddress: data.stateParams.displayAddress, - description: data.stateParams.description, - paypro: data.stateParams.paypro, - feeLevel: configFeeLevel, spendUnconfirmed: walletConfig.spendUnconfirmed, // Vanity tx info (not in the real tx) - recipientType: data.stateParams.recipientType || null, + recipientType: $scope.recipientType || null, toName: data.stateParams.toName, toEmail: data.stateParams.toEmail, toColor: data.stateParams.toColor, network: networkName, - coin: data.stateParams.coin, + coin: $scope.fromWallet.coin, txp: {}, }; @@ -188,12 +198,10 @@ angular.module('copayApp.controllers').controller('confirmController', function( // Other Scope vars $scope.isCordova = isCordova; - $scope.isWindowsPhoneApp = isWindowsPhoneApp; $scope.showAddress = false; - $scope.walletSelectorTitle = gettextCatalog.getString('Send from'); - setWalletSelector(tx.coin, tx.network, tx.toAmount, function(err) { + setWalletSelector(tx.coin, tx.network, tx.amount, function(err) { if (err) { return exitWithError('Could not update wallets'); } @@ -207,7 +215,7 @@ angular.module('copayApp.controllers').controller('confirmController', function( $scope.displayBalanceAsFiat = walletConfig.settings.priceDisplay === 'fiat'; - }); + }; function getSendMaxInfo(tx, wallet, cb) { @@ -231,7 +239,7 @@ angular.module('copayApp.controllers').controller('confirmController', function( return setSendError(msg); } - if (tx.toAmount > Number.MAX_SAFE_INTEGER) { + if (tx.amount > Number.MAX_SAFE_INTEGER) { var msg = gettextCatalog.getString('Amount too big'); $log.warn(msg); return setSendError(msg); @@ -241,7 +249,7 @@ angular.module('copayApp.controllers').controller('confirmController', function( txp.outputs = [{ 'toAddress': tx.toAddress, - 'amount': tx.toAmount, + 'amount': tx.amount, 'message': tx.description }]; @@ -280,13 +288,13 @@ angular.module('copayApp.controllers').controller('confirmController', function( $scope.tx = tx; function updateAmount() { - if (!tx.toAmount) return; + if (!tx.amount) return; // Amount - tx.amountStr = txFormatService.formatAmountStr(wallet.coin, tx.toAmount); + tx.amountStr = txFormatService.formatAmountStr(wallet.coin, tx.amount); tx.amountValueStr = tx.amountStr.split(' ')[0]; tx.amountUnitStr = tx.amountStr.split(' ')[1]; - txFormatService.formatAlternativeStr(wallet.coin, tx.toAmount, function(v) { + txFormatService.formatAlternativeStr(wallet.coin, tx.amount, function(v) { var parts = v.split(' '); tx.alternativeAmountStr = v; tx.alternativeAmountValueStr = parts[0]; @@ -342,7 +350,7 @@ angular.module('copayApp.controllers').controller('confirmController', function( } tx.sendMaxInfo = sendMaxInfo; - tx.toAmount = tx.sendMaxInfo.amount; + tx.amount = tx.sendMaxInfo.amount; updateAmount(); ongoingProcess.set('calculatingFee', false); $timeout(function() { @@ -393,7 +401,7 @@ angular.module('copayApp.controllers').controller('confirmController', function( function useSelectedWallet() { if (!$scope.useSendMax) { - showAmount(tx.toAmount); + showAmount(tx.amount); } $scope.onWalletSelect($scope.wallet); diff --git a/src/js/controllers/sendFlowController.js b/src/js/controllers/sendFlowController.js index ec29d7b50..d6f2b707d 100644 --- a/src/js/controllers/sendFlowController.js +++ b/src/js/controllers/sendFlowController.js @@ -6,34 +6,34 @@ angular.module('copayApp.controllers').controller('sendFlowController', function var satToUnit; var unitDecimals; var satToBtc; + var nextStep = ''; $scope.$on("$ionicView.beforeEnter", function(event, data) { var config = configService.getSync().wallet.settings; - + $scope.params = $stateParams; $scope.specificAmount = $scope.specificAlternativeAmount = ''; unitToSatoshi = config.unitToSatoshi; satToUnit = 1 / unitToSatoshi; satToBtc = 1 / 100000000; unitDecimals = config.unitDecimals; - // in SAT ALWAYS - if ($stateParams.toAmount) { - $scope.requestAmount = (($stateParams.toAmount) * satToUnit).toFixed(unitDecimals); + if ($scope.params.amount) { + console.log("is Payment Request", $scope.params.amount); + + $scope.requestAmount = (($stateParams.amount) * satToUnit).toFixed(unitDecimals); $scope.isPaymentRequest = true; } - - console.log(data, $stateParams); - - $scope.params = $stateParams; }); $scope.$on("$ionicView.enter", function(event, data) { console.log(data, $stateParams); - $scope.type = data.stateParams.fromWalletId ? 'destination' : 'origin'; // origin || destination + $scope.type = data.stateParams && data.stateParams['fromWalletId'] ? 'destination' : 'origin'; // origin || destination $scope.coin = false; // Wallets to show (for destination screen) $scope.walletsEmpty = []; // Show price-header + console.log("current type: "+$scope.type); + if ($scope.type === 'origin') { $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send from'); $scope.walletsEmpty = profileService.getWallets({coin: $scope.coin, hasNoFunds: true}); @@ -57,13 +57,22 @@ angular.module('copayApp.controllers').controller('sendFlowController', function }); }); + function getNextStep() { + if (!$scope.params.toWalletId && !$scope.params.toAddress) { + return 'tabs.send.destination'; + } else if (!$scope.params.amount) { + return 'tabs.send.amount'; + } else { + return 'tabs.send.confirm'; + } + } + $scope.useWallet = function(wallet) { if ($scope.type === 'origin') { $scope.params['fromWalletId'] = wallet.id; - $state.transitionTo('tabs.send.destination', $scope.params); } else { $scope.params['toWalletId'] = wallet.id; - $state.transitionTo('tabs.send.amount', $scope.params); } + $state.transitionTo(getNextStep(), $scope.params); }; }); \ No newline at end of file diff --git a/src/js/routes.js b/src/js/routes.js index 29273d444..de77a34d5 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -270,24 +270,6 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } } }) - .state('tabs.send.origin', { - url: '/origin/:thirdParty/:amount/:toAddress/:toWalletId', - views: { - 'tab-send@tabs': { - controller: 'sendFlowController', - templateUrl: 'views/wallet-origin-destination.html', - } - } - }) - .state('tabs.send.destination', { - url: '/destination/:fromWalletId/:thirdParty/:amount', - views: { - 'tab-send@tabs': { - controller: 'sendFlowController', - templateUrl: 'views/wallet-origin-destination.html', - } - } - }) .state('tabs.settings', { url: '/settings', views: { @@ -305,7 +287,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr */ .state('tabs.send.amount', { - url: '/amount/:recipientType/:toAddress/:toName/:toEmail/:toColor/:coin/:fixedUnit/:fromWalletId/:minShapeshiftAmount/:maxShapeshiftAmount/:shapeshiftOrderId/:displayAddress/:noPrefix', + url: '/amount/:recipientType/:toAddress/:toName/:toEmail/:toColor/:coin/:fixedUnit/:fromWalletId/:toWalletId/:minShapeshiftAmount/:maxShapeshiftAmount/:shapeshiftOrderId/:displayAddress/:noPrefix', views: { 'tab-send@tabs': { controller: 'amountController', @@ -318,12 +300,30 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr views: { 'tab-send@tabs': { controller: 'sendFlowController', - templateUrl: 'views/wallet-to-wallet-transfer.html' + templateUrl: 'views/wallet-origin-destination.html' + } + } + }) + .state('tabs.send.origin', { + url: '/origin/:thirdParty/:amount/:toAddress/:toWalletId', + views: { + 'tab-send@tabs': { + controller: 'sendFlowController', + templateUrl: 'views/wallet-origin-destination.html', + } + } + }) + .state('tabs.send.destination', { + url: '/destination/:thirdParty/:amount/:fromWalletId', + views: { + 'tab-send@tabs': { + controller: 'sendFlowController', + templateUrl: 'views/wallet-origin-destination.html', } } }) .state('tabs.send.confirm', { - url: '/confirm/:recipientType/:toAddress/:toName/:toAmount/:toEmail/:toColor/:description/:coin/:useSendMax/:fromWalletId/:displayAddress/:requiredFeeRate', + url: '/confirm/:thirdParty/:amount/:fromWalletId/:toWalletId/:toAddress', views: { 'tab-send@tabs': { controller: 'confirmController', diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index fc3d37d47..e12cc2255 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -84,7 +84,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat $timeout(function() { if (amount) { $state.transitionTo('tabs.send.origin', { - toAmount: amount, + amount: amount, toAddress: addr, displayAddress: originalAddress ? originalAddress : addr, description: message, @@ -409,7 +409,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat function handlePayPro(payProDetails, coin) { var stateParams = { - toAmount: payProDetails.amount, + amount: payProDetails.amount, toAddress: payProDetails.toAddress, description: payProDetails.memo, paypro: payProDetails, diff --git a/src/sass/views/wallet-origin-destination.scss b/src/sass/views/wallet-origin-destination.scss index 94fbe8e4b..1c6016862 100644 --- a/src/sass/views/wallet-origin-destination.scss +++ b/src/sass/views/wallet-origin-destination.scss @@ -28,7 +28,6 @@ } } .wallets-header { - font-size: 12px; margin: 20px 14px 0px; .title { @@ -43,7 +42,11 @@ margin: 20px 14px 0px; .item-heading { + .subtitle { + font-size: 12px; + } font-weight: 600; + } &-insufficient { From 91dac0f54c460fb7d41cb8c5a523847454df7050 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 24 Jul 2018 12:37:51 -0700 Subject: [PATCH 142/386] Refactored Enter Amount controller to follow latest Angular 1 guidelines. --- src/js/controllers/amount.js | 471 +++++++++++++++--------------- src/js/routes.js | 7 + www/views/amount.html | 50 ++-- www/views/modals/altCurrency.html | 18 +- 4 files changed, 276 insertions(+), 270 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index f4e789436..1bc492136 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -1,62 +1,166 @@ 'use strict'; -angular.module('copayApp.controllers').controller('amountController', function($scope, $filter, $timeout, $ionicModal, $ionicScrollDelegate, $ionicHistory, storageService, walletService, gettextCatalog, platformInfo, lodash, configService, rateService, $stateParams, $window, $state, $log, txFormatService, ongoingProcess, popupService, bwcError, payproService, profileService, bitcore, amazonService, nodeWebkitService) { +angular.module('copayApp.controllers').controller('amountController', amountController); + +function amountController(configService, $filter, $ionicHistory, $ionicModal, $ionicScrollDelegate, lodash, $log, nodeWebkitService, rateService, $scope, $state, $stateParams, $timeout, txFormatService, platformInfo, popupService, profileService, walletService, $window) { + var vm = this; + + vm.allowSend = false; + vm.altCurrencyList = []; + vm.alternativeAmount = ''; + vm.alternativeUnit = ''; + vm.amountModel = { amount: 0 }; + vm.fromWalletId = ''; + vm.globalResult = ''; + vm.isRequestingSpecificAmount = false; + vm.listComplete = false; + vm.lastUsedPopularList = []; + vm.maxShapeshiftAmount = 0; + vm.minShapeshiftAmount = 0; + vm.shapeshiftOrderId = ''; + vm.unit = ''; + + vm.changeUnit = changeUnit; + vm.close = close; + vm.findCurrency = findCurrency; + vm.finish = finish; + vm.goBack = goBack; + vm.loadMore = loadMore; + vm.openPopup = openPopup; + vm.pushDigit = pushDigit; + vm.removeDigit = removeDigit; + vm.save = save; + vm.sendMax = sendMax; + + $scope.$on('$ionicView.beforeEnter', onBeforeEnter); + $scope.$on('$ionicView.leave', onLeave); - var _id; - var unitToSatoshi; - var satToUnit; - var unitDecimals; - var satToBtc; - var SMALL_FONT_SIZE_LIMIT = 10; var LENGTH_EXPRESSION_LIMIT = 19; var LENGTH_BEFORE_COMMA_EXPRESSION_LIMIT = 8; var LENGTH_AFTER_COMMA_EXPRESSION_LIMIT = 8; - var isNW = platformInfo.isNW; - var unitIndex = 0; + var _id; + var altCurrencyModal = null; var altUnitIndex = 0; var availableUnits = []; + var displayAddress = null; var fiatCode; - var fixedUnit; + var hasMaxAmount = true; + var isNW = platformInfo.isNW; + var isAndroid = platformInfo.isAndroid; + var isIos = platformInfo.isIOS; + var lastUsedAltCurrencyList = []; + var nextStep = null; + var unitToSatoshi; + var recipientType = null; + var satToUnit; + var showMenu = false; + var showWarningMessage = false; + var toAddress = ''; + var toColor = null; + var toEmail = null; + var toName = null; + var unitDecimals; + var unitIndex = 0; + var useSendMax = false; - $scope.amountModel = { amount: 0 }; - - $scope.isChromeApp = platformInfo.isChromeApp; - $scope.isAndroid = platformInfo.isAndroid; - $scope.isIos = platformInfo.isIOS; - - $scope.isRequestingSpecificAmount = false; - - $scope.$on('$ionicView.leave', function() { + function onLeave() { angular.element($window).off('keydown'); - }); - - $scope.$on("$ionicView.beforeEnter", function(event, data) { + } + function onBeforeEnter(event, data) { + initCurrencies(); if (data.stateParams.shapeshiftOrderId && data.stateParams.shapeshiftOrderId.length > 0) { - $scope.minShapeshiftAmount = parseFloat(data.stateParams.minShapeshiftAmount); - $scope.maxShapeshiftAmount = parseFloat(data.stateParams.maxShapeshiftAmount); - $scope.shapeshiftOrderId = data.stateParams.shapeshiftOrderId; + vm.minShapeshiftAmount = parseFloat(data.stateParams.minShapeshiftAmount); + vm.maxShapeshiftAmount = parseFloat(data.stateParams.maxShapeshiftAmount); + vm.shapeshiftOrderId = data.stateParams.shapeshiftOrderId; } // To get the wallet from with the new flow - $scope.fromWalletId = data.stateParams.fromWalletId; + vm.fromWalletId = data.stateParams.fromWalletId; if (data.stateParams.noPrefix) { - $scope.showWarningMessage = data.stateParams.noPrefix != 0; - if ($scope.showWarningMessage) { + showWarningMessage = data.stateParams.noPrefix != 0; + if (showWarningMessage) { var message = 'Address doesn\'t contain currency information, please make sure you are sending the correct currency.'; popupService.showAlert('', message, function() {}, 'Ok'); } } - $scope.isRequestingSpecificAmount = !!data.stateParams.id; - + vm.isRequestingSpecificAmount = !!data.stateParams.id; var config = configService.getSync().wallet.settings; + // Go to... + _id = data.stateParams.id; // Optional (BitPay Card ID or Wallet ID) + nextStep = data.stateParams.nextStep; + + setAvailableUnits(); + updateUnitUI(); + + if ($ionicHistory.backView().stateName == 'tabs.receive') { + hasMaxAmount = false; + } + + showMenu = $ionicHistory.backView() && ($ionicHistory.backView().stateName == 'tabs.send' || $ionicHistory.backView().stateName == 'tabs.bitpayCard'); + recipientType = data.stateParams.recipientType || null; + toAddress = data.stateParams.toAddress; + displayAddress = data.stateParams.displayAddress; + toName = data.stateParams.toName; + toEmail = data.stateParams.toEmail; + toColor = data.stateParams.toColor; + + if (!nextStep && !data.stateParams.toAddress) { + $log.error('Bad params at amount') + throw ('bad params'); + } + + var reNr = /^[1234567890\.]$/; + var reOp = /^[\*\+\-\/]$/; + + if (!isAndroid && !isIos) { + var disableKeys = angular.element($window).on('keydown', function(e) { + if (!e.key) return; + if (e.which === 8) { // you can add others here inside brackets. + if (!altCurrencyModal) { + e.preventDefault(); + vm.removeDigit(); + } + } + + if (e.key.match(reNr)) { + vm.pushDigit(e.key); + } else if (e.key.match(reOp)) { + pushOperator(e.key); + } else if (e.keyCode === 86) { + if (e.ctrlKey || e.metaKey) processClipboard(); + } else if (e.keyCode === 13) vm.finish(); + + $timeout(function() { + $scope.$apply(); + }); + }); + } + + unitToSatoshi = config.unitToSatoshi; + satToUnit = 1 / unitToSatoshi; + unitDecimals = config.unitDecimals; + + resetAmount(); + + // in SAT ALWAYS + if ($stateParams.toAmount) { + vm.amountModel.amount = (($stateParams.toAmount) * satToUnit).toFixed(unitDecimals); + } + + processAmount(); + + $timeout(function() { + $ionicScrollDelegate.resize(); + }, 10); + function setAvailableUnits() { var defaults = configService.getDefaults(); var configCache = configService.getSync(); @@ -139,82 +243,10 @@ angular.module('copayApp.controllers').controller('amountController', function($ altUnitIndex = 0; }; + }; - // Go to... - _id = data.stateParams.id; // Optional (BitPay Card ID or Wallet ID) - $scope.nextStep = data.stateParams.nextStep; - - setAvailableUnits(); - updateUnitUI(); - - $scope.hasMaxAmount = true; - if ($ionicHistory.backView().stateName == 'tabs.receive') { - $scope.hasMaxAmount = false; - } - - $scope.showMenu = $ionicHistory.backView() && ($ionicHistory.backView().stateName == 'tabs.send' || $ionicHistory.backView().stateName == 'tabs.bitpayCard'); - $scope.recipientType = data.stateParams.recipientType || null; - $scope.toAddress = data.stateParams.toAddress; - $scope.displayAddress = data.stateParams.displayAddress; - $scope.toName = data.stateParams.toName; - $scope.toEmail = data.stateParams.toEmail; - $scope.toColor = data.stateParams.toColor; - - if (!$scope.nextStep && !data.stateParams.toAddress) { - $log.error('Bad params at amount') - throw ('bad params'); - } - - var reNr = /^[1234567890\.]$/; - var reOp = /^[\*\+\-\/]$/; - - if (!$scope.isAndroid && !$scope.isIos) { - var disableKeys = angular.element($window).on('keydown', function(e) { - if (!e.key) return; - if (e.which === 8) { // you can add others here inside brackets. - if (!$scope.altCurrencyModal) { - e.preventDefault(); - $scope.removeDigit(); - } - } - - if (e.key.match(reNr)) { - $scope.pushDigit(e.key); - } else if (e.key.match(reOp)) { - $scope.pushOperator(e.key); - } else if (e.keyCode === 86) { - if (e.ctrlKey || e.metaKey) processClipboard(); - } else if (e.keyCode === 13) $scope.finish(); - - $timeout(function() { - $scope.$apply(); - }); - }); - } - - $scope.specificAmount = $scope.specificAlternativeAmount = ''; - $scope.isCordova = platformInfo.isCordova; - unitToSatoshi = config.unitToSatoshi; - satToUnit = 1 / unitToSatoshi; - satToBtc = 1 / 100000000; - unitDecimals = config.unitDecimals; - - $scope.resetAmount(); - - // in SAT ALWAYS - if ($stateParams.toAmount) { - $scope.amountModel.amount = (($stateParams.toAmount) * satToUnit).toFixed(unitDecimals); - } - - $scope.processAmount(); - - $timeout(function() { - $ionicScrollDelegate.resize(); - }, 10); - }); - - $scope.goBack = function() { - if ($scope.shapeshiftOrderId) { + function goBack() { + if (vm.shapeshiftOrderId) { $state.go('tabs.send').then(function() { $ionicHistory.clearHistory(); $state.go('tabs.home').then(function() { @@ -227,8 +259,8 @@ angular.module('copayApp.controllers').controller('amountController', function($ } function paste(value) { - $scope.amountModel.amount = value; - $scope.processAmount(); + vm.amountModel.amount = value; + processAmount(); $timeout(function() { $scope.$apply(); }); @@ -240,29 +272,22 @@ angular.module('copayApp.controllers').controller('amountController', function($ if (value && evaluate(value) > 0) paste(evaluate(value)); }; - $scope.sendMax = function() { - $scope.useSendMax = true; - $scope.finish(); - }; - - $scope.toggleAlternative = function() { - if ($scope.amountModel.amount && isExpression($scope.amountModel.amount)) { - var amount = evaluate(format($scope.amountModel.amount)); - $scope.globalResult = '= ' + processResult(amount); - } + function sendMax() { + useSendMax = true; + finish(); }; function updateUnitUI() { - $scope.unit = availableUnits[unitIndex].shortName; - $scope.alternativeUnit = availableUnits[altUnitIndex].shortName; + vm.unit = availableUnits[unitIndex].shortName; + vm.alternativeUnit = availableUnits[altUnitIndex].shortName; - $scope.processAmount(); - $log.debug('Update unit coin @amount unit:' + $scope.unit + " alternativeUnit:" + $scope.alternativeUnit); + processAmount(); + $log.debug('Update unit coin @amount unit:' + vm.unit + " alternativeUnit:" + vm.alternativeUnit); }; - $scope.changeUnit = function() { + function changeUnit() { - $scope.amountModel.amount = '0'; + vm.amountModel.amount = '0'; if (fixedUnit) return; @@ -282,59 +307,35 @@ angular.module('copayApp.controllers').controller('amountController', function($ updateUnitUI(); }; - - $scope.changeAlternativeUnit = function() { - - // Do nothing is fiat is not main unit - if (!availableUnits[unitIndex].isFiat) return; - - var nextCoin = lodash.findIndex(availableUnits, function(x) { - if (x.isFiat) return false; - if (x.id == availableUnits[altUnitIndex].id) return false; - return true; - }); - - if (nextCoin >= 0) { - altUnitIndex = nextCoin; - updateUnitUI(); - } - }; - - function checkFontSize() { - if ($scope.amountModel.amount && $scope.amountModel.amount.length >= SMALL_FONT_SIZE_LIMIT) $scope.smallFont = true; - else $scope.smallFont = false; - }; - - $scope.pushDigit = function(digit) { - if ($scope.amountModel.amount && digit != '.') { - var amountSplitByComma = $scope.amountModel.amount.split('.'); + function pushDigit(digit) { + if (vm.amountModel.amount && digit != '.') { + var amountSplitByComma = vm.amountModel.amount.split('.'); if (amountSplitByComma.length > 1 && amountSplitByComma[1].length >= LENGTH_AFTER_COMMA_EXPRESSION_LIMIT) return; if (amountSplitByComma.length == 1 && amountSplitByComma[0].length >= LENGTH_BEFORE_COMMA_EXPRESSION_LIMIT) return; } - if ($scope.amountModel.amount && $scope.amountModel.amount.length >= LENGTH_EXPRESSION_LIMIT) return; - if ($scope.amountModel.amount.indexOf('.') > -1 && digit == '.') return; - if ($scope.amountModel.amount == '0' && digit == '0') return; - if (availableUnits[unitIndex].isFiat && $scope.amountModel.amount.indexOf('.') > -1 && $scope.amountModel.amount[$scope.amountModel.amount.indexOf('.') + 2]) return; + if (vm.amountModel.amount && vm.amountModel.amount.length >= LENGTH_EXPRESSION_LIMIT) return; + if (vm.amountModel.amount.indexOf('.') > -1 && digit == '.') return; + if (vm.amountModel.amount == '0' && digit == '0') return; + if (availableUnits[unitIndex].isFiat && vm.amountModel.amount.indexOf('.') > -1 && vm.amountModel.amount[vm.amountModel.amount.indexOf('.') + 2]) return; - if ($scope.amountModel.amount == '0' && digit != '.') { - $scope.amountModel.amount = ''; + if (vm.amountModel.amount == '0' && digit != '.') { + vm.amountModel.amount = ''; } - if ($scope.amountModel.amount == '' && digit == '.') { - $scope.amountModel.amount = '0'; + if (vm.amountModel.amount == '' && digit == '.') { + vm.amountModel.amount = '0'; } - $scope.amountModel.amount = ($scope.amountModel.amount + digit).replace('..', '.'); - checkFontSize(); - $scope.processAmount(); + vm.amountModel.amount = (vm.amountModel.amount + digit).replace('..', '.'); + processAmount(); }; - $scope.pushOperator = function(operator) { - if (!$scope.amountModel.amount || $scope.amountModel.amount.length == 0) return; - $scope.amountModel.amount = _pushOperator($scope.amountModel.amount); + function pushOperator(operator) { + if (!vm.amountModel.amount || vm.amountModel.amount.length == 0) return; + vm.amountModel.amount = pushOperator(vm.amountModel.amount); - function _pushOperator(val) { + function pushOperator(val) { if (!isOperator(lodash.last(val))) { return val + operator; } else { @@ -353,61 +354,59 @@ angular.module('copayApp.controllers').controller('amountController', function($ return regex.test(val); }; - $scope.removeDigit = function() { - $scope.amountModel.amount = ($scope.amountModel.amount).toString().slice(0, -1); - $scope.processAmount(); - checkFontSize(); - }; + function removeDigit() { + vm.amountModel.amount = (vm.amountModel.amount).toString().slice(0, -1); + processAmount(); + } - $scope.resetAmount = function() { - $scope.amountModel.amount = $scope.alternativeAmount = $scope.globalResult = ''; - $scope.allowSend = false; - checkFontSize(); - }; + function resetAmount() { + vm.amountModel.amount = vm.alternativeAmount = vm.globalResult = ''; + vm.allowSend = false; + } - $scope.openPopup = function() { + function openPopup() { $ionicModal.fromTemplateUrl('views/modals/altCurrency.html', { scope: $scope }).then(function(modal) { - $scope.altCurrencyModal = modal; - $scope.altCurrencyModal.show(); + altCurrencyModal = modal; + altCurrencyModal.show(); }); + } + + function close() { + altCurrencyModal.remove(); + altCurrencyModal = null; }; - $scope.close = function() { - $scope.altCurrencyModal.remove(); - $scope.altCurrencyModal = false; - }; - - $scope.processAmount = function() { - var formatedValue = format($scope.amountModel.amount); + function processAmount() { + var formatedValue = format(vm.amountModel.amount); var result = evaluate(formatedValue); if (lodash.isNumber(result)) { - $scope.globalResult = isExpression($scope.amountModel.amount) ? '= ' + processResult(result) : ''; + vm.globalResult = isExpression(vm.amountModel.amount) ? '= ' + processResult(result) : ''; if (availableUnits[unitIndex].isFiat) { var a = fromFiat(result); if (a) { - $scope.alternativeAmount = txFormatService.formatAmount(a * unitToSatoshi, true); - $scope.allowSend = lodash.isNumber(a) && a > 0 - && (!$scope.shapeshiftOrderId - || (a >= $scope.minShapeshiftAmount && a <= $scope.maxShapeshiftAmount)); + vm.alternativeAmount = txFormatService.formatAmount(a * unitToSatoshi, true); + vm.allowSend = lodash.isNumber(a) && a > 0 + && (!vm.shapeshiftOrderId + || (a >= vm.minShapeshiftAmount && a <= vm.maxShapeshiftAmount)); } else { if (result) { - $scope.alternativeAmount = 'N/A'; + vm.alternativeAmount = 'N/A'; } else { - $scope.alternativeAmount = null; + vm.alternativeAmount = null; } - $scope.allowSend = false; + vm.allowSend = false; } } else { - $scope.alternativeAmount = $filter('formatFiatAmount')(toFiat(result)); - $scope.allowSend = lodash.isNumber(result) && result > 0 - && (!$scope.shapeshiftOrderId - || (result >= $scope.minShapeshiftAmount && result <= $scope.maxShapeshiftAmount)); + vm.alternativeAmount = $filter('formatFiatAmount')(toFiat(result)); + vm.allowSend = lodash.isNumber(result) && result > 0 + && (!vm.shapeshiftOrderId + || (result >= vm.minShapeshiftAmount && result <= vm.maxShapeshiftAmount)); } } }; @@ -448,24 +447,24 @@ angular.module('copayApp.controllers').controller('amountController', function($ return result.replace('x', '*'); }; - $scope.finish = function() { + function finish() { function finish() { var unit = availableUnits[unitIndex]; - var _amount = evaluate(format($scope.amountModel.amount)); + var _amount = evaluate(format(vm.amountModel.amount)); var coin = unit.id; if (unit.isFiat) { coin = availableUnits[altUnitIndex].id; } - if ($scope.nextStep) { - $state.transitionTo($scope.nextStep, { + if (nextStep) { + $state.transitionTo(nextStep, { id: _id, - amount: $scope.useSendMax ? null : _amount, + amount: useSendMax ? null : _amount, currency: unit.id.toUpperCase(), coin: coin, - useSendMax: $scope.useSendMax, - fromWalletId: $scope.fromWalletId + useSendMax: useSendMax, + fromWalletId: vm.fromWalletId }); } else { var amount = _amount; @@ -477,52 +476,52 @@ angular.module('copayApp.controllers').controller('amountController', function($ } var confirmData = { - recipientType: $scope.recipientType, + recipientType: recipientType, toAmount: amount, - toAddress: $scope.toAddress, - displayAddress: $scope.displayAddress || $scope.toAddress, - toName: $scope.toName, - toEmail: $scope.toEmail, - toColor: $scope.toColor, + toAddress: toAddress, + displayAddress: displayAddress || toAddress, + toName: toName, + toEmail: toEmail, + toColor: toColor, coin: coin, - useSendMax: $scope.useSendMax, - fromWalletId: $scope.fromWalletId + useSendMax: useSendMax, + fromWalletId: vm.fromWalletId }; - if ($scope.shapeshiftOrderId) { + if (vm.shapeshiftOrderId) { var shapeshiftOrderUrl = 'https://www.shapeshift.io/#/status/'; - shapeshiftOrderUrl += $scope.shapeshiftOrderId; + shapeshiftOrderUrl += vm.shapeshiftOrderId; confirmData.description = shapeshiftOrderUrl; - confirmData.fromWalletId = $scope.fromWalletId; + confirmData.fromWalletId = vm.fromWalletId; if (confirmData.useSendMax) { var wallet = lodash.find(profileService.getWallets({ coin: coin }), function(w) { - return w.id == $scope.fromWalletId; + return w.id == vm.fromWalletId; }); var balance = parseFloat(wallet.cachedBalance.substring(0, wallet.cachedBalance.length-4)); - if (balance < $scope.minShapeshiftAmount * 1.04) { + if (balance < vm.minShapeshiftAmount * 1.04) { confirmData.useSendMax = false; - confirmData.toAmount = $scope.minShapeshiftAmount * unitToSatoshi; - } else if (balance > $scope.maxShapeshiftAmount) { + confirmData.toAmount = vm.minShapeshiftAmount * unitToSatoshi; + } else if (balance > vm.maxShapeshiftAmount) { confirmData.useSendMax = false; - confirmData.toAmount = $scope.maxShapeshiftAmount * unitToSatoshi * 0.99; + confirmData.toAmount = vm.maxShapeshiftAmount * unitToSatoshi * 0.99; } } } $state.transitionTo('tabs.send.confirm', confirmData); } - $scope.useSendMax = null; + useSendMax = null; } - if ($scope.showWarningMessage) { - var u = $scope.unit == 'BCH' || $scope.unit == 'BTC' ? $scope.unit : $scope.alternativeUnit; + if (showWarningMessage) { + var u = vm.unit == 'BCH' || vm.unit == 'BTC' ? vm.unit : vm.alternativeUnit; var message = 'Are you sure you want to send ' + u.toUpperCase() + '?'; popupService.showConfirm(message, '', 'Yes', 'No', function(res) { if (!res) { - $scope.useSendMax = null; + useSendMax = null; return; }; finish(); @@ -566,10 +565,10 @@ angular.module('copayApp.controllers').controller('amountController', function($ }]; rateService.whenAvailable(function() { - $scope.listComplete = false; + vm.listComplete = false; var idx = lodash.indexBy(unusedCurrencyList, 'isoCode'); - var idx2 = lodash.indexBy($scope.lastUsedAltCurrencyList, 'isoCode'); + var idx2 = lodash.indexBy(lastUsedAltCurrencyList, 'isoCode'); var idx3 = lodash.indexBy(popularCurrencyList, 'isoCode'); var alternatives = rateService.listAlternatives(true); @@ -582,8 +581,8 @@ angular.module('copayApp.controllers').controller('amountController', function($ } }); - $scope.altCurrencyList = completeAlternativeList.slice(0, 10); - $scope.lastUsedPopularList = lodash.unique(lodash.union($scope.lastUsedAltCurrencyList, popularCurrencyList), 'isoCode'); + vm.altCurrencyList = completeAlternativeList.slice(0, 10); + vm.lastUsedPopularList = lodash.unique(lodash.union(lastUsedAltCurrencyList, popularCurrencyList), 'isoCode'); $timeout(function() { $scope.$apply(); @@ -591,19 +590,19 @@ angular.module('copayApp.controllers').controller('amountController', function($ }); } - $scope.loadMore = function() { + function loadMore() { $timeout(function() { - $scope.altCurrencyList = completeAlternativeList.slice(0, next); + vm.altCurrencyList = completeAlternativeList.slice(0, next); next += 10; - $scope.listComplete = $scope.altCurrencyList.length >= completeAlternativeList.length; + vm.listComplete = vm.altCurrencyList.length >= completeAlternativeList.length; $scope.$broadcast('scroll.infiniteScrollComplete'); }, 100); }; - $scope.findCurrency = function(search) { + function findCurrency(search) { if (!search) initCurrencies(); - var list = lodash.unique(lodash.union(completeAlternativeList, lodash.union($scope.lastUsedAltCurrencyList, popularCurrencyList)), 'isoCode'); - $scope.altCurrencyList = lodash.filter(list, function(item) { + var list = lodash.unique(lodash.union(completeAlternativeList, lodash.union(lastUsedAltCurrencyList, popularCurrencyList)), 'isoCode'); + vm.altCurrencyList = lodash.filter(list, function(item) { var val = item.name var val2 = item.isoCode; return lodash.includes(val.toLowerCase(), search.toLowerCase()) || lodash.includes(val2.toLowerCase(), search.toLowerCase()); @@ -613,7 +612,7 @@ angular.module('copayApp.controllers').controller('amountController', function($ }); }; - $scope.save = function(newAltCurrency) { + function save(newAltCurrency) { var opts = { wallet: { settings: { @@ -634,7 +633,7 @@ angular.module('copayApp.controllers').controller('amountController', function($ availableUnits[altUnitIndex].shortName = newAltCurrency.isoCode; fiatCode = newAltCurrency.isoCode; updateUnitUI(); - $scope.close(); + close(); }); }; -}); +} diff --git a/src/js/routes.js b/src/js/routes.js index 8277314e5..286b27ab1 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -291,6 +291,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr views: { 'tab-send@tabs': { controller: 'amountController', + controllerAs: 'vm', templateUrl: 'views/amount.html' } } @@ -699,6 +700,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr views: { 'tab-receive@tabs': { controller: 'amountController', + controllerAs: 'vm', templateUrl: 'views/amount.html' } } @@ -845,6 +847,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr views: { 'tab-home@tabs': { controller: 'amountController', + controllerAs: 'vm', templateUrl: 'views/amount.html' } } @@ -910,6 +913,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr views: { 'tab-home@tabs': { controller: 'amountController', + controllerAs: 'vm', templateUrl: 'views/amount.html' } } @@ -1029,6 +1033,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr views: { 'tab-home@tabs': { controller: 'amountController', + controllerAs: 'vm', templateUrl: 'views/amount.html' } }, @@ -1081,6 +1086,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr views: { 'tab-home@tabs': { controller: 'amountController', + controllerAs: 'vm', templateUrl: 'views/amount.html' } }, @@ -1137,6 +1143,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr views: { 'tab-home@tabs': { controller: 'amountController', + controllerAs: 'vm', templateUrl: 'views/amount.html' } } diff --git a/www/views/amount.html b/www/views/amount.html index e803ffc10..90187ef59 100644 --- a/www/views/amount.html +++ b/www/views/amount.html @@ -3,37 +3,37 @@ {{'Enter amount' | translate}} - +
-
- Minimum amount: {{minShapeshiftAmount}}
- Maximum amount: {{maxShapeshiftAmount}}
+
+ Minimum amount: {{vm.minShapeshiftAmount}}
+ Maximum amount: {{vm.maxShapeshiftAmount}}
- {{ amountModel.amount || 0 }}{{unit}} + ng-class="{long: vm.amountModel.amount.length > 5, 'very-long': vm.amountModel.amount.length > 10}"> + {{ vm.amountModel.amount || 0 }}{{vm.unit}}
- {{globalResult}} {{unit}} + {{vm.globalResult}} {{vm.unit}}
- {{alternativeAmount || '0.00'}} {{alternativeUnit}} + {{vm.alternativeAmount || '0.00'}} {{vm.alternativeUnit}}
-
+
- -
@@ -11,23 +11,23 @@
-
- {{lastUsedAltCurrency.name}} {{lastUsedAltCurrency.isoCode}} +
+ {{lastUsedAltCurrency.name}} {{lastUsedAltCurrency.isoCode}}
-
{{altCurrency.name}} {{altCurrency.isoCode}} +
{{altCurrency.name}} {{altCurrency.isoCode}}
From bba85794ac3599127b6627f11baaf6d435ee30a5 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Wed, 25 Jul 2018 16:17:42 +0900 Subject: [PATCH 143/386] BitAnalytics 0.2.1 with GA --- Gruntfile.js | 2 +- ...{bitanalytics-0.1.0.js => bitanalytics.js} | 260 +++++++++++++++--- src/js/controllers/addressbookAdd.js | 6 +- src/js/controllers/confirm.js | 6 +- .../controllers/preferencesNotifications.js | 6 +- src/js/controllers/tab-receive.js | 6 +- src/js/controllers/walletDetails.js | 6 +- src/js/routes.js | 6 +- src/js/services/profileService.js | 6 +- www/index.html | 7 +- 10 files changed, 245 insertions(+), 66 deletions(-) rename bitanalytics/{bitanalytics-0.1.0.js => bitanalytics.js} (97%) diff --git a/Gruntfile.js b/Gruntfile.js index 342cc85e7..eb4bb2eb0 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -163,7 +163,7 @@ module.exports = function(grunt) { }, bitanalytics: { src: [ - 'bitanalytics/bitanalytics-0.1.0.js' + 'bitanalytics/bitanalytics.js' ], dest: 'www/lib/bitanalytics.js' }, diff --git a/bitanalytics/bitanalytics-0.1.0.js b/bitanalytics/bitanalytics.js similarity index 97% rename from bitanalytics/bitanalytics-0.1.0.js rename to bitanalytics/bitanalytics.js index db149e481..c8c0d8870 100644 --- a/bitanalytics/bitanalytics-0.1.0.js +++ b/bitanalytics/bitanalytics.js @@ -6276,7 +6276,7 @@ var ClickAction = /** @class */ (function (_super) { }(action_1.default)); exports.default = ClickAction; -},{"../action":4,"../log-event":15,"../log-event-handlers":14}],6:[function(require,module,exports){ +},{"../action":4,"../log-event":16,"../log-event-handlers":15}],6:[function(require,module,exports){ "use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; @@ -6315,7 +6315,7 @@ var BitAnalytics = /** @class */ (function () { exports.default = BitAnalytics; BitAnalytics.main(); -},{"./action-factory":2,"./action-handlers":3,"./channels/adjust-channel":9,"./channels/mixpanel-channel":12,"./log-event":15,"./log-event-handlers":14}],7:[function(require,module,exports){ +},{"./action-factory":2,"./action-handlers":3,"./channels/adjust-channel":9,"./channels/mixpanel-channel":12,"./log-event":16,"./log-event-handlers":15}],7:[function(require,module,exports){ "use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; @@ -6560,11 +6560,10 @@ var FirebaseChannel = /** @class */ (function (_super) { var keys = Object.keys(params); var keysLength = keys.length; var sanitized = {}; - for (var i = 0; i < keysLength; i++) { - var key = keys[i]; + keys.map(function (key) { var cleanKey = key.replace('-', '_').replace(/[\W]+/g, ''); sanitized[cleanKey] = params[key]; - } + }); return sanitized; }; return FirebaseChannel; @@ -6588,13 +6587,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) { }; Object.defineProperty(exports, "__esModule", { value: true }); var channel_1 = __importDefault(require("../channel")); +var ga_1 = __importDefault(require("../external-libs/ga")); var GoogleAnalyticsChannel = /** @class */ (function (_super) { __extends(GoogleAnalyticsChannel, _super); function GoogleAnalyticsChannel(name, config) { var _this = _super.call(this, name) || this; - _this.dataLayer = null; _this.gaInstance = null; - _this.trackingId = ''; _this.eventLabels = ['id']; if (!config.trackingId) { throw new Error('[BitAnalytics] Google Analytics config is missing tracking ID.'); @@ -6602,8 +6600,12 @@ var GoogleAnalyticsChannel = /** @class */ (function (_super) { if (config.eventLabels) { _this.eventLabels = config.eventLabels; } - _this.trackingId = config.trackingId; - _this.setUpGa(); + _this.gaInstance = new ga_1.default({ + trackID: config.trackingId, + appVersion: config.appVersion, + appName: config.appName || 'App' + }); + _this.isReady = true; return _this; } /** @@ -6612,49 +6614,26 @@ var GoogleAnalyticsChannel = /** @class */ (function (_super) { * */ GoogleAnalyticsChannel.prototype.postEvent = function (name, params) { - // Default Google Analytics Events - // https://developers.google.com/analytics/devguides/collection/gtagjs/events - // Useful to convert to these, or start with these? if (this.isReady) { - params.event_category = name; + var category = name; + var action = name; + var label = name; + var value = params['value'] || ''; for (var _i = 0, _a = this.eventLabels; _i < _a.length; _i++) { var eventLabel = _a[_i]; if (params[eventLabel]) { - params.event_label = params[eventLabel]; + label = params[eventLabel]; break; } } - this.gtag('event', name, params); + this.gaInstance.event(category, action, label, value); } }; - /** - * - * Private methods - * - */ - /** - * Mimics function in the tracking snippet - */ - GoogleAnalyticsChannel.prototype.gtag = function () { - var args = []; - for (var _i = 0; _i < arguments.length; _i++) { - args[_i] = arguments[_i]; - } - console.log(arguments); - window.dataLayer.push(arguments); - }; - GoogleAnalyticsChannel.prototype.setUpGa = function () { - // From what GA recommends to insert into page - window.dataLayer = window.dataLayer || []; - this.gtag('js', new Date()); - this.gtag('config', this.trackingId); - this.isReady = true; - }; return GoogleAnalyticsChannel; }(channel_1.default)); exports.default = GoogleAnalyticsChannel; -},{"../channel":8}],12:[function(require,module,exports){ +},{"../channel":8,"../external-libs/ga":14}],12:[function(require,module,exports){ "use strict"; var __extends = (this && this.__extends) || (function () { var extendStatics = Object.setPrototypeOf || @@ -6746,6 +6725,207 @@ exports.default = MixpanelChannel; },{}],14:[function(require,module,exports){ "use strict"; +/* + * name: nwjs-analytics -Node-Webkit Google Analytics integration + * version: 1.0.2 + * github: https://github.com/Daaru00/nwjs-analytics + */ +function GA(opt) { + this.apiVersion = opt.apiVersion || '1'; + this.trackID = opt.trackID || 'UA-XXXXXXXX-X'; + this.clientID = opt.clientID || null; + this.userID = opt.userID || null; + this.appName = opt.appName || 'App'; + this.appVersion = opt.appVersion || '1.0.0'; + this.debug = opt.debug || false; + this.performanceTracking = opt.performanceTracking || true; + this.errorTracking = opt.errorTracking || true; + this.userLanguage = opt.userLanguage || "en"; + this.currency = opt.currency || "EUR"; + this.lastScreenName = opt.lastScreenName || ''; +} +GA.prototype.sendRequest = function (data, callback) { + var ga = this; + if (!this.clientID || this.clientID == null) + this.clientID = this.generateClientID(); + if (!this.userID || this.userID == null) + this.userID = this.generateClientID(); + var postData = "v=" + this.apiVersion + + "&an=" + this.appName + + "&av=" + this.appVersion + + "&tid=" + this.trackID + + "&cid=" + this.clientID + + "&sr=" + this.getScreenResolution() + + "&vp=" + this.getViewportSize(); + Object.keys(data).forEach(function (key) { + var val = data[key]; + if (typeof val != "undefined") + postData += "&" + key + "=" + val; + }); + var http = new XMLHttpRequest(); + var url = "https://www.google-analytics.com"; + if (!this.debug) + url += "/collect"; + else + url += "/debug/collect"; + http.open("GET", url + "?" + postData, true); + http.onreadystatechange = function () { + if (ga.debug) + console.log(http.response); + if (http.readyState == 4 && http.status == 200) { + if (callback) + callback(true); + } + else { + if (callback) + callback(false); + } + }; + http.send(); +}; +GA.prototype.generateClientID = function () { + var id = ""; + var possibilities = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"; + for (var i = 0; i < 5; i++) + id += possibilities.charAt(Math.floor(Math.random() * possibilities.length)); + return id; +}; +GA.prototype.getScreenResolution = function () { + return screen.width + "x" + screen.height; +}; +GA.prototype.getColorDept = function () { + return screen.colorDepth + "-bits"; +}; +GA.prototype.getUserAgent = function () { + return navigator.userAgent; +}; +GA.prototype.getViewportSize = function () { + return window.screen.availWidth + "x" + window.screen.availHeight; +}; +/* + * Measurement Protocol + * [https://developers.google.com/analytics/devguides/collection/protocol/v1/devguide] + */ +GA.prototype.screenView = function (screename) { + var data = { + 't': 'screenview', + 'cd': screename + }; + this.sendRequest(data); + this.lastScreenName = screename; +}; +GA.prototype.event = function (category, action, label, value) { + var data = { + 't': 'event', + 'ec': category, + 'ea': action, + }; + if (label) { + data['el'] = label; + } + if (value) { + data['ev'] = value; + } + if (this.lastScreenName) { + data['cd'] = this.lastScreenName; + } + this.sendRequest(data); +}; +GA.prototype.exception = function (msg, fatal) { + var data = { + 't': 'exception', + 'exd': msg, + 'exf': fatal || 0 + }; + this.sendRequest(data); +}; +GA.prototype.timing = function (category, variable, time, label) { + var data = { + 't': 'timing', + 'utc': category, + 'utv': variable, + 'utt': time, + 'utl': label, + }; + this.sendRequest(data); +}, + GA.prototype.ecommerce = { + transactionID: false, + generateTransactionID: function () { + var id = ""; + var possibilities = "0123456789"; + for (var i = 0; i < 5; i++) + id += possibilities.charAt(Math.floor(Math.random() * possibilities.length)); + return id; + }, + transaction: function (total, items) { + var t_id = ""; + if (!this.ecommerce.transactionID) + t_id = this.ecommerce.generateTransactionID(); + else + t_id = this.ecommerce.transactionID; + var data = { + 't': 'transaction', + 'ti': t_id, + 'tr': total, + 'cu': this.currency, + }; + this.sendRequest(data); + items.forEach(function (item) { + var data = { + 't': 'item', + 'ti': t_id, + 'in': item.name, + 'ip': item.price, + 'iq': item.qty, + 'ic': item.id, + 'cu': this.currency + }; + this.sendRequest(data); + }); + } + }, + GA.prototype.custom = function (data) { + this.sendRequest(data); + }; +module.exports = GA; +/* + * Performance Tracking + */ +/*window.addEventListener("load", function() { + + if(ga.performanceTracking) { + setTimeout(function() { + var timing = window.performance.timing; + var userTime = timing.loadEventEnd - timing.navigationStart; + ga.timing("performance", "pageload", userTime); + }, 0); + } + +}, false);*/ +/* + * Error Reporting + */ +/*window.onerror = function (msg, url, lineNo, columnNo, error) { + var message = [ + 'Message: ' + msg, + 'Line: ' + lineNo, + 'Column: ' + columnNo, + 'Error object: ' + JSON.stringify(error) + ].join(' - '); + + if(ga.errorTracking) + { + setTimeout(function() { + ga.exception(message.toString()); + }, 0); + } + + return false; +};*/ + +},{}],15:[function(require,module,exports){ +"use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; @@ -6865,7 +7045,7 @@ var LogEventHandlers = /** @class */ (function () { }()); exports.default = LogEventHandlers; -},{"./channel-factory":7}],15:[function(require,module,exports){ +},{"./channel-factory":7}],16:[function(require,module,exports){ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var LogEvent = /** @class */ (function () { diff --git a/src/js/controllers/addressbookAdd.js b/src/js/controllers/addressbookAdd.js index 9529d943e..e33f85725 100644 --- a/src/js/controllers/addressbookAdd.js +++ b/src/js/controllers/addressbookAdd.js @@ -36,9 +36,9 @@ angular.module('copayApp.controllers').controller('addressbookAddController', fu addressbook.address = translated.legacy; } - var channel = "firebase"; - if (platformInfo.isNW) { - channel = "ga"; + var channel = "ga"; + if (platformInfo.isCordova) { + channel = "firebase"; } var log = new window.BitAnalytics.LogEvent("contact_created", [{ "coin": $scope.addressbookEntry.coin diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index 03af26fd1..3c0465891 100644 --- a/src/js/controllers/confirm.js +++ b/src/js/controllers/confirm.js @@ -643,9 +643,9 @@ angular.module('copayApp.controllers').controller('confirmController', function( soundService.play('misc/payment_sent.mp3'); } - var channel = "firebase"; - if (platformInfo.isNW) { - channel = "ga"; + var channel = "ga"; + if (platformInfo.isCordova) { + channel = "firebase"; } var log = new window.BitAnalytics.LogEvent("transfer_success", [{ "coin": $scope.wallet.coin, diff --git a/src/js/controllers/preferencesNotifications.js b/src/js/controllers/preferencesNotifications.js index edfb983b5..a9a833ff7 100644 --- a/src/js/controllers/preferencesNotifications.js +++ b/src/js/controllers/preferencesNotifications.js @@ -76,9 +76,9 @@ angular.module('copayApp.controllers').controller('preferencesNotificationsContr emailService.updateEmail(opts); - var channel = "firebase"; - if (platformInfo.isNW) { - channel = "ga"; + var channel = "ga"; + if (platformInfo.isCordova) { + channel = "firebase"; } var log = new window.BitAnalytics.LogEvent("settings_email_notification_toggle", [{ "toggle": $scope.emailNotifications.value diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index 8f25412ec..29acb10d8 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -145,9 +145,9 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi } $scope.paymentReceivedCoin = $scope.wallet.coin; - var channel = "firebase"; - if (platformInfo.isNW) { - channel = "ga"; + var channel = "ga"; + if (platformInfo.isCordova) { + channel = "firebase"; } var log = new window.BitAnalytics.LogEvent("transfer_success", [{ "coin": $scope.wallet.coin, diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index 24237f6c9..241bbce89 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -12,9 +12,9 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun $scope.isAndroid = platformInfo.isAndroid; $scope.isIOS = platformInfo.isIOS; - var channel = "firebase"; - if (platformInfo.isNW) { - channel = "ga"; + var channel = "ga"; + if (platformInfo.isCordova) { + channel = "firebase"; } var log = new window.BitAnalytics.LogEvent("wallet_details_open", [], [channel]); window.BitAnalytics.LogEventHandlers.postEvent(log); diff --git a/src/js/routes.js b/src/js/routes.js index 8277314e5..665294b9b 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -1184,9 +1184,9 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }); - var channel = "firebase"; - if (platformInfo.isNW) { - channel = "ga"; + var channel = "ga"; + if (platformInfo.isCordova) { + channel = "firebase"; } // Send a log to test diff --git a/src/js/services/profileService.js b/src/js/services/profileService.js index 4f8710c28..e79b809f6 100644 --- a/src/js/services/profileService.js +++ b/src/js/services/profileService.js @@ -427,9 +427,9 @@ angular.module('copayApp.services') }, function(err, secret) { if (err) return bwcError.cb(err, gettextCatalog.getString('Error creating wallet'), cb); - var channel = "firebase"; - if (platformInfo.isNW) { - channel = "ga"; + var channel = "ga"; + if (platformInfo.isCordova) { + channel = "firebase"; } var log = new window.BitAnalytics.LogEvent("wallet_created", [{ "coin": opts.coin diff --git a/www/index.html b/www/index.html index 4c73317e3..ecc2d923c 100644 --- a/www/index.html +++ b/www/index.html @@ -11,9 +11,8 @@ - Bitcoin.com Wallet - Bitcoin.com Wallet - - + Bitcoin.com Wallet + @@ -31,7 +30,7 @@ - + From 029ac7dd39379b565668e6b6e4db1fbf57810842 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Wed, 25 Jul 2018 16:26:06 +0900 Subject: [PATCH 144/386] Fix the QRCode scan. --- src/js/controllers/addressbookAdd.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/js/controllers/addressbookAdd.js b/src/js/controllers/addressbookAdd.js index 9529d943e..89d648b46 100644 --- a/src/js/controllers/addressbookAdd.js +++ b/src/js/controllers/addressbookAdd.js @@ -21,6 +21,9 @@ angular.module('copayApp.controllers').controller('addressbookAddController', fu $timeout(function() { var form = addressbookForm; if (data && form) { + if (data.result) { + data = data.result; + } data = data.replace(/^bitcoin(cash)?:/, ''); form.address.$setViewValue(data); form.address.$isValid = true; From 4093e2ba71dff9800d24d3fcdff5980bb58c5dcf Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 25 Jul 2018 11:26:33 +0200 Subject: [PATCH 145/386] refactored the sendFlowController --- src/js/controllers/sendFlowController.js | 53 +++++++++--------------- 1 file changed, 19 insertions(+), 34 deletions(-) diff --git a/src/js/controllers/sendFlowController.js b/src/js/controllers/sendFlowController.js index d6f2b707d..400751867 100644 --- a/src/js/controllers/sendFlowController.js +++ b/src/js/controllers/sendFlowController.js @@ -2,75 +2,60 @@ angular.module('copayApp.controllers').controller('sendFlowController', function($scope, $rootScope, $state, $stateParams, $log, configService, gettextCatalog, profileService) { - var unitToSatoshi; - var satToUnit; - var unitDecimals; - var satToBtc; - var nextStep = ''; - $scope.$on("$ionicView.beforeEnter", function(event, data) { var config = configService.getSync().wallet.settings; $scope.params = $stateParams; - $scope.specificAmount = $scope.specificAlternativeAmount = ''; - unitToSatoshi = config.unitToSatoshi; - satToUnit = 1 / unitToSatoshi; - satToBtc = 1 / 100000000; - unitDecimals = config.unitDecimals; - - if ($scope.params.amount) { - console.log("is Payment Request", $scope.params.amount); - + if ($scope.params.amount) { // There is an amount, so presume that it a payment request + $scope.specificAmount = $scope.specificAlternativeAmount = ''; + var unitToSatoshi = config.unitToSatoshi; + var satToUnit = 1 / unitToSatoshi; + var satToBtc = 1 / 100000000; + var unitDecimals = config.unitDecimals; $scope.requestAmount = (($stateParams.amount) * satToUnit).toFixed(unitDecimals); $scope.isPaymentRequest = true; } }); $scope.$on("$ionicView.enter", function(event, data) { - console.log(data, $stateParams); + configService.whenAvailable(function(config) { + $scope.selectedPriceDisplay = config.wallet.settings.priceDisplay; + }); + $scope.type = data.stateParams && data.stateParams['fromWalletId'] ? 'destination' : 'origin'; // origin || destination $scope.coin = false; // Wallets to show (for destination screen) - $scope.walletsEmpty = []; - // Show price-header - - console.log("current type: "+$scope.type); + $scope.walletsEmpty = []; // empty wallets for origin screen if ($scope.type === 'origin') { $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send from'); $scope.walletsEmpty = profileService.getWallets({coin: $scope.coin, hasNoFunds: true}); } else if ($scope.type === 'destination') { - $scope.fromWallet = profileService.getWallet(data.stateParams.fromWalletId); - $scope.coin = $scope.fromWallet.coin; - + $scope.coin = $scope.fromWallet.coin; // Only show wallets with the select origin wallet coin $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send to'); } - if (!$scope.coin || $scope.coin === 'bch') { + if (!$scope.coin || $scope.coin === 'bch') { // if no specific coin is set or coin is set to bch $scope.walletsBch = profileService.getWallets({coin: 'bch', hasFunds: $scope.type==='origin'}); } - if (!$scope.coin || $scope.coin === 'btc') { + if (!$scope.coin || $scope.coin === 'btc') { // if no specific coin is set or coin is set btc $scope.walletsBtc = profileService.getWallets({coin: 'btc', hasFunds: $scope.type === 'origin'}); } - - configService.whenAvailable(function(config) { - $scope.selectedPriceDisplay = config.wallet.settings.priceDisplay; - }); }); function getNextStep() { - if (!$scope.params.toWalletId && !$scope.params.toAddress) { + if (!$scope.params.toWalletId && !$scope.params.toAddress) { // If we have no toAddress or fromWallet return 'tabs.send.destination'; - } else if (!$scope.params.amount) { + } else if (!$scope.params.amount) { // If we have no amount return 'tabs.send.amount'; - } else { + } else { // If we do have them return 'tabs.send.confirm'; } } $scope.useWallet = function(wallet) { - if ($scope.type === 'origin') { + if ($scope.type === 'origin') { // we're on the origin screen, set wallet to send from $scope.params['fromWalletId'] = wallet.id; - } else { + } else { // we're on the destination screen, set wallet to send to $scope.params['toWalletId'] = wallet.id; } $state.transitionTo(getNextStep(), $scope.params); From b88329fbb36811ce77cb5e783682e9e7dfdc9faa Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 25 Jul 2018 15:07:15 +0200 Subject: [PATCH 146/386] removed unused vars + changes for wallet to wallet transfer --- src/js/controllers/confirm.js | 109 +++++++++++------------ www/views/confirm.html | 4 +- www/views/wallet-origin-destination.html | 1 + 3 files changed, 54 insertions(+), 60 deletions(-) diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index 74b86e623..b57d2ca08 100644 --- a/src/js/controllers/confirm.js +++ b/src/js/controllers/confirm.js @@ -10,16 +10,10 @@ angular.module('copayApp.controllers').controller('confirmController', function( // Config Related values var config = configService.getSync(); var walletConfig = config.wallet; - var unitToSatoshi = walletConfig.settings.unitToSatoshi; - var unitDecimals = walletConfig.settings.unitDecimals; - var satToUnit = 1 / unitToSatoshi; var configFeeLevel = walletConfig.settings.feeLevel ? walletConfig.settings.feeLevel : 'normal'; - // Platform info - var isChromeApp = platformInfo.isChromeApp; var isCordova = platformInfo.isCordova; - var isWindowsPhoneApp = platformInfo.isCordova && platformInfo.isWP; //custom fee flag var usingCustomFee = false; @@ -31,7 +25,6 @@ angular.module('copayApp.controllers').controller('confirmController', function( }, 10); } - $scope.showWalletSelector = function() { $scope.walletSelector = true; refresh(); @@ -45,7 +38,6 @@ angular.module('copayApp.controllers').controller('confirmController', function( $ionicConfig.views.swipeBackEnabled(false); }); - function exitWithError(err) { $log.info('Error setting wallet selector:' + err); popupService.showAlert(gettextCatalog.getString(), bwcError.msg(err), function() { @@ -125,49 +117,8 @@ angular.module('copayApp.controllers').controller('confirmController', function( }); }; $scope.$on("$ionicView.beforeEnter", function(event, data) { - // Setup $scope + $scope.fromWallet = profileService.getWallet(data.stateParams.fromWalletId); // Wallet to send from - var B = data.stateParams.coin == 'bch' ? bitcoreCash : bitcore; - var networkName; - $scope.fromWallet = profileService.getWallet(data.stateParams.fromWalletId); - $scope.recipientType = null; - - try { - if (data.stateParams.toWalletId) { - $scope.recipientType = 'wallet'; // set type to wallet-to-wallet - $ionicLoading.show(); - var wallet = profileService.getWallet(data.stateParams.toWalletId); - walletService.getAddress(wallet, true, function (err, addr) { - $ionicLoading.hide(); - data.stateParams.toAddress = addr; - networkName = (new B.Address(data.stateParams.toAddress)).network.name; - vanityTx(networkName, data); - }); - } else if (data.stateParams.toAddress) { - networkName = (new B.Address(data.stateParams.toAddress)).network.name; - vanityTx(networkName, data); - } - } catch (e) { - var message = gettextCatalog.getString('Invalid address'); - var backText = gettextCatalog.getString('Go back'); - var learnText = gettextCatalog.getString('Learn more'); - popupService.showConfirm(null, message, backText, learnText, function (back) { - $ionicHistory.nextViewOptions({ - disableAnimate: true, - historyRoot: true - }); - $state.go('tabs.send').then(function () { - $ionicHistory.clearHistory(); - if (!back) { - var url = 'https://support.bitpay.com/hc/en-us/articles/115004671663'; - externalLinkService.open(url); - } - }); - }); - return; - } - }); - var vanityTx = function(networkName, data) { // Grab stateParams tx = { amount: parseInt(data.stateParams.amount), @@ -179,10 +130,10 @@ angular.module('copayApp.controllers').controller('confirmController', function( // Vanity tx info (not in the real tx) recipientType: $scope.recipientType || null, - toName: data.stateParams.toName, - toEmail: data.stateParams.toEmail, - toColor: data.stateParams.toColor, - network: networkName, + toName: null, + toEmail: null, + toColor: null, + network: false, coin: $scope.fromWallet.coin, txp: {}, }; @@ -192,10 +143,52 @@ angular.module('copayApp.controllers').controller('confirmController', function( tx.feeRate = parseInt(data.stateParams.requiredFeeRate); } - if (tx.coin && tx.coin == 'bch') { + if (tx.coin && tx.coin === 'bch') { tx.feeLevel = 'normal'; } + var B = data.stateParams.coin === 'bch' ? bitcoreCash : bitcore; + var networkName; + $scope.recipientType = null; + try { + if (data.stateParams.toWalletId) { // There is a toWalletId, so we presume this is a wallet-to-wallet transfer + $scope.recipientType = 'wallet'; // set transaction type to wallet-to-wallet + $ionicLoading.show(); + + var toWallet = profileService.getWallet(data.stateParams.toWalletId); + tx.toColor = toWallet.color; + tx.toName = toWallet.name; + + // We need an address to send to, so we ask the walletService to create a new address for the toWallet. + walletService.getAddress(toWallet, true, function (err, addr) { + $ionicLoading.hide(); + tx.toAddress = addr; + networkName = (new B.Address(tx.toAddress)).network.name; + tx.network = networkName; + setupTx(tx); + }); + } else { // This is a Wallet-to-address transfer + networkName = (new B.Address(tx.toAddress)).network.name; + tx.network = networkName; + setupTx(tx); + } + } catch (e) { + var message = gettextCatalog.getString('Invalid address'); + popupService.showAlert(null, message, function () { + $ionicHistory.nextViewOptions({ + disableAnimate: true, + historyRoot: true + }); + $state.go('tabs.send').then(function () { + $ionicHistory.clearHistory(); + }); + }); + return; + } + }); + + var setupTx = function(networkName, data) { + // Other Scope vars $scope.isCordova = isCordova; $scope.showAddress = false; @@ -410,19 +403,19 @@ angular.module('copayApp.controllers').controller('confirmController', function( function setButtonText(isMultisig, isPayPro) { if (isPayPro) { - if (isCordova && !isWindowsPhoneApp) { + if (isCordova) { $scope.buttonText = gettextCatalog.getString('Slide to pay'); } else { $scope.buttonText = gettextCatalog.getString('Click to pay'); } } else if (isMultisig) { - if (isCordova && !isWindowsPhoneApp) { + if (isCordova) { $scope.buttonText = gettextCatalog.getString('Slide to accept'); } else { $scope.buttonText = gettextCatalog.getString('Click to accept'); } } else { - if (isCordova && !isWindowsPhoneApp) { + if (isCordova) { $scope.buttonText = gettextCatalog.getString('Slide to send'); } else { $scope.buttonText = gettextCatalog.getString('Click to send'); diff --git a/www/views/confirm.html b/www/views/confirm.html index e54837f34..1def16389 100644 --- a/www/views/confirm.html +++ b/www/views/confirm.html @@ -105,13 +105,13 @@ {{buttonText}} diff --git a/www/views/wallet-origin-destination.html b/www/views/wallet-origin-destination.html index 66f5852ad..32ac73e59 100644 --- a/www/views/wallet-origin-destination.html +++ b/www/views/wallet-origin-destination.html @@ -1,6 +1,7 @@ {{'Wallet to wallet transfer' | translate}} +
From d51ab2bf79f732a9b5d4eb0a4e6404840367f993 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 25 Jul 2018 15:11:14 +0200 Subject: [PATCH 147/386] only change button color if it contains an address --- www/views/tab-send.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 8b39808db..999b940df 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -15,7 +15,7 @@
-
+ ng-if="!item.isWallet && item.recipientType != 'wallet'" ng-click="sendToContact(item)"> diff --git a/www/views/wallet-origin-destination.html b/www/views/wallet-origin-destination.html index 32ac73e59..4bdbde22b 100644 --- a/www/views/wallet-origin-destination.html +++ b/www/views/wallet-origin-destination.html @@ -1,13 +1,13 @@ - {{'Wallet to wallet transfer' | translate}} + {{sendFlowTitle}}
Paying
-
$37.42 USD
-
0.04580000 BCH {{requestAmount}}
+
$... USD
+
{{requestAmount}} {{coin.toUpperCase()}}
From decd0a123e1931aaea4ad2763e9fdd10f5701024 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 25 Jul 2018 16:43:45 -0700 Subject: [PATCH 151/386] Buttons on keypad have correct colour in new Enter Amount screen. --- src/js/routes.js | 2 +- src/sass/views/amountNew.scss | 484 ++++++++++++++++++++++++++++++++++ src/sass/views/views.scss | 1 + www/views/amountNew.html | 85 ++++++ 4 files changed, 571 insertions(+), 1 deletion(-) create mode 100644 src/sass/views/amountNew.scss create mode 100644 www/views/amountNew.html diff --git a/src/js/routes.js b/src/js/routes.js index 286b27ab1..5900b88da 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -701,7 +701,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr 'tab-receive@tabs': { controller: 'amountController', controllerAs: 'vm', - templateUrl: 'views/amount.html' + templateUrl: 'views/amountNew.html' } } }) diff --git a/src/sass/views/amountNew.scss b/src/sass/views/amountNew.scss new file mode 100644 index 000000000..cbffe4929 --- /dev/null +++ b/src/sass/views/amountNew.scss @@ -0,0 +1,484 @@ +#view-amount-new { + @extend .deflash-blue; + .recipient-label { + font-size: 14px; + padding-bottom: 0; + color: $v-mid-gray; + } + .item-no-bottom-border + .item { + border-top: 0; + } + .icon-bitpay-card { + background-image: url("../img/icon-bitpay.svg"); + } + .icon-amazon { + background-image: url("../img/icon-amazon.svg"); + } + @media(max-width: 480px) { + .bitcoin-address { + .icon { + left: 8px; + font-size: 24px; + } + .big-icon-svg { + left:5px; + & > .bg{ + width:30px; + height:30px; + box-shadow: none; + } + } + font-size: 13px; + padding-left: 48px; + } + } + @media(max-width: 320px) { + .bitcoin-address { + & > span:last-child { + margin-left: -2px; + } + } + } + .send-gravatar { + left: 11px; + position: absolute; + top: 10px; + } + .amount span input { + display: inline; + width: 120px; + } + .amount-pane-recipient { + position: absolute; + top: 95px; + bottom: 0; + width: 100%; + background-color: #fff; + padding: 0 16px; + + .amount-bar { + padding: 24px 0; + font-size: 18px; + @media(max-height: 480px) { + padding: 0px; + } + @media(max-width: 320px) { + padding: 0px; + } + .title { + float: left; + padding-top: 10px; + color: $v-dark-gray; + font-weight: bold; + @media(max-height: 480px) { + padding: 0px; + } + } + @media(max-height: 480px) { + padding-top: 3px; + } + } + .amount { + display: flex; + flex-direction: column; + justify-content: center; + flex-grow: 1; + position: absolute; + bottom: 254px; + top: 66px; + .light { + color: $v-light-gray; + } + @media(max-height: 480px) { + top: 45px; + } + @media(max-width: 320px) { + bottom: 276px; + top: 60px; + & > div { + display: inline-block; + } + & > div:first-child { + display: inherit; + } + } + } + } + .amount-pane-no-recipient { + position: absolute; + top: 0; + bottom: 0; + width: 100%; + background-color: #fff; + padding: 0 16px; + + .amount-bar { + padding: 24px 0; + font-size: 18px; + .title { + padding-top: 10px; + color: $v-dark-gray; + font-weight: bold; + .limits { + margin-top: 10px; + color: $v-light-gray; + font-size: 12px; + } + .select { + margin: 10px 1px; + } + } + } + .amount { + display: flex; + flex-direction: column; + justify-content: center; + flex-grow: 1; + position: absolute; + bottom: 254px; + top: 66px; + .light { + color: $v-light-gray; + } + } + } + .amount { + padding-top: 10px; + padding-bottom: 10px; + .icon-toggle { + font-size: 1.2em; + width: auto; + margin: 0.8em auto; + border: 1px solid $v-subtle-gray; + color: $v-dark-gray; + border-radius: 3px; + padding: 0 10px; + cursor: pointer; + @media(max-height: 280px) { + margin: 0.1em auto; + } + } + &__editable { + &--minimize { + font-size: 22px; + } + &--standard { + font-size: 42px; + @media(max-height: 480px) { + font-size: 26px; + padding-top: 10px; + } + } + &--placeholder { + color: $v-light-gray; + } + } + &__number { + color: $v-dark-gray; + } + &__currency-toggle { + border: 1px solid $v-subtle-gray; + color: $v-dark-gray; + border-radius: 3px; + padding: 0 10px; + cursor: pointer; + font-size: .6em; + position: relative; + top: -3px; + line-height: 1; + @media(max-width: 320px) { + line-height: 30px; + height: 30px; + } + } + &__currency-toggle-mobile { + border: 1px solid $v-subtle-gray; + color: $v-dark-gray; + border-radius: 3px; + cursor: pointer; + position: relative; + line-height: 1; + @media(max-width: 320px) { + line-height: 30px; + height: 30px; + } + } + &__results { + &--minimize { + font-size: 12px; + } + &--standard { + font-size: 18px; + padding: 10px 0; + } + &--placeholder { + color: $v-light-gray; + } + } + &__result { + color: $v-light-gray; + font-size: .9em; + //margin-bottom: -.9em; TODO matias + line-height: 1; + @media(max-height: 480px) { + margin-bottom: 0; + } + } + &__result-equiv { + color: $v-mid-gray; + font-size: 1.2em; + @media(max-height: 480px) { + margin-top: 0; + font-size: 16px; + } + } + } + + .scroll-content { + display: flex; + flex-direction: column; + + .send-amount { + flex: 1 1 auto; + display: flex; + flex-direction: column; + justify-content: center; + + .send-amount-tool { + flex: 0 1 auto; + + .send-amount-tool-input { + text-align: center; + position: relative; + padding: 10px 30px; + + .text-selectable { + -webkit-user-select: text; + -moz-user-select: text; + -ms-user-select: text; + user-select: text; + } + + .primary-amount { + input, .unit, .primary-amount-display { + font-size: 1.8em; + + @media (min-width: 375px) { + font-size: 2.1em; + } + + @media (min-width: 414px) { + font-size: 2.4em; + } + } + + &.long { + input, .unit, .primary-amount-display { + font-size: 1.6em; + + @media (min-width: 375px) { + font-size: 1.8em; + } + + @media (min-width: 414px) { + font-size: 2em; + } + } + } + + &.very-long { + input, .unit, .primary-amount-display { + font-size: 0.9em; + + @media (min-width: 375px) { + font-size: 1.3em; + } + + @media (min-width: 414px) { + font-size: 1.4em; + } + } + } + + + input { + border:0; + padding:0; + white-space:normal; + background:none; + line-height:1; + box-sizing:content-box; + display: inline-block; + vertical-align: middle; + margin: 0; + height: 1em; + margin-right: 5px; + font-family: 'ProximaNova'; + + @media (min-width: 375px) { + } + + @media (min-width: 414px) { + } + } + + .unit, + .primary-amount-display { + display: inline-block; + vertical-align: middle; + line-height: 1em; + } + + .unit { + font-weight: bold; + } + + .primary-amount-display { + margin-right: 5px; + word-break: break-all; + } + } + + .switch-currencies { + position: absolute; + right: 0; + top: 50%; + transform: translate(0, -50%); + padding: 15px; + + img { + width: 18px; + } + } + } + + .send-amount-actions { + margin-top: 15px; + display: flex; + align-items: center; + justify-content: center; + + .button { + flex: 1 1 auto; + line-height: 1.2em; + + + .button { + margin-left: 10px; + } + + span { + display: flex; + align-items: center; + justify-content: center; + } + } + } + } + } + + .button { + &.no-margin { + margin: 0; + } + } + + .notification-warning { + display: block; + padding: .75rem 1.25rem; + color: #856404; + background-color: #fff3cd; + border: 1px solid #ffeeba; + line-height: 1.4em; + margin-bottom: 20px; + } + + .keypad-container { + position: relative; + //flex: 0 1 196px; + + @media (min-height: 667px) { + //flex: 0 1 224px; + } + + .keypad { + text-align: center; + font-size: 18px; + font-weight: lighter; + position: absolute; + bottom: 0; + width: 100%; + color: $v-text-primary-color; + + @media (min-height: 667px) { + font-size: 24px; + } + + .row { + padding: 0 !important; + margin: 0 !important; + } + + .col { + line-height: 38px; + + @media (min-height: 667px) { + line-height: 45px; + } + } + + .row { + &:last-child { + .col { + padding-bottom: 10px; + } + } + } + + .operator { + background-color: $v-subtle-gray; + font-weight: normal; + cursor: pointer; + + &:active { + background-color: $v-light-gray; + } + } + + .operator-send { + font-weight: bolder; + color: #fff; + background-color: $positive; + font-size: 36px; + cursor: pointer; + + &:active { + background-color: #eaeaea; + } + } + + .digit{ + cursor: pointer; + background-color: #000; + border: 1px solid #262424; + transition: all 0.1s ease; + + + &:active { + background-color: $v-dark-gray; + } + } + + @media(max-height: 480px) { + font-size: 12px; + + } + } + } + } + background: #494949; + + ion-content { + margin-bottom: constant(safe-area-inset-bottom); /* iOS 11.0 */ + margin-bottom: env(safe-area-inset-bottom); /* iOS 11.2 */ + } +} \ No newline at end of file diff --git a/src/sass/views/views.scss b/src/sass/views/views.scss index d4ed735ed..387b68597 100644 --- a/src/sass/views/views.scss +++ b/src/sass/views/views.scss @@ -1,6 +1,7 @@ @import "tabs"; @import "add"; @import "amount"; +@import "amountNew"; @import "confirm"; @import "copayers"; @import "starting"; diff --git a/www/views/amountNew.html b/www/views/amountNew.html new file mode 100644 index 000000000..6fe58eb9b --- /dev/null +++ b/www/views/amountNew.html @@ -0,0 +1,85 @@ + + + + {{'Enter amount (New)' | translate}} + + + + + +
+ +
+
+ Minimum amount: {{vm.minShapeshiftAmount}}
+ Maximum amount: {{vm.maxShapeshiftAmount}}
+
+
+
+
+ {{ vm.amountModel.amount || 0 }}{{vm.unit}} +
+ {{vm.globalResult}} {{vm.unit}} +
+ {{vm.alternativeAmount || '0.00'}} {{vm.alternativeUnit}} +
+
+
+
+ + +
+
+
+
+ +
+
+ +
+
7
+
8
+
9
+
+ +
+
4
+
5
+
6
+
+ +
+
1
+
2
+
3
+
+ +
+
.
+
0
+
+
+
+
+ + +
+
\ No newline at end of file From e539f0e713bb095dfa8f0869e983ba575df49a99 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 25 Jul 2018 17:32:07 -0700 Subject: [PATCH 152/386] Space around amount, and added "Not Enough Funds" warning. --- src/sass/views/amountNew.scss | 9 +++++++ www/views/amountNew.html | 45 ++++++++++++++++++++--------------- 2 files changed, 35 insertions(+), 19 deletions(-) diff --git a/src/sass/views/amountNew.scss b/src/sass/views/amountNew.scss index cbffe4929..0d1798e25 100644 --- a/src/sass/views/amountNew.scss +++ b/src/sass/views/amountNew.scss @@ -244,6 +244,15 @@ flex-direction: column; justify-content: center; + .send-amount-header-footer { + flex: 1 1 auto; + min-height: 10px; + + .warning { + text-align:center; + } + } + .send-amount-tool { flex: 0 1 auto; diff --git a/www/views/amountNew.html b/www/views/amountNew.html index 6fe58eb9b..e6b11750c 100644 --- a/www/views/amountNew.html +++ b/www/views/amountNew.html @@ -1,7 +1,7 @@ - {{'Enter amount (New)' | translate}} + {{'Enter Amount' | translate}} @@ -9,10 +9,12 @@
-
-
- Minimum amount: {{vm.minShapeshiftAmount}}
- Maximum amount: {{vm.maxShapeshiftAmount}}
+
+
@@ -26,21 +28,26 @@
-
- - + -
+
+
+
+ +
From 91daae9f7a8fbe046b65218c3d3e364512cfbbc2 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 25 Jul 2018 18:19:21 -0700 Subject: [PATCH 153/386] Improved amount card layout. Darker background under card. --- src/sass/views/amountNew.scss | 19 ++++++++++++------- www/views/amountNew.html | 2 +- 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/src/sass/views/amountNew.scss b/src/sass/views/amountNew.scss index 0d1798e25..894135725 100644 --- a/src/sass/views/amountNew.scss +++ b/src/sass/views/amountNew.scss @@ -246,10 +246,14 @@ .send-amount-header-footer { flex: 1 1 auto; - min-height: 10px; + min-height: 20px; .warning { - text-align:center; + color: #b7664d; + font-family: 'ProximaNova-Semibold'; + font-size: 12pt; + padding: 0 6px 6px 6px; + text-align: center; } } @@ -269,6 +273,8 @@ } .primary-amount { + color: #333; + font-family: 'ProximaNova-Semibold'; input, .unit, .primary-amount-display { font-size: 1.8em; @@ -338,16 +344,15 @@ line-height: 1em; } - .unit { - font-weight: bold; - } - .primary-amount-display { margin-right: 5px; word-break: break-all; } } + .alternative-amount { + color: #6F6F70; + } .switch-currencies { position: absolute; right: 0; @@ -484,7 +489,7 @@ } } } - background: #494949; + background: #f2f2f2; ion-content { margin-bottom: constant(safe-area-inset-bottom); /* iOS 11.0 */ diff --git a/www/views/amountNew.html b/www/views/amountNew.html index e6b11750c..b9b6c08b2 100644 --- a/www/views/amountNew.html +++ b/www/views/amountNew.html @@ -5,7 +5,7 @@ - +
From 507fb21862c4a1b0eb95742fb5e6d537275efc94 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 25 Jul 2018 18:46:42 -0700 Subject: [PATCH 154/386] Available funds. --- src/js/controllers/amount.js | 2 ++ src/sass/views/amountNew.scss | 42 +++++++++++++++++++++-------------- www/views/amountNew.html | 20 ++++++++++------- 3 files changed, 39 insertions(+), 25 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 1bc492136..1d4cb41f1 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -10,6 +10,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i vm.alternativeAmount = ''; vm.alternativeUnit = ''; vm.amountModel = { amount: 0 }; + vm.availableFunds = '251.00 USD'; vm.fromWalletId = ''; vm.globalResult = ''; vm.isRequestingSpecificAmount = false; @@ -409,6 +410,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i || (result >= vm.minShapeshiftAmount && result <= vm.maxShapeshiftAmount)); } } + console.log('allowSend: ', vm.allowSend); }; function processResult(val) { diff --git a/src/sass/views/amountNew.scss b/src/sass/views/amountNew.scss index 894135725..37de78665 100644 --- a/src/sass/views/amountNew.scss +++ b/src/sass/views/amountNew.scss @@ -365,27 +365,35 @@ } } } + } + } - .send-amount-actions { - margin-top: 15px; + .send-amount-extras { + display: flex; + flex: 0 0 auto; + flex-direction: row-reverse; + align-items: center; + justify-content: space-between; + margin: 0 14px; + + .extra { + display: inline-block; + flex: 0 1 auto; + font-size: 12pt; + } + + .button { + flex: 0 1 auto; + line-height: 1.2em; + + + .button { + margin-left: 10px; + } + + span { display: flex; align-items: center; justify-content: center; - - .button { - flex: 1 1 auto; - line-height: 1.2em; - - + .button { - margin-left: 10px; - } - - span { - display: flex; - align-items: center; - justify-content: center; - } - } } } } diff --git a/www/views/amountNew.html b/www/views/amountNew.html index b9b6c08b2..9d44e9e8d 100644 --- a/www/views/amountNew.html +++ b/www/views/amountNew.html @@ -35,20 +35,24 @@
-
- - +
+ Available Funds: {{vm.availableFunds}} +
+
+
From 2492a405a1ae6f86f9d1098052134d55db2cab76 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Thu, 26 Jul 2018 14:29:53 +0800 Subject: [PATCH 155/386] Adds fee-summary bar, adds amount directive, adds support for fee-summary overlapping with content on scrollable small screens --- src/js/directives/amount.js | 21 +++++++++++++ src/sass/components/amount.scss | 24 ++++++++++++++ src/sass/components/components.scss | 2 ++ src/sass/components/fee-summary.scss | 33 +++++++++++++++++++ src/sass/components/ion-content.scss | 4 +++ src/sass/views/review.scss | 5 +++ www/css/main.css | 47 ++++++++++++++++++++++++++++ www/views/includes/amount.html | 6 ++++ www/views/review.html | 13 +++++++- 9 files changed, 154 insertions(+), 1 deletion(-) create mode 100644 src/js/directives/amount.js create mode 100644 src/sass/components/amount.scss create mode 100644 src/sass/components/fee-summary.scss create mode 100644 www/views/includes/amount.html diff --git a/src/js/directives/amount.js b/src/js/directives/amount.js new file mode 100644 index 000000000..e86bec2fe --- /dev/null +++ b/src/js/directives/amount.js @@ -0,0 +1,21 @@ +'use strict'; +angular.module('bitcoincom.directives') + .directive('amount', [ + '$timeout', + function($timeout) { + return { + restrict: 'E', + scope: { + value: '=', + currency: '=' + }, + templateUrl: 'views/includes/amount.html', + controller: ['$scope', function($scope) { + var valueFormatted = parseFloat($scope.value).toFixed(8); + $scope.start = valueFormatted.slice(0, -5); + $scope.middle = valueFormatted.slice(-5, -2); + $scope.end = valueFormatted.substr(valueFormatted.length - 2); + }] + }; + } +]); \ No newline at end of file diff --git a/src/sass/components/amount.scss b/src/sass/components/amount.scss new file mode 100644 index 000000000..eb0768f4f --- /dev/null +++ b/src/sass/components/amount.scss @@ -0,0 +1,24 @@ +.amount { + .start, + .middle, + .end, + .currency { + display: inline-block; + } + + .start { + font-size: 14px; + } + + .middle { + font-size: 11px; + } + + .end { + font-size: 11px; + } + + .currency { + font-size: 14px; + } +} \ No newline at end of file diff --git a/src/sass/components/components.scss b/src/sass/components/components.scss index 180279125..8d8346265 100644 --- a/src/sass/components/components.scss +++ b/src/sass/components/components.scss @@ -7,3 +7,5 @@ @import "address"; @import "action-minor"; @import "expand-content"; +@import "fee-summary"; +@import "amount"; diff --git a/src/sass/components/fee-summary.scss b/src/sass/components/fee-summary.scss new file mode 100644 index 000000000..5f5236d0c --- /dev/null +++ b/src/sass/components/fee-summary.scss @@ -0,0 +1,33 @@ +.fee-summary { + position: relative; + display: flex; + justify-content: space-between; + width: 100%; + padding: 5px 12px 15px; + box-sizing: border-box; + background-color: #F2F2F2; + + &:before { + content: ''; + position: absolute; + left: 0; + top: -15px; + width: 100%; + height: 15px; + background: linear-gradient(to bottom, rgba(242,242,242,0) 0%,rgba(242,242,242,1) 100%); + } + + .fee-fiat { + &.positive { + color: #70955F; + } + + &.negative { + color: #C24633; + } + } + + .fee-crypto { + color: #BCBCBC; + } +} \ No newline at end of file diff --git a/src/sass/components/ion-content.scss b/src/sass/components/ion-content.scss index 7be47c9ab..56f3960a0 100644 --- a/src/sass/components/ion-content.scss +++ b/src/sass/components/ion-content.scss @@ -10,4 +10,8 @@ ion-content { &.padded-bottom-cta { bottom: 92px; } + + &.padded-bottom-cta-with-summary { + bottom: 134px; + } } \ No newline at end of file diff --git a/src/sass/views/review.scss b/src/sass/views/review.scss index e1d4ebd07..67733fe22 100644 --- a/src/sass/views/review.scss +++ b/src/sass/views/review.scss @@ -5,4 +5,9 @@ margin-bottom: constant(safe-area-inset-bottom); /* iOS 11.0 */ margin-bottom: env(safe-area-inset-bottom); /* iOS 11.2 */ } + + .fee-summary { + position: absolute; + bottom: 92px; + } } \ No newline at end of file diff --git a/www/css/main.css b/www/css/main.css index df8779400..063f60ff7 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -15074,6 +15074,9 @@ log-options #check-bar .checkbox-icon { /* iOS 11.0 */ margin-bottom: env(safe-area-inset-bottom); /* iOS 11.2 */ } + #view-review .fee-summary { + position: absolute; + bottom: 92px; } .gravatar { border-radius: 3px; @@ -15127,6 +15130,9 @@ ion-content.bg-neutral { ion-content.padded-bottom-cta { bottom: 92px; } +ion-content.padded-bottom-cta-with-summary { + bottom: 134px; } + .card.card-gutter-compact { margin: 10px 12px; } @@ -15212,6 +15218,47 @@ ion-content.padded-bottom-cta { opacity: 1; transform: scale(1, 1); } +.fee-summary { + position: relative; + display: flex; + justify-content: space-between; + width: 100%; + padding: 5px 12px 15px; + box-sizing: border-box; + background-color: #F2F2F2; } + .fee-summary:before { + content: ''; + position: absolute; + left: 0; + top: -15px; + width: 100%; + height: 15px; + background: linear-gradient(to bottom, rgba(242, 242, 242, 0) 0%, #f2f2f2 100%); } + .fee-summary .fee-fiat.positive { + color: #70955F; } + .fee-summary .fee-fiat.negative { + color: #C24633; } + .fee-summary .fee-crypto { + color: #BCBCBC; } + +.amount .start, +.amount .middle, +.amount .end, +.amount .currency { + display: inline-block; } + +.amount .start { + font-size: 14px; } + +.amount .middle { + font-size: 11px; } + +.amount .end { + font-size: 11px; } + +.amount .currency { + font-size: 14px; } + /* This is for rules that don't yet have a home. * Our goal is to delete this file. Search the regex: /class=".*CLASS.*?"/ */ diff --git a/www/views/includes/amount.html b/www/views/includes/amount.html new file mode 100644 index 000000000..791983c06 --- /dev/null +++ b/www/views/includes/amount.html @@ -0,0 +1,6 @@ +
+ {{start}} + {{middle}} + {{end}} + {{currency}} +
\ No newline at end of file diff --git a/www/views/review.html b/www/views/review.html index 9de1a403e..4995d3d25 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -7,7 +7,7 @@ -
@@ -63,6 +63,17 @@
+ +
+
Fee: Less than 1 cent
+
+ +
+
+ Date: Thu, 26 Jul 2018 15:04:42 +0200 Subject: [PATCH 156/386] Wallet buttons max width + Receive in viewing wallet. --- src/js/controllers/tab-receive.js | 10 +++++++--- src/js/controllers/walletDetails.js | 11 +++++++++++ src/js/routes.js | 2 +- src/sass/views/tab-home.scss | 4 ++-- src/sass/views/walletDetails.scss | 4 ++-- www/views/walletDetails.html | 2 +- 6 files changed, 24 insertions(+), 9 deletions(-) diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index 8f25412ec..dcb2d1166 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -233,10 +233,14 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi if (!$scope.wallets[0]) return; - // select first wallet if no wallet selected previously - var selectedWallet = checkSelectedWallet($scope.wallet, $scope.wallets); + var selectedWallet = null; + if (data.stateParams.walletId) { // from walletDetails + selectedWallet = checkSelectedWallet(profileService.getWallet(data.stateParams.walletId), $scope.wallets); + } else { + // select first wallet if no wallet selected previously + selectedWallet = checkSelectedWallet($scope.wallet, $scope.wallets); + } $scope.onWalletSelect(selectedWallet); - $scope.showShareButton = platformInfo.isCordova ? (platformInfo.isIOS ? 'iOS' : 'Android') : null; listeners = [ diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index b3fea717e..2436da730 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -483,4 +483,15 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun function rgbToHex(r, g, b) { return "#" + componentToHex(r) + componentToHex(g) + componentToHex(b); } + + $scope.goToReceive = function() { + $state.go('tabs.home', { + walletId: $scope.wallet.id + }).then(function () { + $ionicHistory.clearHistory(); + $state.go('tabs.receive', { + walletId: $scope.wallet.id + }); + }); + }; }); diff --git a/src/js/routes.js b/src/js/routes.js index 8277314e5..f00679727 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -236,7 +236,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }) .state('tabs.receive', { - url: '/receive', + url: '/receive/:walletId', views: { 'tab-receive': { controller: 'tabReceiveController', diff --git a/src/sass/views/tab-home.scss b/src/sass/views/tab-home.scss index 69cdfde4d..680738a3b 100644 --- a/src/sass/views/tab-home.scss +++ b/src/sass/views/tab-home.scss @@ -70,8 +70,8 @@ } } .buttons { - margin-bottom: 0; - margin-top: 6px; + margin: 6px auto 0px; + max-width: 600px; >.col { padding: 5px 10px; margin-bottom: 0; diff --git a/src/sass/views/walletDetails.scss b/src/sass/views/walletDetails.scss index 6be9e6cf2..d03530cbb 100644 --- a/src/sass/views/walletDetails.scss +++ b/src/sass/views/walletDetails.scss @@ -192,8 +192,8 @@ } .buttons { - margin-bottom: 0; - margin-top: 30px; + max-width: 600px; + margin: 30px auto 0; >.col { padding: 5px 10px; margin-bottom: 0; diff --git a/www/views/walletDetails.html b/www/views/walletDetails.html index e2c0f7342..2da69fb6e 100644 --- a/www/views/walletDetails.html +++ b/www/views/walletDetails.html @@ -92,7 +92,7 @@
-
+
Receive
From b2ed16bf2198e48a6eb0ce9c85e4ba4d1b5b0858 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 26 Jul 2018 19:38:29 +0200 Subject: [PATCH 157/386] mobile support for send/receive buttons and some refactors to fix the navigation flow. --- src/js/controllers/walletDetails.js | 17 ++++++++++++++++- src/sass/views/tab-home.scss | 6 +++--- src/sass/views/walletDetails.scss | 12 ++++-------- www/views/walletDetails.html | 24 +++++++++++++++++++++--- 4 files changed, 44 insertions(+), 15 deletions(-) diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index 2436da730..c824cbfda 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -483,7 +483,14 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun function rgbToHex(r, g, b) { return "#" + componentToHex(r) + componentToHex(g) + componentToHex(b); } - + $scope.goToSend = function() { + $state.go('tabs.home', { + walletId: $scope.wallet.id + }).then(function () { + $ionicHistory.clearHistory(); + $state.go('tabs.send'); + }); + }; $scope.goToReceive = function() { $state.go('tabs.home', { walletId: $scope.wallet.id @@ -494,4 +501,12 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun }); }); }; + $scope.goToBuy = function() { + $state.go('tabs.home', { + walletId: $scope.wallet.id + }).then(function () { + $ionicHistory.clearHistory(); + $state.go('tabs.buyandsell'); + }); + }; }); diff --git a/src/sass/views/tab-home.scss b/src/sass/views/tab-home.scss index 680738a3b..708ff4fad 100644 --- a/src/sass/views/tab-home.scss +++ b/src/sass/views/tab-home.scss @@ -70,7 +70,7 @@ } } .buttons { - margin: 6px auto 0px; + margin: 6px auto -12px; max-width: 600px; >.col { padding: 5px 10px; @@ -84,8 +84,8 @@ width: 100%; font-size: 19px; font-weight: bolder; - min-height: 45px; - line-height: 45px; + min-height: auto; + line-height: 36px; } } .wallet-coin-logo { diff --git a/src/sass/views/walletDetails.scss b/src/sass/views/walletDetails.scss index d03530cbb..0536a5735 100644 --- a/src/sass/views/walletDetails.scss +++ b/src/sass/views/walletDetails.scss @@ -132,10 +132,6 @@ position: relative; height: 100%; height: calc(100% - env(safe-area-inset-bottom) * 2); - - &.status-bar { - margin-top: 20px; - } } .bar-header { border: 0; @@ -191,9 +187,9 @@ } } - .buttons { + .send-receive-buttons { max-width: 600px; - margin: 30px auto 0; + margin: 45px auto 0; >.col { padding: 5px 10px; margin-bottom: 0; @@ -206,8 +202,8 @@ width: 100%; font-size: 19px; font-weight: bolder; - min-height: 40px; - line-height: 40px; + min-height: auto; + line-height: 36px; } } } diff --git a/www/views/walletDetails.html b/www/views/walletDetails.html index 2da69fb6e..85aace8fc 100644 --- a/www/views/walletDetails.html +++ b/www/views/walletDetails.html @@ -90,21 +90,23 @@
-
+ +
Receive
-
+
Buy Bitcoin
-
+
Send
+
@@ -212,6 +214,22 @@
+
+
+
+ Receive +
+
+
+
+ Buy Bitcoin +
+
+ Send +
+
+
+
From 8fd0b76a44d5acaeeedae7261a2d073f87b292a9 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 26 Jul 2018 13:09:16 -0700 Subject: [PATCH 158/386] Change Currency button appearance. --- src/sass/views/amountNew.scss | 34 +++++++++++++++------ www/img/icon-alternative-currency-black.svg | 22 +++++++++++++ www/views/amountNew.html | 10 +++--- 3 files changed, 52 insertions(+), 14 deletions(-) create mode 100644 www/img/icon-alternative-currency-black.svg diff --git a/src/sass/views/amountNew.scss b/src/sass/views/amountNew.scss index 37de78665..5229f9b56 100644 --- a/src/sass/views/amountNew.scss +++ b/src/sass/views/amountNew.scss @@ -251,7 +251,7 @@ .warning { color: #b7664d; font-family: 'ProximaNova-Semibold'; - font-size: 12pt; + font-size: 12px; padding: 0 6px 6px 6px; text-align: center; } @@ -371,24 +371,38 @@ .send-amount-extras { display: flex; flex: 0 0 auto; + /* So that if only one item is present, it appears on the right. */ flex-direction: row-reverse; + font-size: 12px; align-items: center; justify-content: space-between; margin: 0 14px; - .extra { - display: inline-block; + .extra, + button.extra { + color: #000; + display: flex; flex: 0 1 auto; - font-size: 12pt; } - .button { - flex: 0 1 auto; - line-height: 1.2em; + button.extra { + background: none; + border: none; + font-family: 'ProximaNova'; + font-size: 14px; + line-height: normal; + min-height: auto; + min-width: auto; + padding: 0; + } - + .button { - margin-left: 10px; - } + .button .icon:before { + font-size: 14px; + line-height: normal; + } + + + .button { span { display: flex; diff --git a/www/img/icon-alternative-currency-black.svg b/www/img/icon-alternative-currency-black.svg new file mode 100644 index 000000000..e9b175256 --- /dev/null +++ b/www/img/icon-alternative-currency-black.svg @@ -0,0 +1,22 @@ + + + + 3A719124-019D-470F-908A-5D61F117A295 + Created with sketchtool. + + + + + + + + + + + + + + + + + diff --git a/www/views/amountNew.html b/www/views/amountNew.html index 9d44e9e8d..753074e54 100644 --- a/www/views/amountNew.html +++ b/www/views/amountNew.html @@ -35,18 +35,20 @@
+
-
Available Funds: {{vm.availableFunds}} -
- +
+ -
- Available Funds: {{vm.availableFunds}} +
+ Available Funds: {{vm.availableFunds}}
From 69b2fac8e576ff06116b05ffe72e0f531bd64209 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Fri, 27 Jul 2018 12:29:34 +0800 Subject: [PATCH 160/386] Updates amount font size --- src/sass/components/amount.scss | 8 ++++---- src/sass/components/fee-summary.scss | 2 +- www/css/main.css | 10 +++++----- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/sass/components/amount.scss b/src/sass/components/amount.scss index eb0768f4f..3280c0706 100644 --- a/src/sass/components/amount.scss +++ b/src/sass/components/amount.scss @@ -7,18 +7,18 @@ } .start { - font-size: 14px; + font-size: 1em; } .middle { - font-size: 11px; + font-size: 0.7857em; } .end { - font-size: 11px; + font-size: 0.7857em; } .currency { - font-size: 14px; + font-size: 1em; } } \ No newline at end of file diff --git a/src/sass/components/fee-summary.scss b/src/sass/components/fee-summary.scss index 5f5236d0c..404643a82 100644 --- a/src/sass/components/fee-summary.scss +++ b/src/sass/components/fee-summary.scss @@ -28,6 +28,6 @@ } .fee-crypto { - color: #BCBCBC; + color: #A7A7A7; } } \ No newline at end of file diff --git a/www/css/main.css b/www/css/main.css index 063f60ff7..7a064f812 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -15239,7 +15239,7 @@ ion-content.padded-bottom-cta-with-summary { .fee-summary .fee-fiat.negative { color: #C24633; } .fee-summary .fee-crypto { - color: #BCBCBC; } + color: #A7A7A7; } .amount .start, .amount .middle, @@ -15248,16 +15248,16 @@ ion-content.padded-bottom-cta-with-summary { display: inline-block; } .amount .start { - font-size: 14px; } + font-size: 1em; } .amount .middle { - font-size: 11px; } + font-size: 0.7857em; } .amount .end { - font-size: 11px; } + font-size: 0.7857em; } .amount .currency { - font-size: 14px; } + font-size: 1em; } /* This is for rules that don't yet have a home. * Our goal is to delete this file. Search the regex: /class=".*CLASS.*?"/ From e344fd567b3e1bbc74727dc5a1a898ffb85aa1cf Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 27 Jul 2018 17:45:12 +0900 Subject: [PATCH 161/386] Add translations and remove googletagmanager --- i18n/po/ca/template-ca.po | 128 +++++++++- i18n/po/cs/template-cs.po | 130 +++++++++- i18n/po/de/template-de.po | 412 +++++++++++++++++++++----------- i18n/po/es-ES/template-es-ES.po | 130 +++++++++- i18n/po/fa/template-fa.po | 130 +++++++++- i18n/po/fr/template-fr.po | 134 ++++++++++- i18n/po/it/template-it.po | 130 +++++++++- i18n/po/ja/template-ja.po | 140 ++++++++++- i18n/po/ko/template-ko.po | 130 +++++++++- i18n/po/nl/template-nl.po | 130 +++++++++- i18n/po/pl/template-pl.po | 194 ++++++++++++--- i18n/po/pt-BR/template-pt-BR.po | 130 +++++++++- i18n/po/ru/template-ru.po | 130 +++++++++- i18n/po/sv-SE/template-sv-SE.po | 128 +++++++++- i18n/po/vi/template-vi.po | 401 ++++++++++++++++++++----------- i18n/po/zh-CN/template-zh-CN.po | 164 +++++++++++-- www/index.html | 7 +- 17 files changed, 2351 insertions(+), 397 deletions(-) diff --git a/i18n/po/ca/template-ca.po b/i18n/po/ca/template-ca.po index 515fcd814..088cd870b 100644 --- a/i18n/po/ca/template-ca.po +++ b/i18n/po/ca/template-ca.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Catalan\n" "Language: ca\n" -"PO-Revision-Date: 2018-07-04 09:26\n" +"PO-Revision-Date: 2018-07-27 08:43\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "Compra & ven bitcoins" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "Compra bitcoins" @@ -619,10 +620,14 @@ msgstr "S'està connectant a Glidera..." msgid "Connection reset by peer" msgstr "Connexió reiniciada per un parell" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "Contactes" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "Adreces utilitzades freqüentment desades" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "Continua" @@ -823,7 +828,7 @@ msgstr "Crea una cartera compartida" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "Crea una cartera bitcoin" @@ -2533,6 +2538,14 @@ msgstr "Cerca transaccions" msgid "Search or enter bitcoin address" msgstr "Cerca o introdueix l'adreça bitcoin" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "Porta-retalls" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "Teniu el porta-retalls buit" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "Cerca transaccions" @@ -2591,9 +2604,70 @@ msgid "Send by email" msgstr "Envia per correu electrònic" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "Envia des de" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "Enviat a" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "Enganxa des del porta-retalls" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "Enganxa l'adreça" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "Transferència de cartera a cartera" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "Escaneja el codi QR" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Envia bitcoins més ràpid!" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Envia bitcoins més ràpid!" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "Deseu adreces utilitzades freqüentment i envieu-los bitcoins d'un sol toc" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "Afegiu el primer contacte" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "La vostra cartera bitcoin és buida" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "Per començar, compreu Bitcoin Cash (BCH) o Bitcoin Core (BTC), o compartiu la vostra adreça." + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "Podeu rebre bitcoins des de qualsevol cartera o servei." + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "Per començar, heu de crear una cartera bitcoin i obtenir uns quants bitcoins." + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "Compra Bitcoins ara" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "Mostra la meva adreça" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "Envia import màxim" @@ -3636,3 +3710,51 @@ msgstr "{{updatingTxHistoryProgress}} transaccions descarregades" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.m}}-de-{{wallet.n}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "Comunitat" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "Reddit de Bitcoin Cash" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "Twitter de Bitcoin.com" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "Explora Bitcoin.com" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "Jocs de Bitcoin Cash" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "Notícies" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "Xarxa minera" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "Eines" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "Gràfiques de preus del bitcoin" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "Bitcoin Cash gratis" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "Les vostres carteres bitcoin ja estan a punt!" + diff --git a/i18n/po/cs/template-cs.po b/i18n/po/cs/template-cs.po index 14fe7faf2..5a3702736 100644 --- a/i18n/po/cs/template-cs.po +++ b/i18n/po/cs/template-cs.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Czech\n" "Language: cs\n" -"PO-Revision-Date: 2018-07-04 09:26\n" +"PO-Revision-Date: 2018-07-27 08:43\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "Koupit & prodat Bitcoin" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "Koupit Bitcoin" @@ -619,10 +620,14 @@ msgstr "Připojování ke Glidera..." msgid "Connection reset by peer" msgstr "Připojení přerušeno druhou stranou" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "Kontakty" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "Uložené, často používané adresy" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "Pokračovat" @@ -823,7 +828,7 @@ msgstr "Vytvořit sdílenou peněženku" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "Vytvořit Bitcoin peněženku" @@ -2533,6 +2538,14 @@ msgstr "Vyhledávání transakcí" msgid "Search or enter bitcoin address" msgstr "Vyhledat nebo zadat Bitcoin adresu" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "Schránka" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "Vaše schránka je prázdná" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "Vyhledávání transakcí" @@ -2591,9 +2604,70 @@ msgid "Send by email" msgstr "Poslat e-mailem" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "Odeslat z" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "Odeslat" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "Vložit ze schránky" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "Vložit adresu" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "Převod mezi peněženkami" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "Skenovat QR kód" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Odesílejte Bitcoin rychleji!" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Odesílejte Bitcoin rychleji!" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "Uložte si často používané adresy a posílejte jim Bitcoin jedním kliknutím" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "Přidat váš první kontakt" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "Vaše Bitcoin peněženka je prázdná" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "Chcete-li začít, nakupte Bitcoin Cash (BCH) nebo Bitcoin Core (BTC), nebo sdílejte svou adresu." + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "Můžete přijímat Bitcoin z jakékoliv peněženky nebo služby." + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "Chcete-li začít, budete muset vytvořit Bitcoin peněženku a Bitcoin získat." + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "Koupit Bitcoin" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "Zobrazit mou adresu" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "Odeslat maximální částku" @@ -3030,7 +3104,7 @@ msgstr "Chcete-li začít, nakupte Bitcoin nebo sdílejte svou adresu. Můžete #: www/views/tab-send.html:33 msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." -msgstr "Chcete-li začít, budete muset vytvořit Bitcoin peněženku a Bitcoin získat." +msgstr "Chcete-li začít, budete potřebovat vytvořit Bitcoin peněženku a získat Bitcoin." #: src/js/services/bitpayAccountService.js:73 msgid "To {{reason}} you must first add your BitPay account - {{email}}" @@ -3636,3 +3710,51 @@ msgstr "{{updatingTxHistoryProgress}} transakcí staženo" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.m}}-z-{{wallet.n}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "Komunita" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "Bitcoin Cash Reddit" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "Bitcoin.com Twitter" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "Prohlédnout Bitcoin.com" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "Bitcoin Cash hry" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "Novinky" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "Těžební pool" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "Nástroje" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "Grafy cen Bitcoinu" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "Bitcoin Cash zdarma" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "Vaše Bitcoin peněženka je připravena!" + diff --git a/i18n/po/de/template-de.po b/i18n/po/de/template-de.po index 7b3a50d69..18d8ca0f4 100644 --- a/i18n/po/de/template-de.po +++ b/i18n/po/de/template-de.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: German\n" "Language: de\n" -"PO-Revision-Date: 2018-07-04 03:57\n" +"PO-Revision-Date: 2018-07-27 08:44\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -79,7 +79,7 @@ msgstr "Kontonummer" #: www/views/tab-home.html:61 msgid "Instant transactions with low fees" -msgstr "" +msgstr "Sofortige Transaktionen mit niedrigen Gebühren" #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" @@ -226,7 +226,7 @@ msgstr "Betrag zu hoch" #: www/views/includes/walletHistory.html:31 msgid "Amount too low to spend" -msgstr "Betrag ist zu niedrig zum ausgeben" +msgstr "Betrag ist zu niedrig zum Ausgeben" #: src/js/controllers/tab-home.js:147 msgid "An update to this app is available. For your security, please update to the latest version." @@ -384,7 +384,7 @@ msgstr "Bitcoin-Netzwerk Gebührenübersicht" #: www/views/tab-home.html:83 #: www/views/tab-settings.html:107 msgid "Bitcoin Core Wallets" -msgstr "Bitcoin Core Brieftaschen" +msgstr "Bitcoin Core Wallets" #: src/js/services/incomingData.js:151 msgid "Bitcoin cash Payment" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "Kaufe & Verkaufe Bitcoins" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "Kaufe Bitcoins" @@ -547,7 +548,7 @@ msgstr "Schließen" #: www/views/includes/cash.html:2 #: www/views/preferencesInformation.html:17 msgid "Coin" -msgstr "" +msgstr "Münze" #: www/views/preferences.html:22 msgid "Color" @@ -563,7 +564,7 @@ msgstr "Beenden Sie den Backupvorgang um diese Option zu nutzen" #: www/views/bitpayCard.html:93 msgid "Completed" -msgstr "" +msgstr "Abgeschlossen" #: src/js/controllers/buyAmazon.js:311 #: src/js/controllers/buyMercadoLibre.js:305 @@ -584,7 +585,7 @@ msgstr "Bestätigen & Beenden" #: www/views/buyAmazon.html:90 msgid "Confirm purchase" -msgstr "" +msgstr "Kauf bestätigen" #: www/views/modals/pin.html:10 msgid "Confirm your PIN" @@ -619,10 +620,14 @@ msgstr "Verbinde mit Glidera..." msgid "Connection reset by peer" msgstr "Verbindung von Peer zurückgesetzt" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "Kontakte" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "Gespeicherte häufig verwendete Adressen" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "Weiter" @@ -633,7 +638,7 @@ msgstr "Übersetzungen beitragen" #: src/js/controllers/confirm.js:130 msgid "Copay only supports Bitcoin Cash using new version numbers addresses" -msgstr "" +msgstr "Copay unterstützt nur Bitcoin Cash bei Adressen welche das neue Adressformat benutzen" #: src/js/services/bwcError.js:62 msgid "Copayer already in this wallet" @@ -675,7 +680,7 @@ msgstr "In die Zwischenablage kopieren" #: src/js/controllers/buyMercadoLibre.js:102 msgid "Could not access Gift Card Service" -msgstr "" +msgstr "Der Geschenkkartendienst konnte nicht erreicht werden" #: www/views/tab-import-phrase.html:2 msgid "Could not access the wallet at the server. Please check:" @@ -683,7 +688,7 @@ msgstr "Kein Zugriff auf Wallet des Servers. Überprüfen Sie bitte:" #: src/js/controllers/buyAmazon.js:102 msgid "Could not access to Amazon.com" -msgstr "" +msgstr "Auf Amazon.com konnte nicht zugegriffen werden" #: src/js/services/profileService.js:511 msgid "Could not access wallet" @@ -707,13 +712,13 @@ msgstr "Adresse konnte nicht erstellt werden" #: src/js/controllers/topup.js:92 msgid "Could not create the invoice" -msgstr "" +msgstr "Die Rechnung konnte nicht erstellt werden" #: src/js/controllers/buyAmazon.js:164 #: src/js/controllers/buyMercadoLibre.js:164 #: src/js/controllers/topup.js:142 msgid "Could not create transaction" -msgstr "" +msgstr "Transaktion konnte nicht erstellt werden" #: src/js/services/profileService.js:350 msgid "Could not create using the specified extended private key" @@ -737,7 +742,7 @@ msgstr "Zahlungsvorschlag konnte nicht gelöscht werden" #: src/js/controllers/cashScan.js:117 msgid "Could not duplicate" -msgstr "" +msgstr "Konnte nicht duplizieren" #: src/js/services/feeService.js:73 msgid "Could not get dynamic fee" @@ -749,13 +754,13 @@ msgstr "Dynamische Gebühr für den Level konnte nicht abgerufen werden: {{feeLe #: src/js/controllers/modals/feeLevels.js:112 msgid "Could not get fee levels" -msgstr "" +msgstr "Gebühren konnten nicht abgerufen werden" #: src/js/controllers/buyAmazon.js:122 #: src/js/controllers/buyMercadoLibre.js:122 #: src/js/controllers/topup.js:100 msgid "Could not get the invoice" -msgstr "" +msgstr "Konnte die Rechnung nicht erhalten" #: src/js/controllers/bitpayCard.js:66 msgid "Could not get transactions" @@ -800,7 +805,7 @@ msgstr "Zahlung kann nicht gesendet werden" #: src/js/controllers/buyMercadoLibre.js:318 #: src/js/controllers/topup.js:299 msgid "Could not send transaction" -msgstr "" +msgstr "Transaktion konnte nicht gesendet werden" #: www/views/walletDetails.html:210 msgid "Could not update transaction history" @@ -823,7 +828,7 @@ msgstr "Erstelle eine gemeinsame Wallet" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "Erstelle Bitcoin-Wallet" @@ -859,7 +864,7 @@ msgstr "Aktuelle Gebühr für dieses Verfahren" #: src/js/services/feeService.js:15 msgid "Custom" -msgstr "" +msgstr "Eigene" #: www/views/customAmount.html:9 msgid "Custom Amount" @@ -867,7 +872,7 @@ msgstr "Benutzerdefinierter Betrag" #: src/js/controllers/preferencesFee.js:85 msgid "Custom Fee" -msgstr "" +msgstr "Eigene Gebühr" #: www/views/modals/mercadolibre-card-details.html:56 #: www/views/modals/txp-details.html:87 @@ -944,11 +949,11 @@ msgstr "Herunterladen" #: www/views/cashScan.html:37 msgid "Duplicate for BCH" -msgstr "Duplikat für BCH" +msgstr "Für BCH duplizieren" #: src/js/services/onGoingProcess.js:49 msgid "Duplicating wallet..." -msgstr "" +msgstr "Wallet wird dupliziert..." #: www/views/addresses.html:19 msgid "Each bitcoin wallet can generate billions of addresses from your 12-word backup. A new address is automatically generated and shown each time you receive a payment." @@ -960,7 +965,7 @@ msgstr "Wirtschaftlich" #: www/views/onboarding/collectEmail.html:27 msgid "Edit" -msgstr "" +msgstr "Bearbeiten" #: www/views/addressbook.add.html:29 #: www/views/addressbook.view.html:22 @@ -977,7 +982,7 @@ msgstr "Obergrenze für leere Adressen erreicht. Neue Adressen können nicht gen #: www/views/preferencesCash.html:17 msgid "Enable Bitcoin Cash wallet creation and operation within the App." -msgstr "" +msgstr "Bitcoin Cash-Wallet-Erstellung und Betrieb innerhalb der App aktivieren." #: www/views/tab-scan.html:19 msgid "Enable camera access in your device settings to get started." @@ -993,7 +998,7 @@ msgstr "Pushbenachrichtigungen aktivieren" #: www/views/preferencesNotifications.html:33 msgid "Enable sound" -msgstr "" +msgstr "Sound einschalten" #: www/views/tab-scan.html:18 msgid "Enable the camera to get started." @@ -1014,11 +1019,11 @@ msgstr "Eingabe des Zwei-Faktor-Authentifizierungs-Codes für das BitPay Konto" #: www/views/amount.html:4 msgid "Enter amount" -msgstr "" +msgstr "Betrag eingeben" #: www/views/modals/chooseFeeLevel.html:41 msgid "Enter custom fee" -msgstr "" +msgstr "Eigene Gebühr eingeben" #: src/js/services/walletService.js:1029 msgid "Enter new spending password" @@ -1032,7 +1037,7 @@ msgstr "Wiederherstellungsphrase eingeben (BIP39)" #: www/views/onboarding/collectEmail.html:13 msgid "Enter your email" -msgstr "" +msgstr "Ihre E-Mail Adresse eingeben" #: www/views/backup.html:69 msgid "Enter your password" @@ -1123,12 +1128,12 @@ msgstr "Fehler beim bestätigen" #: src/js/controllers/buyAmazon.js:179 msgid "Error creating gift card" -msgstr "" +msgstr "Fehler beim Erstellen der Geschenkkarte" #: src/js/controllers/buyAmazon.js:94 #: src/js/controllers/buyMercadoLibre.js:94 msgid "Error creating the invoice" -msgstr "" +msgstr "Fehler beim Erstellen der Rechnung" #: src/js/services/profileService.js:412 msgid "Error creating wallet" @@ -1136,17 +1141,17 @@ msgstr "Fehler beim Erstellen des Wallets" #: src/js/controllers/confirm.js:296 msgid "Error getting SendMax information" -msgstr "" +msgstr "Fehler beim Abrufen der SendMax Informationen" #: src/js/controllers/buyAmazon.js:136 #: src/js/controllers/buyMercadoLibre.js:136 #: src/js/controllers/topup.js:114 msgid "Error in Payment Protocol" -msgstr "" +msgstr "Fehler im Zahlungsprotokoll" #: src/js/controllers/bitpayCardIntro.js:14 msgid "Error pairing BitPay Account" -msgstr "" +msgstr "Fehler beim Paaren mit BitPay Konto" #: src/js/controllers/paperWallet.js:41 msgid "Error scanning funds:" @@ -1201,7 +1206,7 @@ msgstr "Erweiterte öffentliche Schlüssel" #: src/js/services/onGoingProcess.js:20 msgid "Extracting Wallet information..." -msgstr "" +msgstr "Wallet-Informationen extrahieren..." #: src/js/controllers/export.js:115 #: src/js/controllers/export.js:126 @@ -1222,16 +1227,16 @@ msgstr "Gebühr" #: www/views/modals/chooseFeeLevel.html:75 msgid "Fee level" -msgstr "" +msgstr "Gebührenstufe" #: src/js/controllers/modals/feeLevels.js:100 msgid "Fee level is not defined" -msgstr "" +msgstr "Gebührenstufe ist nicht definiert" #: www/views/confirm.html:79 #: www/views/modals/txp-details.html:99 msgid "Fee:" -msgstr "" +msgstr "Gebühr:" #: src/js/controllers/feedback/send.js:23 msgid "Feedback could not be submitted. Please try again later." @@ -1243,7 +1248,7 @@ msgstr "BitPay Konto abrufen..." #: src/js/services/onGoingProcess.js:21 msgid "Fetching payment information" -msgstr "" +msgstr "Zahlungsinformationen abrufen" #: www/views/export.html:14 #: www/views/import.html:16 @@ -1252,7 +1257,7 @@ msgstr "Datei/Text" #: www/views/preferencesLogs.html:17 msgid "Filter setting" -msgstr "" +msgstr "Filtereinstellungen" #: src/js/services/fingerprintService.js:43 #: src/js/services/fingerprintService.js:48 @@ -1285,7 +1290,7 @@ msgstr "Von BitPay Konto" #: www/views/tab-import-phrase.html:57 msgid "From Hardware Wallet" -msgstr "" +msgstr "Aus der Hardware-Wallet" #: www/views/tab-export-qrCode.html:5 msgid "From the destination device, go to Add wallet > Import wallet and scan this QR code" @@ -1301,7 +1306,7 @@ msgstr "Betrag gefunden:" #: www/views/topup.html:49 msgid "Funds to be added" -msgstr "" +msgstr "Hinzuzufügende Mittel" #: www/views/paperWallet.html:51 msgid "Funds transferred" @@ -1309,7 +1314,7 @@ msgstr "Betrag übermittelt" #: www/views/topup.html:103 msgid "Funds were added to debit card" -msgstr "" +msgstr "Mittel wurden auf die Debitkarte hinzugefügt" #: www/views/paperWallet.html:22 msgid "Funds will be transferred to" @@ -1317,7 +1322,7 @@ msgstr "Beträge werden überwiesen an" #: www/views/tab-receive.html:51 msgid "Generate new address" -msgstr "" +msgstr "Neue Adresse generieren" #: src/js/services/onGoingProcess.js:22 msgid "Generating .csv file..." @@ -1338,7 +1343,7 @@ msgstr "Erhalten Sie Neuigkeiten und Aktualisierungen von BitPay" #: www/views/onboarding/welcome.html:8 msgctxt "button" msgid "Get started" -msgstr "" +msgstr "Loslegen" #: www/views/bitpayCard.html:49 msgid "Get started" @@ -1355,20 +1360,20 @@ msgstr "Entgelt-Level werden abgerufen..." #: www/views/buyAmazon.html:43 #: www/views/buyMercadoLibre.html:42 msgid "Gift Card" -msgstr "Geschenk-Karte" +msgstr "Geschenkkarte" #: www/views/modals/mercadolibre-card-details.html:30 #: www/views/modals/mercadolibre-card-details.html:35 msgid "Gift Card is not available to use anymore" -msgstr "" +msgstr "Geschenkkarte kann nicht mehr verwendet werden" #: src/js/controllers/buyAmazon.js:204 msgid "Gift card expired" -msgstr "" +msgstr "Geschenkkarte ist abgelaufen" #: www/views/buyAmazon.html:111 msgid "Gift card generated and ready to use." -msgstr "" +msgstr "Geschenkkarte generiert und einsatzbereit." #: src/js/controllers/bitpayCard.js:114 #: src/js/controllers/bitpayCard.js:124 @@ -1414,7 +1419,7 @@ msgstr "Hardware-Wallet" #: src/js/controllers/create.js:180 #: src/js/controllers/join.js:145 msgid "Hardware wallets are not yet supported with Bitcoin Cash" -msgstr "" +msgstr "Bitcoin Cash unterstützt keine Hardware-Wallets" #: www/views/tab-settings.html:20 msgid "Help & Support" @@ -1531,7 +1536,7 @@ msgstr "Wenn Sie einen Screenshot erstellen, kann die Sicherung von anderen Apps #: www/views/tab-import-hardware.html:42 #: www/views/tab-import-phrase.html:80 msgid "Import" -msgstr "" +msgstr "Import" #: www/views/import.html:3 msgid "Import Wallet" @@ -1580,13 +1585,13 @@ msgstr "QR code hat falsches Format" #: src/js/services/bwcError.js:113 msgid "Incorrect network address" -msgstr "" +msgstr "Falsche Netzwerkadresse" #: src/js/controllers/confirm.js:114 #: src/js/controllers/confirm.js:306 #: src/js/services/bwcError.js:44 msgid "Insufficient confirmed funds" -msgstr "" +msgstr "Unzureichende bestätigte Mittel" #: src/js/controllers/topup.js:165 #: src/js/controllers/topup.js:177 @@ -1606,7 +1611,7 @@ msgstr "Ungültig" #: src/js/controllers/buyMercadoLibre.js:137 #: src/js/controllers/topup.js:115 msgid "Invalid URL" -msgstr "" +msgstr "Ungültige URL" #: src/js/controllers/create.js:186 #: src/js/controllers/import.js:345 @@ -1635,7 +1640,7 @@ msgstr "Einladung um eine {{appName}} Wallet zu teilen" #: www/views/mercadoLibreCards.html:20 #: www/views/modals/mercadolibre-card-details.html:48 msgid "Invoice expired" -msgstr "" +msgstr "Rechnung abgelaufen" #: src/js/controllers/feedback/send.js:79 msgid "Is there anything we could do better?" @@ -1696,7 +1701,7 @@ msgstr "Letzter Monat" #: www/views/preferencesCash.html:18 #: www/views/tx-details.html:94 msgid "Learn more" -msgstr "" +msgstr "Weitere Informationen" #: www/views/backup.html:43 msgid "Let's verify your backup phrase." @@ -1737,15 +1742,15 @@ msgstr "Zeitsperre aktiv. Bitte auf die Entfernung des Zahlungsvorschlags warten #: www/views/includes/logOptions.html:3 msgid "Log options" -msgstr "" +msgstr "Log-Optionen" #: www/views/modals/bitpay-card-confirmation.html:14 msgid "Log out" -msgstr "" +msgstr "Abmelden" #: www/views/addresses.html:87 msgid "Low amount inputs" -msgstr "" +msgstr "Zu wenige Inputs" #: www/views/includes/walletHistory.html:27 msgid "Low fees" @@ -1777,11 +1782,11 @@ msgstr "Notiz" #: www/views/mercadoLibre.html:6 msgid "Mercado Livre Brazil Gift Cards" -msgstr "" +msgstr "Mercado Livre Brazil Geschenkkarten" #: src/js/controllers/buyMercadoLibre.js:98 msgid "Mercadolibre Gift Card Service is not available at this moment. Please try back later." -msgstr "" +msgstr "Der MercadoLibre Geschenkkarten-Dienst ist aktuell nicht erreichbar. Bitte versuchen Sie es später noch einmal." #: www/views/modals/txp-details.html:131 msgid "Merchant Message" @@ -1791,7 +1796,7 @@ msgstr "Händlernachricht" #: www/views/buyMercadoLibre.html:54 #: www/views/topup.html:63 msgid "Miner Fee" -msgstr "" +msgstr "Miner-Gebühr" #: src/js/services/bwcError.js:134 msgid "Missing parameter" @@ -1828,13 +1833,13 @@ msgstr "Hinweis: Um eine Brieftasche aus einer 3rd-Party-Software zu importieren #: www/views/preferences.html:15 #: www/views/preferencesAlias.html:17 msgid "Name" -msgstr "" +msgstr "Name" #: www/views/buyAmazon.html:49 #: www/views/buyMercadoLibre.html:48 #: www/views/topup.html:56 msgid "Network Cost" -msgstr "" +msgstr "Netzwerkkosten" #: src/js/services/bwcError.js:47 msgid "Network error" @@ -1863,7 +1868,7 @@ msgstr "Keine Wallet" #: src/js/controllers/buyAmazon.js:115 #: src/js/controllers/buyMercadoLibre.js:115 msgid "No access key defined" -msgstr "" +msgstr "Kein Zugangsschlüssel definiert" #: www/views/onboarding/backupRequest.html:5 msgid "No backup, no bitcoin." @@ -1875,7 +1880,7 @@ msgstr "Noch keine Kontakte" #: www/views/preferencesLogs.html:16 msgid "No entries for this log level" -msgstr "" +msgstr "Keine Einträge für dieses Log-level" #: www/views/preferencesExternal.html:12 msgid "No hardware information available." @@ -1896,7 +1901,7 @@ msgstr "Keine aktuellen Transaktionen" #: src/js/controllers/buyAmazon.js:44 #: src/js/controllers/topup.js:47 msgid "No signing proposal: No private key" -msgstr "" +msgstr "Kein Unterzeichnungsvorschlag: Privater Schlüssel nicht vorhanden" #: www/views/walletDetails.html:204 msgid "No transactions yet" @@ -1915,7 +1920,7 @@ msgstr "Kein Wallet ausgewählt" #: src/js/controllers/confirm.js:85 #: src/js/controllers/topup.js:265 msgid "No wallets available" -msgstr "" +msgstr "Keine Wallets verfügbar" #: www/views/paperWallet.html:45 msgid "No wallets available to receive funds" @@ -1923,19 +1928,19 @@ msgstr "Keine Wallet verfügbar um Guthaben zu erhalten" #: www/views/cashScan.html:15 msgid "No wallets eligible for Bitcoin Cash support" -msgstr "" +msgstr "Keine Wallet zur Unterstützung von Bitcoin Cash geeignet" #: src/js/controllers/cashScan.js:58 msgid "Non BIP44 wallet" -msgstr "" +msgstr "Wallet ist keine BIP44-Wallet" #: www/views/cashScan.html:46 msgid "Non eligible BTC wallets" -msgstr "" +msgstr "Keine geeigneten BTC Wallets" #: src/js/services/feeService.js:12 msgid "Normal" -msgstr "" +msgstr "Normal" #: src/js/services/bwcError.js:80 msgid "Not authorized" @@ -1964,7 +1969,7 @@ msgstr "Notiz" #: www/views/backup.html:19 msgid "Note: if this BCH wallet was duplicated from a BTC wallet, they share the same recovery phrase." -msgstr "" +msgstr "Hinweis: Wenn diese BCH-Wallet aus einer BTC-Wallet dupliziert wurde, verwenden sie die selbe Wiederherstellungsphrase." #: www/views/modals/wallets.html:25 msgid "Notice: only 1-1 (single signature) wallets can be used for sell bitcoin" @@ -1977,15 +1982,15 @@ msgstr "Benachrichtigungen" #: www/views/onboarding/collectEmail.html:9 msgid "Notifications by email" -msgstr "" +msgstr "Benachrichtigungen per e-Mail" #: www/views/tx-details.html:117 msgid "Notify me if confirmed" -msgstr "" +msgstr "Benachrichtige mich sobald sie bestätigt ist" #: www/views/preferencesNotifications.html:24 msgid "Notify me when transactions are confirmed" -msgstr "" +msgstr "Benachrichtigen Sie mich, wenn Transaktionen bestätigt werden" #: www/views/includes/backupNeededPopup.html:8 msgid "Now is a good time to backup your wallet. If this device is lost, it is impossible to access your funds without a backup." @@ -2004,7 +2009,7 @@ msgstr "Jetzt ist die perfekte Zeit um Ihre Umgebung zu überprüfen. In der Nä #: src/js/services/popupService.js:72 #: www/views/modals/chooseFeeLevel.html:6 msgid "OK" -msgstr "" +msgstr "Okay" #: www/views/modals/tx-status.html:12 #: www/views/modals/tx-status.html:24 @@ -2023,7 +2028,7 @@ msgstr "Oh nein!" #: src/js/controllers/buyMercadoLibre.js:306 msgid "Ok" -msgstr "" +msgstr "Okay" #: www/views/tab-home.html:39 msgid "On this screen you can see all your wallets, accounts, and assets." @@ -2053,7 +2058,7 @@ msgstr "Öffne GitHub Projekt" #: src/js/controllers/bitpayCard.js:123 #: src/js/controllers/tx-details.js:192 msgid "Open Explorer" -msgstr "" +msgstr "Explorer öffnen" #: www/views/tab-scan.html:22 msgid "Open Settings" @@ -2069,11 +2074,11 @@ msgstr "Öffne Website" #: src/js/controllers/preferencesCash.js:32 msgid "Open bitcoincash.org?" -msgstr "" +msgstr "bitcoincash.org öffnen?" #: src/js/controllers/cashScan.js:18 msgid "Open the recovery tool." -msgstr "" +msgstr "Öffnen Sie das Recovery-Tool." #: www/views/tab-receive.html:27 msgid "Open wallet" @@ -2081,7 +2086,7 @@ msgstr "Öffne Wallet" #: www/views/includes/incomingDataMenu.html:19 msgid "Open website" -msgstr "" +msgstr "Öffne Website" #: www/views/bitpayCardIntro.html:34 msgid "Order the BitPay Card" @@ -2173,7 +2178,7 @@ msgstr "Zahlung akzeptiert. Sie wird durch Glidera übermittelt. Falls ein Probl #: src/js/services/incomingData.js:152 msgid "Payment address was translated to new Bitcoin Cash address format:" -msgstr "" +msgstr "Die Zahlungsadresse wurde auf das neue Bitcoin Cash-Adressformat übersetzt:" #: www/views/modals/txp-details.html:107 msgid "Payment details" @@ -2186,7 +2191,7 @@ msgstr "Zahlungsanforderung" #: www/views/mercadoLibreCards.html:22 #: www/views/modals/mercadolibre-card-details.html:39 msgid "Pending" -msgstr "" +msgstr "Ausstehend" #: www/views/proposals.html:4 msgid "Pending Proposals" @@ -2232,7 +2237,7 @@ msgstr "Bitte Copay aktualisieren, um diese Aktion auszuführen" #: www/views/walletDetails.html:142 #: www/views/walletDetails.html:62 msgid "Please wait" -msgstr "" +msgstr "Bitte warten" #: src/js/controllers/import.js:238 msgid "Please, select your backup file" @@ -2240,7 +2245,7 @@ msgstr "Bitte die Sicherungsdatei wählen" #: www/views/bitpayCard.html:81 msgid "Pre-Auth Holds" -msgstr "" +msgstr "Pre-Auth Holds" #: www/views/tab-settings.html:40 msgid "Preferences" @@ -2264,7 +2269,7 @@ msgstr "höchste Priorität" #: www/views/includes/incomingDataMenu.html:80 msgid "Private Key" -msgstr "" +msgstr "Privater Schlüssel" #: src/js/controllers/paperWallet.js:136 msgid "Private key encrypted. Enter password" @@ -2298,11 +2303,11 @@ msgstr "Vorschläge" #: src/js/controllers/buyAmazon.js:282 msgid "Purchase Amount is limited to {{limitPerDay}} {{currency}} per day" -msgstr "" +msgstr "Kaufbetrag beschränkt ist auf {{limitPerDay}} {{currency}} pro Tag beschränkt" #: src/js/controllers/buyMercadoLibre.js:281 msgid "Purchase amount must be a value between 50 and 2000" -msgstr "" +msgstr "Kaufbetrag muss ein Wert zwischen 50 und 2000 sein" #: www/views/onboarding/notifications.html:3 msgid "Push Notifications" @@ -2340,11 +2345,11 @@ msgstr "Mehr anzeigen" #: src/js/controllers/preferences.js:65 #: src/js/controllers/tx-details.js:54 msgid "Read more in our Wiki" -msgstr "" +msgstr "Lesen Sie mehr in unserem Wiki" #: src/js/controllers/cashScan.js:61 msgid "Read only wallet" -msgstr "" +msgstr "Schreibgeschützte Wallet" #: www/views/tab-receive.html:3 #: www/views/tabs.html:7 @@ -2353,7 +2358,7 @@ msgstr "Empfangen" #: www/views/customAmount.html:44 msgid "Receive in" -msgstr "" +msgstr "Erhalten in" #: www/views/includes/walletHistory.html:24 #: www/views/tx-details.html:18 @@ -2402,7 +2407,7 @@ msgstr "Wallet wiederherstellen..." #: www/views/modals/mercadolibre-card-details.html:22 msgid "Redeem now" -msgstr "" +msgstr "Jetzt einlösen" #: src/js/controllers/modals/txpDetails.js:63 #: src/js/controllers/tx-details.js:80 @@ -2420,7 +2425,7 @@ msgstr "Release-Informationen" #: www/views/addressbook.view.html:36 #: www/views/modals/mercadolibre-card-details.html:69 msgid "Remove" -msgstr "" +msgstr "Entfernen" #: src/js/controllers/preferencesBitpayServices.js:7 msgid "Remove BitPay Account?" @@ -2503,7 +2508,7 @@ msgstr "Adresse auf neue Beträge überprüfen" #: www/views/modals/fingerprintCheck.html:11 msgid "Scan again" -msgstr "" +msgstr "Erneut scannen" #: src/js/services/fingerprintService.js:56 msgid "Scan your fingerprint please" @@ -2511,7 +2516,7 @@ msgstr "Scannen Sie bitte Ihren Fingerabdruck" #: www/views/preferencesCash.html:23 msgid "Scan your wallets for Bitcoin Cash" -msgstr "" +msgstr "Durchsuche deine Wallet nach Bitcoin Cash" #: src/js/services/onGoingProcess.js:30 msgid "Scanning Wallet funds..." @@ -2519,7 +2524,7 @@ msgstr "Prüfe Wallet auf neue Beträge..." #: www/views/includes/walletList.html:11 msgid "Scanning funds..." -msgstr "" +msgstr "Mittel werden durchsucht..." #: www/views/includes/screenshotWarningModal.html:7 msgid "Screenshots are not secure" @@ -2533,6 +2538,14 @@ msgstr "Transaktionen durchsuchen" msgid "Search or enter bitcoin address" msgstr "Bitcoin-Adresse suchen oder eingeben" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "Zwischenablage" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "Ihre Zwischenablage ist leer" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "Transaktionen durchsuchen" @@ -2547,7 +2560,7 @@ msgstr "Sicherheit" #: www/views/modals/mercadolibre-card-details.html:64 msgid "See invoice" -msgstr "" +msgstr "Rechnung einsehen" #: www/views/tab-import-file.html:7 msgid "Select a backup file" @@ -2591,16 +2604,77 @@ msgid "Send by email" msgstr "Per E-Mail versenden" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "Senden von" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "Senden an" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "Aus Zwischenablage einfügen" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "Adresse einfügen" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "Wallet-zu-Wallet-Überweisung" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "QR-Code scannen" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Versenden Sie Bitcoin schneller!" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Versenden Sie Bitcoin schneller!" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "Speichern Sie häufig verwendete Adressen und senden Sie ihnen Bitcoin mit nur einem Tippen" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "Ihren ersten Kontakt hinzufügen" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "Ihre Bitcoin-Wallet ist leer" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "Um loszulegen, können sie entweder Bitcoin Cash (BCH) oder Bitcoin Core (BTC) kaufen, oder uns ihre Adresse mitteilen." + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "Sie können Bitcoin von jeder Wallet oder jedem Dienst erhalten." + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "Um loszulegen müssen Sie eine Bitcoin-Wallet erstellen und einige Bitcoins erhalten." + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "Bitcoin jetzt kaufen" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "Meine Adresse anzeigen" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "Sende max. Betrag" #: www/views/includes/incomingDataMenu.html:46 msgid "Send payment to this address" -msgstr "" +msgstr "Zahlung an diese Adresse senden" #: www/views/feedback/rateApp.html:17 msgid "Send us feedback instead" @@ -2651,11 +2725,11 @@ msgstr "Antwort des Servers konnte nicht verifiziert werden" #: src/js/controllers/buyAmazon.js:97 #: src/js/controllers/buyMercadoLibre.js:97 msgid "Service not available" -msgstr "" +msgstr "Dienst ist nicht verfügbar" #: www/views/includes/homeIntegrations.html:3 msgid "Services" -msgstr "" +msgstr "Dienste" #: www/views/preferencesLogs.html:3 msgid "Session Log" @@ -2671,7 +2745,7 @@ msgstr "Passwort einrichten" #: src/js/controllers/preferencesFee.js:85 msgid "Set your own fee in satoshis/byte" -msgstr "" +msgstr "Legen Sie Ihre eigene Gebühr in Satoshis/byte fest" #: www/views/tab-settings.html:3 #: www/views/tabs.html:19 @@ -2747,24 +2821,24 @@ msgstr "Überspringen" #: src/js/controllers/confirm.js:371 #: src/js/controllers/modals/txpDetails.js:47 msgid "Slide to accept" -msgstr "" +msgstr "Zum Akzeptieren schieben" #: www/views/buyAmazon.html:96 msgid "Slide to buy" -msgstr "" +msgstr "Zum Kaufen schieben" #: src/js/controllers/confirm.js:365 msgid "Slide to pay" -msgstr "" +msgstr "Zum Bezahlen schieben" #: src/js/controllers/confirm.js:377 #: src/js/controllers/modals/txpDetails.js:40 msgid "Slide to send" -msgstr "" +msgstr "Zum Senden schieben" #: www/views/cashScan.html:56 msgid "Some of your wallets are not eligible for Bitcoin Cash support. You can try to access BCH funds from these wallets using the" -msgstr "" +msgstr "Einige ihrer Wallets sind nicht zur Unterstützung von Bitcoin Cash geeignet. Sie können versuchen, auf BCH Mittel von diesen Wallets aus zuzugreifen indem Sie die" #: src/js/controllers/create.js:88 #: src/js/controllers/join.js:71 @@ -2785,7 +2859,7 @@ msgstr "Berechtigungscode erforderlich" #: www/views/walletDetails.html:173 msgid "Spending this balance will need significant Bitcoin network fees" -msgstr "" +msgstr "Die Ausgabe dieses Betrages wird signifikante Bitcoin-Netzwerkgebühren erfordern" #: www/views/tab-send.html:28 msgid "Start sending bitcoin" @@ -2798,11 +2872,11 @@ msgstr "Sperre des Startups" #: www/views/mercadoLibreCards.html:21 #: www/views/modals/mercadolibre-card-details.html:42 msgid "Still pending" -msgstr "" +msgstr "Noch ausstehend" #: www/views/topup.html:101 msgid "Success" -msgstr "" +msgstr "Erfolg" #: src/js/services/feeService.js:14 msgid "Super Economy" @@ -2810,7 +2884,7 @@ msgstr "Niedrigste Priorität" #: www/views/preferencesCash.html:11 msgid "Support Bitcoin Cash" -msgstr "" +msgstr "Bitcoin Cash unterstützen" #: www/views/paperWallet.html:7 msgid "Sweep" @@ -2840,7 +2914,7 @@ msgstr "Anzeigen durch tippen und halten" #: www/views/includes/walletInfo.html:3 msgid "Tap to recreate" -msgstr "" +msgstr "Zum neu erstellen tippen" #: www/views/includes/walletInfo.html:4 msgid "Tap to retry" @@ -2860,11 +2934,11 @@ msgstr "Nutzungsbedingungen" #: www/views/tab-create-personal.html:118 #: www/views/tab-import-phrase.html:68 msgid "Testnet" -msgstr "" +msgstr "Testnet" #: www/views/includes/incomingDataMenu.html:61 msgid "Text" -msgstr "" +msgstr "Text" #: src/js/controllers/feedback/send.js:27 #: src/js/controllers/feedback/send.js:76 @@ -2999,7 +3073,7 @@ msgstr "Diese Wiederherstellungsphrase entstand mit einem Passwort. Zur Wiederhe #: www/views/tx-details.html:91 msgid "This transaction amount is too small compared to current Bitcoin network fees. Spending these funds will need a Bitcoin network fee cost comparable to the funds itself." -msgstr "" +msgstr "Dieser Betrag ist zu klein im Vergleich zu den aktuellen Bitcoin-Netzwerk-Gebühren. Diese Mittel benötigen eine Bitcoin Netzwerk Gebühr mit vergleichbarer Größe zu den Mitteln." #: www/views/tx-details.html:87 msgid "This transaction could take a long time to confirm or could be dropped due to the low fees set by the sender" @@ -3034,15 +3108,15 @@ msgstr "Um loszulegen müssen Sie eine Bitcoin-Wallet erstellen und einige Bitco #: src/js/services/bitpayAccountService.js:73 msgid "To {{reason}} you must first add your BitPay account - {{email}}" -msgstr "" +msgstr "Zum {{reason}} müssen Sie erst Ihr BitPay-Konto hinzufügen - {{email}}" #: src/js/services/onGoingProcess.js:48 msgid "Top up in progress..." -msgstr "" +msgstr "Aufladung in Bearbeitung..." #: src/js/controllers/topup.js:206 msgid "Top up {{amountStr}} to debit card ({{cardLastNumber}})" -msgstr "" +msgstr "Laden sie {{amountStr}} auf die Debitkarte ({{cardLastNumber}}) auf" #: www/views/buyAmazon.html:61 #: www/views/buyMercadoLibre.html:60 @@ -3061,7 +3135,7 @@ msgstr "Gesamtanzahl der Copayer" #: www/views/addresses.html:81 msgid "Total wallet inputs" -msgstr "" +msgstr "Alle Wallet-Inputs" #: src/js/services/fingerprintService.js:63 #: src/js/services/fingerprintService.js:68 @@ -3074,7 +3148,7 @@ msgstr "Transaktion" #: www/views/confirm.html:126 msgid "Transaction Created" -msgstr "" +msgstr "Transaktion erstellt" #: www/views/preferencesAdvanced.html:29 #: www/views/preferencesHistory.html:3 @@ -3089,11 +3163,11 @@ msgstr "Transaktion wurde bereits übermittelt" #: src/js/controllers/buyMercadoLibre.js:301 #: src/js/controllers/topup.js:281 msgid "Transaction has not been created" -msgstr "" +msgstr "Transaktion wurde nicht erstellt" #: www/views/topup.html:104 msgid "Transaction initiated" -msgstr "" +msgstr "Transaktion eingeleitet" #: src/js/controllers/tx-details.js:119 msgid "Transaction not available at this time" @@ -3106,11 +3180,11 @@ msgstr "Transaktion konnte nicht gefunden werden" #: www/views/modals/chooseFeeLevel.html:55 msgid "Transactions without fee are not supported." -msgstr "" +msgstr "Transaktionen ohne Gebühren werden nicht unterstützt." #: src/js/controllers/paperWallet.js:109 msgid "Transfer to" -msgstr "" +msgstr "Transfer zu" #: www/views/tab-send.html:67 msgid "Transfer to Wallet" @@ -3130,7 +3204,7 @@ msgstr "Wiederherstellungsphrase eingeben (in der Regel 12 Wörter)" #: src/js/controllers/backup.js:75 msgid "Uh oh..." -msgstr "" +msgstr "Oh oh..." #: www/views/tx-details.html:100 msgid "Unconfirmed" @@ -3178,12 +3252,12 @@ msgstr "Überprüfe Wiederherstellungsphrase..." #: www/views/modals/fingerprintCheck.html:4 msgid "Verify your identity" -msgstr "" +msgstr "Bestätigen Sie Ihre Identität" #: www/views/preferencesAbout.html:14 #: www/views/preferencesExternal.html:25 msgid "Version" -msgstr "" +msgstr "Version" #: www/views/tab-export-file.html:69 msgid "View" @@ -3200,7 +3274,7 @@ msgstr "Nutzungsbedingungen anzeigen" #: src/js/controllers/bitpayCard.js:122 #: src/js/controllers/tx-details.js:191 msgid "View Transaction on Explorer.Bitcoin.com" -msgstr "" +msgstr "Transaktion auf Explorer.Bitcoin.com ansehen" #: src/js/controllers/tab-home.js:148 msgid "View Update" @@ -3212,7 +3286,7 @@ msgstr "Auf blockchain anzeigen" #: www/views/mercadoLibre.html:26 msgid "Visit mercadolivre.com.br →" -msgstr "" +msgstr "Besuchen Sie mercadolivre.com.br →" #: www/views/walletDetails.html:182 msgid "WARNING: Key derivation is not working on this device/wallet. Actions cannot be performed on this wallet." @@ -3274,7 +3348,7 @@ msgstr "Wallet-Informationen" #: www/views/addresses.html:76 msgid "Wallet Inputs" -msgstr "" +msgstr "Wallet-Inputs" #: www/views/join.html:26 msgid "Wallet Invitation" @@ -3328,7 +3402,7 @@ msgstr "Wallet exstiert bereits" #: src/js/services/profileService.js:516 msgid "Wallet already in {{appName}}" -msgstr "" +msgstr "Wallet bereits in {{appName}}" #: www/views/includes/walletActivity.html:6 msgid "Wallet created" @@ -3379,7 +3453,7 @@ msgstr "Wallet ist nicht beim Wallet-Service registiert. Neu erzeugen mit \"Neue #: www/views/backup.html:12 msgid "Wallet recovery phrase not available" -msgstr "" +msgstr "Wallet Wiederherstellungsphrase ist nicht verfügbar" #: src/js/services/bwcError.js:50 msgid "Wallet service not found" @@ -3387,7 +3461,7 @@ msgstr "Wallet-Dienst nicht gefunden" #: www/views/tab-home.html:69 msgid "Wallets" -msgstr "" +msgstr "Wallets" #: src/js/controllers/addressbookView.js:36 #: src/js/controllers/modals/txpDetails.js:153 @@ -3424,7 +3498,7 @@ msgstr "Wir sind immer auf der Suche nach Möglichkeiten um {{appName}} zu verbe #: www/views/includes/incomingDataMenu.html:6 msgid "Website" -msgstr "" +msgstr "Webseite" #: www/views/preferencesLanguage.html:16 msgid "We’re always looking for translation contributions! You can make corrections or help to make this app available in your native language by joining our community on Crowdin." @@ -3504,11 +3578,11 @@ msgstr "Sie kontrollieren Ihre Bitcoins." #: www/views/modals/chooseFeeLevel.html:64 msgid "You should not set a fee higher than {{maxFeeRecommended}} satoshis/byte." -msgstr "" +msgstr "Sie sollten keine Gebühren welche höher als {{maxFeeRecommended}} satoshis/byte sind wählen." #: www/views/modals/bitpay-card-confirmation.html:5 msgid "You will need to log back for fill in your BitPay Card." -msgstr "" +msgstr "Sie müssen sich wieder anmelden um ihre BitPay-Karte aufzufüllen." #: www/views/preferencesNotifications.html:34 msgid "You'll receive email notifications about payments sent and received from your wallets." @@ -3516,12 +3590,12 @@ msgstr "Sie erhalten E-Mail Benachrichtigungen über gesendete und empfangen Zah #: www/views/bitpayCard.html:50 msgid "Your BitPay Card is ready. Add funds to your card to start using it at stores and ATMs worldwide." -msgstr "" +msgstr "Ihre BitPay-Karte ist bereit. Fügen sie Mittel auf Ihre Karte hinzu um diesen bei Geschäften und Geldautomaten weltweit zu benutzen." #: www/views/mercadoLibre.html:57 #: www/views/mercadoLibreCards.html:6 msgid "Your Gift Cards" -msgstr "" +msgstr "Ihre Geschenkkarten" #: www/views/includes/confirmBackupPopup.html:6 msgid "Your bitcoin wallet is backed up!" @@ -3533,7 +3607,7 @@ msgstr "Ihre Bitcoin-Wallet ist fertig!" #: www/views/modals/chooseFeeLevel.html:61 msgid "Your fee is lower than recommended." -msgstr "" +msgstr "Ihre Gebühren sind niedriger als empfohlen." #: www/views/feedback/send.html:42 msgid "Your ideas, feedback, or comments" @@ -3554,11 +3628,11 @@ msgstr "Passwort" #: www/views/buyAmazon.html:102 msgid "Your purchase could not be completed" -msgstr "" +msgstr "Ihre Bestellung konnte nicht abgeschlossen werden" #: www/views/buyAmazon.html:105 msgid "Your purchase was added to the list of pending" -msgstr "" +msgstr "Ihre Bestellung wurde in die Liste der anstehenden Bestellungen hinzugefügt" #: www/views/onboarding/backupRequest.html:10 msgid "Your wallet is never saved to cloud storage or standard device backups." @@ -3580,7 +3654,7 @@ msgstr "[Guthaben versteckt]" #: www/views/walletDetails.html:141 #: www/views/walletDetails.html:61 msgid "[Scanning Funds]" -msgstr "" +msgstr "[Mittel werden durchsucht...]" #: src/js/controllers/bitpayCardIntro.js:11 msgid "add your BitPay Visa card(s)" @@ -3604,15 +3678,15 @@ msgstr "in Arbeit..." #: www/views/cashScan.html:57 msgid "recovery tool." -msgstr "" +msgstr "Wiederherstellungstool." #: src/js/controllers/buyAmazon.js:239 msgid "{{amountStr}} for Amazon.com Gift Card" -msgstr "" +msgstr "{{amountStr}} für Amazon.com Geschenkkarte" #: src/js/controllers/buyMercadoLibre.js:237 msgid "{{amountStr}} for Mercado Livre Brazil Gift Card" -msgstr "" +msgstr "{{amountStr}} für Mercado Livre Brazil Geschenkkarte" #: www/views/preferencesBwsUrl.html:21 msgid "{{appName}} depends on Bitcore Wallet Service (BWS) for blockchain information, networking and Copayer synchronization. The default configuration points to https://bws.bitpay.com (BitPay's public BWS instance)." @@ -3624,7 +3698,7 @@ msgstr "{{fee}} wird für Bitcoin-Netzwerkgebühren abgezogen werden." #: www/views/confirm.html:85 msgid "{{tx.txp[wallet.id].feeRatePerStr}} of the sending amount" -msgstr "" +msgstr "{{tx.txp[wallet.id].feeRatePerStr}} von dem sendenden Betrag" #: www/views/walletDetails.html:218 msgid "{{updatingTxHistoryProgress}} transactions downloaded" @@ -3636,3 +3710,51 @@ msgstr "{{updatingTxHistoryProgress}} Transaktionen werden heruntergeladen" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.m}}-von-{{wallet.n}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "Community" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "Bitcoin Cash Reddit" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "Bitcoin.com Twitter" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "Erkunden Sie Bitcoin.com" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "Bitcoin Cash Spiele" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "Neuigkeiten" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "Mining-Pool" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "Werkzeuge" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "Bitcoin Preis-Charts" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "Kostenloses Bitcoin Cash" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "Ihre Bitcoin-Wallet ist fertig!" + diff --git a/i18n/po/es-ES/template-es-ES.po b/i18n/po/es-ES/template-es-ES.po index e062b4d1e..9338825d0 100644 --- a/i18n/po/es-ES/template-es-ES.po +++ b/i18n/po/es-ES/template-es-ES.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Spanish\n" "Language: es\n" -"PO-Revision-Date: 2018-07-04 09:27\n" +"PO-Revision-Date: 2018-07-27 08:44\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "Comprar & Vender Bitcoin" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "Comprar Bitcoin" @@ -619,10 +620,14 @@ msgstr "Conectando a Glidera..." msgid "Connection reset by peer" msgstr "Conexión re establecida" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "Contactos" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "Direcciones frecuentes guardadas" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "Continuar" @@ -823,7 +828,7 @@ msgstr "Crear billetera compartida" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "Crear billetera" @@ -2533,6 +2538,14 @@ msgstr "Buscar transacciones" msgid "Search or enter bitcoin address" msgstr "Buscar o introducir dirección bitcoin" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "Portapapeles" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "Portapapeles vacío" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "Buscar transacciones" @@ -2591,9 +2604,70 @@ msgid "Send by email" msgstr "Enviar por correo electrónico" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "Enviar desde" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "Enviar a" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "Pegar portapapeles" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "Pegar dirección" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "Billetera a billetera" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "Escanear código QR" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "¡Envía Bitcoin más rápido!" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "¡Envía Bitcoin más rápido!" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "Guardar las direcciones que usas frecuentemente y envía Bitcoin en un click" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "Añadie tu primer contacto" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "Tu billetera Bitcoin está vacía" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "Para empezar, compra Bitcoin Cash (BCH) o Bitcoin Core (BTC), o comparte tu dirección." + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "Puedes recibir bitcoin desde cualquier billetera o servicio." + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "Para empezar, necesitarás crear una billetera y obtener bitcoins." + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "Comprar Bitcoin ahora" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "Ver mi dirección" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "Enviar la máxima cantidad" @@ -3030,7 +3104,7 @@ msgstr "Para empezar, compra bitcoin o comparte tu dirección. Puedes recibir bi #: www/views/tab-send.html:33 msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." -msgstr "Para empezar, necesitarás crear una billetera y obtener bitcoins." +msgstr "Para empezar, necesitarás crear una billetera y obtener Bitcoins." #: src/js/services/bitpayAccountService.js:73 msgid "To {{reason}} you must first add your BitPay account - {{email}}" @@ -3636,3 +3710,51 @@ msgstr "{{updatingTxHistoryProgress}} transacciones descargadas" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.m}}-de-{{wallet.n}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift - Cambia BTC a BCH" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "Comunidad" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "Reddit de Bitcoin Cash" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "Twitter de Bitcoin.com" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "Explora Bitcoin.com" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "Juegos de Bitcoin Cash" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "Noticias" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "Minería en la nube" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "Herramientas" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "Gráfica de precios Bitcoin" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "Bitcoin Cash gratis" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "¡Tus billeteras Bitcoin están listas!" + diff --git a/i18n/po/fa/template-fa.po b/i18n/po/fa/template-fa.po index aa4b76892..148ac9147 100644 --- a/i18n/po/fa/template-fa.po +++ b/i18n/po/fa/template-fa.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Persian\n" "Language: fa\n" -"PO-Revision-Date: 2018-07-04 09:27\n" +"PO-Revision-Date: 2018-07-27 08:44\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "خرید & فروش بیتکوین" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "خرید بیتکوین" @@ -619,10 +620,14 @@ msgstr "در حال اتصال به Glidera..." msgid "Connection reset by peer" msgstr "ریست اتصال توسط همکار" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "تماسها" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "آدرس های ذخیره شده که اغلب مورد استفاده قرار گرفته اند" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "ادامه" @@ -823,7 +828,7 @@ msgstr "ایجاد کیف پول مشترک" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "ایجاد کیف پول بیتکوین" @@ -2533,6 +2538,14 @@ msgstr "جستجوی تراکنش ها" msgid "Search or enter bitcoin address" msgstr "جستجو و یا وارد کردن آدرس بیتکوین" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "کلیپ بورد" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "کلیپ بورد شما خالی است" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "جستجوی تراکنش ها" @@ -2591,9 +2604,70 @@ msgid "Send by email" msgstr "ارسال توسط ایمیل" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "ارسال از" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "ارسال به" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "جای گذاری کلیپ برد" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "جای گذاری آدرس" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "انتقال پول از کیف پول به کیف پول" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "اسکن کد QR" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "ارسال سریع تر بیت کوین!" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "ارسال سریع تر بیت کوین!" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "ذخیره آدرس های اغلب استفاده شده و ارسال بیت کوین به آنها تنها با یک ضربه" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "اولین تماس خود اضافه کنید" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "کیف پول بیت کوین شما خالی است" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "برای شروع، Bitcoin Cash (BCH) یا Bitcoin Core (BTC) بخرید و یا آدرس خود را به اشتراک بگذارید." + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "شما می توانید از هر کیف پول و یا خدمات بیت کوین دریافت کنید." + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "برای شروع، شما نیاز دارید که یک کیف پول ایجاد کنید و مقداری بیتکوین تهیه کنید." + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "خرید بیت کوین همین الان" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "نمایش آدرس من" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "ارسال حداکثر مقدار" @@ -3030,7 +3104,7 @@ msgstr "برای شروع، بیتکوین بخرید و یا آدرس خود ر #: www/views/tab-send.html:33 msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." -msgstr "برای شروع، شما نیاز دارید که یک کیف پول ایجاد کنید و مقداری بیتکوین تهیه کنید." +msgstr "برای شروع، شما نیاز دارید که یک کیف پول بیت کوین ایجاد کرده و مقداری بیت کوین تهیه کنید." #: src/js/services/bitpayAccountService.js:73 msgid "To {{reason}} you must first add your BitPay account - {{email}}" @@ -3636,3 +3710,51 @@ msgstr "{{updatingTxHistoryProgress}} تراکنش دانلود شد" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.m}} از {{wallet.n}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "جامعه" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "Bitcoin Cash Reddit" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "توییتر Bitcoin.com" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "کاوش Bitcoin.com" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "Bitcoin Cash Games" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "اخبار" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "استخر استخراج" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "ابزارها" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "نمودارهای قیمت بیت کوین" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "رایگان Bitcoin Cash" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "کیف پول بیت کوین شما آماده است!" + diff --git a/i18n/po/fr/template-fr.po b/i18n/po/fr/template-fr.po index f49b0fe55..d87845d47 100644 --- a/i18n/po/fr/template-fr.po +++ b/i18n/po/fr/template-fr.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: French\n" "Language: fr\n" -"PO-Revision-Date: 2018-07-04 09:26\n" +"PO-Revision-Date: 2018-07-27 08:44\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -79,7 +79,7 @@ msgstr "Numéro de compte" #: www/views/tab-home.html:61 msgid "Instant transactions with low fees" -msgstr "Transactions instantanées à bas frais" +msgstr "Instant transactions with low fees" #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "Acheter & vendre des bitcoins" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "Acheter des bitcoins" @@ -619,10 +620,14 @@ msgstr "Connexion à Glidera..." msgid "Connection reset by peer" msgstr "Connexion réinitialisée par un pair" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "Contacts" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "Adresses fréquemment utilisées enregistrées" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "Continuer" @@ -823,7 +828,7 @@ msgstr "Créer un portefeuille partagé" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "Créer un portefeuille bitcoin" @@ -993,7 +998,7 @@ msgstr "Autoriser les notifications" #: www/views/preferencesNotifications.html:33 msgid "Enable sound" -msgstr "Activer le son" +msgstr "Malayu" #: www/views/tab-scan.html:18 msgid "Enable the camera to get started." @@ -2533,6 +2538,14 @@ msgstr "Rechercher des transactions" msgid "Search or enter bitcoin address" msgstr "Recherchez ou saisissez une adresse bitcoin" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "Presse-papiers" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "Votre presse-papiers est vide" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "Rechercher des transactions" @@ -2591,9 +2604,70 @@ msgid "Send by email" msgstr "Envoyer par e-mail" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "Envoyer à partir de" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "Envoyer à" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "Coller le contenu du presse-papiers" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "Coller l'adresse" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "Transfert de portefeuille à portefeuille" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "Numérisez le code QR" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Envoyez des Bitcoin plus vite !" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Envoyez des Bitcoin plus vite !" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "Enregistrez les adresses fréquemment utilisées et envoyez-leurs des Bitcoins en un seul geste" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "Ajoutez votre premier contact" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "Votre portefeuille Bitcoin est vide" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "Pour commencer, achetez des Bitcoins Cash (BCH) ou des Bitcoins Core (BTC), ou partagez votre adresse." + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "Vous pouvez recevoir des Bitcoins de n'importe quel portefeuille ou service." + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "Pour commencer, vous aurez besoin de créer un portefeuille bitcoin et d'obtenir quelques bitcoins." + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "Acheter des Bitcoins maintenant" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "Afficher mon adresse" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "Envoyer le montant maximal" @@ -3030,7 +3104,7 @@ msgstr "Pour commencer, achetez des bitcoins ou partagez votre adresse. Vous pou #: www/views/tab-send.html:33 msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." -msgstr "Pour commencer, vous aurez besoin de créer un portefeuille bitcoin et d'obtenir quelques bitcoins." +msgstr "Pour commencer, vous aurez besoin de créer un portefeuille Bitcoin et d'obtenir quelques bitcoins." #: src/js/services/bitpayAccountService.js:73 msgid "To {{reason}} you must first add your BitPay account - {{email}}" @@ -3636,3 +3710,51 @@ msgstr "{{updatingTxHistoryProgress}} transactions téléchargées" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.m}}-sur-{{wallet.n}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "Communauté" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "Reddit Bitcoin Cash" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "Twitter Bitcoin.com" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "Explorez Bitcoin.com" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "Jeux Bitcoin Cash" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "Nouvelles" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "Coopératives de mineurs" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "Outils" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "Graphiques du prix du Bitcoin" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "Bitcoin Cash Gratuit" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "Vos portefeuilles bitcoin sont prêts !" + diff --git a/i18n/po/it/template-it.po b/i18n/po/it/template-it.po index 1fcaea030..62738bf84 100644 --- a/i18n/po/it/template-it.po +++ b/i18n/po/it/template-it.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Italian\n" "Language: it\n" -"PO-Revision-Date: 2018-07-04 09:27\n" +"PO-Revision-Date: 2018-07-27 08:44\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "Comprare & Vendere Bitcoin" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "Acquista Bitcoin" @@ -619,10 +620,14 @@ msgstr "Connessione a Glidera..." msgid "Connection reset by peer" msgstr "Connessione ripristinata dall'utente" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "Contatti" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "Indirizzi più utilizzati salvati" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "Continua" @@ -823,7 +828,7 @@ msgstr "Creare portafoglio condiviso" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "Creare portafoglio bitcoin" @@ -2533,6 +2538,14 @@ msgstr "Cerca Transazioni" msgid "Search or enter bitcoin address" msgstr "Cerca o inserisci indirizzo bitcoin" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "Appunti" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "Gli appunti sono vuoti" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "Ricerca transazioni" @@ -2591,9 +2604,70 @@ msgid "Send by email" msgstr "Invia via email" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "Inviata Da" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "Invia a" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "Incolla appunti" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "Incolla indirizzo" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "Trasferimento da portafoglio a portafoglio" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "Scansiona codice QR" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Invia Bitcoin più velocemente!" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Invia Bitcoin più velocemente!" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "Salva gli indirizzi più utilizzati e invia Bitcoin con un solo tocco" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "Aggiungi il tuo primo contatto" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "Il tuo portafoglio Bitcoin è vuoto" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "Per iniziare, acquista Bitcoin Cash (BCH) o Bitcoin Core (BTC), oppure condividi il tuo indirizzo." + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "Puoi ricevere Bitcoin da qualsiasi portafoglio o servizio." + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "Per iniziare, è necessario che tu crei un portafoglio bitcoin e ottenerne qualcuno." + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "Acquista subito Bitcoin" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "Visualizza il mio indirizzo" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "Inviare l'importo massimo" @@ -3030,7 +3104,7 @@ msgstr "Per iniziare, acquista bitcoin o condividi il tuo indirizzo. È possibil #: www/views/tab-send.html:33 msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." -msgstr "Per iniziare, è necessario che tu crei un portafoglio bitcoin e ottenerne qualcuno." +msgstr "Per iniziare, devi creare un portafoglio bitcoin e ottenere qualche bitcoin." #: src/js/services/bitpayAccountService.js:73 msgid "To {{reason}} you must first add your BitPay account - {{email}}" @@ -3636,3 +3710,51 @@ msgstr "{{updatingTxHistoryProgress}} transazioni scaricate" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.m}}-di-{{wallet.n}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "Community" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "Bitcoin Cash su Reddit" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "Bitcoin.com su Twitter" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "Esplora Bitcoin.com" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "Giochi Bitcoin Cash" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "News" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "Mining Pool" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "Strumenti" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "Tabella prezzi Bitcoin" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "Bitcoin Cash gratis" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "I tuoi portafogli Bitcoin sono pronti!" + diff --git a/i18n/po/ja/template-ja.po b/i18n/po/ja/template-ja.po index e7df99c1b..30668ce9d 100644 --- a/i18n/po/ja/template-ja.po +++ b/i18n/po/ja/template-ja.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Japanese\n" "Language: ja\n" -"PO-Revision-Date: 2018-07-04 09:27\n" +"PO-Revision-Date: 2018-07-27 08:44\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -406,7 +406,7 @@ msgstr "ビットコインは世界で
最も安全な仮想通貨。" #: www/views/preferencesFee.html:11 msgid "Bitcoin transactions include a fee collected by miners on the network." -msgstr "ビットコインの取引はネットワークの安全を守る「採掘者」と呼ばれる者達に送る手数料が含まれます。" +msgstr "ビットコインの取引はネットワークの安全を守る「採掘者」と呼ばれる方達に送る手数料が含まれます。" #: www/views/buyAmazon.html:108 msgid "Bought {{amountUnitStr}}" @@ -439,6 +439,7 @@ msgid "Buy & Sell Bitcoin" msgstr "ビットコインの購入&売却" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "ビットコインを購入" @@ -621,10 +622,14 @@ msgstr "Glidera に接続中…" msgid "Connection reset by peer" msgstr "接続がピアによってリセットされました" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "連絡先" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "よく使う保存済みのアドレス" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "続ける" @@ -825,7 +830,7 @@ msgstr "共有ウォレットを作成" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "ビットコインウォレット作成" @@ -995,7 +1000,7 @@ msgstr "プッシュ通知を有効化" #: www/views/preferencesNotifications.html:33 msgid "Enable sound" -msgstr "音を有効にする" +msgstr "サウンドを有効にする" #: www/views/tab-scan.html:18 msgid "Enable the camera to get started." @@ -1348,7 +1353,7 @@ msgstr "始めよう" #: www/views/addressbook.html:20 msgid "Get started by adding your first one." -msgstr "初めての連絡先を追加しましょう。" +msgstr "連絡先を追加しましょう。" #: src/js/services/onGoingProcess.js:23 msgid "Getting fee levels..." @@ -1873,7 +1878,7 @@ msgstr "バックアップは非常に重要です!" #: www/views/addressbook.html:19 msgid "No contacts yet" -msgstr "連絡先が無い" +msgstr "連絡先はありません" #: www/views/preferencesLogs.html:16 msgid "No entries for this log level" @@ -2006,7 +2011,7 @@ msgstr "今一度周りの環境をよく見てみましょう。隠しカメラ #: src/js/services/popupService.js:72 #: www/views/modals/chooseFeeLevel.html:6 msgid "OK" -msgstr "わかりました" +msgstr "OK" #: www/views/modals/tx-status.html:12 #: www/views/modals/tx-status.html:24 @@ -2535,6 +2540,14 @@ msgstr "取引を検索" msgid "Search or enter bitcoin address" msgstr "連絡先検索かビットコインアドレスを指定" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "クリップボード" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "クリップボードは空です" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "取引を検索" @@ -2593,9 +2606,70 @@ msgid "Send by email" msgstr "メールで送信" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "ここから送金" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "送金先:" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "クリップボードからペースト" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "アドレスをペースト" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "ウォレット間送金" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "QRコードを読み取る" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "ビットコイン送金をより高速に!" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "ビットコイン送金をより高速に!" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "よく使うアドレスを保存すればワンタップでビットコインを送金できます" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "最初の連絡先を追加" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "ビットコインウォレットが空です" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "始めるには、Bitcoin Cash (BCH) または Bitcoin Core (BTC) を購入するか、あなたのアドレスを共有してください。" + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "どのウォレットやサービスからでもビットコインを受け取ることができます。" + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "はじめに、ビットコインウォレットを作成し、ビットコインを入手する必要があります。" + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "今すぐビットコインを購入" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "自分のアドレスを表示" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "全残高を送金" @@ -3450,7 +3524,7 @@ msgstr "送金発生時のメール通知はどのメールアドレスで受け #: www/views/addresses.html:19 msgid "Why?" -msgstr "なぜ?" +msgstr "なぜですか?" #: www/views/feedback/rateApp.html:10 msgid "Would you be willing to rate {{appName}} in the app store?" @@ -3642,3 +3716,51 @@ msgstr "{{updatingTxHistoryProgress}} 個の取引ダウンロード済み" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.m}} の{{wallet.n}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "コミュニティ" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "Bitcoin Cash Reddit" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "Bitcoin.com Twitter" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "Bitcoin.com を参照" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "Bitcoin Cash ゲーム" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "ニュース" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "マイニングプール" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "ツール" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "ビットコインの価格チャート" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "無料 Bitcoin Cash" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "ビットコインウォレットが完成しました!" + diff --git a/i18n/po/ko/template-ko.po b/i18n/po/ko/template-ko.po index cee1be7d1..6285496ae 100644 --- a/i18n/po/ko/template-ko.po +++ b/i18n/po/ko/template-ko.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Korean\n" "Language: ko\n" -"PO-Revision-Date: 2018-07-04 09:27\n" +"PO-Revision-Date: 2018-07-27 08:44\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "비트코인 구매 & 판매" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "비트코인 구매" @@ -619,10 +620,14 @@ msgstr "Glidera에 연결 중..." msgid "Connection reset by peer" msgstr "연결 실패" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "연락처" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "자주 사용하는 저장된 주소" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "계속하기" @@ -823,7 +828,7 @@ msgstr "공유 지갑 만들기" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "비트코인 지갑 만들기" @@ -2533,6 +2538,14 @@ msgstr "거래 기록 검색하기" msgid "Search or enter bitcoin address" msgstr "비트코인 주소를 찾거나 작성" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "클립보드" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "클립보드가 비어 있습니다" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "거래 기록 검색" @@ -2591,9 +2604,70 @@ msgid "Send by email" msgstr "이메일로 보내기" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "출처" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "보내기" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "클립보드 붙여넣기" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "주소 붙여넣기" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "지갑 간 전송" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "QR 코드 스캔" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "비트코인 속성 전송!" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "비트코인 속성 전송!" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "자주 사용하는 주소를 저장하고 한 번의 탭으로 저장된 주소에 비트코인 전송" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "첫 번째 연락처 추가" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "비트코인 지갑이 비어 있습니다" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "시작하려면 비트코인 캐시(BCH) 또는 비트코인 코어(BTC)를 구매하거나 주소를 공유합니다." + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "지갑 또는 서비스에서 비트코인을 받을 수 있습니다." + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "시작하시기 위해선 비트코인 지갑을 생성하시거나 비트코인을 구매하세요." + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "지금 비트코인 구매" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "내 주소 보기" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "최대 수량 보내기" @@ -3030,7 +3104,7 @@ msgstr "시작하시려면 비트코인을 구매하시거나 주소를 등록 #: www/views/tab-send.html:33 msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." -msgstr "시작하시기 위해선 비트코인 지갑을 생성하시거나 비트코인을 구매하세요." +msgstr "시작하려면 비트코인 지갑을 만들고 비트코인을 구매하십시오." #: src/js/services/bitpayAccountService.js:73 msgid "To {{reason}} you must first add your BitPay account - {{email}}" @@ -3636,3 +3710,51 @@ msgstr "{{updatingTxHistoryProgress}} 거래 내역 다운로드 완료" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.n}}의 {{wallet.m}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "커뮤니티" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "BCH Reddit" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "Bitcoin.com 트위터" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "Bitcoin.com 탐색" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "BCH 게임" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "소식" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "채굴 풀" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "도구" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "비트코인 가격 차트" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "무료 BCH" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "비트코인 지갑이 완료되었습니다!" + diff --git a/i18n/po/nl/template-nl.po b/i18n/po/nl/template-nl.po index 754c41e21..b66d0b892 100644 --- a/i18n/po/nl/template-nl.po +++ b/i18n/po/nl/template-nl.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Dutch\n" "Language: nl\n" -"PO-Revision-Date: 2018-07-04 09:26\n" +"PO-Revision-Date: 2018-07-27 08:44\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "Koop & Verkoop Bitcoin" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "Bitcoin kopen" @@ -619,10 +620,14 @@ msgstr "Verbinding maken met Glidera..." msgid "Connection reset by peer" msgstr "Verbinding is gereset door peer" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "Contactpersonen" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "Opgeslagen veelgebruikte adressen" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "Ga verder" @@ -823,7 +828,7 @@ msgstr "Gedeelde Portemonnee Aanmaken" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "Bitcoin portemonnee aanmaken" @@ -2533,6 +2538,14 @@ msgstr "Doorzoek Transacties" msgid "Search or enter bitcoin address" msgstr "Zoeken of bitcoin adres invullen" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "Klembord" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "Uw klembord is leeg" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "Doorzoek transacties" @@ -2591,9 +2604,70 @@ msgid "Send by email" msgstr "Verstuur via email" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "Verzenden vanuit" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "Verzenden naar" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "Klembord plakken" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "Adres plakken" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "Portemonnee overdracht" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "Scan QR-code" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Stuur Bitcoin sneller!" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Stuur Bitcoin sneller!" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "Sla veelgebruikte adressen op en verstuur ze Bitcoin met een druk op de knop" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "Uw eerste contact toevoegen" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "Uw Bitcoin portemonnee is leeg" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "Om aan de slag te gaan, koop Bitcoin Cash (BCH) of Bitcoin Core (BTC), of deel uw adres." + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "U kunt Bitcoin ontvangen van elke portemonnee of dienst." + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "Om aan de slag te gaan zult u een bitcoin portemonnee moeten aanmaken en wat bitcoin moeten verkrijgen." + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "Bitcoin kopen" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "Toon mijn adres" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "Verzend maximale hoeveelheid" @@ -3030,7 +3104,7 @@ msgstr "Om aan de slag te gaan, koop bitcoin of deel uw adres. U kunt bitcoin on #: www/views/tab-send.html:33 msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." -msgstr "Om aan de slag te gaan zult u een bitcoin portemonnee moeten aanmaken en wat bitcoin moeten verkrijgen." +msgstr "Om aan de slag te gaan, zult u een Bitcoin-portemonnee aan moeten maken en wat Bitcoin moeten verkrijgen." #: src/js/services/bitpayAccountService.js:73 msgid "To {{reason}} you must first add your BitPay account - {{email}}" @@ -3636,3 +3710,51 @@ msgstr "{{updatingTxHistoryProgress}} transacties gedownload" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.m}}-van-{{wallet.n}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "Community" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "Bitcoin Cash Reddit" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "Bitcoin.com Twitter" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "Bitcoin.com verkennen" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "Bitcoin Cash spellen" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "Nieuws" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "Mining Pool" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "Hulpmiddelen" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "Bitcoin prijs grafieken" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "Gratis Bitcoin Cash" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "Uw bitcoin portemonnee is gereed!" + diff --git a/i18n/po/pl/template-pl.po b/i18n/po/pl/template-pl.po index ce075e00b..ef9888ca5 100644 --- a/i18n/po/pl/template-pl.po +++ b/i18n/po/pl/template-pl.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Polish\n" "Language: pl\n" -"PO-Revision-Date: 2018-07-04 03:58\n" +"PO-Revision-Date: 2018-07-27 08:44\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -79,7 +79,7 @@ msgstr "Numer konta" #: www/views/tab-home.html:61 msgid "Instant transactions with low fees" -msgstr "" +msgstr "Natychmiastowe transakcje z niskimi prowizjami" #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" @@ -363,12 +363,12 @@ msgstr "Adres bitcoin" #: www/views/cashScan.html:4 msgid "Bitcoin Cash (BCH) Balances" -msgstr "" +msgstr "Salda Bitcoin Cash (BCH)" #: www/views/preferencesCash.html:3 #: www/views/tab-settings.html:47 msgid "Bitcoin Cash Support" -msgstr "" +msgstr "Wsparcie Bitcoin Cash" #: www/views/tab-home.html:98 #: www/views/tab-settings.html:115 @@ -384,7 +384,7 @@ msgstr "Polityka prowizji sieci bitcoin" #: www/views/tab-home.html:83 #: www/views/tab-settings.html:107 msgid "Bitcoin Core Wallets" -msgstr "" +msgstr "Portfele Bitcoin Core" #: src/js/services/incomingData.js:151 msgid "Bitcoin cash Payment" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "Kup & sprzedaj bitcoiny" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "Kup bitcoiny" @@ -619,10 +620,14 @@ msgstr "Łączenie z Gildera..." msgid "Connection reset by peer" msgstr "Połączenie zostało zresetowane" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "Kontakty" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "Zapisane często używane adresy" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "Dalej" @@ -823,7 +828,7 @@ msgstr "Utwórz współdzielony portfel" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "Utwórz portfel bitcoin" @@ -977,7 +982,7 @@ msgstr "Puste adresy osiągnęły limit. Nowe adresy nie mogą być generowane." #: www/views/preferencesCash.html:17 msgid "Enable Bitcoin Cash wallet creation and operation within the App." -msgstr "" +msgstr "Włącz tworzenie i obsługę portfela Bitcoin Cash w aplikacji." #: www/views/tab-scan.html:19 msgid "Enable camera access in your device settings to get started." @@ -993,7 +998,7 @@ msgstr "Włącz powiadomienia" #: www/views/preferencesNotifications.html:33 msgid "Enable sound" -msgstr "" +msgstr "Włącz dźwięk" #: www/views/tab-scan.html:18 msgid "Enable the camera to get started." @@ -1001,7 +1006,7 @@ msgstr "Włącz kamerę aby rozpocząć." #: www/views/tab-settings.html:49 msgid "Enabled" -msgstr "" +msgstr "Włączono" #: src/js/services/walletService.js:1047 #: src/js/services/walletService.js:1062 @@ -1586,7 +1591,7 @@ msgstr "Nieprawidłowy adres" #: src/js/controllers/confirm.js:306 #: src/js/services/bwcError.js:44 msgid "Insufficient confirmed funds" -msgstr "" +msgstr "Niewystarczające potwierdzone środki" #: src/js/controllers/topup.js:165 #: src/js/controllers/topup.js:177 @@ -1931,7 +1936,7 @@ msgstr "Nie BIP44 portfel" #: www/views/cashScan.html:46 msgid "Non eligible BTC wallets" -msgstr "" +msgstr "Niewspierane portfele BTC" #: src/js/services/feeService.js:12 msgid "Normal" @@ -2004,7 +2009,7 @@ msgstr "Nadszedł czas, aby sprawdzić swoje otoczenie. Czy jesteś w pobliżu o #: src/js/services/popupService.js:72 #: www/views/modals/chooseFeeLevel.html:6 msgid "OK" -msgstr "" +msgstr "OK" #: www/views/modals/tx-status.html:12 #: www/views/modals/tx-status.html:24 @@ -2023,7 +2028,7 @@ msgstr "O nie!" #: src/js/controllers/buyMercadoLibre.js:306 msgid "Ok" -msgstr "" +msgstr "Ok" #: www/views/tab-home.html:39 msgid "On this screen you can see all your wallets, accounts, and assets." @@ -2053,7 +2058,7 @@ msgstr "Otwórz projekt GitHub" #: src/js/controllers/bitpayCard.js:123 #: src/js/controllers/tx-details.js:192 msgid "Open Explorer" -msgstr "" +msgstr "Otwórz Explorer" #: www/views/tab-scan.html:22 msgid "Open Settings" @@ -2069,7 +2074,7 @@ msgstr "Otwórz stronę internetową" #: src/js/controllers/preferencesCash.js:32 msgid "Open bitcoincash.org?" -msgstr "" +msgstr "Otworzyć bitcoincash.org?" #: src/js/controllers/cashScan.js:18 msgid "Open the recovery tool." @@ -2240,7 +2245,7 @@ msgstr "Proszę wybrać plik kopii zapasowej" #: www/views/bitpayCard.html:81 msgid "Pre-Auth Holds" -msgstr "" +msgstr "Wstrzymanie przedautoryzacyjne" #: www/views/tab-settings.html:40 msgid "Preferences" @@ -2353,7 +2358,7 @@ msgstr "Otrzymaj" #: www/views/customAmount.html:44 msgid "Receive in" -msgstr "" +msgstr "Otrzymaj w" #: www/views/includes/walletHistory.html:24 #: www/views/tx-details.html:18 @@ -2511,7 +2516,7 @@ msgstr "Proszę zeskanować linie papilarne" #: www/views/preferencesCash.html:23 msgid "Scan your wallets for Bitcoin Cash" -msgstr "" +msgstr "Skanuj portfele w poszukiwaniu Bitcoin Cash" #: src/js/services/onGoingProcess.js:30 msgid "Scanning Wallet funds..." @@ -2533,6 +2538,14 @@ msgstr "Szukaj transakcji" msgid "Search or enter bitcoin address" msgstr "Wyszukaj lub wpisz adres bitcoin" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "Schowek" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "Schowek jest pusty" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "Szukaj transakcji" @@ -2591,9 +2604,70 @@ msgid "Send by email" msgstr "Wyślij przez e-mail" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "Wyślij z" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "Wyślij do" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "Wklej ze schowka" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "Wklej adres" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "Transfer z portfela do portfela" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "Zeskanuj kod QR" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Przesyłaj Bitcoiny szybciej!" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Przesyłaj Bitcoiny szybciej!" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "Zapisz często używane adresy i wyślij im Bitcoin za pomocą jednego dotknięcia" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "Dodaj swój pierwszy kontakt" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "Twój portfel jest pusty" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "Aby zacząć, kup Bitcoin Cash (BCH) lub Bitcoin Core (BTC), albo udostępnij swój adres." + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "Bitcoiny można odbierać z dowolnego portfela lub usługi." + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "Aby rozpocząć należy utworzyć portfel i dostać trochę bitcoinów." + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "Kup Bitcoin teraz" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "Pokaż mój adres" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "Wyślij całą kwotę" @@ -2764,7 +2838,7 @@ msgstr "Przesuń, aby wysłać" #: www/views/cashScan.html:56 msgid "Some of your wallets are not eligible for Bitcoin Cash support. You can try to access BCH funds from these wallets using the" -msgstr "" +msgstr "Niektóre z twoich portfeli nie kwalifikują się do wsparcia Bitcoin Cash. Dostęp do środków BCH z tych portfeli można spróbować uzyskać, korzystając z" #: src/js/controllers/create.js:88 #: src/js/controllers/join.js:71 @@ -2785,7 +2859,7 @@ msgstr "Wymagane hasło wypłat" #: www/views/walletDetails.html:173 msgid "Spending this balance will need significant Bitcoin network fees" -msgstr "" +msgstr "Wydanie tego salda będzie wymagało znacznych opłat sieciowych Bitcoin" #: www/views/tab-send.html:28 msgid "Start sending bitcoin" @@ -2810,7 +2884,7 @@ msgstr "Super Ekonomiczna" #: www/views/preferencesCash.html:11 msgid "Support Bitcoin Cash" -msgstr "" +msgstr "Wsparcie Bitcoin Cash" #: www/views/paperWallet.html:7 msgid "Sweep" @@ -2860,7 +2934,7 @@ msgstr "Warunki użytkowania" #: www/views/tab-create-personal.html:118 #: www/views/tab-import-phrase.html:68 msgid "Testnet" -msgstr "" +msgstr "Testnet" #: www/views/includes/incomingDataMenu.html:61 msgid "Text" @@ -2999,7 +3073,7 @@ msgstr "Ta kluczowa fraza został utworzona przy użyciu hasła. Aby odzyskać p #: www/views/tx-details.html:91 msgid "This transaction amount is too small compared to current Bitcoin network fees. Spending these funds will need a Bitcoin network fee cost comparable to the funds itself." -msgstr "" +msgstr "Ta kwota transakcji jest zbyt mała w porównaniu z obecnymi opłatami sieci Bitcoin. Wydanie tych środków będzie wymagało opłaty sieciowej Bitcoin, która jest porównywalna do kosztów samych funduszy." #: www/views/tx-details.html:87 msgid "This transaction could take a long time to confirm or could be dropped due to the low fees set by the sender" @@ -3034,15 +3108,15 @@ msgstr "Aby rozpocząć należy utworzyć portfel i dostać trochę bitcoinów." #: src/js/services/bitpayAccountService.js:73 msgid "To {{reason}} you must first add your BitPay account - {{email}}" -msgstr "" +msgstr "Aby móc wykonać czynność {{reason}}, musisz przedtem dodać swoje konto BitPay – {{email}}" #: src/js/services/onGoingProcess.js:48 msgid "Top up in progress..." -msgstr "" +msgstr "Doładowanie w trakcie..." #: src/js/controllers/topup.js:206 msgid "Top up {{amountStr}} to debit card ({{cardLastNumber}})" -msgstr "" +msgstr "Doładuj o {{amountStr}} kartę debetową ({{cardLastNumber}})" #: www/views/buyAmazon.html:61 #: www/views/buyMercadoLibre.html:60 @@ -3061,7 +3135,7 @@ msgstr "Liczba współwłaścicieli portfela" #: www/views/addresses.html:81 msgid "Total wallet inputs" -msgstr "" +msgstr "Dane wejściowe portfela łącznie" #: src/js/services/fingerprintService.js:63 #: src/js/services/fingerprintService.js:68 @@ -3200,7 +3274,7 @@ msgstr "Zobacz zasady użytkowania" #: src/js/controllers/bitpayCard.js:122 #: src/js/controllers/tx-details.js:191 msgid "View Transaction on Explorer.Bitcoin.com" -msgstr "" +msgstr "Zobacz transakcję na Explorer.Bitcoin.com" #: src/js/controllers/tab-home.js:148 msgid "View Update" @@ -3212,7 +3286,7 @@ msgstr "Zobacz na blockchainie" #: www/views/mercadoLibre.html:26 msgid "Visit mercadolivre.com.br →" -msgstr "" +msgstr "Odwiedź mercadolivre.com.br →" #: www/views/walletDetails.html:182 msgid "WARNING: Key derivation is not working on this device/wallet. Actions cannot be performed on this wallet." @@ -3274,7 +3348,7 @@ msgstr "Informacje o portfelu" #: www/views/addresses.html:76 msgid "Wallet Inputs" -msgstr "" +msgstr "Dane wejściowe portfela" #: www/views/join.html:26 msgid "Wallet Invitation" @@ -3328,7 +3402,7 @@ msgstr "Portfel już istnieje" #: src/js/services/profileService.js:516 msgid "Wallet already in {{appName}}" -msgstr "" +msgstr "Portfel już w aplikacji {{appName}}" #: www/views/includes/walletActivity.html:6 msgid "Wallet created" @@ -3508,7 +3582,7 @@ msgstr "Nie należy ustawiać opłatę wyższą niż {{maxFeeRecommended}} satos #: www/views/modals/bitpay-card-confirmation.html:5 msgid "You will need to log back for fill in your BitPay Card." -msgstr "" +msgstr "Musisz zalogować się ponownie, aby wypełnić swoją kartę BitPay." #: www/views/preferencesNotifications.html:34 msgid "You'll receive email notifications about payments sent and received from your wallets." @@ -3580,7 +3654,7 @@ msgstr "[Balans ukryty]" #: www/views/walletDetails.html:141 #: www/views/walletDetails.html:61 msgid "[Scanning Funds]" -msgstr "" +msgstr "[Skanowanie środków]" #: src/js/controllers/bitpayCardIntro.js:11 msgid "add your BitPay Visa card(s)" @@ -3612,7 +3686,7 @@ msgstr "{{amountStr}} dla karty upominkowej Amazon.com" #: src/js/controllers/buyMercadoLibre.js:237 msgid "{{amountStr}} for Mercado Livre Brazil Gift Card" -msgstr "" +msgstr "{{amountStr}} na karcie podarunkowej Mercado Livre Brazil" #: www/views/preferencesBwsUrl.html:21 msgid "{{appName}} depends on Bitcore Wallet Service (BWS) for blockchain information, networking and Copayer synchronization. The default configuration points to https://bws.bitpay.com (BitPay's public BWS instance)." @@ -3624,7 +3698,7 @@ msgstr "{{fee}} zostanie potrącone jako prowizja sieci bitcoin." #: www/views/confirm.html:85 msgid "{{tx.txp[wallet.id].feeRatePerStr}} of the sending amount" -msgstr "" +msgstr "{{tx.txp[wallet.id].feeRatePerStr}} wysyłanej kwoty" #: www/views/walletDetails.html:218 msgid "{{updatingTxHistoryProgress}} transactions downloaded" @@ -3636,3 +3710,51 @@ msgstr "{{updatingTxHistoryProgress}} transakcje pobrane" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.m}}-z-{{wallet.n}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "Społeczność" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "Reddit Bitcoin Cash" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "Twitter Bitcoin.com" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "Poznaj Bitcoin.com" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "Gry Bitcoin Cash" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "Aktualności" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "Pula kopalni" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "Narzędzia" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "Wykresy kursu Bitcoin" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "Darmowa Bitcoin Cash" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "Twoje portfele Bitcoin są gotowe!" + diff --git a/i18n/po/pt-BR/template-pt-BR.po b/i18n/po/pt-BR/template-pt-BR.po index c83259bf9..6879b52c4 100644 --- a/i18n/po/pt-BR/template-pt-BR.po +++ b/i18n/po/pt-BR/template-pt-BR.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Portuguese, Brazilian\n" "Language: pt\n" -"PO-Revision-Date: 2018-07-04 09:27\n" +"PO-Revision-Date: 2018-07-27 08:44\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "Comprar & Vender Bitcoin" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "Comprar Bitcoin" @@ -619,10 +620,14 @@ msgstr "A conectar ao Glidera..." msgid "Connection reset by peer" msgstr "Ligação redefinida pelo mesmo nível" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "Contactos" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "Salvou os endereços usados com frequência" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "Continuar" @@ -823,7 +828,7 @@ msgstr "Criar carteira partilhada" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "Criar carteira bitcoin" @@ -2533,6 +2538,14 @@ msgstr "Procurar transações" msgid "Search or enter bitcoin address" msgstr "Procure ou digite o endereço bitcoin" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "Área de transferência" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "A sua área de transferência está vazia" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "Procurar transações" @@ -2591,9 +2604,70 @@ msgid "Send by email" msgstr "Enviar por E-mail" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "Enviar De" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "Enviar para" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "Colar na área de trabalho" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "Colar endereço" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "Transferência de carteira para carteira" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "Digitalizar o código QR" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Envie Bitcoin mais rápido!" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Envie Bitcoin mais rápido!" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "Salvar endereços usados com frequência e enviar Bitcoin com apenas um toque" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "Adicionar o seu primeiro contato" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "Sua carteira de Bitcoin está vazia" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "Para começar, compre Bitcoin Cash (BCH) ou Bitcoin Core (BTC) ou compartilhe o seu endereço." + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "Você pode receber bitcoin de qualquer carteira ou serviço." + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "Para começar, você precisa criar uma carteira de bitcoins e obter alguns bitcoins." + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "Compre Bitcoin agora" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "Mostrar meu endereço" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "Quantidade Máxima de envio" @@ -3030,7 +3104,7 @@ msgstr "Para começar, compre bitcoins ou compartilhe seu endereço. Você pode #: www/views/tab-send.html:33 msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." -msgstr "Para começar, você precisa criar uma carteira de bitcoins e obter alguns bitcoins." +msgstr "Para começar, você precisará criar uma carteira e obter algum bitcoin." #: src/js/services/bitpayAccountService.js:73 msgid "To {{reason}} you must first add your BitPay account - {{email}}" @@ -3636,3 +3710,51 @@ msgstr "Transações de {{updatingTxHistoryProgress}} transferidas" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.m}}-de-{{wallet.n}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "Comunidade" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "Bitcoin Cash Reddit" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "Twitter Bitcoin.com" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "Explore Bitcoin.com" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "Jogos Bitcoin Cash" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "Notícias" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "Pool de mineração" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "Ferramentas" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "Gráficos de preço do Bitcoin" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "Bitcoin Cash grátis" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "As suas carteiras de Bitcoin estão prontas!" + diff --git a/i18n/po/ru/template-ru.po b/i18n/po/ru/template-ru.po index 074fa9937..a9d5d2970 100644 --- a/i18n/po/ru/template-ru.po +++ b/i18n/po/ru/template-ru.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Russian\n" "Language: ru\n" -"PO-Revision-Date: 2018-07-04 09:27\n" +"PO-Revision-Date: 2018-07-27 08:44\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -79,7 +79,7 @@ msgstr "Номер учётной записи" #: www/views/tab-home.html:61 msgid "Instant transactions with low fees" -msgstr "Мгновенные транзакции с низкой оплатой" +msgstr "Мгновенные транзакции с низкой комиссией" #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "Купить & продать биткойн" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "Купить биткойн" @@ -619,10 +620,14 @@ msgstr "Подключение к Glidera..." msgid "Connection reset by peer" msgstr "Соединение сброшено другой стороной" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "Контакты" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "Сохраненные часто используемые адреса" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "Продолжить" @@ -823,7 +828,7 @@ msgstr "Создать общий кошелёк" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "Создать биткойн-кошелёк" @@ -2533,6 +2538,14 @@ msgstr "Поиск транзакций" msgid "Search or enter bitcoin address" msgstr "Найти или ввести биткойн-адрес" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "Буфер обмена" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "Буфер обмена пуст" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "Поиск транзакций" @@ -2591,9 +2604,70 @@ msgid "Send by email" msgstr "Отправить на email" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "Отправить от" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "Получатель" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "Вставить из буфера обмена" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "Вставить адрес" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "Перевод с кошелька на кошелек" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "Сканировать QR код" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Отправляйте биткойны еще быстрее!" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "Отправляйте биткойны еще быстрее!" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "Сохраняйте часто используемые адреса кошельков и отправляйте на них биткойны одним нажатием" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "Добавить первый контакт" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "Ваш кошелёк пуст" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "Чтобы начать работу, купите Bitcoin Cash (BCH) или Bitcoin Core (BTC), или поделитесь вашим адресом." + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "Вы можете получать биткойны с любого кошелька или сервиса." + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "Чтобы начать работу, вам нужно создать кошелёк и получить биткойн." + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "Купить биткойны сейчас" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "Показать мой адрес" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "Отправить макс. сумму" @@ -3636,3 +3710,51 @@ msgstr "{{updatingTxHistoryProgress}} транзакций загружено" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.m}}-из-{{wallet.n}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "Сообщество" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "Bitcoin Cash Reddit" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "Bitcoin.com Twitter" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "Обзор Bitcoin.com" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "Игры Bitcoin Cash" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "Новости" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "Пул для майнинга" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "Инструменты" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "Динамика курса биткойна" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "Bitcoin Cash бесплатно" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "Ваши кошельки готовы!" + diff --git a/i18n/po/sv-SE/template-sv-SE.po b/i18n/po/sv-SE/template-sv-SE.po index bc496d6d5..7ffdda946 100644 --- a/i18n/po/sv-SE/template-sv-SE.po +++ b/i18n/po/sv-SE/template-sv-SE.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Swedish\n" "Language: sv\n" -"PO-Revision-Date: 2018-07-04 03:58\n" +"PO-Revision-Date: 2018-07-27 08:44\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "" @@ -619,10 +620,14 @@ msgstr "" msgid "Connection reset by peer" msgstr "" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "" @@ -823,7 +828,7 @@ msgstr "" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "" @@ -2533,6 +2538,14 @@ msgstr "" msgid "Search or enter bitcoin address" msgstr "" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "" @@ -2591,9 +2604,70 @@ msgid "Send by email" msgstr "" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "" + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "" + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "" + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "" @@ -3636,3 +3710,51 @@ msgstr "" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "" + diff --git a/i18n/po/vi/template-vi.po b/i18n/po/vi/template-vi.po index d965b6ee8..ef9db2029 100644 --- a/i18n/po/vi/template-vi.po +++ b/i18n/po/vi/template-vi.po @@ -11,11 +11,11 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Vietnamese\n" "Language: vi\n" -"PO-Revision-Date: 2018-07-04 03:58\n" +"PO-Revision-Date: 2018-07-27 08:44\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" -msgstr "(Đáng tin cậy)" +msgstr "(Tin cậy)" #: www/views/includes/txp.html:23 #: www/views/includes/walletHistory.html:64 @@ -28,7 +28,7 @@ msgstr "* A payment proposal can be deleted if 1) you are the creator, and no ot #: www/views/tx-details.html:82 msgid "- {{btx.feeRateStr}} of the transaction" -msgstr "{{btx.feeRateStr}} của giao dịch" +msgstr "- {{btx.feeRateStr}} of the transaction" #: www/views/modals/txp-details.html:102 msgid "- {{tx.feeRateStr}} of the transaction" @@ -41,7 +41,9 @@ msgstr "Xếp hạng 5 sao giúp chúng tôi để {{appName}} đến tay nhiề #: www/views/mercadoLibre.html:18 #: www/views/mercadoLibre.html:40 msgid "Only redeemable on Mercado Livre (Brazil)" -msgstr "Only redeemable on Mercado Livre (Brazil)" +msgstr "Only redeemable on \n" +"Mercado Livre (Brazil) #\n\n" +"2" #: src/js/controllers/feedback/send.js:27 #: www/views/feedback/complete.html:21 @@ -54,7 +56,8 @@ msgstr "A total of {{amountAboveMaxSizeStr}} were excluded. The maximum size all #: src/js/controllers/confirm.js:395 msgid "A total of {{amountBelowFeeStr}} were excluded. These funds come from UTXOs smaller than the network fee provided." -msgstr "A total of {{amountBelowFeeStr}} were excluded. These funds come from UTXOs smaller than the network fee provided." +msgstr "Tổng cộng {{amountBelowFeeStr}} đã bị loại trừ. Số tiền này đến từ UTXOs nhỏ hơn chi phí mạng cung cấp.#\n" +"1" #: src/js/controllers/preferencesAbout.js:6 #: www/views/tab-settings.html:156 @@ -79,7 +82,7 @@ msgstr "Account Number" #: www/views/tab-home.html:61 msgid "Instant transactions with low fees" -msgstr "" +msgstr "2" #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" @@ -124,338 +127,339 @@ msgstr "Add account" #: www/views/tab-create-personal.html:62 #: www/views/tab-create-shared.html:91 msgid "Add an optional password to secure the recovery phrase" -msgstr "" +msgstr "Add a password option to allow a secure cluster" #: www/views/includes/incomingDataMenu.html:41 msgid "Add as a contact" -msgstr "" +msgstr "Thêm như một liên hệ" #: src/js/controllers/confirm.js:424 msgid "Add description" -msgstr "" +msgstr "Thêm mô tả" #: www/views/topup.html:6 msgid "Add funds" -msgstr "" +msgstr "Nạp tiền" #: src/js/services/bitpayAccountService.js:78 msgid "Add this BitPay account ({{email}})?" -msgstr "" +msgstr "Thêm BitPay ({{email}}) tài khoản này?" #: www/views/add.html:3 msgid "Add wallet" -msgstr "" +msgstr "Thêm ví" #: www/views/addressbook.view.html:26 #: www/views/customAmount.html:28 #: www/views/modals/paypro.html:24 msgid "Address" -msgstr "" +msgstr "Địa chỉ" #: www/views/addressbook.html:6 #: www/views/tab-settings.html:13 msgid "Address Book" -msgstr "" +msgstr "Sổ địa chỉ" #: www/views/preferencesInformation.html:41 msgid "Address Type" -msgstr "" +msgstr "Loại địa chỉ" #: www/views/addresses.html:64 msgid "Addresses With Balance" -msgstr "" +msgstr "Địa chỉ với số dư" #: www/views/tab-settings.html:149 msgid "Advanced" -msgstr "" +msgstr "Nâng cao" #: www/views/advancedSettings.html:3 msgid "Advanced Settings" -msgstr "" +msgstr "Cài đặt nâng cao" #: www/views/bitpayCard.html:62 msgid "All" -msgstr "" +msgstr "Tất cả" #: www/views/allAddresses.html:3 msgid "All Addresses" -msgstr "" +msgstr "Tất cả địa chỉ" #: www/views/modals/wallet-balance.html:18 msgid "All of your bitcoin wallet balance may not be available for immediate spending." -msgstr "" +msgstr "Tất cả số dư ví bitcoin của bạn có thể không có sẵn cho chi tiêu ngay lập tức." #: www/views/tab-receive.html:25 msgid "All signing devices must be added to this multisig wallet before bitcoin addresses can be created." -msgstr "" +msgstr "All contract device will be added to this multisig before the bitcoin address has been created." #: www/views/tab-scan.html:21 msgid "Allow Camera Access" -msgstr "" +msgstr "Allow camera access" #: www/views/onboarding/notifications.html:7 msgid "Allow notifications" -msgstr "" +msgstr "Allow notification" #: www/views/onboarding/disclaimer.html:14 msgid "Almost done! Let's review." -msgstr "" +msgstr "Most as completed! We see review." #: www/views/preferencesAltCurrency.html:4 #: www/views/tab-settings.html:79 msgid "Alternative Currency" -msgstr "" +msgstr "Money Currency instead" #: src/js/controllers/buyAmazon.js:98 msgid "Amazon.com is not available at this moment. Please try back later." -msgstr "" +msgstr "Amazon.com is not available at this time. Please try again again." #: www/views/amount.html:44 #: www/views/customAmount.html:34 #: www/views/includes/output.html:7 msgid "Amount" -msgstr "" +msgstr "Quantity" #: src/js/services/bwcError.js:110 msgid "Amount below minimum allowed" -msgstr "" +msgstr "Maximum amount of the minimum amount" #: src/js/controllers/confirm.js:216 msgid "Amount too big" -msgstr "" +msgstr "Amount too large" #: www/views/includes/walletHistory.html:31 msgid "Amount too low to spend" -msgstr "" +msgstr "Amount too low for standard" #: src/js/controllers/tab-home.js:147 msgid "An update to this app is available. For your security, please update to the latest version." -msgstr "" +msgstr "Hotel have a Update for this application. To preserve your password, please please update the latest version." #: www/views/backupWarning.html:14 msgid "Anyone with your backup phrase can access or spend your bitcoin." -msgstr "" +msgstr "Każdy, kto ma Twoją kluczową là một trong những điều tuyệt vời nhất." #: www/views/addresses.html:94 msgid "Approximate Bitcoin network fee to transfer wallet's balance (with normal priority)" -msgstr "" +msgstr "La taxa approssimativa della rete Bitcoin cho mỗi lần gửi tiền theo yêu cầu của bạn" #: www/views/backupWarning.html:10 msgid "Are you being watched?" -msgstr "" +msgstr "Chúng tôi vigilen?" #: src/js/controllers/preferencesExternal.js:15 msgid "Are you being watched? Anyone with your recovery phrase can access or spend your bitcoin." -msgstr "" +msgstr "You are tracking? Bất cứ ai có thể phục hồi từ bạn, bạn có thể truy cập hoặc bitcoin chi tiêu của bạn." #: src/js/controllers/copayers.js:56 msgid "Are you sure you want to cancel and delete this wallet?" -msgstr "" +msgstr "Are you sure you want to cancel and remove this video?" #: src/js/controllers/addressbookView.js:37 msgid "Are you sure you want to delete this contact?" -msgstr "" +msgstr "Bạn có chắc chắn muốn xóa địa chỉ liên hệ này không?" #: src/js/controllers/preferencesDelete.js:25 msgid "Are you sure you want to delete this wallet?" -msgstr "" +msgstr "Are you sure you want to delete this wallet?" #: src/js/controllers/modals/txpDetails.js:154 msgid "Are you sure you want to reject this transaction?" -msgstr "" +msgstr "Are you sure you want to reject this transaction?" #: src/js/controllers/modals/txpDetails.js:171 msgid "Are you sure you want to remove this transaction?" -msgstr "" +msgstr "Are you sure you want to remove this transaction?" #: src/js/controllers/onboarding/backupRequest.js:23 msgid "Are you sure you want to skip it?" -msgstr "" +msgstr "Are you sure you want to skip it?" #: www/views/modals/bitpay-card-confirmation.html:4 msgid "Are you sure you would like to log out of your BitPay Card account?" -msgstr "" +msgstr "Bạn có chắc chắn muốn đăng xuất khỏi tài khoản Thẻ BitPay của mình không?" #: src/js/controllers/preferencesBitpayCard.js:7 #: src/js/controllers/preferencesBitpayServices.js:20 msgid "Are you sure you would like to remove your BitPay Card ({{lastFourDigits}}) from this device?" -msgstr "" +msgstr "Are you sure you would like to remove your BitPay Card ({{lastFourDigits}}) from this device?" #: www/views/includes/walletInfo.html:10 msgid "Auditable" -msgstr "" +msgstr "Auditable" #: www/views/modals/wallet-balance.html:42 msgid "Available" -msgstr "" +msgstr "Available" #: www/views/includes/available-balance.html:3 msgid "Available Balance" -msgstr "" +msgstr "Available Balance" #: www/views/modals/chooseFeeLevel.html:24 #: www/views/preferencesFee.html:15 msgid "Average confirmation time" -msgstr "" +msgstr "Average confirmation time" #: www/views/join.html:143 #: www/views/tab-create-personal.html:113 #: www/views/tab-create-shared.html:142 #: www/views/tab-import-phrase.html:51 msgid "BIP32 path for address derivation" -msgstr "" +msgstr "Đường dẫn BIP32 cho dẫn xuất địa chỉ" #: www/views/cashScan.html:25 msgid "BTC wallets" -msgstr "" +msgstr "Ví BTC" #: www/views/preferences.html:34 msgid "Backup" -msgstr "" +msgstr "Backup" #: www/views/includes/backupNeededPopup.html:7 msgid "Backup Needed" -msgstr "" +msgstr "Backup Needed" #: src/js/controllers/lockSetup.js:87 msgid "Backup all livenet wallets before using this function" -msgstr "" +msgstr "Backup all livenet wallets before using this function" #: src/js/controllers/cashScan.js:64 #: www/views/includes/walletListSettings.html:12 #: www/views/preferences.html:36 msgid "Backup needed" -msgstr "" +msgstr "Cần sao lưu" #: www/views/includes/backupNeededPopup.html:9 msgid "Backup now" -msgstr "" +msgstr "Sao lưu ngay" #: www/views/onboarding/backupRequest.html:11 #: www/views/tab-export-file.html:89 msgid "Backup wallet" -msgstr "" +msgstr "Backup wallet" #: src/js/controllers/lockSetup.js:84 msgid "Backup your wallet before using this function" -msgstr "" +msgstr "Backup your wallet before using this function" #: src/js/services/profileService.js:446 msgid "Bad wallet invitation" -msgstr "" +msgstr "Bad wallet invitation" #: www/views/preferencesInformation.html:102 msgid "Balance By Address" -msgstr "" +msgstr "Balance By Address" #: www/views/includes/confirmBackupPopup.html:7 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 "" +msgstr "Hãy chắc chắn lưu trữ cụm từ khôi phục của bạn ở một nơi an toàn. Nếu ứng dụng này bị xóa, tiền của bạn không thể được phục hồi mà không có nó." #: www/views/preferencesBitpayServices.html:9 msgid "BitPay Visa® Cards" -msgstr "" +msgstr "BitPay Visa & reg; thẻ" #: www/views/addressbook.add.html:38 #: www/views/includes/incomingDataMenu.html:29 msgid "Bitcoin Address" -msgstr "" +msgstr "Bitcoin Address" #: www/views/cashScan.html:4 msgid "Bitcoin Cash (BCH) Balances" -msgstr "" +msgstr "Bitcoin Cash (BCH) Balances" #: www/views/preferencesCash.html:3 #: www/views/tab-settings.html:47 msgid "Bitcoin Cash Support" -msgstr "" +msgstr "Bitcoin Cash Support" #: www/views/tab-home.html:98 #: www/views/tab-settings.html:115 msgid "Bitcoin Cash Wallets" -msgstr "" +msgstr "Bitcoin Cash Wallets" #: www/views/modals/chooseFeeLevel.html:4 #: www/views/preferencesFee.html:4 #: www/views/tab-settings.html:90 msgid "Bitcoin Network Fee Policy" -msgstr "" +msgstr "Bitcoin Network Fee Policy" #: www/views/tab-home.html:83 #: www/views/tab-settings.html:107 msgid "Bitcoin Core Wallets" -msgstr "" +msgstr "Bitcoin Core Wallets" #: src/js/services/incomingData.js:151 msgid "Bitcoin cash Payment" -msgstr "" +msgstr "Bitcoin cash Payment" #: www/views/onboarding/tour.html:31 msgid "Bitcoin is a currency." -msgstr "" +msgstr "Bitcoin is a currency." #: www/views/onboarding/disclaimer.html:15 msgid "Bitcoin is different – it cannot be safely held with a bank or web service." -msgstr "" +msgstr "–." #: www/views/onboarding/tour.html:18 msgid "Bitcoin is secure,
digital money." -msgstr "" +msgstr "Bitcoin là an toàn,
tiền kỹ thuật số." #: www/views/preferencesFee.html:11 msgid "Bitcoin transactions include a fee collected by miners on the network." -msgstr "" +msgstr "Bitcoin transactions include a fee collected by miners on the network." #: www/views/buyAmazon.html:108 msgid "Bought {{amountUnitStr}}" -msgstr "" +msgstr "Bought {{amountUnitStr}}" #: www/views/modals/txp-details.html:36 msgid "Broadcast Payment" -msgstr "" +msgstr "Broadcast Payment" #: src/js/controllers/modals/txpDetails.js:64 #: src/js/controllers/tx-details.js:81 msgid "Broadcasted" -msgstr "" +msgstr "Broadcasted" #: src/js/services/onGoingProcess.js:11 msgid "Broadcasting transaction" -msgstr "" +msgstr "Broadcasting transaction" #: www/views/unsupported.html:6 msgid "Browser unsupported" -msgstr "" +msgstr "Browser unsupported" #: www/views/buyAmazon.html:5 #: www/views/buyMercadoLibre.html:6 msgid "Buy" -msgstr "" +msgstr "Buy" #: www/views/includes/buyAndSellCard.html:3 msgid "Buy & Sell Bitcoin" -msgstr "" +msgstr "Buy & Sell Bitcoin" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" -msgstr "" +msgstr "Buy Bitcoin" #: www/views/mercadoLibre.html:22 #: www/views/mercadoLibre.html:50 msgid "Buy a Gift Card" -msgstr "" +msgstr "Buy a Gift Card" #: src/js/controllers/buyAmazon.js:334 msgid "Buy from" -msgstr "" +msgstr "Buy from" #: src/js/services/onGoingProcess.js:40 msgid "Buying Bitcoin..." -msgstr "" +msgstr "Mua Bitcoin..." #: src/js/services/onGoingProcess.js:12 msgid "Calculating fee" -msgstr "" +msgstr "Phí tính toán" #: src/js/controllers/buyAmazon.js:313 #: src/js/controllers/buyMercadoLibre.js:307 @@ -474,65 +478,65 @@ msgstr "" #: www/views/modals/bitpay-card-confirmation.html:8 #: www/views/modals/confirmation.html:13 msgid "Cancel" -msgstr "" +msgstr "Hủy bỏ" #: www/views/copayers.html:36 msgid "Cancel invitation" -msgstr "" +msgstr "Hủy lời mời" #: src/js/controllers/onboarding/tour.js:52 msgid "Cannot Create Wallet" -msgstr "" +msgstr "Không thể tạo Wallet" #: src/js/services/profileService.js:442 msgid "Cannot join the same wallet more that once" -msgstr "" +msgstr "Cannot join the same wallet more that once" #: www/views/includes/bitpayCardsCard.html:2 msgid "Cards" -msgstr "" +msgstr "Cards" #: www/views/modals/paypro.html:30 msgid "Certified by" -msgstr "" +msgstr "Certified by" #: www/views/preferencesExternal.html:19 msgid "Check installation and retry." -msgstr "" +msgstr "Check installation and retry." #: www/views/tab-import-file.html:4 msgid "Choose a backup file from your computer" -msgstr "" +msgstr "Chọn tệp sao lưu từ máy tính của bạn" #: www/views/modals/wallets.html:9 msgid "Choose your destination wallet" -msgstr "" +msgstr "Choose your destination wallet" #: www/views/modals/wallets.html:10 msgid "Choose your source wallet" -msgstr "" +msgstr "Chọn ví nguồn của bạn" #: www/views/backup.html:61 msgid "Clear" -msgstr "" +msgstr "Clear" #: www/views/preferencesHistory.html:24 msgid "Clear cache" -msgstr "" +msgstr "Clear cache" #: src/js/controllers/confirm.js:373 #: src/js/controllers/modals/txpDetails.js:49 msgid "Click to accept" -msgstr "" +msgstr "Click to accept" #: src/js/controllers/confirm.js:367 msgid "Click to pay" -msgstr "" +msgstr "Click to pay" #: src/js/controllers/confirm.js:379 #: src/js/controllers/modals/txpDetails.js:42 msgid "Click to send" -msgstr "" +msgstr "Click to send" #: www/views/customAmount.html:4 #: www/views/modals/mercadolibre-card-details.html:3 @@ -542,28 +546,28 @@ msgstr "" #: www/views/modals/wallet-balance.html:3 #: www/views/modals/wallets.html:5 msgid "Close" -msgstr "" +msgstr "Close" #: www/views/includes/cash.html:2 #: www/views/preferencesInformation.html:17 msgid "Coin" -msgstr "" +msgstr "Coin" #: www/views/preferences.html:22 msgid "Color" -msgstr "" +msgstr "Màu" #: www/views/preferencesAbout.html:21 msgid "Commit hash" -msgstr "" +msgstr "Commit hash" #: www/views/preferences.html:49 msgid "Complete the backup process to use this option" -msgstr "" +msgstr "Complete the backup process to use this option" #: www/views/bitpayCard.html:93 msgid "Completed" -msgstr "" +msgstr "Completed" #: src/js/controllers/buyAmazon.js:311 #: src/js/controllers/buyMercadoLibre.js:305 @@ -575,95 +579,99 @@ msgstr "" #: www/views/confirm.html:4 #: www/views/onboarding/collectEmail.html:32 msgid "Confirm" -msgstr "" +msgstr "Confirm" #: www/views/modals/terms.html:26 #: www/views/onboarding/disclaimer.html:44 msgid "Confirm & Finish" -msgstr "" +msgstr "Confirm & Finish" #: www/views/buyAmazon.html:90 msgid "Confirm purchase" -msgstr "" +msgstr "Confirm purchase" #: www/views/modals/pin.html:10 msgid "Confirm your PIN" -msgstr "" +msgstr "Confirm your PIN" #: src/js/services/walletService.js:1033 msgid "Confirm your new spending password" -msgstr "" +msgstr "Confirm your new spending password" #: www/views/tx-details.html:98 msgid "Confirmations" -msgstr "" +msgstr "Confirmations" #: www/views/bitpayCard.html:68 #: www/views/modals/wallet-balance.html:61 msgid "Confirming" -msgstr "" +msgstr "Xác nhận" #: www/views/bitpayCardIntro.html:37 msgid "Connect my BitPay Card" -msgstr "" +msgstr "Kết nối thẻ BitPay của tôi" #: src/js/services/onGoingProcess.js:13 msgid "Connecting to Coinbase..." -msgstr "" +msgstr "Connecting to Coinbase..." #: src/js/services/onGoingProcess.js:14 msgid "Connecting to Glidera..." -msgstr "" +msgstr "Đang kết nối với Glidera ..." #: src/js/services/bwcError.js:53 msgid "Connection reset by peer" -msgstr "" +msgstr "Đặt lại kết nối theo ngang hàng" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" -msgstr "" +msgstr "Contacts" + +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "Save the regular usage" #: www/views/onboarding/notifications.html:9 msgid "Continue" -msgstr "" +msgstr "Continue" #: www/views/preferencesLanguage.html:26 msgid "Contribute Translations" -msgstr "" +msgstr "Contribute Translations" #: src/js/controllers/confirm.js:130 msgid "Copay only supports Bitcoin Cash using new version numbers addresses" -msgstr "" +msgstr "Copay chỉ hỗ trợ Bitcoin Cash bằng cách sử dụng số phiên bản mới" #: src/js/services/bwcError.js:62 msgid "Copayer already in this wallet" -msgstr "" +msgstr "Copayer already in this wallet" #: src/js/services/bwcError.js:77 msgid "Copayer already voted on this spend proposal" -msgstr "" +msgstr "Coper is this option" #: src/js/services/bwcError.js:107 msgid "Copayer data mismatch" -msgstr "" +msgstr "Dữ liệu Copayer không khớp" #: www/views/includes/walletActivity.html:2 msgid "Copayer joined" -msgstr "" +msgstr "Copayer joined" #: www/views/preferencesInformation.html:94 msgid "Copayer {{$index}}" -msgstr "" +msgstr "Copayer {{$index}}" #: src/js/controllers/copayers.js:79 #: src/js/controllers/export.js:193 #: www/views/includes/copyToClipboard.html:4 msgid "Copied to clipboard" -msgstr "" +msgstr "Sao chép vào clipboard" #: www/views/tab-export-file.html:94 msgid "Copy this text as it is to a safe place (notepad or email)" -msgstr "" +msgstr "Copy this text as it is to a safe place (notepad or email)" #: www/views/includes/incomingDataMenu.html:51 #: www/views/includes/incomingDataMenu.html:70 @@ -671,35 +679,35 @@ msgstr "" #: www/views/includes/logOptions.html:9 #: www/views/tab-export-file.html:78 msgid "Copy to clipboard" -msgstr "" +msgstr "Sao chép vào clipboard" #: src/js/controllers/buyMercadoLibre.js:102 msgid "Could not access Gift Card Service" -msgstr "" +msgstr "Could not access Gift Card Service" #: www/views/tab-import-phrase.html:2 msgid "Could not access the wallet at the server. Please check:" -msgstr "" +msgstr "Could not access the wallet at the server. Please check:" #: src/js/controllers/buyAmazon.js:102 msgid "Could not access to Amazon.com" -msgstr "" +msgstr "Could not access to Amazon.com" #: src/js/services/profileService.js:511 msgid "Could not access wallet" -msgstr "" +msgstr "Could not access wallet" #: src/js/controllers/confirm.js:210 msgid "Could not add message to imported wallet without shared encrypting key" -msgstr "" +msgstr "Could not add message to imported wallet without shared encrypting key" #: src/js/controllers/modals/txpDetails.js:199 msgid "Could not broadcast payment" -msgstr "" +msgstr "Could not broadcast payment" #: src/js/services/bwcError.js:41 msgid "Could not build transaction" -msgstr "" +msgstr "Cannot build transaction" #: src/js/services/walletService.js:854 msgid "Could not create address" @@ -823,7 +831,7 @@ msgstr "" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "" @@ -916,7 +924,7 @@ msgstr "" #: www/views/modals/mercadolibre-card-details.html:6 #: www/views/topup.html:45 msgid "Details" -msgstr "" +msgstr "Chi tiết" #: src/js/controllers/lockSetup.js:9 #: src/js/controllers/tab-settings.js:65 @@ -2533,6 +2541,14 @@ msgstr "" msgid "Search or enter bitcoin address" msgstr "" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "" @@ -2591,9 +2607,70 @@ msgid "Send by email" msgstr "" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "" + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "" + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "" + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "" @@ -3636,3 +3713,51 @@ msgstr "" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "" + diff --git a/i18n/po/zh-CN/template-zh-CN.po b/i18n/po/zh-CN/template-zh-CN.po index 8c274b798..eb8304e89 100644 --- a/i18n/po/zh-CN/template-zh-CN.po +++ b/i18n/po/zh-CN/template-zh-CN.po @@ -11,7 +11,7 @@ msgstr "" "Last-Translator: emilold\n" "Language-Team: Chinese Simplified\n" "Language: zh\n" -"PO-Revision-Date: 2018-07-04 03:57\n" +"PO-Revision-Date: 2018-07-27 08:43\n" #: www/views/modals/paypro.html:34 msgid "(Trusted)" @@ -79,7 +79,7 @@ msgstr "帐号" #: www/views/tab-home.html:61 msgid "Instant transactions with low fees" -msgstr "" +msgstr "以较低费用进行即时交易" #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" @@ -363,12 +363,12 @@ msgstr "比特币地址" #: www/views/cashScan.html:4 msgid "Bitcoin Cash (BCH) Balances" -msgstr "" +msgstr "Bitcoin Cash (BCH) 余额" #: www/views/preferencesCash.html:3 #: www/views/tab-settings.html:47 msgid "Bitcoin Cash Support" -msgstr "" +msgstr "Bitcoin Cash 支持" #: www/views/tab-home.html:98 #: www/views/tab-settings.html:115 @@ -384,7 +384,7 @@ msgstr "比特币网络手续费策略" #: www/views/tab-home.html:83 #: www/views/tab-settings.html:107 msgid "Bitcoin Core Wallets" -msgstr "" +msgstr "Bitcoin Core 钱包" #: src/js/services/incomingData.js:151 msgid "Bitcoin cash Payment" @@ -437,6 +437,7 @@ msgid "Buy & Sell Bitcoin" msgstr "购买或出售比特币" #: www/views/tab-send.html:35 +#: src/js/services/buyAndSellService.js:26 msgid "Buy Bitcoin" msgstr "购买比特币" @@ -619,10 +620,14 @@ msgstr "正在连接 Glidera..." msgid "Connection reset by peer" msgstr "连接被对方重置" -#: www/views/tab-send.html:45 +#: www/views/tab-send.html:85 msgid "Contacts" msgstr "联系人" +#: www/views/tab-send.html:86 +msgid "Saved frequently used addresses" +msgstr "保存的常用地址" + #: www/views/onboarding/notifications.html:9 msgid "Continue" msgstr "继续" @@ -653,7 +658,7 @@ msgstr "Copayer 加入" #: www/views/preferencesInformation.html:94 msgid "Copayer {{$index}}" -msgstr "" +msgstr "Copayer {{$index}}" #: src/js/controllers/copayers.js:79 #: src/js/controllers/export.js:193 @@ -823,7 +828,7 @@ msgstr "创建自己的免费钱包" #: www/views/onboarding/tour.html:51 #: www/views/tab-home.html:75 -#: www/views/tab-send.html:36 +#: www/views/tab-send.html:75 msgid "Create bitcoin wallet" msgstr "创建比特币的钱包" @@ -977,7 +982,7 @@ msgstr "已达到空地址限制。无法生成新的地址。" #: www/views/preferencesCash.html:17 msgid "Enable Bitcoin Cash wallet creation and operation within the App." -msgstr "" +msgstr "在应用内启用 Bitcoin Cash 创建和操作。" #: www/views/tab-scan.html:19 msgid "Enable camera access in your device settings to get started." @@ -993,7 +998,7 @@ msgstr "启用推式通知" #: www/views/preferencesNotifications.html:33 msgid "Enable sound" -msgstr "" +msgstr "启用声音" #: www/views/tab-scan.html:18 msgid "Enable the camera to get started." @@ -1001,7 +1006,7 @@ msgstr "使该摄像机开始。" #: www/views/tab-settings.html:49 msgid "Enabled" -msgstr "" +msgstr "已启用" #: src/js/services/walletService.js:1047 #: src/js/services/walletService.js:1062 @@ -1586,7 +1591,7 @@ msgstr "网络地址不正确" #: src/js/controllers/confirm.js:306 #: src/js/services/bwcError.js:44 msgid "Insufficient confirmed funds" -msgstr "" +msgstr "确认的资金不足" #: src/js/controllers/topup.js:165 #: src/js/controllers/topup.js:177 @@ -2011,7 +2016,7 @@ msgstr "好的" #: www/views/modals/tx-status.html:36 #: www/views/modals/tx-status.html:46 msgid "OKAY" -msgstr "" +msgstr "确定" #: www/views/modals/terms.html:15 msgid "Official English Disclaimer" @@ -2053,7 +2058,7 @@ msgstr "打开 GitHub 项目" #: src/js/controllers/bitpayCard.js:123 #: src/js/controllers/tx-details.js:192 msgid "Open Explorer" -msgstr "" +msgstr "打开浏览器" #: www/views/tab-scan.html:22 msgid "Open Settings" @@ -2069,7 +2074,7 @@ msgstr "打开网站" #: src/js/controllers/preferencesCash.js:32 msgid "Open bitcoincash.org?" -msgstr "" +msgstr "打开 bitcoincash.org?" #: src/js/controllers/cashScan.js:18 msgid "Open the recovery tool." @@ -2511,7 +2516,7 @@ msgstr "请扫描你的指纹" #: www/views/preferencesCash.html:23 msgid "Scan your wallets for Bitcoin Cash" -msgstr "" +msgstr "扫描您的 Bitcoin Cash 钱包" #: src/js/services/onGoingProcess.js:30 msgid "Scanning Wallet funds..." @@ -2533,6 +2538,14 @@ msgstr "搜索交易" msgid "Search or enter bitcoin address" msgstr "搜索或输入比特币地址" +#: src/js/controllers/tab-send.js:28 +msgid "Clipboard" +msgstr "剪贴板" + +#: src/js/controllers/tab-send.js:29 +msgid "Your Clipboard is empty" +msgstr "您的剪贴板为空" + #: www/views/modals/search.html:16 msgid "Search transactions" msgstr "搜索交易" @@ -2591,9 +2604,70 @@ msgid "Send by email" msgstr "通过电邮发送" #: src/js/controllers/confirm.js:177 +#: src/js/controllers/tab-send.js:94 msgid "Send from" msgstr "从发送" +#: src/js/controllers/tab-send.js:77 +msgid "Send to" +msgstr "发送到" + +#: www/views/tab-send.html:20 +msgid "Paste Clipboard" +msgstr "粘贴剪贴板" + +#: www/views/tab-send.html:21 +msgid "Paste Address" +msgstr "粘贴地址" + +#: www/views/tab-send.html:27 +msgid "Wallet to Wallet Transfer" +msgstr "钱包转账" + +#: www/views/tab-send.html:35 +msgid "Scan QR Code" +msgstr "扫描二维码" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "更快地发送比特币!" + +#: www/views/tab-send.html:46 +msgid "Send Bitcoin faster!" +msgstr "更快地发送比特币!" + +#: www/views/tab-send.html:50 +msgid "Save frequently used addresses and send them Bitcoin in just one tap" +msgstr "保存常用地址,只需点击一下即可将比特币发送到这些地址" + +#: www/views/tab-send.html:55 +msgid "Add your first contact" +msgstr "添加您的第一个联系人" + +#: www/views/tab-send.html:65 +msgid "Your Bitcoin wallet is empty" +msgstr "您的比特币钱包为空" + +#: www/views/tab-send.html:69 +msgid "To get started, buy Bitcoin Cash (BCH) or Bitcoin Core (BTC), or share your address." +msgstr "首先,购买 Bitcoin Cash (BCH) 或 Bitcoin Core (BTC),或者共享您的地址。" + +#: www/views/tab-send.html:70 +msgid "You can receive bitcoin from any wallet or service." +msgstr "您可以从任何钱包或服务接收比特币。" + +#: www/views/tab-send.html:72 +msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." +msgstr "若要开始,您将需要创建一个比特币的钱包,并获得一些比特币。" + +#: www/views/tab-send.html:74 +msgid "Buy Bitcoin now" +msgstr "立即购买比特币" + +#: www/views/tab-send.html:76 +msgid "Show my address" +msgstr "显示我的地址" + #: www/views/includes/itemSelector.html:8 msgid "Send max amount" msgstr "发送最大数量" @@ -2810,7 +2884,7 @@ msgstr "超级经济" #: www/views/preferencesCash.html:11 msgid "Support Bitcoin Cash" -msgstr "" +msgstr "支持 Bitcoin Cash" #: www/views/paperWallet.html:7 msgid "Sweep" @@ -2860,7 +2934,7 @@ msgstr "使用条款" #: www/views/tab-create-personal.html:118 #: www/views/tab-import-phrase.html:68 msgid "Testnet" -msgstr "" +msgstr "测试网" #: www/views/includes/incomingDataMenu.html:61 msgid "Text" @@ -3030,7 +3104,7 @@ msgstr "若要开始,请买比特币或共享您的地址。你可以从任何 #: www/views/tab-send.html:33 msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." -msgstr "若要开始,您将需要创建一个比特币的钱包,并获得一些比特币。" +msgstr "首先,您需要创建一个比特币钱包,并获得一些比特币。" #: src/js/services/bitpayAccountService.js:73 msgid "To {{reason}} you must first add your BitPay account - {{email}}" @@ -3200,7 +3274,7 @@ msgstr "查看服务条款" #: src/js/controllers/bitpayCard.js:122 #: src/js/controllers/tx-details.js:191 msgid "View Transaction on Explorer.Bitcoin.com" -msgstr "" +msgstr "在 Explorer.Bitcoin.com 上查看交易" #: src/js/controllers/tab-home.js:148 msgid "View Update" @@ -3596,7 +3670,7 @@ msgstr "我" #: www/views/addressbook.add.html:32 msgid "name@example.com" -msgstr "" +msgstr "name@example.com" #: www/views/preferencesHistory.html:15 msgid "preparing..." @@ -3636,3 +3710,51 @@ msgstr "下载的 {{updatingTxHistoryProgress}} 交易" msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "{{wallet.m}}{{wallet.n}}" +#: src/js/services/shapeshiftService.js:8 +msgid "Shapeshift" +msgstr "Shapeshift" + +#: www/views/includes/community.html:3 +msgid "Community" +msgstr "社区" + +#: src/js/services/communityService.js:40 +msgid "Bitcoin Cash Reddit" +msgstr "Bitcoin Cash Reddit" + +#: src/js/services/communityService.js:47 +msgid "Bitcoin.com Twitter" +msgstr "Bitcoin.com Twitter" + +#: www/views/includes/nextSteps.html:3 +msgid "Explore Bitcoin.com" +msgstr "探索 Bitcoin.com" + +#: src/js/services/bitcoincomService.js:21 +msgid "Bitcoin Cash Games" +msgstr "Bitcoin Cash 游戏" + +#: src/js/services/bitcoincomService.js:28 +msgid "News" +msgstr "新闻" + +#: src/js/services/bitcoincomService.js:35 +msgid "Mining Pool" +msgstr "矿池" + +#: src/js/services/bitcoincomService.js:42 +msgid "Tools" +msgstr "工具" + +#: src/js/services/bitcoincomService.js:49 +msgid "Bitcoin Price Charts" +msgstr "比特币价格图表" + +#: src/js/services/bitcoincomService.js:56 +msgid "Free Bitcoin Cash" +msgstr "免费的 Bitcoin Cash" + +#: www/views/tab-home.html:30 +msgid "Your Bitcoin Wallets are ready!" +msgstr "您的比特币钱包已就绪!" + diff --git a/www/index.html b/www/index.html index 4c73317e3..ecc2d923c 100644 --- a/www/index.html +++ b/www/index.html @@ -11,9 +11,8 @@ - Bitcoin.com Wallet - Bitcoin.com Wallet - - + Bitcoin.com Wallet + @@ -31,7 +30,7 @@ - + From d122048a7b7d25a3934ef5557a778bfcff46317e Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 27 Jul 2018 17:46:19 +0900 Subject: [PATCH 162/386] Increment version --- app-template/bitcoincom/appConfig.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app-template/bitcoincom/appConfig.json b/app-template/bitcoincom/appConfig.json index fefcb9a4f..238f38002 100644 --- a/app-template/bitcoincom/appConfig.json +++ b/app-template/bitcoincom/appConfig.json @@ -24,9 +24,9 @@ "windowsAppId": "804636ee-b017-4cad-8719-e58ac97ffa5c", "pushSenderId": "1036948132229", "description": "A Secure Bitcoin Wallet", - "version": "4.13.0", - "fullVersion": "4.13-rc1", - "androidVersion": "413000", + "version": "4.13.1", + "fullVersion": "4.13-rc2", + "androidVersion": "413100", "_extraCSS": "", "_enabledExtensions": { "coinbase": false, From 47de79cc64ec2ce6856960938a7b854a0679a0ab Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Fri, 27 Jul 2018 17:03:09 +0800 Subject: [PATCH 163/386] Adds support for 0, 2, 3 and 8 decimal places and locale commas and decimals --- src/js/directives/amount.js | 89 ++++++++++++++++++++++++++------- src/sass/components/amount.scss | 3 ++ www/css/main.css | 9 ++-- www/views/includes/amount.html | 5 +- www/views/review.html | 4 +- 5 files changed, 84 insertions(+), 26 deletions(-) diff --git a/src/js/directives/amount.js b/src/js/directives/amount.js index e86bec2fe..ff61288b3 100644 --- a/src/js/directives/amount.js +++ b/src/js/directives/amount.js @@ -1,21 +1,76 @@ 'use strict'; + +/** + * @desc amount directive that can be used to display formatted financial values + * @example + */ angular.module('bitcoincom.directives') - .directive('amount', [ - '$timeout', - function($timeout) { - return { - restrict: 'E', - scope: { - value: '=', - currency: '=' - }, - templateUrl: 'views/includes/amount.html', - controller: ['$scope', function($scope) { - var valueFormatted = parseFloat($scope.value).toFixed(8); - $scope.start = valueFormatted.slice(0, -5); - $scope.middle = valueFormatted.slice(-5, -2); - $scope.end = valueFormatted.substr(valueFormatted.length - 2); - }] + .directive('amount', [ + '$timeout', + function($timeout) { + return { + restrict: 'E', + scope: { + value: '@', + currency: '@' + }, + templateUrl: 'views/includes/amount.html', + controller: ['$scope', function($scope) { + var decimalPlaces = { + '0': ['BIF', 'CLP', 'DJF', 'GNF', 'ILS', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'UGX', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'], + '3': ['BHD', 'IQD', 'JOD', 'KWD', 'OMR', 'TND'], + '8': ['BCH', 'BTC'] }; - } + + var numberWithCommas = function(x) { + return parseFloat(x).toLocaleString(); + }; + + var buildAmount = function(start, middle, end) { + $scope.start = start; + $scope.middle = middle; + $scope.end = end; + }; + + var getDecimalPlaces = function(currency) { + if (decimalPlaces['0'].indexOf($scope.currency.toUpperCase()) > -1) return '0'; + if (decimalPlaces['3'].indexOf($scope.currency.toUpperCase()) > -1) return '3'; + if (decimalPlaces['8'].indexOf($scope.currency.toUpperCase()) > -1) return '8'; + return '2'; + }; + + switch (getDecimalPlaces($scope.currency)) { + case '0': + var valueFormatted = numberWithCommas(Math.round(parseFloat($scope.value))); + buildAmount(valueFormatted, '', ''); + break; + + case '2': + var valueProcessing = parseFloat(parseFloat($scope.value).toFixed(2)); + var valueFormatted = numberWithCommas(valueProcessing); + buildAmount(valueFormatted, '', ''); + break; + + case '3': + var valueProcessing = parseFloat(parseFloat($scope.value).toFixed(3)); + var valueFormatted = numberWithCommas(valueProcessing); + buildAmount(valueFormatted, '', ''); + break; + + case '8': + var valueFormatted = parseFloat($scope.value).toFixed(8); + if (parseFloat($scope.value) == 0) { + buildAmount('0', '', ''); + } else { + buildAmount(valueFormatted, '', ''); + var start = numberWithCommas(valueFormatted.slice(0, -5)); + var middle = valueFormatted.slice(-5, -2); + var end = valueFormatted.substr(valueFormatted.length - 2); + buildAmount(start, middle, end); + } + break; + } + }] + }; + } ]); \ No newline at end of file diff --git a/src/sass/components/amount.scss b/src/sass/components/amount.scss index 3280c0706..d8fe552a2 100644 --- a/src/sass/components/amount.scss +++ b/src/sass/components/amount.scss @@ -12,13 +12,16 @@ .middle { font-size: 0.7857em; + margin-left: 5px; } .end { font-size: 0.7857em; + margin-left: 5px; } .currency { font-size: 1em; + margin-left: 5px; } } \ No newline at end of file diff --git a/www/css/main.css b/www/css/main.css index 7a064f812..3b7ddca9d 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -15251,13 +15251,16 @@ ion-content.padded-bottom-cta-with-summary { font-size: 1em; } .amount .middle { - font-size: 0.7857em; } + font-size: 0.7857em; + margin-left: 5px; } .amount .end { - font-size: 0.7857em; } + font-size: 0.7857em; + margin-left: 5px; } .amount .currency { - font-size: 1em; } + font-size: 1em; + margin-left: 5px; } /* This is for rules that don't yet have a home. * Our goal is to delete this file. Search the regex: /class=".*CLASS.*?"/ diff --git a/www/views/includes/amount.html b/www/views/includes/amount.html index 791983c06..5d006fe46 100644 --- a/www/views/includes/amount.html +++ b/www/views/includes/amount.html @@ -1,6 +1,3 @@
- {{start}} - {{middle}} - {{end}} - {{currency}} + {{start}}{{middle}}{{end}}{{currency}}
\ No newline at end of file diff --git a/www/views/review.html b/www/views/review.html index 4995d3d25..64c256fd8 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -69,8 +69,8 @@
+ value="{{fee.value}}" + currency="{{fee.currency}}">
From 2b32fe9bdccb603cef9d85f5d4c1bf09197dcd07 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Fri, 27 Jul 2018 17:04:53 +0800 Subject: [PATCH 164/386] Changes amount directive scope values to bind to parent scope property --- src/js/directives/amount.js | 4 ++-- www/views/review.html | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/js/directives/amount.js b/src/js/directives/amount.js index ff61288b3..bf519c0d0 100644 --- a/src/js/directives/amount.js +++ b/src/js/directives/amount.js @@ -11,8 +11,8 @@ angular.module('bitcoincom.directives') return { restrict: 'E', scope: { - value: '@', - currency: '@' + value: '=', + currency: '=' }, templateUrl: 'views/includes/amount.html', controller: ['$scope', function($scope) { diff --git a/www/views/review.html b/www/views/review.html index 64c256fd8..4995d3d25 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -69,8 +69,8 @@
+ value="fee.value" + currency="fee.currency">
From 81e9f527ff05dbca5977c3bf7aff5c519cf6a6aa Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Sat, 28 Jul 2018 13:04:04 -0700 Subject: [PATCH 165/386] Route for send amount. --- src/js/routes.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/routes.js b/src/js/routes.js index 5900b88da..5b0b59d77 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -292,7 +292,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr 'tab-send@tabs': { controller: 'amountController', controllerAs: 'vm', - templateUrl: 'views/amount.html' + templateUrl: 'views/amountNew.html' } } }) From 0ba1ea1f423435b7ce3e74a84750ca374dec2b03 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Sat, 28 Jul 2018 15:36:23 -0700 Subject: [PATCH 166/386] Use All Available Funds button. --- src/sass/variables.scss | 4 +++ src/sass/views/amountNew.scss | 60 +++++++++++++++++++++++------------ www/views/amountNew.html | 16 ++++++---- 3 files changed, 53 insertions(+), 27 deletions(-) diff --git a/src/sass/variables.scss b/src/sass/variables.scss index cb21c030a..c2ab16254 100644 --- a/src/sass/variables.scss +++ b/src/sass/variables.scss @@ -9,6 +9,7 @@ $v-font-family-light: "Roboto-Light", sans-serif- /* Colors */ $v-bitcoin-orange: #fab915 !default; +$v-off-black: #262424; $v-dark-gray: #445 !default; $v-mid-gray: #667 !default; $v-light-gray: #9b9bab !default; @@ -24,8 +25,11 @@ $v-text-accent-color: #647ce8 !default; $v-success-color: #13e5b6 !default; $v-warning-color: #ffa500 !default; +$v-warning-color-2: #b7664d; $v-error-color: #ef473a !default; +$v-background-under-card: #f2f2f2; + $v-wallet-color-map: ( 0: (color: #dd4b39, name: 'Cinnabar'), 1: (color: #f38f12, name: 'Carrot Orange'), diff --git a/src/sass/views/amountNew.scss b/src/sass/views/amountNew.scss index 5f27361b3..eb29d9ee4 100644 --- a/src/sass/views/amountNew.scss +++ b/src/sass/views/amountNew.scss @@ -249,7 +249,6 @@ min-height: 20px; .warning { - color: #b7664d; font-family: 'ProximaNova-Semibold'; font-size: 12px; padding: 0 6px 6px 6px; @@ -433,37 +432,59 @@ .keypad-container { position: relative; + font-size: 18px; + line-height: 2em; //flex: 0 1 196px; + @media (min-height: 667px) { + font-size: 24px; + } + + @media(max-height: 480px) { + font-size: 12px; + } + @media (min-height: 667px) { //flex: 0 1 224px; } + .sendmax { + background: $v-off-black; + + .button { + color: white; + background: black; + border: 1px solid $v-off-black; + border-radius: 0; + font-size: 0.8em; + line-height: 2em; + margin-bottom: 1.618em; + width: 100%; + + .available-funds-amount { + color: #C9C9C9; + } + + &:active { + background-color: $v-dark-gray; + } + } + } + .keypad { text-align: center; - font-size: 18px; font-weight: lighter; position: absolute; bottom: 0; width: 100%; color: $v-text-primary-color; - @media (min-height: 667px) { - font-size: 24px; - } + .row { padding: 0 !important; margin: 0 !important; } - - .col { - line-height: 38px; - - @media (min-height: 667px) { - line-height: 45px; - } - } .row { &:last-child { @@ -498,23 +519,22 @@ .digit{ cursor: pointer; background-color: #000; - border: 1px solid #262424; + border: 1px solid $v-off-black; transition: all 0.1s ease; - &:active { background-color: $v-dark-gray; } } - @media(max-height: 480px) { - font-size: 12px; - - } } } } - background: #f2f2f2; + + .warning { + color: $v-warning-color-2; + } + background: $v-background-under-card; ion-content { margin-bottom: constant(safe-area-inset-bottom); /* iOS 11.0 */ diff --git a/www/views/amountNew.html b/www/views/amountNew.html index 1b29f6e44..9449c361d 100644 --- a/www/views/amountNew.html +++ b/www/views/amountNew.html @@ -48,16 +48,18 @@ Available Funds: {{vm.availableFunds}}
- -
+
+ +
+
From 72a5b3cabd57396947d08fe329362ac59c3e690d Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Sat, 28 Jul 2018 17:18:52 -0700 Subject: [PATCH 167/386] Primary ("Next") button. --- src/sass/variables.scss | 1 + src/sass/views/amountNew.scss | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/src/sass/variables.scss b/src/sass/variables.scss index c2ab16254..67d5a044b 100644 --- a/src/sass/variables.scss +++ b/src/sass/variables.scss @@ -81,6 +81,7 @@ $v-button-primary-active-bg: darken($v-accent-color, 10% $v-button-primary-active-border: transparent !default; $v-button-primary-clear-bg: none !default; $v-button-primary-clear-color: $v-accent-color !default; +$v-button-primary-disabled-bg: $v-mid-gray; $v-button-primary-outline-bg: transparent !default; $v-button-primary-outline-border: $v-accent-color !default; $v-button-primary-outline-color: $v-accent-color !default; diff --git a/src/sass/views/amountNew.scss b/src/sass/views/amountNew.scss index eb29d9ee4..bbca0f5a2 100644 --- a/src/sass/views/amountNew.scss +++ b/src/sass/views/amountNew.scss @@ -529,6 +529,16 @@ } } + + .button-primary { + background-color: $v-primary-color; + border-radius: 0; + font-family: 'ProximaNova-Semibold'; + } + + .button-primary[disabled] { + background-color: $v-button-primary-disabled-bg; + } } .warning { From 9781f90f2b21095d2ab34468c3336cf663bad3b4 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Sat, 28 Jul 2018 19:20:12 -0700 Subject: [PATCH 168/386] Warning colour for insufficient funds. --- src/js/controllers/amount.js | 1 + src/sass/views/amountNew.scss | 6 +++++- www/views/amountNew.html | 8 ++++---- 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 1d4cb41f1..a4c8171a4 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -12,6 +12,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i vm.amountModel = { amount: 0 }; vm.availableFunds = '251.00 USD'; vm.fromWalletId = ''; + vm.fundsAreInsufficient = true; vm.globalResult = ''; vm.isRequestingSpecificAmount = false; vm.listComplete = false; diff --git a/src/sass/views/amountNew.scss b/src/sass/views/amountNew.scss index bbca0f5a2..9dad8b045 100644 --- a/src/sass/views/amountNew.scss +++ b/src/sass/views/amountNew.scss @@ -377,10 +377,14 @@ justify-content: space-between; margin: 0 14px; - .availableFunds { + .available-funds { color: #6F6F70; } + .warning { + color: $v-warning-color-2; + } + .extra, button.extra { display: flex; diff --git a/www/views/amountNew.html b/www/views/amountNew.html index 9449c361d..b23a34fbf 100644 --- a/www/views/amountNew.html +++ b/www/views/amountNew.html @@ -29,7 +29,7 @@
-
- -
- Available Funds: {{vm.availableFunds}} +
+ Available Funds:{{vm.availableFunds}}
From 7669ab247981245fbe611d59cb86bbd3372da2b4 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 30 Jul 2018 19:28:30 +1200 Subject: [PATCH 171/386] Transitioning from the Shapeshift screen. --- src/js/controllers/shapeshift.js | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/shapeshift.js b/src/js/controllers/shapeshift.js index a58fc20b6..5bc815d19 100644 --- a/src/js/controllers/shapeshift.js +++ b/src/js/controllers/shapeshift.js @@ -1,6 +1,9 @@ 'use strict'; angular.module('copayApp.controllers').controller('shapeshiftController', function($scope, $interval, profileService, walletService, popupService, lodash, $ionicNavBarDelegate) { + var vm = this; + + //vm.buyBitcion = buyBitcoin; var walletsBtc = []; var walletsBch = []; @@ -21,6 +24,12 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi $scope.singleToWallet = $scope.toWallets.length == 1; } + function buyBitcoin() { + console.log('buyBitcoin()'); + } + + $scope.buyBitcoin = buyBitcoin; + $scope.onFromWalletSelect = function(wallet) { $scope.fromWallet = wallet; showToWallets(); @@ -37,12 +46,24 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi } $scope.$on("$ionicView.beforeEnter", function(event, data) { + console.log('beforeEnter()'); walletsBtc = profileService.getWallets({coin: 'btc'}); walletsBch = profileService.getWallets({coin: 'bch'}); $scope.fromWallets = lodash.filter(walletsBtc.concat(walletsBch), function(w) { return w.status.balance.availableAmount > 0; }); - if ($scope.fromWallets.length == 0) return; + console.log('Checking wallets.'); + if ($scope.fromWallets.length == 0) { + // Need to go to new origin screen here, with parameters + var params = { + thirdParty: { + id: 'shapeshift' + } + }; + console.log('Asking for transition'); + $state.transitionTo('tabs.send', params); + return + } $scope.onFromWalletSelect($scope.fromWallets[0]); $scope.onToWalletSelect($scope.toWallets[0]); $scope.singleFromWallet = $scope.fromWallets.length == 1; From 3732d21728b92993771ab51aefc114b31a84d5bb Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 30 Jul 2018 09:37:14 +0200 Subject: [PATCH 172/386] send/receive iPhoneX fixes --- src/js/controllers/walletDetails.js | 14 +++++++------- src/sass/views/walletDetails.scss | 19 ++++++++++++------- 2 files changed, 19 insertions(+), 14 deletions(-) diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index c824cbfda..f4f2d2488 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -327,16 +327,16 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun } scrollPos = scrollPos || 0; - var amountHeight = 230 - scrollPos; + var amountHeight = 210 - scrollPos; if (amountHeight < 80) { amountHeight = 80; } var contentMargin = amountHeight; - if (contentMargin > 230) { - contentMargin = 230; + if (contentMargin > 210) { + contentMargin = 210; } - var amountScale = (amountHeight / 230); + var amountScale = (amountHeight / 210); if (amountScale < 0.5) { amountScale = 0.5; } @@ -354,9 +354,9 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun top = TOP_BALANCE_BUTTON; } - var amountTop = ((amountScale - 0.85) / 0.85) * top; - if (amountTop < -10) { - amountTop = -10; + var amountTop = ((amountScale - 0.80) / 0.80) * top; //0.85 + if (amountTop < -2) { + amountTop = -2; } if (amountTop > top) { amountTop = top; diff --git a/src/sass/views/walletDetails.scss b/src/sass/views/walletDetails.scss index 0536a5735..8d6972f09 100644 --- a/src/sass/views/walletDetails.scss +++ b/src/sass/views/walletDetails.scss @@ -132,10 +132,15 @@ position: relative; height: 100%; height: calc(100% - env(safe-area-inset-bottom) * 2); + + &.status-bar { + margin-top: 20px; + margin-top: env(safe-area-inset-top); + } } .bar-header { border: 0; - background: none; + background: rgb(238, 182, 64); .title, .button { color: #fff; } @@ -143,13 +148,13 @@ background-color: transparent; } } - //.nav-bar-block, .bar { - //background-color: inherit !important; - //} + .nav-bar-block, .bar { + background-color: inherit !important; + } ion-content { &.collapsible { - margin-top: 210px; + margin-top: 230px; } padding-top: 0; @@ -189,7 +194,7 @@ .send-receive-buttons { max-width: 600px; - margin: 45px auto 0; + margin: 25px auto 0; >.col { padding: 5px 10px; margin-bottom: 0; @@ -211,7 +216,7 @@ width: 100%; text-align: center; color: #fff; - height: 210px; + height: 230px; padding-top: 40px; display: block; align-items: center; From 2b96293c80302181f52b0c4d6701b342fee974ab Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Mon, 30 Jul 2018 16:40:16 +0800 Subject: [PATCH 173/386] Move amount directive to a separate branch --- src/js/directives/amount.js | 76 ----------------------------- src/sass/components/amount.scss | 27 ---------- src/sass/components/components.scss | 1 - www/css/main.css | 21 -------- 4 files changed, 125 deletions(-) delete mode 100644 src/js/directives/amount.js delete mode 100644 src/sass/components/amount.scss diff --git a/src/js/directives/amount.js b/src/js/directives/amount.js deleted file mode 100644 index bf519c0d0..000000000 --- a/src/js/directives/amount.js +++ /dev/null @@ -1,76 +0,0 @@ -'use strict'; - -/** - * @desc amount directive that can be used to display formatted financial values - * @example - */ -angular.module('bitcoincom.directives') - .directive('amount', [ - '$timeout', - function($timeout) { - return { - restrict: 'E', - scope: { - value: '=', - currency: '=' - }, - templateUrl: 'views/includes/amount.html', - controller: ['$scope', function($scope) { - var decimalPlaces = { - '0': ['BIF', 'CLP', 'DJF', 'GNF', 'ILS', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'UGX', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'], - '3': ['BHD', 'IQD', 'JOD', 'KWD', 'OMR', 'TND'], - '8': ['BCH', 'BTC'] - }; - - var numberWithCommas = function(x) { - return parseFloat(x).toLocaleString(); - }; - - var buildAmount = function(start, middle, end) { - $scope.start = start; - $scope.middle = middle; - $scope.end = end; - }; - - var getDecimalPlaces = function(currency) { - if (decimalPlaces['0'].indexOf($scope.currency.toUpperCase()) > -1) return '0'; - if (decimalPlaces['3'].indexOf($scope.currency.toUpperCase()) > -1) return '3'; - if (decimalPlaces['8'].indexOf($scope.currency.toUpperCase()) > -1) return '8'; - return '2'; - }; - - switch (getDecimalPlaces($scope.currency)) { - case '0': - var valueFormatted = numberWithCommas(Math.round(parseFloat($scope.value))); - buildAmount(valueFormatted, '', ''); - break; - - case '2': - var valueProcessing = parseFloat(parseFloat($scope.value).toFixed(2)); - var valueFormatted = numberWithCommas(valueProcessing); - buildAmount(valueFormatted, '', ''); - break; - - case '3': - var valueProcessing = parseFloat(parseFloat($scope.value).toFixed(3)); - var valueFormatted = numberWithCommas(valueProcessing); - buildAmount(valueFormatted, '', ''); - break; - - case '8': - var valueFormatted = parseFloat($scope.value).toFixed(8); - if (parseFloat($scope.value) == 0) { - buildAmount('0', '', ''); - } else { - buildAmount(valueFormatted, '', ''); - var start = numberWithCommas(valueFormatted.slice(0, -5)); - var middle = valueFormatted.slice(-5, -2); - var end = valueFormatted.substr(valueFormatted.length - 2); - buildAmount(start, middle, end); - } - break; - } - }] - }; - } -]); \ No newline at end of file diff --git a/src/sass/components/amount.scss b/src/sass/components/amount.scss deleted file mode 100644 index d8fe552a2..000000000 --- a/src/sass/components/amount.scss +++ /dev/null @@ -1,27 +0,0 @@ -.amount { - .start, - .middle, - .end, - .currency { - display: inline-block; - } - - .start { - font-size: 1em; - } - - .middle { - font-size: 0.7857em; - margin-left: 5px; - } - - .end { - font-size: 0.7857em; - margin-left: 5px; - } - - .currency { - font-size: 1em; - margin-left: 5px; - } -} \ No newline at end of file diff --git a/src/sass/components/components.scss b/src/sass/components/components.scss index 8d8346265..a689138bf 100644 --- a/src/sass/components/components.scss +++ b/src/sass/components/components.scss @@ -8,4 +8,3 @@ @import "action-minor"; @import "expand-content"; @import "fee-summary"; -@import "amount"; diff --git a/www/css/main.css b/www/css/main.css index 3b7ddca9d..f059eeaac 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -15241,27 +15241,6 @@ ion-content.padded-bottom-cta-with-summary { .fee-summary .fee-crypto { color: #A7A7A7; } -.amount .start, -.amount .middle, -.amount .end, -.amount .currency { - display: inline-block; } - -.amount .start { - font-size: 1em; } - -.amount .middle { - font-size: 0.7857em; - margin-left: 5px; } - -.amount .end { - font-size: 0.7857em; - margin-left: 5px; } - -.amount .currency { - font-size: 1em; - margin-left: 5px; } - /* This is for rules that don't yet have a home. * Our goal is to delete this file. Search the regex: /class=".*CLASS.*?"/ */ From e1d65bc5572818d19f22acfc494f14636f2cfc15 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Mon, 30 Jul 2018 16:49:57 +0800 Subject: [PATCH 174/386] Adds amount directive --- src/js/directives/amount.js | 76 ++ src/sass/components/amount.scss | 27 + src/sass/components/components.scss | 1 + src/sass/main.scss | 1 + www/css/main.css | 1183 ++++++++++++++------------- www/index.html | 7 +- 6 files changed, 734 insertions(+), 561 deletions(-) create mode 100644 src/js/directives/amount.js create mode 100644 src/sass/components/amount.scss create mode 100644 src/sass/components/components.scss diff --git a/src/js/directives/amount.js b/src/js/directives/amount.js new file mode 100644 index 000000000..bf519c0d0 --- /dev/null +++ b/src/js/directives/amount.js @@ -0,0 +1,76 @@ +'use strict'; + +/** + * @desc amount directive that can be used to display formatted financial values + * @example + */ +angular.module('bitcoincom.directives') + .directive('amount', [ + '$timeout', + function($timeout) { + return { + restrict: 'E', + scope: { + value: '=', + currency: '=' + }, + templateUrl: 'views/includes/amount.html', + controller: ['$scope', function($scope) { + var decimalPlaces = { + '0': ['BIF', 'CLP', 'DJF', 'GNF', 'ILS', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'UGX', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'], + '3': ['BHD', 'IQD', 'JOD', 'KWD', 'OMR', 'TND'], + '8': ['BCH', 'BTC'] + }; + + var numberWithCommas = function(x) { + return parseFloat(x).toLocaleString(); + }; + + var buildAmount = function(start, middle, end) { + $scope.start = start; + $scope.middle = middle; + $scope.end = end; + }; + + var getDecimalPlaces = function(currency) { + if (decimalPlaces['0'].indexOf($scope.currency.toUpperCase()) > -1) return '0'; + if (decimalPlaces['3'].indexOf($scope.currency.toUpperCase()) > -1) return '3'; + if (decimalPlaces['8'].indexOf($scope.currency.toUpperCase()) > -1) return '8'; + return '2'; + }; + + switch (getDecimalPlaces($scope.currency)) { + case '0': + var valueFormatted = numberWithCommas(Math.round(parseFloat($scope.value))); + buildAmount(valueFormatted, '', ''); + break; + + case '2': + var valueProcessing = parseFloat(parseFloat($scope.value).toFixed(2)); + var valueFormatted = numberWithCommas(valueProcessing); + buildAmount(valueFormatted, '', ''); + break; + + case '3': + var valueProcessing = parseFloat(parseFloat($scope.value).toFixed(3)); + var valueFormatted = numberWithCommas(valueProcessing); + buildAmount(valueFormatted, '', ''); + break; + + case '8': + var valueFormatted = parseFloat($scope.value).toFixed(8); + if (parseFloat($scope.value) == 0) { + buildAmount('0', '', ''); + } else { + buildAmount(valueFormatted, '', ''); + var start = numberWithCommas(valueFormatted.slice(0, -5)); + var middle = valueFormatted.slice(-5, -2); + var end = valueFormatted.substr(valueFormatted.length - 2); + buildAmount(start, middle, end); + } + break; + } + }] + }; + } +]); \ No newline at end of file diff --git a/src/sass/components/amount.scss b/src/sass/components/amount.scss new file mode 100644 index 000000000..d8fe552a2 --- /dev/null +++ b/src/sass/components/amount.scss @@ -0,0 +1,27 @@ +.amount { + .start, + .middle, + .end, + .currency { + display: inline-block; + } + + .start { + font-size: 1em; + } + + .middle { + font-size: 0.7857em; + margin-left: 5px; + } + + .end { + font-size: 0.7857em; + margin-left: 5px; + } + + .currency { + font-size: 1em; + margin-left: 5px; + } +} \ No newline at end of file diff --git a/src/sass/components/components.scss b/src/sass/components/components.scss new file mode 100644 index 000000000..def6289fa --- /dev/null +++ b/src/sass/components/components.scss @@ -0,0 +1 @@ +@import "amount.scss"; diff --git a/src/sass/main.scss b/src/sass/main.scss index 7b3e46291..516656449 100644 --- a/src/sass/main.scss +++ b/src/sass/main.scss @@ -9,4 +9,5 @@ @import "mixins/mixins"; @import "views/views"; @import "directives/directives"; +@import "components/components"; @import "shame"; diff --git a/www/css/main.css b/www/css/main.css index b4e67edac..d30a89142 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -9970,7 +9970,7 @@ ion-nav-bar.hide { .card { margin: 20px 14px; } -ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm:before, ion-view#copayers-invitation:before, ion-view#tab-home:before, ion-view#tab-receive:before, ion-view#tab-send:before, ion-view.settings:before, ion-view#bitpayCard:before, ion-view#bitpayCard-intro:before, ion-view#view-address-book:before, ion-view#addresses:before, ion-view#send-feedback:before, ion-view#choose-fee-level:before, ion-view#txp-details:before, ion-view#coinbase:before, ion-view#glidera:before, ion-view#amazon:before, ion-view#mercadolibre:before, ion-view#custom-amount:before { +ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm:before, ion-view#copayers-invitation:before, ion-view#tab-home:before, ion-view#tab-receive:before, ion-view#tab-send:before, ion-view.settings:before, ion-view#bitpayCard:before, ion-view#bitpayCard-intro:before, ion-view#view-address-book:before, ion-view#addresses:before, ion-view#choose-fee-level:before, ion-view#txp-details:before, ion-view#coinbase:before, ion-view#glidera:before, ion-view#amazon:before, ion-view#mercadolibre:before, ion-view#custom-amount:before { content: " "; display: block; position: absolute; @@ -9980,7 +9980,7 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm height: 44px; background-color: #fab915; } -.platform-ios.platform-cordova:not(.fullscreen) ion-view.deflash-blue:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-amount:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-confirm:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#copayers-invitation:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-home:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-receive:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-send:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view.settings:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#bitpayCard:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#bitpayCard-intro:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-address-book:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#addresses:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#send-feedback:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#choose-fee-level:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#txp-details:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#coinbase:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#glidera:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#amazon:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#mercadolibre:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#custom-amount:before { +.platform-ios.platform-cordova:not(.fullscreen) ion-view.deflash-blue:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-amount:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-confirm:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#copayers-invitation:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-home:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-receive:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-send:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view.settings:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#bitpayCard:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#bitpayCard-intro:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-address-book:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#addresses:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#choose-fee-level:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#txp-details:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#coinbase:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#glidera:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#amazon:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#mercadolibre:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#custom-amount:before { height: 64px; } .just-a-hint, .icon.bp-arrow-right, .icon.bp-arrow-down, .icon.bp-arrow-up { @@ -10071,10 +10071,12 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm .loading .spinner svg { margin-top: 0; } -.button.button-primary.button-standard, .button.button-secondary.button-standard, .button.button-light.button-standard, .button.button-assertive.button-standard, +.button.button-primary.button-standard, .button.button-secondary.button-standard, .button.button-light.button-standard, .button.button-white.button-standard, .button.button-green.button-standard, .button.button-assertive.button-standard, .onboarding .button.button-primary.button-standard, .onboarding .button.button-secondary.button-standard, .onboarding .button.button-light.button-standard, +.onboarding .button.button-white.button-standard, +.onboarding .button.button-green.button-standard, .onboarding .button.button-assertive.button-standard { width: 85%; max-width: 300px; @@ -10118,10 +10120,12 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm box-shadow: none; color: #fff; } -.button.button-primary.button-standard + .button-standard, .button.button-secondary.button-standard + .button-standard, .button.button-light.button-standard + .button-standard, .button.button-assertive.button-standard + .button-standard, +.button.button-primary.button-standard + .button-standard, .button.button-secondary.button-standard + .button-standard, .button.button-light.button-standard + .button-standard, .button.button-white.button-standard + .button-standard, .button.button-green.button-standard + .button-standard, .button.button-assertive.button-standard + .button-standard, .onboarding .button.button-primary.button-standard + .button-standard, .onboarding .button.button-secondary.button-standard + .button-standard, .onboarding .button.button-light.button-standard + .button-standard, +.onboarding .button.button-white.button-standard + .button-standard, +.onboarding .button.button-green.button-standard + .button-standard, .onboarding .button.button-assertive.button-standard + .button-standard { margin-top: 1rem; } @@ -10183,8 +10187,67 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm font-size: 0.7em !important; display: inline !important; } -.button.button-full { - display: block; } +.button { + border-radius: 6px; } + .button.button-full { + display: block; } + .button-green { + border-color: #FFF; + background-color: #719561; + color: #FFF; + border: 0px; + box-shadow: 0 2px 11px 0 #C1C1C1; } + .button-green:hover { + color: #FFF; + text-decoration: none; } + .button-green.active, .button-green.activated { + border-color: #FFF; + background-color: #606060; } + .button-green.button-clear { + border-color: transparent; + background: none; + box-shadow: none; + color: #FFF; } + .button-green.button-icon { + border-color: transparent; + background: none; } + .button-green.button-outline { + border-color: #C1C1C1; + background: transparent; + color: #C1C1C1; } + .button-green.button-outline.active, .button-green.button-outline.activated { + background-color: #C1C1C1; + box-shadow: none; + color: #fff; } + .button-white { + border-color: #C1C1C1; + background-color: #FFF; + color: #606060; + box-shadow: 0 2px 11px 0 #C1C1C1; } + .button-white:hover { + color: #606060; + text-decoration: none; } + .button-white.active, .button-white.activated { + border-color: #FFF; + background-color: #C1C1C1; } + .button-white.button-clear { + border-color: transparent; + background: none; + box-shadow: none; + color: #FFF; } + .button-white.button-icon { + border-color: transparent; + background: none; } + .button-white.button-outline { + border-color: #C1C1C1; + background: transparent; + color: #C1C1C1; } + .button-white.button-outline.active, .button-white.button-outline.activated { + background-color: #C1C1C1; + box-shadow: none; + color: #fff; } + .button-white.activated { + color: #FFF; } .button-clear { background: none !important; } @@ -10197,6 +10260,22 @@ textarea.d-block { display: block; width: 100%; } +qrcode { + position: relative; } + qrcode.qr-overlay::before { + content: ""; + background-size: 100% 100%; + display: block; + left: 88px; + margin-top: 88px; + width: 44px; + height: 44px; + position: absolute; } + qrcode.qr-overlay--bch::before { + background-image: url("../img/qr-overlay-bch.png"); } + qrcode.qr-overlay--btc::before { + background-image: url("../img/qr-overlay-btc.png"); } + .center-block { float: none; margin: 0 auto; } @@ -10237,6 +10316,10 @@ textarea.d-block { font-weight: 700; } #tab-home .card > .item-heading .icon, #tab-home .list > .item-heading .icon, #tab-send .card > .item-heading .icon, #tab-send .list > .item-heading .icon { color: #667; } + #tab-home .card > .item-heading .subtitle, #tab-home .list > .item-heading .subtitle, #tab-send .card > .item-heading .subtitle, #tab-send .list > .item-heading .subtitle { + color: #667; + font-size: 12px; + font-weight: 300; } #view-add .item { margin-bottom: 10px; @@ -10260,349 +10343,345 @@ textarea.d-block { #view-add .bg.join { padding: 10px; } -#view-amount .recipient-label { - font-size: 14px; - padding-bottom: 0; - color: #667; } - -#view-amount .item-no-bottom-border + .item { - border-top: 0; } - -#view-amount .icon-bitpay-card { - background-image: url("../img/icon-bitpay.svg"); } - -#view-amount .icon-amazon { - background-image: url("../img/icon-amazon.svg"); } - -@media (max-width: 480px) { - #view-amount .bitcoin-address { - font-size: 13px; - padding-left: 48px; } - #view-amount .bitcoin-address .icon { - left: 8px; - font-size: 24px; } - #view-amount .bitcoin-address .big-icon-svg { - left: 5px; } - #view-amount .bitcoin-address .big-icon-svg > .bg { - width: 30px; - height: 30px; - box-shadow: none; } } - -@media (max-width: 320px) { - #view-amount .bitcoin-address > span:last-child { - margin-left: -2px; } } - -#view-amount .send-gravatar { - left: 11px; - position: absolute; - top: 10px; } - -#view-amount .amount span input { - display: inline; - width: 120px; } - -#view-amount .amount-pane-recipient { - position: absolute; - top: 95px; - bottom: 0; - width: 100%; - background-color: #fff; - padding: 0 16px; } - #view-amount .amount-pane-recipient .amount-bar { - padding: 24px 0; - font-size: 18px; } - @media (max-height: 480px) { - #view-amount .amount-pane-recipient .amount-bar { - padding: 0px; } } - @media (max-width: 320px) { - #view-amount .amount-pane-recipient .amount-bar { - padding: 0px; } } - #view-amount .amount-pane-recipient .amount-bar .title { - float: left; - padding-top: 10px; - color: #445; - font-weight: bold; } +#view-amount { + background: #494949; } + #view-amount .recipient-label { + font-size: 14px; + padding-bottom: 0; + color: #667; } + #view-amount .item-no-bottom-border + .item { + border-top: 0; } + #view-amount .icon-bitpay-card { + background-image: url("../img/icon-bitpay.svg"); } + #view-amount .icon-amazon { + background-image: url("../img/icon-amazon.svg"); } + @media (max-width: 480px) { + #view-amount .bitcoin-address { + font-size: 13px; + padding-left: 48px; } + #view-amount .bitcoin-address .icon { + left: 8px; + font-size: 24px; } + #view-amount .bitcoin-address .big-icon-svg { + left: 5px; } + #view-amount .bitcoin-address .big-icon-svg > .bg { + width: 30px; + height: 30px; + box-shadow: none; } } + @media (max-width: 320px) { + #view-amount .bitcoin-address > span:last-child { + margin-left: -2px; } } + #view-amount .send-gravatar { + left: 11px; + position: absolute; + top: 10px; } + #view-amount .amount span input { + display: inline; + width: 120px; } + #view-amount .amount-pane-recipient { + position: absolute; + top: 95px; + bottom: 0; + width: 100%; + background-color: #fff; + padding: 0 16px; } + #view-amount .amount-pane-recipient .amount-bar { + padding: 24px 0; + font-size: 18px; } @media (max-height: 480px) { - #view-amount .amount-pane-recipient .amount-bar .title { + #view-amount .amount-pane-recipient .amount-bar { padding: 0px; } } - @media (max-height: 480px) { - #view-amount .amount-pane-recipient .amount-bar { - padding-top: 3px; } } - #view-amount .amount-pane-recipient .amount { - display: flex; - flex-direction: column; - justify-content: center; - flex-grow: 1; - position: absolute; - bottom: 254px; - top: 66px; } - #view-amount .amount-pane-recipient .amount .light { - color: #9b9bab; } - @media (max-height: 480px) { - #view-amount .amount-pane-recipient .amount { - top: 45px; } } - @media (max-width: 320px) { - #view-amount .amount-pane-recipient .amount { - bottom: 276px; - top: 60px; } - #view-amount .amount-pane-recipient .amount > div { - display: inline-block; } - #view-amount .amount-pane-recipient .amount > div:first-child { - display: inherit; } } - -#view-amount .amount-pane-no-recipient { - position: absolute; - top: 0; - bottom: 0; - width: 100%; - background-color: #fff; - padding: 0 16px; } - #view-amount .amount-pane-no-recipient .amount-bar { - padding: 24px 0; - font-size: 18px; } - #view-amount .amount-pane-no-recipient .amount-bar .title { - padding-top: 10px; - color: #445; - font-weight: bold; } - #view-amount .amount-pane-no-recipient .amount-bar .title .limits { - margin-top: 10px; - color: #9b9bab; - font-size: 12px; } - #view-amount .amount-pane-no-recipient .amount-bar .title .select { - margin: 10px 1px; } - #view-amount .amount-pane-no-recipient .amount { - display: flex; - flex-direction: column; - justify-content: center; - flex-grow: 1; - position: absolute; - bottom: 254px; - top: 66px; } - #view-amount .amount-pane-no-recipient .amount .light { - color: #9b9bab; } - -#view-amount .amount { - padding-top: 10px; - padding-bottom: 10px; } - #view-amount .amount .icon-toggle { - font-size: 1.2em; - width: auto; - margin: 0.8em auto; - border: 1px solid #f2f2f2; - color: #445; - border-radius: 3px; - padding: 0 10px; - cursor: pointer; } - @media (max-height: 280px) { - #view-amount .amount .icon-toggle { - margin: 0.1em auto; } } - #view-amount .amount__editable--minimize { - font-size: 22px; } - #view-amount .amount__editable--standard { - font-size: 42px; } - @media (max-height: 480px) { - #view-amount .amount__editable--standard { - font-size: 26px; - padding-top: 10px; } } - #view-amount .amount__editable--placeholder { - color: #9b9bab; } - #view-amount .amount__number { - color: #445; } - #view-amount .amount__currency-toggle { - border: 1px solid #f2f2f2; - color: #445; - border-radius: 3px; - padding: 0 10px; - cursor: pointer; - font-size: .6em; - position: relative; - top: -3px; - line-height: 1; } - @media (max-width: 320px) { - #view-amount .amount__currency-toggle { - line-height: 30px; - height: 30px; } } - #view-amount .amount__currency-toggle-mobile { - border: 1px solid #f2f2f2; - color: #445; - border-radius: 3px; - cursor: pointer; - position: relative; - line-height: 1; } - @media (max-width: 320px) { - #view-amount .amount__currency-toggle-mobile { - line-height: 30px; - height: 30px; } } - #view-amount .amount__results--minimize { - font-size: 12px; } - #view-amount .amount__results--standard { - font-size: 18px; - padding: 10px 0; } - #view-amount .amount__results--placeholder { - color: #9b9bab; } - #view-amount .amount__result { - color: #9b9bab; - font-size: .9em; - line-height: 1; } - @media (max-height: 480px) { - #view-amount .amount__result { - margin-bottom: 0; } } - #view-amount .amount__result-equiv { - color: #667; - font-size: 1.2em; } - @media (max-height: 480px) { - #view-amount .amount__result-equiv { - margin-top: 0; - font-size: 16px; } } - -#view-amount .scroll-content { - display: flex; - flex-direction: column; } - #view-amount .scroll-content .send-amount { - flex: 1 1 auto; - display: flex; - flex-direction: column; - justify-content: center; } - #view-amount .scroll-content .send-amount .send-amount-tool { - flex: 0 1 auto; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input { - text-align: center; - position: relative; - padding: 10px 30px; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .text-selectable { - -webkit-user-select: text; - -moz-user-select: text; - -ms-user-select: text; - user-select: text; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - font-size: 1.8em; } - @media (min-width: 375px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - font-size: 2.1em; } } - @media (min-width: 414px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - font-size: 2.4em; } } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { - font-size: 1.6em; } - @media (min-width: 375px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { - font-size: 1.8em; } } - @media (min-width: 414px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { - font-size: 2em; } } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { - font-size: 0.9em; } - @media (min-width: 375px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { - font-size: 1.3em; } } - @media (min-width: 414px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { - font-size: 1.4em; } } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input { - border: 0; - padding: 0; - white-space: normal; - background: none; - line-height: 1; - box-sizing: content-box; - display: inline-block; - vertical-align: middle; - margin: 0; - height: 1em; - margin-right: 5px; - font-family: 'ProximaNova'; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - display: inline-block; - vertical-align: middle; - line-height: 1em; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit { - font-weight: bold; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - margin-right: 5px; - word-break: break-all; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .switch-currencies { - position: absolute; - right: 0; - top: 50%; - transform: translate(0, -50%); - padding: 15px; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .switch-currencies img { - width: 18px; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions { - margin-top: 15px; - display: flex; - align-items: center; - justify-content: center; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button { - flex: 1 1 auto; - line-height: 1.2em; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button + .button { - margin-left: 10px; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button span { - display: flex; - align-items: center; - justify-content: center; } - #view-amount .scroll-content .button.no-margin { - margin: 0; } - #view-amount .scroll-content .notification-warning { - display: block; - padding: .75rem 1.25rem; - color: #856404; - background-color: #fff3cd; - border: 1px solid #ffeeba; - line-height: 1.4em; - margin-bottom: 20px; } - #view-amount .scroll-content .keypad-container { - position: relative; } - #view-amount .scroll-content .keypad-container .keypad { - text-align: center; - font-size: 18px; - font-weight: lighter; - position: absolute; - bottom: 0; - width: 100%; - color: #667; } - @media (min-height: 667px) { - #view-amount .scroll-content .keypad-container .keypad { - font-size: 24px; } } - #view-amount .scroll-content .keypad-container .keypad .row { - padding: 0 !important; - margin: 0 !important; } - #view-amount .scroll-content .keypad-container .keypad .col { - line-height: 38px; } - @media (min-height: 667px) { - #view-amount .scroll-content .keypad-container .keypad .col { - line-height: 45px; } } - #view-amount .scroll-content .keypad-container .keypad .row:last-child .col { - padding-bottom: 10px; } - #view-amount .scroll-content .keypad-container .keypad .operator { - background-color: #f2f2f2; - font-weight: normal; - cursor: pointer; } - #view-amount .scroll-content .keypad-container .keypad .operator:active { - background-color: #9b9bab; } - #view-amount .scroll-content .keypad-container .keypad .operator-send { - font-weight: bolder; - color: #fff; - background-color: #494949; - font-size: 36px; - cursor: pointer; } - #view-amount .scroll-content .keypad-container .keypad .operator-send:active { - background-color: #eaeaea; } - #view-amount .scroll-content .keypad-container .keypad .digit { - cursor: pointer; - border-top: 1px solid #f2f2f2; - border-left: 1px solid #f2f2f2; - transition: all 0.1s ease; } - #view-amount .scroll-content .keypad-container .keypad .digit:active { - background-color: #f2f2f2; } + @media (max-width: 320px) { + #view-amount .amount-pane-recipient .amount-bar { + padding: 0px; } } + #view-amount .amount-pane-recipient .amount-bar .title { + float: left; + padding-top: 10px; + color: #445; + font-weight: bold; } + @media (max-height: 480px) { + #view-amount .amount-pane-recipient .amount-bar .title { + padding: 0px; } } @media (max-height: 480px) { - #view-amount .scroll-content .keypad-container .keypad { - font-size: 12px; } } + #view-amount .amount-pane-recipient .amount-bar { + padding-top: 3px; } } + #view-amount .amount-pane-recipient .amount { + display: flex; + flex-direction: column; + justify-content: center; + flex-grow: 1; + position: absolute; + bottom: 254px; + top: 66px; } + #view-amount .amount-pane-recipient .amount .light { + color: #9b9bab; } + @media (max-height: 480px) { + #view-amount .amount-pane-recipient .amount { + top: 45px; } } + @media (max-width: 320px) { + #view-amount .amount-pane-recipient .amount { + bottom: 276px; + top: 60px; } + #view-amount .amount-pane-recipient .amount > div { + display: inline-block; } + #view-amount .amount-pane-recipient .amount > div:first-child { + display: inherit; } } + #view-amount .amount-pane-no-recipient { + position: absolute; + top: 0; + bottom: 0; + width: 100%; + background-color: #fff; + padding: 0 16px; } + #view-amount .amount-pane-no-recipient .amount-bar { + padding: 24px 0; + font-size: 18px; } + #view-amount .amount-pane-no-recipient .amount-bar .title { + padding-top: 10px; + color: #445; + font-weight: bold; } + #view-amount .amount-pane-no-recipient .amount-bar .title .limits { + margin-top: 10px; + color: #9b9bab; + font-size: 12px; } + #view-amount .amount-pane-no-recipient .amount-bar .title .select { + margin: 10px 1px; } + #view-amount .amount-pane-no-recipient .amount { + display: flex; + flex-direction: column; + justify-content: center; + flex-grow: 1; + position: absolute; + bottom: 254px; + top: 66px; } + #view-amount .amount-pane-no-recipient .amount .light { + color: #9b9bab; } + #view-amount .amount { + padding-top: 10px; + padding-bottom: 10px; } + #view-amount .amount .icon-toggle { + font-size: 1.2em; + width: auto; + margin: 0.8em auto; + border: 1px solid #f2f2f2; + color: #445; + border-radius: 3px; + padding: 0 10px; + cursor: pointer; } + @media (max-height: 280px) { + #view-amount .amount .icon-toggle { + margin: 0.1em auto; } } + #view-amount .amount__editable--minimize { + font-size: 22px; } + #view-amount .amount__editable--standard { + font-size: 42px; } + @media (max-height: 480px) { + #view-amount .amount__editable--standard { + font-size: 26px; + padding-top: 10px; } } + #view-amount .amount__editable--placeholder { + color: #9b9bab; } + #view-amount .amount__number { + color: #445; } + #view-amount .amount__currency-toggle { + border: 1px solid #f2f2f2; + color: #445; + border-radius: 3px; + padding: 0 10px; + cursor: pointer; + font-size: .6em; + position: relative; + top: -3px; + line-height: 1; } + @media (max-width: 320px) { + #view-amount .amount__currency-toggle { + line-height: 30px; + height: 30px; } } + #view-amount .amount__currency-toggle-mobile { + border: 1px solid #f2f2f2; + color: #445; + border-radius: 3px; + cursor: pointer; + position: relative; + line-height: 1; } + @media (max-width: 320px) { + #view-amount .amount__currency-toggle-mobile { + line-height: 30px; + height: 30px; } } + #view-amount .amount__results--minimize { + font-size: 12px; } + #view-amount .amount__results--standard { + font-size: 18px; + padding: 10px 0; } + #view-amount .amount__results--placeholder { + color: #9b9bab; } + #view-amount .amount__result { + color: #9b9bab; + font-size: .9em; + line-height: 1; } + @media (max-height: 480px) { + #view-amount .amount__result { + margin-bottom: 0; } } + #view-amount .amount__result-equiv { + color: #667; + font-size: 1.2em; } + @media (max-height: 480px) { + #view-amount .amount__result-equiv { + margin-top: 0; + font-size: 16px; } } + #view-amount .scroll-content { + display: flex; + flex-direction: column; } + #view-amount .scroll-content .send-amount { + flex: 1 1 auto; + display: flex; + flex-direction: column; + justify-content: center; } + #view-amount .scroll-content .send-amount .send-amount-tool { + flex: 0 1 auto; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input { + text-align: center; + position: relative; + padding: 10px 30px; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .text-selectable { + -webkit-user-select: text; + -moz-user-select: text; + -ms-user-select: text; + user-select: text; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + font-size: 1.8em; } + @media (min-width: 375px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + font-size: 2.1em; } } + @media (min-width: 414px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + font-size: 2.4em; } } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { + font-size: 1.6em; } + @media (min-width: 375px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { + font-size: 1.8em; } } + @media (min-width: 414px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { + font-size: 2em; } } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { + font-size: 0.9em; } + @media (min-width: 375px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { + font-size: 1.3em; } } + @media (min-width: 414px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { + font-size: 1.4em; } } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input { + border: 0; + padding: 0; + white-space: normal; + background: none; + line-height: 1; + box-sizing: content-box; + display: inline-block; + vertical-align: middle; + margin: 0; + height: 1em; + margin-right: 5px; + font-family: 'ProximaNova'; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + display: inline-block; + vertical-align: middle; + line-height: 1em; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit { + font-weight: bold; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + margin-right: 5px; + word-break: break-all; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .switch-currencies { + position: absolute; + right: 0; + top: 50%; + transform: translate(0, -50%); + padding: 15px; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .switch-currencies img { + width: 18px; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions { + margin-top: 15px; + display: flex; + align-items: center; + justify-content: center; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button { + flex: 1 1 auto; + line-height: 1.2em; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button + .button { + margin-left: 10px; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button span { + display: flex; + align-items: center; + justify-content: center; } + #view-amount .scroll-content .button.no-margin { + margin: 0; } + #view-amount .scroll-content .notification-warning { + display: block; + padding: .75rem 1.25rem; + color: #856404; + background-color: #fff3cd; + border: 1px solid #ffeeba; + line-height: 1.4em; + margin-bottom: 20px; } + #view-amount .scroll-content .keypad-container { + position: relative; } + #view-amount .scroll-content .keypad-container .keypad { + text-align: center; + font-size: 18px; + font-weight: lighter; + position: absolute; + bottom: 0; + width: 100%; + color: #667; } + @media (min-height: 667px) { + #view-amount .scroll-content .keypad-container .keypad { + font-size: 24px; } } + #view-amount .scroll-content .keypad-container .keypad .row { + padding: 0 !important; + margin: 0 !important; } + #view-amount .scroll-content .keypad-container .keypad .col { + line-height: 38px; } + @media (min-height: 667px) { + #view-amount .scroll-content .keypad-container .keypad .col { + line-height: 45px; } } + #view-amount .scroll-content .keypad-container .keypad .row:last-child .col { + padding-bottom: 10px; } + #view-amount .scroll-content .keypad-container .keypad .operator { + background-color: #f2f2f2; + font-weight: normal; + cursor: pointer; } + #view-amount .scroll-content .keypad-container .keypad .operator:active { + background-color: #9b9bab; } + #view-amount .scroll-content .keypad-container .keypad .operator-send { + font-weight: bolder; + color: #fff; + background-color: #494949; + font-size: 36px; + cursor: pointer; } + #view-amount .scroll-content .keypad-container .keypad .operator-send:active { + background-color: #eaeaea; } + #view-amount .scroll-content .keypad-container .keypad .digit { + cursor: pointer; + border-top: 1px solid #f2f2f2; + border-left: 1px solid #f2f2f2; + transition: all 0.1s ease; } + #view-amount .scroll-content .keypad-container .keypad .digit:active { + background-color: #f2f2f2; } + @media (max-height: 480px) { + #view-amount .scroll-content .keypad-container .keypad { + font-size: 12px; } } + #view-amount ion-content { + margin-bottom: constant(safe-area-inset-bottom); + /* iOS 11.0 */ + margin-bottom: env(safe-area-inset-bottom); + /* iOS 11.2 */ } #view-confirm { - background-color: #ffffff; } + background-color: #494949; } #view-confirm .item-note { float: none; } #view-confirm .item-note .fee-rate { @@ -10622,6 +10701,13 @@ textarea.d-block { margin-top: -3px; } #view-confirm .toggle { cursor: pointer; } + #view-confirm ion-content { + background-color: #ffffff; } + #view-confirm slide-to-accept, #view-confirm slide-to-accept-success { + margin-bottom: constant(safe-area-inset-bottom); + /* iOS 11.0 */ + margin-bottom: env(safe-area-inset-bottom); + /* iOS 11.2 */ } #copayers-invitation .button-share { color: #fff; @@ -10728,6 +10814,8 @@ textarea.d-block { #tab-home .card-banner { padding: 0; } + #tab-home .card-banner svg { + margin: 40px auto 40px; } #tab-home .card-banner__img { width: 100%; display: block; } @@ -10951,123 +11039,154 @@ textarea.d-block { #cordova-plugin-qrscanner-still, #cordova-plugin-qrscanner-video-preview { background-color: #fab915 !important; } -#tab-send .input input { - width: 100%; - height: auto; } +#tab-send-header { + height: 300px; + width: 100%; } -#tab-send .input.item { - height: 55px; } +#tab-send-contacts { + height: calc(100vh - 300px - 50px - 44px); + /* screen size - button container - bottom-tab-menu - header top */ + overflow: scroll; } + #tab-send-contacts.ios { + height: calc(100vh - 300px - 50px - 44px - 18px); } -#tab-send .input i.left { - padding-left: 15px; } +#tab-send .input { + width: 100%; } + #tab-send .input input { + width: 100%; + height: 57px; + background: #FFF; + border: 1px #D9D9D9 solid; } + #tab-send .input input::placeholder { + color: #DCDCDC; } + #tab-send .input i.left { + padding-left: 15px; } + #tab-send .input i.qr { + cursor: pointer; + cursor: hand; + padding-right: 5px; } -#tab-send .input i.qr { - cursor: pointer; - cursor: hand; - padding-right: 5px; } - -#tab-send .qr-scan-icon { - cursor: pointer; - cursor: hand; - border-left: 1px solid #e4e4e4; - padding-left: 10px; } - -#tab-send .qr-icon { - line-height: 20px; } - -#tab-send .zero-state-cta { - padding-bottom: 3vh; - left: 0; } - -#tab-send .send-heading { - font-size: 14px; - font-weight: bold; - padding: 0 0 16px 0; - border: none; } - -#tab-send .send-header-wrapper { - padding: 10px; - background-color: white; - box-shadow: 0px 5px 10px 0px #cccccc; } - -#tab-send .search-wrapper { +#tab-send .send-wrapper { + padding: 18px 9px 9px 9px; background-color: #f2f2f2; border-radius: 3px; border: none; } - #tab-send .search-wrapper .svg#Bitcoin_Symbol { - width: 14px; } - #tab-send .search-wrapper .svg#Bitcoin_Symbol .st0 { - fill: #cccccc; } - #tab-send .search-wrapper.focus { - background: none; } - #tab-send .search-wrapper.focus .svg#Bitcoin_Symbol { - display: none; } - #tab-send .search-wrapper.focus .search-input { - padding-left: 30px; } - #tab-send .search-wrapper.focus .search-input:focus::-webkit-input-placeholder { - opacity: 0; } - -#tab-send .abs-v-center { - position: absolute; - top: 50%; - transform: translateY(-50%); } + #tab-send .send-wrapper:after { + display: block; + position: relative; + height: 1px; + background: #DEDEDE; + bottom: 0; + content: ''; + margin: 10px 6px 0px; } + #tab-send .send-wrapper.focus .search-input { + padding-left: 30px; } + #tab-send .send-wrapper.focus .search-input:focus::-webkit-input-placeholder { + opacity: 0; } + #tab-send .send-wrapper .buttons { + margin: auto; + margin-top: 18px; } + #tab-send .send-wrapper .buttons .button { + height: 60px; + line-height: 16px; + margin-right: 0px; + width: 95%; + max-width: none; + padding: 2px; } + #tab-send .send-wrapper .buttons .button-clipboard-paste { + margin-left: 0; } + #tab-send .send-wrapper .buttons .button-clipboard-paste .address { + display: none; } + #tab-send .send-wrapper .buttons .button-clipboard-paste .icon { + background: url(../img/icon-clipboard-paste.svg); + width: 15px; + height: 19px; + display: inline-block; + margin-bottom: 4px; } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content { + background: #FAB915; + color: #FFF !important; + border: 0; + box-shadow: 0 2px 11px 0 #C1C1C1; } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address .address, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content .address { + display: none; } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address .icon, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content .icon { + background: url(../img/icon-clipboard-paste-white.svg); } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address.contains-address .address, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content.contains-address .address { + display: inline; } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address.contains-address .non-address, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content.contains-address .non-address { + display: none; } + #tab-send .send-wrapper .buttons .button span { + font-size: 14px; } + #tab-send .send-wrapper .buttons .button img { + height: 16px; + width: auto; + margin: 2px 0 4px; } + #tab-send .send-wrapper .buttons .button-qr { + font-weight: bold; + max-width: none; + width: 100%; + height: 95px; + margin-top: 20px; } + #tab-send .send-wrapper .buttons .button-qr img { + vertical-align: middle; + margin-right: 12px; + width: 43px; + height: 43px; } + #tab-send .send-wrapper .buttons .button-qr span { + font-size: 19px; } #tab-send .search-input { background-color: transparent; padding-left: 30px; } -#tab-send .separator-left { - border-left: 1px solid #d9d9df; - padding-left: 10px; - height: 70%; } - -#tab-send .bitcoin-address { - border-top: none; - padding-bottom: .5rem; } - @media (max-width: 480px) { - #tab-send .bitcoin-address input { - font-size: 14px; } } - #tab-send .bitcoin-address .icon { - line-height: 31px; - padding-top: 2px; - padding-bottom: 1px; } - -#tab-send .show-more { - text-align: center; - padding: 20px; - font-size: 16px; - color: #387ef5; - font-weight: bold; } - #tab-send .sendTip { + padding-top: 5vh; text-align: center; } - #tab-send .sendTip > .item-heading { - margin-top: 10px; - background: 0 none; } - #tab-send .sendTip img { - content: url("../img/app/tab-icons/ico-send-selected.svg"); } #tab-send .sendTip .item { border-style: none; } #tab-send .sendTip > .title { font-size: 20px; - font-weight: bold; color: #445; margin: 20px 10px; } #tab-send .sendTip > .subtitle { font-size: 1rem; line-height: 1.5em; font-weight: 300; - color: #445; + color: #6F6F70; margin: 20px 1em 2.5em; } #tab-send .sendTip .big-icon-svg .bg.green { padding: 0 10px; box-shadow: none; } + #tab-send .sendTip .buttons { + margin-top: 18px; } + #tab-send .sendTip .buttons .button { + font-weight: bold; + font-size: 19px; } + #tab-send .sendTip .button-first-contact img { + height: 19px; + width: 19px; + margin-right: 6px; + vertical-align: sub; } + +#tab-send .item-heading { + line-height: 16px; + font-size: 14px; + font-weight: bold; } + #tab-send .item-heading .subtitle { + color: #B5B2B2; + font-size: 12px; + font-weight: 300; } #tab-send .list .item { + font-weight: 600; color: #444; - border-top: none; - padding-top: 1.5rem; - padding-bottom: 1.5rem; } + padding-top: 0.6rem; + padding-bottom: 0.6rem; } + #tab-send .list .item p { + font-weight: normal; } + #tab-send .list .item.item-icon-left { + padding-left: 64px; } #tab-send .list .item .big-icon-svg { left: 5px; } #tab-send .list .item .big-icon-svg > .bg { @@ -11077,7 +11196,7 @@ textarea.d-block { #tab-send .list .item:before { display: block; position: absolute; - width: 80%; + width: 100%; height: 1px; background: rgba(221, 221, 221, 0.3); top: 0; @@ -11096,6 +11215,28 @@ textarea.d-block { #tab-send .scroll { height: 100%; } +#tab-send .card.contacts { + margin: 4px 4px 16px 4px; + border-radius: 6px; + box-shadow: 0px 2px 1px 0 #C1C1C1; } + #tab-send .card.contacts .gravatar { + border-radius: 30px; + height: 40px; + width: 40px; } + +@media only screen and (min-device-width: 320px) and (max-device-width: 568px) { + #tab-send .send-wrapper .buttons .button-qr { + height: 60px; } + #tab-send .send-wrapper .buttons .button-qr span { + font-size: 16px; } + #tab-send #tab-send-header { + height: 270px; } + #tab-send #tab-send-contacts { + height: calc(100vh - 270px - 50px - 44px); + /* screen size - button container - bottom-tab-menu - header top */ } + #tab-send #tab-send-contacts.ios { + height: calc(100vh - 270px - 50px - 44px - 18px); } } + .settings .icon-bitpay { background-image: url("../img/icon-bitpay.svg"); } @@ -11604,7 +11745,8 @@ textarea.d-block { fill: white; } #walletDetails .bp-content { position: relative; - height: 100%; } + height: 100%; + height: calc(100% - env(safe-area-inset-bottom) * 2); } #walletDetails .bp-content.status-bar { margin-top: 20px; } #walletDetails .bar-header { @@ -11618,7 +11760,8 @@ textarea.d-block { background-color: inherit !important; } #walletDetails ion-content { padding-top: 0; - top: 0; } + top: 0; + margin-bottom: 16px; } #walletDetails ion-content.collapsible { margin-top: 210px; } #walletDetails ion-content .scroll { @@ -12211,7 +12354,6 @@ a.item { position: relative; height: 70px; border-color: #fab915; - background-color: #fab915; padding-top: 20px; margin-bottom: 50px; text-align: center; } @@ -13013,74 +13155,13 @@ a.item { .onboarding-illustration-backup-warning { background-image: url(../img/app/backup-warning.svg); } -#rate-card .item-heading { - font-weight: 700; } - -#rate-card .row { - border: none; } - -#rate-card .item-icon-right { - margin: 0; } - -#rate-card .feedback-flow-button { - margin-bottom: 20px; } - -#rate-card .icon-svg > img { - height: 1.8rem; - margin-bottom: 5px; } - -#send-feedback { - background-color: #ffffff; } - #send-feedback .row { - border: none; } - #send-feedback .skip { - color: rgba(255, 255, 255, 0.3); } - #send-feedback .feedback-heading { - padding-top: 20px; } - #send-feedback .feedback-title { - padding-left: 10px; - font-size: 20px; - font-weight: bold; - color: #445; } - #send-feedback .rating { - text-align: right; - padding-right: 15px; } - #send-feedback .comment { - padding: 0 20px 20px; - font-size: 1rem; - line-height: 1.5em; - font-weight: 300; - color: #445; } - #send-feedback .user-feedback { - border-top: 1px solid #f2f2f2; - border-bottom: 1px solid #f2f2f2; - padding: 20px; - width: 100%; - margin-bottom: 20px; - -webkit-appearance: none; } - #send-feedback .send-feedback-star { - height: 1rem; - margin-left: 5px; } - #send-feedback .form-fade-in { - opacity: 0; - animation-name: fadeIn; - animation-duration: .5s; - animation-fill-mode: forwards; - animation-timing-function: ease-in; } - -@keyframes fadeIn { - from { - opacity: 0; } - to { - opacity: 1; } } - -#complete { +#share-app { background-color: #fff; } - #complete .complete-layout { + #share-app .share-app-layout { display: flex; flex-direction: column; height: 100%; } - #complete .complete-layout__expand { + #share-app .share-app-layout__expand { display: flex; flex-direction: column; flex-grow: 1; @@ -13089,36 +13170,27 @@ a.item { text-align: center; opacity: 0; transition: opacity .3s; } - #complete .complete-layout__expand.fade-in { + #share-app .share-app-layout__expand.fade-in { opacity: 1; } - #complete .share-the-love-illustration { + #share-app .share-the-love-illustration { width: 5rem; margin: 1rem; } - #complete .send-feedback-illustration { - height: 16rem; - margin: 1rem; } - #complete .feedback-title { - font-size: 20px; - font-weight: bold; - color: #445; - margin: 20px 10px; - text-align: center; } - #complete .subtitle { + #share-app .subtitle { padding: 10px 30px 20px; text-align: center; color: #667; } - #complete .icon-svg > img { + #share-app .icon-svg > img { height: 16rem; width: 16rem; margin: 10px; } - #complete .socialsharing-icon { + #share-app .socialsharing-icon { display: inline-block; width: 60px; } - #complete .addressbook-icon-svg { + #share-app .addressbook-icon-svg { display: inline-block; width: 50px; height: 50px; } - #complete .share-buttons { + #share-app .share-buttons { padding: 50px 10px 30px; background-color: #f2f2f2; text-align: center; @@ -13130,7 +13202,7 @@ a.item { animation-fill-mode: forwards; animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1); animation-delay: .2s; } - #complete .share-buttons__action { + #share-app .share-buttons__action { display: inline-block; color: #667; font-size: .9rem; @@ -13148,38 +13220,6 @@ a.item { transform: translateY(0); opacity: 1; } } -#rate-app { - background-color: #ffffff; - text-align: center; } - #rate-app .skip-rating { - color: #445; - position: absolute; - top: 5px; - right: 10px; - padding: 15px; } - #rate-app .icon-svg > img { - width: 80px; - height: 80px; - margin-top: 15px; } - #rate-app .feedback-title { - font-size: 20px; - font-weight: bold; - color: #445; - margin: 80px 50px 10px; - text-align: center; } - #rate-app .share-the-love-illustration { - width: 5rem; - margin: 1rem; } - #rate-app .subtitle { - padding: 10px 30px 20px 40px; - color: #667; } - #rate-app .rate-buttons { - bottom: 0; - width: 100%; - position: absolute; - background-color: #f2f2f2; - padding: 30px 0 15px; } - action-sheet .bp-action-sheet__sheet { background: #fff; width: calc(100% + 1px); @@ -13800,7 +13840,11 @@ slide-to-accept-success { transform: translateY(5rem); opacity: 0; transition: transform 400ms ease, opacity 400ms ease; - transition-delay: 250ms; } + transition-delay: 250ms; + margin-bottom: constant(safe-area-inset-bottom); + /* iOS 11.0 */ + margin-bottom: env(safe-area-inset-bottom); + /* iOS 11.2 */ } slide-to-accept-success .slide-success__footer.reveal { -webkit-transform: translateY(0); transform: translateY(0); @@ -13858,16 +13902,16 @@ slide-to-accept-success { line-height: 30px; } #txp-details .head .amount-label .amount, #view-confirm .head .amount-label .amount { - font-size: 38px; - margin-bottom: .5rem; } - #txp-details .head .amount-label .amount > .unit, - #view-confirm .head .amount-label .amount > .unit { - font-family: "Roboto-Light"; } + font-size: 16px; + color: #9B9B9B; + font-family: "Roboto-Light"; } #txp-details .head .amount-label .alternative, #view-confirm .head .amount-label .alternative { - font-size: 16px; - font-family: "Roboto-Light"; - color: #9B9B9B; } + font-size: 38px; + margin-bottom: .5rem; } + #txp-details .head .amount-label .alternative > .unit, + #view-confirm .head .amount-label .alternative > .unit { + font-family: "Roboto-Light"; } #txp-details .item, #view-confirm .item { border-color: #EFEFEF; } @@ -14155,6 +14199,10 @@ wallet-selector .subheader { font-weight: bold; padding-bottom: 10px; border-bottom: 1px solid #EFEFEF; } + wallet-selector .subheader .subtitle { + color: #667; + font-size: 12px; + font-weight: 300; } wallet-selector .subheader .wallet-coin-logo { vertical-align: middle; margin-right: 5px; } @@ -15018,6 +15066,27 @@ log-options #check-bar .checkbox-icon { border-radius: 3px; display: inline-block; } +.amount .start, +.amount .middle, +.amount .end, +.amount .currency { + display: inline-block; } + +.amount .start { + font-size: 1em; } + +.amount .middle { + font-size: 0.7857em; + margin-left: 5px; } + +.amount .end { + font-size: 0.7857em; + margin-left: 5px; } + +.amount .currency { + font-size: 1em; + margin-left: 5px; } + /* This is for rules that don't yet have a home. * Our goal is to delete this file. Search the regex: /class=".*CLASS.*?"/ */ diff --git a/www/index.html b/www/index.html index 4c73317e3..ecc2d923c 100644 --- a/www/index.html +++ b/www/index.html @@ -11,9 +11,8 @@ - Bitcoin.com Wallet - Bitcoin.com Wallet - - + Bitcoin.com Wallet + @@ -31,7 +30,7 @@ - + From 7fb2792a1a93cc02534177f5218f7bba8cd6ee3c Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Mon, 30 Jul 2018 16:56:27 +0800 Subject: [PATCH 175/386] Adds size-equal class to amount directive --- src/sass/components/amount.scss | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/sass/components/amount.scss b/src/sass/components/amount.scss index d8fe552a2..b22604181 100644 --- a/src/sass/components/amount.scss +++ b/src/sass/components/amount.scss @@ -20,6 +20,13 @@ margin-left: 5px; } + &.size-equal { + .middle, + .end { + font-size: 1em; + } + } + .currency { font-size: 1em; margin-left: 5px; From f4b0b4606781afabbbe68c5ff5dbca5c6df248bb Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Mon, 30 Jul 2018 17:33:38 +0800 Subject: [PATCH 176/386] Adds size-equal and capitalizes currency text --- src/js/directives/amount.js | 13 +++++++++++-- src/sass/components/amount.scss | 1 + www/css/main.css | 7 ++++++- www/views/includes/amount.html | 4 ++++ 4 files changed, 22 insertions(+), 3 deletions(-) create mode 100644 www/views/includes/amount.html diff --git a/src/js/directives/amount.js b/src/js/directives/amount.js index bf519c0d0..98d6ac59f 100644 --- a/src/js/directives/amount.js +++ b/src/js/directives/amount.js @@ -2,7 +2,13 @@ /** * @desc amount directive that can be used to display formatted financial values - * @example + * size-equal attribute is optional, defaults to false. + * @example fee = { + * value: 12.49382901, + * currency: 'BCH' + * } + * @example + * @example */ angular.module('bitcoincom.directives') .directive('amount', [ @@ -12,10 +18,13 @@ angular.module('bitcoincom.directives') restrict: 'E', scope: { value: '=', - currency: '=' + currency: '=', + sizeEqual: '=' }, templateUrl: 'views/includes/amount.html', controller: ['$scope', function($scope) { + if (typeof $scope.sizeEqual != 'undefined') $scope.sizeEqual = false; + var decimalPlaces = { '0': ['BIF', 'CLP', 'DJF', 'GNF', 'ILS', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'UGX', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'], '3': ['BHD', 'IQD', 'JOD', 'KWD', 'OMR', 'TND'], diff --git a/src/sass/components/amount.scss b/src/sass/components/amount.scss index b22604181..363d38a20 100644 --- a/src/sass/components/amount.scss +++ b/src/sass/components/amount.scss @@ -30,5 +30,6 @@ .currency { font-size: 1em; margin-left: 5px; + text-transform: uppercase; } } \ No newline at end of file diff --git a/www/css/main.css b/www/css/main.css index d30a89142..1798f4b98 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -15083,9 +15083,14 @@ log-options #check-bar .checkbox-icon { font-size: 0.7857em; margin-left: 5px; } +.amount.size-equal .middle, +.amount.size-equal .end { + font-size: 1em; } + .amount .currency { font-size: 1em; - margin-left: 5px; } + margin-left: 5px; + text-transform: uppercase; } /* This is for rules that don't yet have a home. * Our goal is to delete this file. Search the regex: /class=".*CLASS.*?"/ diff --git a/www/views/includes/amount.html b/www/views/includes/amount.html new file mode 100644 index 000000000..4cf2807ad --- /dev/null +++ b/www/views/includes/amount.html @@ -0,0 +1,4 @@ +
+ {{start}}{{middle}}{{end}}{{currency}} +
\ No newline at end of file From 5c4890fac48c60f6428e3acc73bcc96fdf6873f4 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Mon, 30 Jul 2018 17:34:20 +0800 Subject: [PATCH 177/386] Removes amount directive template --- www/views/includes/amount.html | 3 --- 1 file changed, 3 deletions(-) delete mode 100644 www/views/includes/amount.html diff --git a/www/views/includes/amount.html b/www/views/includes/amount.html deleted file mode 100644 index 5d006fe46..000000000 --- a/www/views/includes/amount.html +++ /dev/null @@ -1,3 +0,0 @@ -
- {{start}}{{middle}}{{end}}{{currency}} -
\ No newline at end of file From da536a3f5b035fe7524f96825bf4957f08a4422f Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Mon, 30 Jul 2018 17:45:26 +0800 Subject: [PATCH 178/386] Fixes default value of size-equal --- src/js/directives/amount.js | 2 +- www/views/tab-home.html | 15 +++++++++++++++ 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/src/js/directives/amount.js b/src/js/directives/amount.js index 98d6ac59f..a23069157 100644 --- a/src/js/directives/amount.js +++ b/src/js/directives/amount.js @@ -23,7 +23,7 @@ angular.module('bitcoincom.directives') }, templateUrl: 'views/includes/amount.html', controller: ['$scope', function($scope) { - if (typeof $scope.sizeEqual != 'undefined') $scope.sizeEqual = false; + if (typeof $scope.sizeEqual == 'undefined') $scope.sizeEqual = false; var decimalPlaces = { '0': ['BIF', 'CLP', 'DJF', 'GNF', 'ILS', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'UGX', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'], diff --git a/www/views/tab-home.html b/www/views/tab-home.html index 8df176a56..459618996 100644 --- a/www/views/tab-home.html +++ b/www/views/tab-home.html @@ -22,6 +22,21 @@
+
+ + + +
+
From 51bd97012173e0487a11a3224a6100bf648b5897 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Mon, 30 Jul 2018 17:46:00 +0800 Subject: [PATCH 179/386] Merges amount directive From e0ef42b09a23ec7fe098a009dce87c244b2ac645 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Mon, 30 Jul 2018 17:47:05 +0800 Subject: [PATCH 180/386] Removes dummy text --- www/views/tab-home.html | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/www/views/tab-home.html b/www/views/tab-home.html index 459618996..8df176a56 100644 --- a/www/views/tab-home.html +++ b/www/views/tab-home.html @@ -22,21 +22,6 @@
-
- - - -
-
From 734153ec5b76cd4f8a5c130d4e534bbdcf62ba72 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 30 Jul 2018 15:17:15 +0200 Subject: [PATCH 181/386] more fixes on the send/receive on Android & iOS / removed some unused code --- src/js/controllers/walletDetails.js | 12 ++---------- src/sass/views/walletDetails.scss | 4 +++- www/views/walletDetails.html | 8 ++++---- 3 files changed, 9 insertions(+), 15 deletions(-) diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index f4f2d2488..ffbc070f5 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -12,13 +12,6 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun $scope.isAndroid = platformInfo.isAndroid; $scope.isIOS = platformInfo.isIOS; - $scope.currencySymbols = { - 'EUR': '€', - 'GBP': '£', - 'USD': '$', - 'YEN' : '' - }; - var channel = "firebase"; if (platformInfo.isNW) { channel = "ga"; @@ -354,7 +347,7 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun top = TOP_BALANCE_BUTTON; } - var amountTop = ((amountScale - 0.80) / 0.80) * top; //0.85 + var amountTop = ((amountScale - 0.80) / 0.80) * top; if (amountTop < -2) { amountTop = -2; } @@ -365,8 +358,7 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun var t = amountTop; $scope.altAmountOpacity = (amountHeight - 100) / 80; - - $scope.buttonsOpacity = (amountHeight - 150)/80; + $scope.buttonsOpacity = (amountHeight - 140) / 70; $window.requestAnimationFrame(function() { $scope.amountHeight = amountHeight + 'px'; $scope.contentMargin = contentMargin + 'px'; diff --git a/src/sass/views/walletDetails.scss b/src/sass/views/walletDetails.scss index 8d6972f09..6b760bbc4 100644 --- a/src/sass/views/walletDetails.scss +++ b/src/sass/views/walletDetails.scss @@ -194,7 +194,9 @@ .send-receive-buttons { max-width: 600px; - margin: 25px auto 0; + position: absolute; + bottom: 20px; + >.col { padding: 5px 10px; margin-bottom: 0; diff --git a/www/views/walletDetails.html b/www/views/walletDetails.html index 85aace8fc..e29cd5c51 100644 --- a/www/views/walletDetails.html +++ b/www/views/walletDetails.html @@ -91,7 +91,7 @@
-
+
Receive @@ -214,17 +214,17 @@
-
+
Receive
-
+
Buy Bitcoin
-
+
Send
From ed291b1ac5f706315c5e074e1389cc9e6b3f1fbc Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 30 Jul 2018 15:25:52 +0200 Subject: [PATCH 182/386] removed currencySymbolService and it's references --- src/js/controllers/walletDetails.js | 7 +- src/js/services/currencySymbolService.js | 195 ----------------------- www/views/walletDetails.html | 16 +- 3 files changed, 9 insertions(+), 209 deletions(-) delete mode 100644 src/js/services/currencySymbolService.js diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index ffbc070f5..3e92b2a40 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('walletDetailsController', function($scope, $rootScope, $interval, $timeout, $filter, $log, $ionicModal, $ionicPopover, $state, $stateParams, $ionicHistory, profileService, lodash, configService, currencySymbolService, platformInfo, walletService, txpModalService, externalLinkService, popupService, addressbookService, storageService, $ionicScrollDelegate, $window, bwcError, gettextCatalog, timeService, feeService, appConfigService, rateService) { +angular.module('copayApp.controllers').controller('walletDetailsController', function($scope, $rootScope, $interval, $timeout, $filter, $log, $ionicModal, $ionicPopover, $state, $stateParams, $ionicHistory, profileService, lodash, configService, platformInfo, walletService, txpModalService, externalLinkService, popupService, addressbookService, storageService, $ionicScrollDelegate, $window, bwcError, gettextCatalog, timeService, feeService, appConfigService, rateService) { var HISTORY_SHOW_LIMIT = 10; var currentTxHistoryPage = 0; @@ -256,11 +256,6 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun return !tx.confirmations || tx.confirmations === 0; }; - $scope.currencySymbol = function(code) { - var symbol = currencySymbolService.getCurrencySymbol(code); - return symbol?symbol:""; - }; - $scope.showMore = function() { $timeout(function() { currentTxHistoryPage++; diff --git a/src/js/services/currencySymbolService.js b/src/js/services/currencySymbolService.js deleted file mode 100644 index 029cd9eb2..000000000 --- a/src/js/services/currencySymbolService.js +++ /dev/null @@ -1,195 +0,0 @@ -'use strict'; - -angular.module('copayApp.services').factory('currencySymbolService', function($log) { - var root = {}; - root.currencySymbols = { - 'AED': 'د.إ', - 'AFN': '؋', - 'ALL': 'L', - 'AMD': '֏', - 'ANG': 'ƒ', - 'AOA': 'Kz', - 'ARS': '$', - 'AUD': '$', - 'AWG': 'ƒ', - 'AZN': '₼', - 'BAM': 'KM', - 'BBD': '$', - 'BDT': '৳', - 'BGN': 'лв', - 'BHD': '.د.ب', - 'BIF': 'FBu', - 'BMD': '$', - 'BND': '$', - 'BOB': '$b', - 'BRL': 'R$', - 'BSD': '$', - 'BTC': '฿', - 'BTN': 'Nu.', - 'BWP': 'P', - 'BYR': 'Br', - 'BYN': 'Br', - 'BZD': 'BZ$', - 'CAD': '$', - 'CDF': 'FC', - 'CHF': 'CHF', - 'CLP': '$', - 'CNY': '¥', - 'COP': '$', - 'CRC': '₡', - 'CUC': '$', - 'CUP': '₱', - 'CVE': '$', - 'CZK': 'Kč', - 'DJF': 'Fdj', - 'DKK': 'kr', - 'DOP': 'RD$', - 'DZD': 'دج', - 'EEK': 'kr', - 'EGP': '£', - 'ERN': 'Nfk', - 'ETB': 'Br', - 'ETH': 'Ξ', - 'EUR': '€', - 'FJD': '$', - 'FKP': '£', - 'GBP': '£', - 'GEL': '₾', - 'GGP': '£', - 'GHC': '₵', - 'GHS': 'GH₵', - 'GIP': '£', - 'GMD': 'D', - 'GNF': 'FG', - 'GTQ': 'Q', - 'GYD': '$', - 'HKD': '$', - 'HNL': 'L', - 'HRK': 'kn', - 'HTG': 'G', - 'HUF': 'Ft', - 'IDR': 'Rp', - 'ILS': '₪', - 'IMP': '£', - 'INR': '₹', - 'IQD': 'ع.د', - 'IRR': '﷼', - 'ISK': 'kr', - 'JEP': '£', - 'JMD': 'J$', - 'JOD': 'JD', - 'JPY': '¥', - 'KES': 'KSh', - 'KGS': 'лв', - 'KHR': '៛', - 'KMF': 'CF', - 'KPW': '₩', - 'KRW': '₩', - 'KWD': 'KD', - 'KYD': '$', - 'KZT': 'лв', - 'LAK': '₭', - 'LBP': '£', - 'LKR': '₨', - 'LRD': '$', - 'LSL': 'M', - 'LTC': 'Ł', - 'LTL': 'Lt', - 'LVL': 'Ls', - 'LYD': 'LD', - 'MAD': 'MAD', - 'MDL': 'lei', - 'MGA': 'Ar', - 'MKD': 'ден', - 'MMK': 'K', - 'MNT': '₮', - 'MOP': 'MOP$', - 'MRO': 'UM', - 'MRU': 'UM', - 'MUR': '₨', - 'MVR': 'Rf', - 'MWK': 'MK', - 'MXN': '$', - 'MYR': 'RM', - 'MZN': 'MT', - 'NAD': '$', - 'NGN': '₦', - 'NIO': 'C$', - 'NOK': 'kr', - 'NPR': '₨', - 'NZD': '$', - 'OMR': '﷼', - 'PAB': 'B/.', - 'PEN': 'S/.', - 'PGK': 'K', - 'PHP': '₱', - 'PKR': '₨', - 'PLN': 'zł', - 'PYG': 'Gs', - 'QAR': '﷼', - 'RMB': '¥', - 'RON': 'lei', - 'RSD': 'Дин.', - 'RUB': '₽', - 'RWF': 'R₣', - 'SAR': '﷼', - 'SBD': '$', - 'SCR': '₨', - 'SDG': 'ج.س.', - 'SEK': 'kr', - 'SGD': '$', - 'SHP': '£', - 'SLL': 'Le', - 'SOS': 'S', - 'SRD': '$', - 'SSP': '£', - 'STD': 'Db', - 'STN': 'Db', - 'SVC': '$', - 'SYP': '£', - 'SZL': 'E', - 'THB': '฿', - 'TJS': 'SM', - 'TMT': 'T', - 'TND': 'د.ت', - 'TOP': 'T$', - 'TRL': '₤', - 'TRY': '₺', - 'TTD': 'TT$', - 'TVD': '$', - 'TWD': 'NT$', - 'TZS': 'TSh', - 'UAH': '₴', - 'UGX': 'USh', - 'USD': '$', - 'UYU': '$U', - 'UZS': 'лв', - 'VEF': 'Bs', - 'VND': '₫', - 'VUV': 'VT', - 'WST': 'WS$', - 'XAF': 'FCFA', - 'XBT': 'Ƀ', - 'XCD': '$', - 'XOF': 'CFA', - 'XPF': '₣', - 'YER': '﷼', - 'ZAR': 'R', - 'ZWD': 'Z$' - }; - - root.getCurrencySymbol = function(code) { - if (!code) return false; - - code = code.toUpperCase(); - - if (root.currencySymbols[code]) { - return root.currencySymbols[code]; - } - $log.debug("Currency symbol for "+code+" not found"); - return false; - }; - - return root; - -}); \ No newline at end of file diff --git a/www/views/walletDetails.html b/www/views/walletDetails.html index e29cd5c51..f9cf662cb 100644 --- a/www/views/walletDetails.html +++ b/www/views/walletDetails.html @@ -34,7 +34,7 @@ on-hold="hideToggle()" ng-style="{'transform': amountScale}" ng-class="{amount__balance: amountIsCollapsible}"> - {{currencySymbol(status.alternativeIsoCode)}} {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}} + {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}}
- {{currencySymbol(status.alternativeIsoCode)}} {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}} + {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}}
@@ -86,7 +86,7 @@   - {{currencySymbol(status.alternativeIsoCode)}} {{status.spendableBalanceAlternative}} {{status.alternativeIsoCode}} + {{status.spendableBalanceAlternative}} {{status.alternativeIsoCode}}
@@ -148,7 +148,7 @@ class="size-14 amount-alternative" ng-if="status.totalBalanceAlternative && wallet.network == 'livenet'" ng-style="{opacity: altAmountOpacity}"> - {{currencySymbol(status.alternativeIsoCode)}} {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}} + {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}}
@@ -158,7 +158,7 @@ on-hold="hideToggle()" ng-style="{'transform': amountScale}" ng-class="{amount__balance: amountIsCollapsible}"> - {{currencySymbol(status.alternativeIsoCode)}} {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}} + {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}}
  - {{currencySymbol(status.alternativeIsoCode)}} {{status.spendableBalanceAlternative}} {{status.alternativeIsoCode}} + {{status.spendableBalanceAlternative}} {{status.alternativeIsoCode}}
@@ -205,7 +205,7 @@
From 0fdd478ae4969e8258e53f70c6d7810dcfd3e0bc Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 31 Jul 2018 12:47:03 +1200 Subject: [PATCH 183/386] Fixed up bold fonts. --- src/sass/views/amountNew.scss | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/sass/views/amountNew.scss b/src/sass/views/amountNew.scss index 0e1d183b6..c0ce94c7a 100644 --- a/src/sass/views/amountNew.scss +++ b/src/sass/views/amountNew.scss @@ -273,7 +273,7 @@ .primary-amount { color: #333; - font-family: 'ProximaNova-Semibold'; + font-weight: bold; input, .unit, .primary-amount-display { font-size: 1.8em; @@ -537,11 +537,12 @@ .button-primary { background-color: $v-primary-color; border-radius: 0; - font-family: 'ProximaNova-Semibold'; + font-weight: bold; } .button-primary[disabled] { background-color: $v-button-primary-disabled-bg; + opacity: 1; } } From 71a31ce39954c1ec1d245f612ec0420196a5a649 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 31 Jul 2018 13:25:56 +1200 Subject: [PATCH 184/386] Available funds now accurately reflects the primary currency choice. --- src/js/controllers/amount.js | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 3cf93b4c9..070dc5e9b 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -671,21 +671,21 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i }; function updateAvailableFundsStringIfNeeded() { - console.log('updateAvailableFundsStringIfNeeded()'); if (vm.fromWalletId && availableSatoshis !== null) { - console.log('updating'); availableFundsInFiat = ''; vm.availableFunds = availableFundsInCrypto; var coin = availableUnits[altUnitIndex].isFiat ? availableUnits[unitIndex].id : availableUnits[altUnitIndex].id; txFormatService.formatAlternativeStr(coin, availableSatoshis, function formatCallback(formatted){ - console.log('txFormatService returned'); if (formatted) { availableFundsInFiat = formatted; - if (availableUnits[unitIndex].isFiat) { - vm.availableFunds = availableFundsInFiat; - } else { - vm.availableFunds = availableFundsInCrypto; - } + + $scope.$apply(function() { + if (availableUnits[unitIndex].isFiat) { + vm.availableFunds = availableFundsInFiat; + } else { + vm.availableFunds = availableFundsInCrypto; + } + }); } }); } From 2353109adfbacad28f9ab8f1e0c1e158dd4b75e4 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 31 Jul 2018 17:59:26 +1200 Subject: [PATCH 185/386] Bugfix for font for insufficient funds warning. --- src/sass/views/amountNew.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sass/views/amountNew.scss b/src/sass/views/amountNew.scss index c0ce94c7a..8c8e771f7 100644 --- a/src/sass/views/amountNew.scss +++ b/src/sass/views/amountNew.scss @@ -249,7 +249,7 @@ min-height: 20px; .warning { - font-family: 'ProximaNova-Semibold'; + font-weight: bold; font-size: 12px; padding: 0 6px 6px 6px; text-align: center; From 778cbfbab0a9877be520b05226f093a8edf12a66 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 31 Jul 2018 19:16:11 +1200 Subject: [PATCH 186/386] Should have been part of merge for amount directive. --- src/sass/main.scss | 1 + 1 file changed, 1 insertion(+) diff --git a/src/sass/main.scss b/src/sass/main.scss index 7b3e46291..516656449 100644 --- a/src/sass/main.scss +++ b/src/sass/main.scss @@ -9,4 +9,5 @@ @import "mixins/mixins"; @import "views/views"; @import "directives/directives"; +@import "components/components"; @import "shame"; From 5a0c1417d47b1e38f8a479254e07a69caa29c903 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Tue, 31 Jul 2018 15:44:59 +0800 Subject: [PATCH 187/386] Prevents reassignment of bound attribute size-equal --- src/js/directives/amount.js | 2 +- www/views/includes/amount.html | 2 +- www/views/tab-home.html | 6 ++++++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/js/directives/amount.js b/src/js/directives/amount.js index a23069157..f991f0a28 100644 --- a/src/js/directives/amount.js +++ b/src/js/directives/amount.js @@ -23,7 +23,7 @@ angular.module('bitcoincom.directives') }, templateUrl: 'views/includes/amount.html', controller: ['$scope', function($scope) { - if (typeof $scope.sizeEqual == 'undefined') $scope.sizeEqual = false; + $scope.displaySizeEqual = typeof $scope.sizeEqual == 'undefined' ? false : true; var decimalPlaces = { '0': ['BIF', 'CLP', 'DJF', 'GNF', 'ILS', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'UGX', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'], diff --git a/www/views/includes/amount.html b/www/views/includes/amount.html index 4cf2807ad..361dededc 100644 --- a/www/views/includes/amount.html +++ b/www/views/includes/amount.html @@ -1,4 +1,4 @@
+ ng-class="{ 'size-equal': displaySizeEqual }"> {{start}}{{middle}}{{end}}{{currency}}
\ No newline at end of file diff --git a/www/views/tab-home.html b/www/views/tab-home.html index 8df176a56..77ecbfefe 100644 --- a/www/views/tab-home.html +++ b/www/views/tab-home.html @@ -21,6 +21,12 @@ Download
+
+ +
From 8dc1e060481e01d92f319bf66ac948b342273ff2 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Tue, 31 Jul 2018 15:46:12 +0800 Subject: [PATCH 188/386] Removes dummy values on home tab --- www/views/tab-home.html | 6 ------ 1 file changed, 6 deletions(-) diff --git a/www/views/tab-home.html b/www/views/tab-home.html index 77ecbfefe..8df176a56 100644 --- a/www/views/tab-home.html +++ b/www/views/tab-home.html @@ -21,12 +21,6 @@ Download
-
- -
From 02f7bcc2812f323fcf39363328e8f77c2d7a4087 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 31 Jul 2018 20:18:27 +1200 Subject: [PATCH 189/386] Not using amount directive. Removed safety area below All Available Funds button. --- src/js/controllers/amount.js | 49 ++++++++++++++++++----------------- src/sass/views/amountNew.scss | 1 - www/views/amountNew.html | 4 +-- 3 files changed, 27 insertions(+), 27 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 070dc5e9b..c50a949a0 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -9,13 +9,14 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i vm.altCurrencyList = []; vm.alternativeAmount = ''; vm.alternativeUnit = ''; - vm.amountModel = { amount: 0 }; + vm.amount = '0'; vm.availableFunds = ''; vm.fromWalletId = ''; // Use insufficient for logic, as when the amount is invalid, funds being // either sufficent or insufficient doesn't make sense. vm.fundsAreInsufficient = false; vm.globalResult = ''; + vm.hello = 'hi'; vm.isRequestingSpecificAmount = false; vm.listComplete = false; vm.lastUsedPopularList = []; @@ -77,9 +78,9 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i } function onBeforeEnter(event, data) { - + initCurrencies(); - + vm.hello = 'greetings'; if (data.stateParams.shapeshiftOrderId && data.stateParams.shapeshiftOrderId.length > 0) { vm.minShapeshiftAmount = parseFloat(data.stateParams.minShapeshiftAmount); vm.maxShapeshiftAmount = parseFloat(data.stateParams.maxShapeshiftAmount); @@ -159,7 +160,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i // in SAT ALWAYS if ($stateParams.toAmount) { - vm.amountModel.amount = (($stateParams.toAmount) * satToUnit).toFixed(unitDecimals); + vm.amount = (($stateParams.toAmount) * satToUnit).toFixed(unitDecimals); } processAmount(); @@ -271,7 +272,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i } function paste(value) { - vm.amountModel.amount = value; + vm.amount = value; processAmount(); $timeout(function() { $scope.$apply(); @@ -299,7 +300,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i function changeUnit() { - vm.amountModel.amount = '0'; + vm.amount = '0'; if (fixedUnit) return; @@ -321,32 +322,32 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i }; function pushDigit(digit) { - if (vm.amountModel.amount && digit != '.') { - var amountSplitByComma = vm.amountModel.amount.split('.'); + if (vm.amount && digit != '.') { + var amountSplitByComma = vm.amount.split('.'); if (amountSplitByComma.length > 1 && amountSplitByComma[1].length >= LENGTH_AFTER_COMMA_EXPRESSION_LIMIT) return; if (amountSplitByComma.length == 1 && amountSplitByComma[0].length >= LENGTH_BEFORE_COMMA_EXPRESSION_LIMIT) return; } - if (vm.amountModel.amount && vm.amountModel.amount.length >= LENGTH_EXPRESSION_LIMIT) return; - if (vm.amountModel.amount.indexOf('.') > -1 && digit == '.') return; - if (vm.amountModel.amount == '0' && digit == '0') return; - if (availableUnits[unitIndex].isFiat && vm.amountModel.amount.indexOf('.') > -1 && vm.amountModel.amount[vm.amountModel.amount.indexOf('.') + 2]) return; + if (vm.amount && vm.amount.length >= LENGTH_EXPRESSION_LIMIT) return; + if (vm.amount.indexOf('.') > -1 && digit == '.') return; + if (vm.amount == '0' && digit == '0') return; + if (availableUnits[unitIndex].isFiat && vm.amount.indexOf('.') > -1 && vm.amount[vm.amount.indexOf('.') + 2]) return; - if (vm.amountModel.amount == '0' && digit != '.') { - vm.amountModel.amount = ''; + if (vm.amount == '0' && digit != '.') { + vm.amount = ''; } - if (vm.amountModel.amount == '' && digit == '.') { - vm.amountModel.amount = '0'; + if (vm.amount == '' && digit == '.') { + vm.amount = '0'; } - vm.amountModel.amount = (vm.amountModel.amount + digit).replace('..', '.'); + vm.amount = (vm.amount + digit).replace('..', '.'); processAmount(); }; function pushOperator(operator) { - if (!vm.amountModel.amount || vm.amountModel.amount.length == 0) return; - vm.amountModel.amount = pushOperator(vm.amountModel.amount); + if (!vm.amount || vm.amount.length == 0) return; + vm.amount = pushOperator(vm.amount); function pushOperator(val) { if (!isOperator(lodash.last(val))) { @@ -368,12 +369,12 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i }; function removeDigit() { - vm.amountModel.amount = (vm.amountModel.amount).toString().slice(0, -1); + vm.amount = (vm.amount).toString().slice(0, -1); processAmount(); } function resetAmount() { - vm.amountModel.amount = vm.alternativeAmount = vm.globalResult = ''; + vm.amount = vm.alternativeAmount = vm.globalResult = '0'; vm.allowSend = false; } @@ -393,11 +394,11 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i }; function processAmount() { - var formatedValue = format(vm.amountModel.amount); + var formatedValue = format(vm.amount); var result = evaluate(formatedValue); if (lodash.isNumber(result)) { - vm.globalResult = isExpression(vm.amountModel.amount) ? '= ' + processResult(result) : ''; + vm.globalResult = isExpression(vm.amount) ? '= ' + processResult(result) : ''; if (availableUnits[unitIndex].isFiat) { @@ -481,7 +482,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i function finish() { var unit = availableUnits[unitIndex]; - var _amount = evaluate(format(vm.amountModel.amount)); + var _amount = evaluate(format(vm.amount)); var coin = unit.id; if (unit.isFiat) { coin = availableUnits[altUnitIndex].id; diff --git a/src/sass/views/amountNew.scss b/src/sass/views/amountNew.scss index 8c8e771f7..24338fe99 100644 --- a/src/sass/views/amountNew.scss +++ b/src/sass/views/amountNew.scss @@ -462,7 +462,6 @@ border-radius: 0; font-size: 0.8em; line-height: 2em; - margin-bottom: 1.618em; width: 100%; .available-funds-amount { diff --git a/www/views/amountNew.html b/www/views/amountNew.html index b67757f5e..e0296219a 100644 --- a/www/views/amountNew.html +++ b/www/views/amountNew.html @@ -19,8 +19,8 @@
- {{ vm.amountModel.amount || 0 }}{{vm.unit}} + ng-class="{long: vm.amount.length > 5, 'very-long': vm.amount.length > 10}"> + {{vm.amount}} {{vm.unit}}
{{vm.globalResult}} {{vm.unit}}
From 1895e0dbeb3fbee50bb2e7141d1d2b26edabd260 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Tue, 31 Jul 2018 16:23:45 +0800 Subject: [PATCH 190/386] Adds watcher for changes to value or currency scope variables --- src/js/directives/amount.js | 65 ++++++++++++++++++++----------------- 1 file changed, 36 insertions(+), 29 deletions(-) diff --git a/src/js/directives/amount.js b/src/js/directives/amount.js index f991f0a28..9622ca09d 100644 --- a/src/js/directives/amount.js +++ b/src/js/directives/amount.js @@ -48,37 +48,44 @@ angular.module('bitcoincom.directives') return '2'; }; - switch (getDecimalPlaces($scope.currency)) { - case '0': - var valueFormatted = numberWithCommas(Math.round(parseFloat($scope.value))); - buildAmount(valueFormatted, '', ''); - break; - - case '2': - var valueProcessing = parseFloat(parseFloat($scope.value).toFixed(2)); - var valueFormatted = numberWithCommas(valueProcessing); - buildAmount(valueFormatted, '', ''); - break; - - case '3': - var valueProcessing = parseFloat(parseFloat($scope.value).toFixed(3)); - var valueFormatted = numberWithCommas(valueProcessing); - buildAmount(valueFormatted, '', ''); - break; - - case '8': - var valueFormatted = parseFloat($scope.value).toFixed(8); - if (parseFloat($scope.value) == 0) { - buildAmount('0', '', ''); - } else { + var formatNumbers = function(currency, value) { + switch (getDecimalPlaces(currency)) { + case '0': + var valueFormatted = numberWithCommas(Math.round(parseFloat(value))); buildAmount(valueFormatted, '', ''); - var start = numberWithCommas(valueFormatted.slice(0, -5)); - var middle = valueFormatted.slice(-5, -2); - var end = valueFormatted.substr(valueFormatted.length - 2); - buildAmount(start, middle, end); - } - break; + break; + + case '2': + var valueProcessing = parseFloat(parseFloat(value).toFixed(2)); + var valueFormatted = numberWithCommas(valueProcessing); + buildAmount(valueFormatted, '', ''); + break; + + case '3': + var valueProcessing = parseFloat(parseFloat(value).toFixed(3)); + var valueFormatted = numberWithCommas(valueProcessing); + buildAmount(valueFormatted, '', ''); + break; + + case '8': + var valueFormatted = parseFloat(value).toFixed(8); + if (parseFloat(value) == 0) { + buildAmount('0', '', ''); + } else { + buildAmount(valueFormatted, '', ''); + var start = numberWithCommas(valueFormatted.slice(0, -5)); + var middle = valueFormatted.slice(-5, -2); + var end = valueFormatted.substr(valueFormatted.length - 2); + buildAmount(start, middle, end); + } + break; + } } + + formatNumbers($scope.currency, $scope.value); + $scope.$watchGroup(['currency', 'value'], function() { + formatNumbers($scope.currency, $scope.value); + }); }] }; } From 0cba978d6539574e9a75098b6a94b2c596e36462 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 31 Jul 2018 20:25:21 +1200 Subject: [PATCH 191/386] Replaced old amount screen. --- src/js/routes.js | 4 +- src/sass/views/amount.scss | 158 +++++++--- src/sass/views/amountNew.scss | 557 ---------------------------------- src/sass/views/views.scss | 1 - www/views/amount.html | 63 ++-- www/views/amountNew.html | 102 ------- 6 files changed, 158 insertions(+), 727 deletions(-) delete mode 100644 src/sass/views/amountNew.scss delete mode 100644 www/views/amountNew.html diff --git a/src/js/routes.js b/src/js/routes.js index 5b0b59d77..286b27ab1 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -292,7 +292,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr 'tab-send@tabs': { controller: 'amountController', controllerAs: 'vm', - templateUrl: 'views/amountNew.html' + templateUrl: 'views/amount.html' } } }) @@ -701,7 +701,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr 'tab-receive@tabs': { controller: 'amountController', controllerAs: 'vm', - templateUrl: 'views/amountNew.html' + templateUrl: 'views/amount.html' } } }) diff --git a/src/sass/views/amount.scss b/src/sass/views/amount.scss index c712d85e5..daf6cf4fe 100644 --- a/src/sass/views/amount.scss +++ b/src/sass/views/amount.scss @@ -244,6 +244,18 @@ flex-direction: column; justify-content: center; + .send-amount-header-footer { + flex: 1 1 auto; + min-height: 20px; + + .warning { + font-weight: bold; + font-size: 12px; + padding: 0 6px 6px 6px; + text-align: center; + } + } + .send-amount-tool { flex: 0 1 auto; @@ -260,6 +272,8 @@ } .primary-amount { + color: #333; + font-weight: bold; input, .unit, .primary-amount-display { font-size: 1.8em; @@ -329,16 +343,15 @@ line-height: 1em; } - .unit { - font-weight: bold; - } - .primary-amount-display { margin-right: 5px; word-break: break-all; } } + .alternative-amount { + color: #6F6F70; + } .switch-currencies { position: absolute; right: 0; @@ -351,27 +364,56 @@ } } } + } + } - .send-amount-actions { - margin-top: 15px; + .send-amount-extras { + display: flex; + flex: 0 0 auto; + /* So that if only one item is present, it appears on the right. */ + flex-direction: row-reverse; + font-size: 12px; + align-items: center; + justify-content: space-between; + margin: 0 14px; + + .available-funds { + color: #6F6F70; + } + + .warning { + color: $v-warning-color-2; + } + + .extra, + button.extra { + /*display: flex;*/ + flex: 0 1 auto; + } + + button.extra { + background: none; + border: none; + color: #000; + font-family: 'ProximaNova'; + font-size: 14px; + line-height: normal; + min-height: auto; + min-width: auto; + padding: 0; + } + + .button .icon:before { + font-size: 14px; + line-height: normal; + } + + + .button { + span { display: flex; align-items: center; justify-content: center; - - .button { - flex: 1 1 auto; - line-height: 1.2em; - - + .button { - margin-left: 10px; - } - - span { - display: flex; - align-items: center; - justify-content: center; - } - } } } } @@ -394,37 +436,58 @@ .keypad-container { position: relative; + font-size: 18px; + line-height: 2em; //flex: 0 1 196px; + @media (min-height: 667px) { + font-size: 24px; + } + + @media(max-height: 480px) { + font-size: 12px; + } + @media (min-height: 667px) { //flex: 0 1 224px; } + .sendmax { + background: $v-off-black; + + .button { + color: white; + background: black; + border: 1px solid $v-off-black; + border-radius: 0; + font-size: 0.8em; + line-height: 2em; + width: 100%; + + .available-funds-amount { + color: #C9C9C9; + } + + &:active { + background-color: $v-dark-gray; + } + } + } + .keypad { text-align: center; - font-size: 18px; font-weight: lighter; position: absolute; bottom: 0; width: 100%; - color: $v-mid-gray; + color: $v-text-primary-color; + - @media (min-height: 667px) { - font-size: 24px; - } .row { padding: 0 !important; margin: 0 !important; } - - .col { - line-height: 38px; - - @media (min-height: 667px) { - line-height: 45px; - } - } .row { &:last-child { @@ -458,23 +521,34 @@ .digit{ cursor: pointer; - border-top: 1px solid $v-subtle-gray; - border-left: 1px solid $v-subtle-gray; + background-color: #000; + border: 1px solid $v-off-black; transition: all 0.1s ease; &:active { - background-color: $v-subtle-gray; + background-color: $v-dark-gray; } } - @media(max-height: 480px) { - font-size: 12px; - - } } } + + .button-primary { + background-color: $v-primary-color; + border-radius: 0; + font-weight: bold; + } + + .button-primary[disabled] { + background-color: $v-button-primary-disabled-bg; + opacity: 1; + } } - background: #494949; + + .warning { + color: $v-warning-color-2; + } + background: $v-background-under-card; ion-content { margin-bottom: constant(safe-area-inset-bottom); /* iOS 11.0 */ diff --git a/src/sass/views/amountNew.scss b/src/sass/views/amountNew.scss deleted file mode 100644 index 24338fe99..000000000 --- a/src/sass/views/amountNew.scss +++ /dev/null @@ -1,557 +0,0 @@ -#view-amount-new { - @extend .deflash-blue; - .recipient-label { - font-size: 14px; - padding-bottom: 0; - color: $v-mid-gray; - } - .item-no-bottom-border + .item { - border-top: 0; - } - .icon-bitpay-card { - background-image: url("../img/icon-bitpay.svg"); - } - .icon-amazon { - background-image: url("../img/icon-amazon.svg"); - } - @media(max-width: 480px) { - .bitcoin-address { - .icon { - left: 8px; - font-size: 24px; - } - .big-icon-svg { - left:5px; - & > .bg{ - width:30px; - height:30px; - box-shadow: none; - } - } - font-size: 13px; - padding-left: 48px; - } - } - @media(max-width: 320px) { - .bitcoin-address { - & > span:last-child { - margin-left: -2px; - } - } - } - .send-gravatar { - left: 11px; - position: absolute; - top: 10px; - } - .amount span input { - display: inline; - width: 120px; - } - .amount-pane-recipient { - position: absolute; - top: 95px; - bottom: 0; - width: 100%; - background-color: #fff; - padding: 0 16px; - - .amount-bar { - padding: 24px 0; - font-size: 18px; - @media(max-height: 480px) { - padding: 0px; - } - @media(max-width: 320px) { - padding: 0px; - } - .title { - float: left; - padding-top: 10px; - color: $v-dark-gray; - font-weight: bold; - @media(max-height: 480px) { - padding: 0px; - } - } - @media(max-height: 480px) { - padding-top: 3px; - } - } - .amount { - display: flex; - flex-direction: column; - justify-content: center; - flex-grow: 1; - position: absolute; - bottom: 254px; - top: 66px; - .light { - color: $v-light-gray; - } - @media(max-height: 480px) { - top: 45px; - } - @media(max-width: 320px) { - bottom: 276px; - top: 60px; - & > div { - display: inline-block; - } - & > div:first-child { - display: inherit; - } - } - } - } - .amount-pane-no-recipient { - position: absolute; - top: 0; - bottom: 0; - width: 100%; - background-color: #fff; - padding: 0 16px; - - .amount-bar { - padding: 24px 0; - font-size: 18px; - .title { - padding-top: 10px; - color: $v-dark-gray; - font-weight: bold; - .limits { - margin-top: 10px; - color: $v-light-gray; - font-size: 12px; - } - .select { - margin: 10px 1px; - } - } - } - .amount { - display: flex; - flex-direction: column; - justify-content: center; - flex-grow: 1; - position: absolute; - bottom: 254px; - top: 66px; - .light { - color: $v-light-gray; - } - } - } - .amount { - padding-top: 10px; - padding-bottom: 10px; - .icon-toggle { - font-size: 1.2em; - width: auto; - margin: 0.8em auto; - border: 1px solid $v-subtle-gray; - color: $v-dark-gray; - border-radius: 3px; - padding: 0 10px; - cursor: pointer; - @media(max-height: 280px) { - margin: 0.1em auto; - } - } - &__editable { - &--minimize { - font-size: 22px; - } - &--standard { - font-size: 42px; - @media(max-height: 480px) { - font-size: 26px; - padding-top: 10px; - } - } - &--placeholder { - color: $v-light-gray; - } - } - &__number { - color: $v-dark-gray; - } - &__currency-toggle { - border: 1px solid $v-subtle-gray; - color: $v-dark-gray; - border-radius: 3px; - padding: 0 10px; - cursor: pointer; - font-size: .6em; - position: relative; - top: -3px; - line-height: 1; - @media(max-width: 320px) { - line-height: 30px; - height: 30px; - } - } - &__currency-toggle-mobile { - border: 1px solid $v-subtle-gray; - color: $v-dark-gray; - border-radius: 3px; - cursor: pointer; - position: relative; - line-height: 1; - @media(max-width: 320px) { - line-height: 30px; - height: 30px; - } - } - &__results { - &--minimize { - font-size: 12px; - } - &--standard { - font-size: 18px; - padding: 10px 0; - } - &--placeholder { - color: $v-light-gray; - } - } - &__result { - color: $v-light-gray; - font-size: .9em; - //margin-bottom: -.9em; TODO matias - line-height: 1; - @media(max-height: 480px) { - margin-bottom: 0; - } - } - &__result-equiv { - color: $v-mid-gray; - font-size: 1.2em; - @media(max-height: 480px) { - margin-top: 0; - font-size: 16px; - } - } - } - - .scroll-content { - display: flex; - flex-direction: column; - - .send-amount { - flex: 1 1 auto; - display: flex; - flex-direction: column; - justify-content: center; - - .send-amount-header-footer { - flex: 1 1 auto; - min-height: 20px; - - .warning { - font-weight: bold; - font-size: 12px; - padding: 0 6px 6px 6px; - text-align: center; - } - } - - .send-amount-tool { - flex: 0 1 auto; - - .send-amount-tool-input { - text-align: center; - position: relative; - padding: 10px 30px; - - .text-selectable { - -webkit-user-select: text; - -moz-user-select: text; - -ms-user-select: text; - user-select: text; - } - - .primary-amount { - color: #333; - font-weight: bold; - input, .unit, .primary-amount-display { - font-size: 1.8em; - - @media (min-width: 375px) { - font-size: 2.1em; - } - - @media (min-width: 414px) { - font-size: 2.4em; - } - } - - &.long { - input, .unit, .primary-amount-display { - font-size: 1.6em; - - @media (min-width: 375px) { - font-size: 1.8em; - } - - @media (min-width: 414px) { - font-size: 2em; - } - } - } - - &.very-long { - input, .unit, .primary-amount-display { - font-size: 0.9em; - - @media (min-width: 375px) { - font-size: 1.3em; - } - - @media (min-width: 414px) { - font-size: 1.4em; - } - } - } - - - input { - border:0; - padding:0; - white-space:normal; - background:none; - line-height:1; - box-sizing:content-box; - display: inline-block; - vertical-align: middle; - margin: 0; - height: 1em; - margin-right: 5px; - font-family: 'ProximaNova'; - - @media (min-width: 375px) { - } - - @media (min-width: 414px) { - } - } - - .unit, - .primary-amount-display { - display: inline-block; - vertical-align: middle; - line-height: 1em; - } - - .primary-amount-display { - margin-right: 5px; - word-break: break-all; - } - } - - .alternative-amount { - color: #6F6F70; - } - .switch-currencies { - position: absolute; - right: 0; - top: 50%; - transform: translate(0, -50%); - padding: 15px; - - img { - width: 18px; - } - } - } - } - } - - .send-amount-extras { - display: flex; - flex: 0 0 auto; - /* So that if only one item is present, it appears on the right. */ - flex-direction: row-reverse; - font-size: 12px; - align-items: center; - justify-content: space-between; - margin: 0 14px; - - .available-funds { - color: #6F6F70; - } - - .warning { - color: $v-warning-color-2; - } - - .extra, - button.extra { - /*display: flex;*/ - flex: 0 1 auto; - } - - button.extra { - background: none; - border: none; - color: #000; - font-family: 'ProximaNova'; - font-size: 14px; - line-height: normal; - min-height: auto; - min-width: auto; - padding: 0; - } - - .button .icon:before { - font-size: 14px; - line-height: normal; - } - - - .button { - span { - display: flex; - align-items: center; - justify-content: center; - } - } - } - - .button { - &.no-margin { - margin: 0; - } - } - - .notification-warning { - display: block; - padding: .75rem 1.25rem; - color: #856404; - background-color: #fff3cd; - border: 1px solid #ffeeba; - line-height: 1.4em; - margin-bottom: 20px; - } - - .keypad-container { - position: relative; - font-size: 18px; - line-height: 2em; - //flex: 0 1 196px; - - @media (min-height: 667px) { - font-size: 24px; - } - - @media(max-height: 480px) { - font-size: 12px; - } - - @media (min-height: 667px) { - //flex: 0 1 224px; - } - - .sendmax { - background: $v-off-black; - - .button { - color: white; - background: black; - border: 1px solid $v-off-black; - border-radius: 0; - font-size: 0.8em; - line-height: 2em; - width: 100%; - - .available-funds-amount { - color: #C9C9C9; - } - - &:active { - background-color: $v-dark-gray; - } - } - } - - .keypad { - text-align: center; - font-weight: lighter; - position: absolute; - bottom: 0; - width: 100%; - color: $v-text-primary-color; - - - - .row { - padding: 0 !important; - margin: 0 !important; - } - - .row { - &:last-child { - .col { - padding-bottom: 10px; - } - } - } - - .operator { - background-color: $v-subtle-gray; - font-weight: normal; - cursor: pointer; - - &:active { - background-color: $v-light-gray; - } - } - - .operator-send { - font-weight: bolder; - color: #fff; - background-color: $positive; - font-size: 36px; - cursor: pointer; - - &:active { - background-color: #eaeaea; - } - } - - .digit{ - cursor: pointer; - background-color: #000; - border: 1px solid $v-off-black; - transition: all 0.1s ease; - - &:active { - background-color: $v-dark-gray; - } - } - - } - } - - .button-primary { - background-color: $v-primary-color; - border-radius: 0; - font-weight: bold; - } - - .button-primary[disabled] { - background-color: $v-button-primary-disabled-bg; - opacity: 1; - } - } - - .warning { - color: $v-warning-color-2; - } - background: $v-background-under-card; - - ion-content { - margin-bottom: constant(safe-area-inset-bottom); /* iOS 11.0 */ - margin-bottom: env(safe-area-inset-bottom); /* iOS 11.2 */ - } -} \ No newline at end of file diff --git a/src/sass/views/views.scss b/src/sass/views/views.scss index 387b68597..d4ed735ed 100644 --- a/src/sass/views/views.scss +++ b/src/sass/views/views.scss @@ -1,7 +1,6 @@ @import "tabs"; @import "add"; @import "amount"; -@import "amountNew"; @import "confirm"; @import "copayers"; @import "starting"; diff --git a/www/views/amount.html b/www/views/amount.html index 90187ef59..77c52f96c 100644 --- a/www/views/amount.html +++ b/www/views/amount.html @@ -1,24 +1,26 @@ - {{'Enter amount' | translate}} + {{'Enter Amount' | translate}} - +
-
-
- Minimum amount: {{vm.minShapeshiftAmount}}
- Maximum amount: {{vm.maxShapeshiftAmount}}
+
+
- {{ vm.amountModel.amount || 0 }}{{vm.unit}} + ng-class="{long: vm.amount.length > 5, 'very-long': vm.amount.length > 10}"> + {{vm.amount}} {{vm.unit}}
{{vm.globalResult}} {{vm.unit}}
@@ -26,26 +28,41 @@
-
- - + -
+
+
+ +
+ +
+ Available Funds:{{vm.availableFunds}} +
-
+
+ +
+ +
7
diff --git a/www/views/amountNew.html b/www/views/amountNew.html deleted file mode 100644 index e0296219a..000000000 --- a/www/views/amountNew.html +++ /dev/null @@ -1,102 +0,0 @@ - - - - {{'Enter Amount' | translate}} - - - - - -
- -
- -
-
-
- {{vm.amount}} {{vm.unit}} -
- {{vm.globalResult}} {{vm.unit}} -
- {{vm.alternativeAmount || '0.00'}} {{vm.alternativeUnit}} -
-
-
- -
-
- -
- -
- Available Funds:{{vm.availableFunds}} -
-
-
- -
-
- -
- -
- -
-
7
-
8
-
9
-
- -
-
4
-
5
-
6
-
- -
-
1
-
2
-
3
-
- -
-
.
-
0
-
-
-
-
- - -
-
\ No newline at end of file From 281b969fc325f97e7ed287086960338fbc1ada07 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 31 Jul 2018 15:03:20 +0200 Subject: [PATCH 192/386] Shapeshift refactor / Empty case / CSS --- i18n/po/template.pot | 4 + src/js/controllers/shapeshift.js | 102 +++++---- ...troller.js => walletSelectorController.js} | 2 +- src/js/routes.js | 6 +- src/sass/mixins/layout.scss | 39 ++++ src/sass/views/shapeshift.scss | 14 ++ src/sass/views/tab-send.scss | 37 +--- src/sass/views/views.scss | 1 + www/views/shapeshift.html | 206 ++++++++++-------- 9 files changed, 230 insertions(+), 181 deletions(-) rename src/js/controllers/{sendFlowController.js => walletSelectorController.js} (94%) create mode 100644 src/sass/views/shapeshift.scss diff --git a/i18n/po/template.pot b/i18n/po/template.pot index df01cecec..10656ae42 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -3112,6 +3112,10 @@ msgstr "" msgid "Top up {{amountStr}} to debit card ({{cardLastNumber}})" msgstr "" +#: www/views/shapeshift.html:30 +msgid "Start ShapeShift" +msgstr "" + #: www/views/buyAmazon.html:61 #: www/views/buyMercadoLibre.html:60 #: www/views/modals/wallet-balance.html:23 diff --git a/src/js/controllers/shapeshift.js b/src/js/controllers/shapeshift.js index 5bc815d19..8e991c5b4 100644 --- a/src/js/controllers/shapeshift.js +++ b/src/js/controllers/shapeshift.js @@ -1,10 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('shapeshiftController', function($scope, $interval, profileService, walletService, popupService, lodash, $ionicNavBarDelegate) { - var vm = this; - - //vm.buyBitcion = buyBitcoin; - +angular.module('copayApp.controllers').controller('shapeshiftController', function($scope, $state, $interval, profileService, walletService, popupService, lodash, $ionicNavBarDelegate) { var walletsBtc = []; var walletsBch = []; @@ -19,59 +15,51 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi } function showToWallets() { - $scope.toWallets = $scope.fromWallet.coin == 'btc' ? walletsBch : walletsBtc; + $scope.toWallets = $scope.fromWallet.coin === 'btc' ? walletsBch : walletsBtc; $scope.onToWalletSelect($scope.toWallets[0]); - $scope.singleToWallet = $scope.toWallets.length == 1; + $scope.singleToWallet = $scope.toWallets.length === 1; } - function buyBitcoin() { - console.log('buyBitcoin()'); - } - - $scope.buyBitcoin = buyBitcoin; - - $scope.onFromWalletSelect = function(wallet) { - $scope.fromWallet = wallet; - showToWallets(); - generateAddress(wallet, function(addr) { - $scope.fromWalletAddress = addr; - }); - }; - - $scope.onToWalletSelect = function(wallet) { - $scope.toWallet = wallet; - generateAddress(wallet, function(addr) { - $scope.toWalletAddress = addr; - }); - } + // $scope.onFromWalletSelect = function(wallet) { + // $scope.fromWallet = wallet; + // showToWallets(); + // generateAddress(wallet, function(addr) { + // $scope.fromWalletAddress = addr; + // }); + // }; + // + // $scope.onToWalletSelect = function(wallet) { + // $scope.toWallet = wallet; + // generateAddress(wallet, function(addr) { + // $scope.toWalletAddress = addr; + // }); + // }; $scope.$on("$ionicView.beforeEnter", function(event, data) { - console.log('beforeEnter()'); walletsBtc = profileService.getWallets({coin: 'btc'}); walletsBch = profileService.getWallets({coin: 'bch'}); $scope.fromWallets = lodash.filter(walletsBtc.concat(walletsBch), function(w) { return w.status.balance.availableAmount > 0; }); - console.log('Checking wallets.'); - if ($scope.fromWallets.length == 0) { - // Need to go to new origin screen here, with parameters - var params = { - thirdParty: { - id: 'shapeshift' - } - }; - console.log('Asking for transition'); - $state.transitionTo('tabs.send', params); - return - } - $scope.onFromWalletSelect($scope.fromWallets[0]); - $scope.onToWalletSelect($scope.toWallets[0]); - $scope.singleFromWallet = $scope.fromWallets.length == 1; - $scope.singleToWallet = $scope.toWallets.length == 1; + + if ($scope.fromWallets.length === 0) { + // return + // } else { + // $scope.onFromWalletSelect($scope.fromWallets[0]); + } + + // $scope.onToWalletSelect($scope.toWallets[0]); + + $scope.singleFromWallet = $scope.fromWallets.length === 1; + // $scope.singleToWallet = $scope.toWallets.length == 1; $scope.fromWalletSelectorTitle = 'From'; $scope.toWalletSelectorTitle = 'To'; $scope.showFromWallets = false; $scope.showToWallets = false; + $scope.walletsWithFunds = profileService.getWallets({onlyComplete: true, hasFunds: true}); + console.log($scope.walletsWithFunds); + $scope.wallets = profileService.getWallets({onlyComplete: true}); + $scope.hasWallets = !lodash.isEmpty($scope.wallets); }); $scope.$on("$ionicView.enter", function(event, data) { @@ -80,9 +68,33 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi $scope.showFromWalletSelector = function() { $scope.showFromWallets = true; - } + }; $scope.showToWalletSelector = function() { $scope.showToWallets = true; + }; + + // This could probably be enhanced refactoring the routes abstract states + $scope.createWallet = function() { + $state.go('tabs.home').then(function() { + $state.go('tabs.add.create-personal'); + }); + }; + + $scope.buyBitcoin = function() { + $state.go('tabs.home').then(function() { + $state.go('tabs.buyandsell'); + }); + }; + + $scope.shapeshift = function() { + var params = { + thirdParty: { + id: 'shapeshift' + } + }; + $state.go('tabs.home').then(function() { + $state.transitionTo('tabs.send', params); + }); } }); diff --git a/src/js/controllers/sendFlowController.js b/src/js/controllers/walletSelectorController.js similarity index 94% rename from src/js/controllers/sendFlowController.js rename to src/js/controllers/walletSelectorController.js index a6965bd96..7f5519452 100644 --- a/src/js/controllers/sendFlowController.js +++ b/src/js/controllers/walletSelectorController.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('sendFlowController', function($scope, $rootScope, $state, $stateParams, $log, $ionicHistory, configService, gettextCatalog, profileService) { +angular.module('copayApp.controllers').controller('walletSelectorController', function($scope, $rootScope, $state, $stateParams, $log, $ionicHistory, configService, gettextCatalog, profileService) { $scope.$on("$ionicView.beforeEnter", function(event, data) { var config = configService.getSync().wallet.settings; diff --git a/src/js/routes.js b/src/js/routes.js index 0fa92750e..f7641b545 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -299,7 +299,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr url: '/wallet-to-wallet', views: { 'tab-send@tabs': { - controller: 'sendFlowController', + controller: 'walletSelectorController', templateUrl: 'views/wallet-origin-destination.html' } } @@ -308,7 +308,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr url: '/origin/:thirdParty/:amount/:toAddress/:toWalletId/:coin', views: { 'tab-send@tabs': { - controller: 'sendFlowController', + controller: 'walletSelectorController', templateUrl: 'views/wallet-origin-destination.html', } } @@ -317,7 +317,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr url: '/destination/:thirdParty/:amount/:fromWalletId', views: { 'tab-send@tabs': { - controller: 'sendFlowController', + controller: 'walletSelectorController', templateUrl: 'views/wallet-origin-destination.html', } } diff --git a/src/sass/mixins/layout.scss b/src/sass/mixins/layout.scss index b03d53800..e03a735fa 100644 --- a/src/sass/mixins/layout.scss +++ b/src/sass/mixins/layout.scss @@ -18,3 +18,42 @@ .absolute-center{ @include absolute-center(); } + +@mixin empty-case() { + padding-top: 5vh; + text-align: center; + .item { + border-style: none; + } + & > .title { + font-size: 20px; + color: $v-dark-gray; + margin: 20px 10px; + } + & > .subtitle { + font-size: 1rem; + line-height: 1.5em; + font-weight: 300; + color: #6F6F70; + margin: 20px 1em 2.5em; + } + .big-icon-svg { + .bg.green { + padding: 0 10px; + box-shadow: none; + } + } + .buttons { + margin-top: 18px; + .button { + font-weight: bold; + font-size: 19px; + } + } + .button-first-contact img { + height: 19px; + width: 19px; + margin-right: 6px; + vertical-align: sub; + } +} \ No newline at end of file diff --git a/src/sass/views/shapeshift.scss b/src/sass/views/shapeshift.scss new file mode 100644 index 000000000..8b4b941ab --- /dev/null +++ b/src/sass/views/shapeshift.scss @@ -0,0 +1,14 @@ +#shapeshift { + .empty-case { + @include empty-case(); + } + .button-shapeshift { + @extend %button-standard; + + @include button-style(#243F5D, #FFF, #606060, #FFF, #FFF); + @include button-clear(#FFF); + @include button-outline(#C1C1C1); + border: 0px; + @include button-shadow(); + } +} \ No newline at end of file diff --git a/src/sass/views/tab-send.scss b/src/sass/views/tab-send.scss index a4025156f..4fbe8e531 100644 --- a/src/sass/views/tab-send.scss +++ b/src/sass/views/tab-send.scss @@ -133,42 +133,7 @@ padding-left: 30px; } .sendTip { - padding-top: 5vh; - text-align: center; - .item { - border-style: none; - } - & > .title { - font-size: 20px; - color: $v-dark-gray; - margin: 20px 10px; - } - & > .subtitle { - font-size: 1rem; - line-height: 1.5em; - font-weight: 300; - color: #6F6F70; - margin: 20px 1em 2.5em; - } - .big-icon-svg { - .bg.green { - padding: 0 10px; - box-shadow: none; - } - } - .buttons { - margin-top: 18px; - .button { - font-weight: bold; - font-size: 19px; - } - } - .button-first-contact img { - height: 19px; - width: 19px; - margin-right: 6px; - vertical-align: sub; - } + @include empty-case(); } .item-heading { line-height: 16px; diff --git a/src/sass/views/views.scss b/src/sass/views/views.scss index e1a122dbb..700a45b62 100644 --- a/src/sass/views/views.scss +++ b/src/sass/views/views.scss @@ -14,6 +14,7 @@ @import "walletBalance"; @import "walletDetails"; @import "advancedSettings"; +@import "shapeshift"; @import "bitpayCard"; @import "bitpayCardIntro"; @import "buyandsell"; diff --git a/www/views/shapeshift.html b/www/views/shapeshift.html index 48664ebba..6a0a0e4e2 100644 --- a/www/views/shapeshift.html +++ b/www/views/shapeshift.html @@ -1,4 +1,4 @@ - + {{'Shapeshift'|translate}} @@ -10,107 +10,121 @@
-
-
- No available wallets to convert between. - - +
+
+ Your Bitcoin wallet is empty +
+
+
+

Before exchanging your BTC to BCH, you will need to add funds to your wallet.

+

You can receive Bitcoin from any wallet or service.

+
+
+

Using Shapeshift will allow you to exchange your BTC for BCH.

+

The process is fast and you will receive the exchanged amount in your wallet.

+
+
To get started, you'll need to create a bitcoin wallet and get some bitcoin.
+
+ + + +
- - + + + + + + + + + + + + + + - - -
- - - - - -
+ + + + + + + + + + + + + + + + + + + + + + + + + - - + + + + + + + + - - - + + + + + + + + + From 42d77903e1dd02fe66d10bba16bc1dd2e433a14f Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 31 Jul 2018 17:21:56 +0200 Subject: [PATCH 193/386] Third Party Service integration (Shapeshift) (CSS + translations + wallet selector + routes) --- i18n/po/template.pot | 4 + src/js/controllers/shapeshift.js | 31 +--- .../controllers/walletSelectorController.js | 29 +++- src/js/routes.js | 8 +- src/js/services/incomingData.js | 33 ++-- src/sass/mixins/layout.scss | 11 ++ www/views/header-thirdparty.html | 3 + www/views/shapeshift.html | 148 +++++++++--------- ...n-destination.html => walletSelector.html} | 5 +- 9 files changed, 143 insertions(+), 129 deletions(-) create mode 100644 www/views/header-thirdparty.html rename www/views/{wallet-origin-destination.html => walletSelector.html} (90%) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index 10656ae42..4a53f4b7b 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -3116,6 +3116,10 @@ msgstr "" msgid "Start ShapeShift" msgstr "" +#: www/views/shapeshift.html:34 +msgid "This service is provided by the third-party ShapeShift, who will charge a small fee for the service. The fee will be shown before you start the transaction." +msgstr "" + #: www/views/buyAmazon.html:61 #: www/views/buyMercadoLibre.html:60 #: www/views/modals/wallet-balance.html:23 diff --git a/src/js/controllers/shapeshift.js b/src/js/controllers/shapeshift.js index 8e991c5b4..ade7afb5b 100644 --- a/src/js/controllers/shapeshift.js +++ b/src/js/controllers/shapeshift.js @@ -20,21 +20,6 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi $scope.singleToWallet = $scope.toWallets.length === 1; } - // $scope.onFromWalletSelect = function(wallet) { - // $scope.fromWallet = wallet; - // showToWallets(); - // generateAddress(wallet, function(addr) { - // $scope.fromWalletAddress = addr; - // }); - // }; - // - // $scope.onToWalletSelect = function(wallet) { - // $scope.toWallet = wallet; - // generateAddress(wallet, function(addr) { - // $scope.toWalletAddress = addr; - // }); - // }; - $scope.$on("$ionicView.beforeEnter", function(event, data) { walletsBtc = profileService.getWallets({coin: 'btc'}); walletsBch = profileService.getWallets({coin: 'bch'}); @@ -42,22 +27,12 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi return w.status.balance.availableAmount > 0; }); - if ($scope.fromWallets.length === 0) { - // return - // } else { - // $scope.onFromWalletSelect($scope.fromWallets[0]); - } - - // $scope.onToWalletSelect($scope.toWallets[0]); - $scope.singleFromWallet = $scope.fromWallets.length === 1; - // $scope.singleToWallet = $scope.toWallets.length == 1; $scope.fromWalletSelectorTitle = 'From'; $scope.toWalletSelectorTitle = 'To'; $scope.showFromWallets = false; $scope.showToWallets = false; $scope.walletsWithFunds = profileService.getWallets({onlyComplete: true, hasFunds: true}); - console.log($scope.walletsWithFunds); $scope.wallets = profileService.getWallets({onlyComplete: true}); $scope.hasWallets = !lodash.isEmpty($scope.wallets); }); @@ -89,12 +64,10 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi $scope.shapeshift = function() { var params = { - thirdParty: { - id: 'shapeshift' - } + thirdParty: JSON.stringify({id: 'shapeshift'}) }; $state.go('tabs.home').then(function() { - $state.transitionTo('tabs.send', params); + $state.transitionTo('tabs.send.origin', params); }); } }); diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index 7f5519452..4f0533084 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -1,16 +1,16 @@ 'use strict'; -angular.module('copayApp.controllers').controller('walletSelectorController', function($scope, $rootScope, $state, $stateParams, $log, $ionicHistory, configService, gettextCatalog, profileService) { +angular.module('copayApp.controllers').controller('walletSelectorController', function($scope, $rootScope, $state, $log, $ionicHistory, configService, gettextCatalog, profileService) { $scope.$on("$ionicView.beforeEnter", function(event, data) { var config = configService.getSync().wallet.settings; - $scope.sendFlowTitle = ""; + $scope.sendFlowTitle = ""; if ($state.current.name === 'tabs.send.wallet-to-wallet') { $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); } - $scope.params = $stateParams; + $scope.params = $state.params; $scope.coin = false; // Wallets to show (for destination screen or contacts) $scope.type = data.stateParams && data.stateParams['fromWalletId'] ? 'destination' : 'origin'; // origin || destination @@ -21,14 +21,11 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu if ($scope.params.amount) { // There is an amount, so presume that it a payment request $scope.sendFlowTitle = gettextCatalog.getString('Payment request'); $scope.specificAmount = $scope.specificAlternativeAmount = ''; - $scope.requestAmount = (($stateParams.amount) * (1 / config.unitToSatoshi)).toFixed(config.unitDecimals); + $scope.requestAmount = (($state.params.amount) * (1 / config.unitToSatoshi)).toFixed(config.unitDecimals); $scope.isPaymentRequest = true; } if ($scope.params.thirdParty) { - // Third Party Service - if ($scope.params.thirdParty.id === 'shapeshift') { - - } + $scope.thirdParty = JSON.parse($scope.params.thirdParty); // Parse stringified JSON-object } }); @@ -48,6 +45,19 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send to'); } + if ($scope.thirdParty) { + + // Third party services specific logic + + if ($scope.thirdParty.id === 'shapeshift' && $scope.type === 'destination') { // Shapeshift wants to know the + if ($scope.coin === 'bch') { + $scope.coin = 'btc'; + } else { + $scope.coin = 'bch'; + } + } + } + if (!$scope.coin || $scope.coin === 'bch') { // if no specific coin is set or coin is set to bch $scope.walletsBch = profileService.getWallets({coin: 'bch', hasFunds: $scope.type==='origin'}); } @@ -57,6 +67,9 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu }); function getNextStep() { + if ($scope.thirdParty) { + $scope.params.thirdParty = JSON.stringify($scope.thirdParty) // re-stringify JSON-object + } if (!$scope.params.toWalletId && !$scope.params.toAddress) { // If we have no toAddress or fromWallet return 'tabs.send.destination'; } else if (!$scope.params.amount) { // If we have no amount diff --git a/src/js/routes.js b/src/js/routes.js index f7641b545..54f481783 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -300,7 +300,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr views: { 'tab-send@tabs': { controller: 'walletSelectorController', - templateUrl: 'views/wallet-origin-destination.html' + templateUrl: 'views/walletSelector.html' } } }) @@ -309,7 +309,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr views: { 'tab-send@tabs': { controller: 'walletSelectorController', - templateUrl: 'views/wallet-origin-destination.html', + templateUrl: 'views/walletSelector.html', } } }) @@ -318,7 +318,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr views: { 'tab-send@tabs': { controller: 'walletSelectorController', - templateUrl: 'views/wallet-origin-destination.html', + templateUrl: 'views/walletSelector.html', } } }) @@ -995,7 +995,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr /* Shapeshift */ .state('tabs.shapeshift', { - url: '/shapeshift', + url: '/shapeshift/:fromWalletId/:toWalletId', views: { 'tab-home@tabs': { controller: 'shapeshiftController', diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index e12cc2255..7a9e67fe7 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -8,7 +8,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat $rootScope.$broadcast('incomingDataMenu.showMenu', data); }; - root.redir = function(data, shapeshiftData) { + root.redir = function(data, serviceId, serviceData) { var originalAddress = null; var noPrefixInAddress = 0; @@ -75,7 +75,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat return true; } - function goSend(addr, amount, message, coin, shapeshiftData) { + function goSend(addr, amount, message, coin, serviceId, serviceData) { $state.go('tabs.send', {}, { 'reload': true, 'notify': $state.current.name == 'tabs.send' ? false : true @@ -97,11 +97,18 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat displayAddress: originalAddress ? originalAddress : addr, noPrefix: noPrefixInAddress }; - if (shapeshiftData) { - params['fromWalletId'] = shapeshiftData.fromWalletId; - params['minShapeshiftAmount'] = shapeshiftData.minAmount; - params['maxShapeshiftAmount'] = shapeshiftData.maxAmount; - params['shapeshiftOrderId'] = shapeshiftData.orderId; + if (serviceId) { + if (!params['thirdParty']) { + params['thirdParty'] = []; + } + params['thirdParty']['id'] = serviceId; + } + + if (serviceData) { + params['thirdParty']['data'] = serviceData; + // params['thirdParty']['minShapeshiftAmount'] = serviceData.minAmount; + // params['thirdParty']['maxShapeshiftAmount'] = serviceData.maxAmount; + // params['thirdParty']['shapeshiftOrderId'] = serviceData.orderId; $state.transitionTo('tabs.send.amount', params); } else { $state.transitionTo('tabs.send.origin', params); @@ -148,12 +155,12 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat if (parsed.r) { payproService.getPayProDetails(parsed.r, coin, function(err, details) { if (err) { - if (addr && amount) goSend(addr, amount, message, coin, shapeshiftData); + if (addr && amount) goSend(addr, amount, message, coin, serviceId, serviceData); else popupService.showAlert(gettextCatalog.getString('Error'), err); } else handlePayPro(details, coin); }); } else { - goSend(addr, amount, message, coin, shapeshiftData); + goSend(addr, amount, message, coin, serviceId, serviceData); } return true; // Cash URI @@ -171,14 +178,14 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat payproService.getPayProDetails(parsed.r, coin, function(err, details) { if (err) { if (addr && amount) - goSend(addr, amount, message, coin, shapeshiftData); + goSend(addr, amount, message, coin, serviceId, serviceData); else popupService.showAlert(gettextCatalog.getString('Error'), err); } handlePayPro(details, coin); }); } else { - goSend(addr, amount, message, coin, shapeshiftData); + goSend(addr, amount, message, coin, serviceId, serviceData); } return true; @@ -214,14 +221,14 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat payproService.getPayProDetails(parsed.r, coin, function(err, details) { if (err) { if (addr && amount) - goSend(addr, amount, message, coin, shapeshiftData); + goSend(addr, amount, message, coin, serviceId, serviceData); else popupService.showAlert(gettextCatalog.getString('Error'), err); } handlePayPro(details, coin); }); } else { - goSend(addr, amount, message, coin, shapeshiftData); + goSend(addr, amount, message, coin, serviceId, serviceData); } } ); diff --git a/src/sass/mixins/layout.scss b/src/sass/mixins/layout.scss index e03a735fa..269a50320 100644 --- a/src/sass/mixins/layout.scss +++ b/src/sass/mixins/layout.scss @@ -19,6 +19,17 @@ @include absolute-center(); } +.third-party-notice { + font-size: 12px; + margin: 0px 14px; + font-weight: 600; + color: #6F6F70; + + @media (min-width: 768px) { + text-align: center; + } +} + @mixin empty-case() { padding-top: 5vh; text-align: center; diff --git a/www/views/header-thirdparty.html b/www/views/header-thirdparty.html new file mode 100644 index 000000000..7a6750a22 --- /dev/null +++ b/www/views/header-thirdparty.html @@ -0,0 +1,3 @@ +
+ +
\ No newline at end of file diff --git a/www/views/shapeshift.html b/www/views/shapeshift.html index 6a0a0e4e2..9f5a98423 100644 --- a/www/views/shapeshift.html +++ b/www/views/shapeshift.html @@ -31,83 +31,85 @@
- - - - - - - - - - - - - +
This service is provided by the third-party ShapeShift, who will charge a small fee for the service. The fee will be shown before you start the transaction.
- - - - - - - - - - + +
+ + + +
+ + + + + + diff --git a/www/views/wallet-origin-destination.html b/www/views/walletSelector.html similarity index 90% rename from www/views/wallet-origin-destination.html rename to www/views/walletSelector.html index 4bdbde22b..a4cc4db81 100644 --- a/www/views/wallet-origin-destination.html +++ b/www/views/walletSelector.html @@ -4,6 +4,7 @@ +
Paying
$... USD
@@ -14,7 +15,7 @@ {{headerTitle}}
-
+
Bitcoin Cash (BCH)
Instant transactions with low fees
@@ -35,7 +36,7 @@ From a952edfe692ee0c82c873544d0a4a7e21a075315 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 31 Jul 2018 17:40:58 +0200 Subject: [PATCH 194/386] border-radius fix --- src/sass/buttons.scss | 1 + src/sass/views/includes/clickToAccept.scss | 1 + src/sass/views/includes/slideToAccept.scss | 3 +++ 3 files changed, 5 insertions(+) diff --git a/src/sass/buttons.scss b/src/sass/buttons.scss index a8512ae64..e343f8fd2 100644 --- a/src/sass/buttons.scss +++ b/src/sass/buttons.scss @@ -55,6 +55,7 @@ .button { border-radius: 6px; &.button-full { + border-radius: 0; display: block; } &-green { diff --git a/src/sass/views/includes/clickToAccept.scss b/src/sass/views/includes/clickToAccept.scss index a38455ac3..cbc7a2c75 100644 --- a/src/sass/views/includes/clickToAccept.scss +++ b/src/sass/views/includes/clickToAccept.scss @@ -8,6 +8,7 @@ click-to-accept { .click-to-accept { &__button.button.button-primary.button-standard { + border-radius: 0; height: 100%; max-width: 9999px; width: 100%; diff --git a/src/sass/views/includes/slideToAccept.scss b/src/sass/views/includes/slideToAccept.scss index 75502c6a8..24775116d 100644 --- a/src/sass/views/includes/slideToAccept.scss +++ b/src/sass/views/includes/slideToAccept.scss @@ -13,6 +13,9 @@ slide-to-accept { } .slide { + .button { + border-radius: 0; + } &__listener { height: 100%; width: 100%; From f3a350f6645ddcdfd03b2f926e8af2b67dd93110 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 1 Aug 2018 11:33:24 +1200 Subject: [PATCH 195/386] Redirecting to new Review screen when sending max. --- src/js/controllers/amount.js | 2 +- src/js/controllers/review.controller.js | 9 +++++++++ src/js/controllers/review.js | 5 ----- src/js/routes.js | 1 + 4 files changed, 11 insertions(+), 6 deletions(-) create mode 100644 src/js/controllers/review.controller.js delete mode 100644 src/js/controllers/review.js diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 52695e829..399acde49 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -508,7 +508,7 @@ angular.module('copayApp.controllers').controller('amountController', function($ } } - $state.transitionTo('tabs.send.confirm', confirmData); + $state.transitionTo('tabs.send.review', confirmData); } $scope.useSendMax = null; } diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js new file mode 100644 index 000000000..217e15b00 --- /dev/null +++ b/src/js/controllers/review.controller.js @@ -0,0 +1,9 @@ +'use strict'; + +angular + .module('copayApp.controllers') + .controller('reviewController', reviewController); + +function reviewController() { + var vm = this; +} diff --git a/src/js/controllers/review.js b/src/js/controllers/review.js deleted file mode 100644 index 1effff0ba..000000000 --- a/src/js/controllers/review.js +++ /dev/null @@ -1,5 +0,0 @@ -'use strict'; - -angular.module('copayApp.controllers').controller('reviewController', function($rootScope, $scope, $interval, $filter, $timeout, $ionicScrollDelegate, gettextCatalog, walletService, platformInfo, lodash, configService, $stateParams, $window, $state, $log, profileService, bitcore, bitcoreCash, txFormatService, ongoingProcess, $ionicModal, popupService, $ionicHistory, $ionicConfig, payproService, feeService, bwcError, txConfirmNotification, externalLinkService, firebaseEventsService, soundService) { - -}); diff --git a/src/js/routes.js b/src/js/routes.js index 79b88e2f7..99513c278 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -321,6 +321,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr views: { 'tab-send@tabs': { controller: 'reviewController', + controllerAs: 'vm', templateUrl: 'views/review.html' } }, From 52f1e93e5b7688364a5fc7a73442731a6325c55b Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 1 Aug 2018 11:36:25 +1200 Subject: [PATCH 196/386] Header text. --- i18n/po/template.pot | 4 ++++ www/views/review.html | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index a23e5dbae..caa984046 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -3699,3 +3699,7 @@ msgstr "" #: www/views/includes/walletInfo.html:18 msgid "{{wallet.m}}-of-{{wallet.n}}" msgstr "" + +#: www/views/review.html:4 +msgid "Review Transaction" +msgstr "" \ No newline at end of file diff --git a/www/views/review.html b/www/views/review.html index 4995d3d25..35fb6a51a 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -1,7 +1,7 @@ - {{'Review'|translate}} + {{'Review Transaction' | translate}} From d6176e0f3ee97514017195d0a2bea83d45ae0b57 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 1 Aug 2018 14:28:26 +1200 Subject: [PATCH 197/386] Getting crypto value. --- src/js/controllers/review.controller.js | 46 ++++++++++++++++++++++++- src/js/routes.js | 2 +- 2 files changed, 46 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 217e15b00..937790d9c 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,6 +4,50 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController() { +function reviewController(configService, $log, $scope,) { var vm = this; + + vm.primaryAmount = '0'; + vm.primaryCurrency = ''; + + vm.secondaryAmount = ''; + vm.secondaryCurrency = ''; + + var config; + var amount = { + crypto: { + quantity: 0, + currency: '' + }, + fiat: null + }; + var priceDisplayIsFiat = true; + + $scope.$on("$ionicView.beforeEnter", onBeforeEnter); + + + function onBeforeEnter(event, data) { + + amount.crypto.quantity = data.stateParams.toAmount; + amount.crypto.currency = data.stateParams.coin.toUpperCase(); + console.log('cryptoAmount', cryptoAmount); + //vm.amount = cryptoAmount.toFixed(8); + console.log('vm.amount:', vm.amount); + + vm.secondaryAmount = amount.crypto.quantity; + vm.secondaryCurrency = amount.crypto.currency; + + configService.get(function onConfig(err, configCache) { + if (err) { + $log.err('Error getting config.', err); + return; + } else { + console.log('Got config.'); + config = configCache; + // Use this later if have time + priceDisplayIsFiat = config.wallet.settings.priceDisplay === 'fiat'; + } + }); + } + } diff --git a/src/js/routes.js b/src/js/routes.js index 99513c278..92193090a 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -317,7 +317,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }) .state('tabs.send.review', { - url: '/review', + url: '/review/:coin/:fromWalletId/:toAmount/:useSendMax', views: { 'tab-send@tabs': { controller: 'reviewController', From 38c3f2fb70f97f16029c1ea7482025c2d2658b49 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 1 Aug 2018 17:17:34 +1200 Subject: [PATCH 198/386] Displaying the amount. --- src/js/controllers/review.controller.js | 55 +++++++++++++++++++------ src/js/routes.js | 2 +- www/views/review.html | 4 +- 3 files changed, 45 insertions(+), 16 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 937790d9c..4995e9dc2 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,33 +4,37 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController(configService, $log, $scope,) { +function reviewController(configService, $log, $scope, txFormatService) { var vm = this; - vm.primaryAmount = '0'; + vm.primaryAmount = ''; vm.primaryCurrency = ''; vm.secondaryAmount = ''; vm.secondaryCurrency = ''; - var config; - var amount = { - crypto: { - quantity: 0, - currency: '' - }, - fiat: null - }; - var priceDisplayIsFiat = true; + + var coin = ''; + //var config = null; + var satoshis = null; + + //var priceDisplayIsFiat = true; $scope.$on("$ionicView.beforeEnter", onBeforeEnter); function onBeforeEnter(event, data) { - amount.crypto.quantity = data.stateParams.toAmount; + satoshis = parseInt(data.stateParams.amount, 10); + coin = data.stateParams.coin; + + updateAmount(); + + + /* + //amount.crypto.quantity = ; amount.crypto.currency = data.stateParams.coin.toUpperCase(); - console.log('cryptoAmount', cryptoAmount); + console.log('crypto:', JSON.stringify(amount.crypto)); //vm.amount = cryptoAmount.toFixed(8); console.log('vm.amount:', vm.amount); @@ -48,6 +52,31 @@ function reviewController(configService, $log, $scope,) { priceDisplayIsFiat = config.wallet.settings.priceDisplay === 'fiat'; } }); + */ } + function updateAmount() { + if (typeof satoshis !== 'number') { + return; + } + + var amountStr = txFormatService.formatAmountStr(coin, satoshis); + var amountParts = amountStr.split(' '); + vm.primaryAmount = amountParts[0]; + vm.primaryCurrency = amountParts[1]; + txFormatService.formatAlternativeStr(coin, satoshis, function(v) { + if (!v) { + vm.secondaryAmount = ''; + vm.secondaryCurrency = ''; + return; + } + vm.secondaryAmount = vm.primaryAmount; + vm.secondaryCurrency = vm.primaryCurrency; + + var fiatParts = v.split(' '); + vm.primaryAmount = fiatParts[0]; + vm.primaryCurrency = fiatParts[1]; + }); + } + } diff --git a/src/js/routes.js b/src/js/routes.js index 92193090a..d38e0e0de 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -317,7 +317,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }) .state('tabs.send.review', { - url: '/review/:coin/:fromWalletId/:toAmount/:useSendMax', + url: '/review/:coin/:fromWalletId/:amount/:useSendMax', views: { 'tab-send@tabs': { controller: 'reviewController', diff --git a/www/views/review.html b/www/views/review.html index 35fb6a51a..ebec1581b 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -11,8 +11,8 @@ ng-init="memoExpanded = false">
-

13.98 USD

-

0.014 BCH

+

+

From 18e00e5fcadbb6243b3c00bf87e57f5f0bb56240 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Wed, 1 Aug 2018 16:59:13 +0800 Subject: [PATCH 199/386] Renames amount directive to formatted-amount, fixes formatting for crypto --- src/js/directives/amount.js | 92 ------------------ src/js/directives/formattedAmount.js | 96 +++++++++++++++++++ .../{amount.html => formatted-amount.html} | 0 3 files changed, 96 insertions(+), 92 deletions(-) delete mode 100644 src/js/directives/amount.js create mode 100644 src/js/directives/formattedAmount.js rename www/views/includes/{amount.html => formatted-amount.html} (100%) diff --git a/src/js/directives/amount.js b/src/js/directives/amount.js deleted file mode 100644 index 9622ca09d..000000000 --- a/src/js/directives/amount.js +++ /dev/null @@ -1,92 +0,0 @@ -'use strict'; - -/** - * @desc amount directive that can be used to display formatted financial values - * size-equal attribute is optional, defaults to false. - * @example fee = { - * value: 12.49382901, - * currency: 'BCH' - * } - * @example - * @example - */ -angular.module('bitcoincom.directives') - .directive('amount', [ - '$timeout', - function($timeout) { - return { - restrict: 'E', - scope: { - value: '=', - currency: '=', - sizeEqual: '=' - }, - templateUrl: 'views/includes/amount.html', - controller: ['$scope', function($scope) { - $scope.displaySizeEqual = typeof $scope.sizeEqual == 'undefined' ? false : true; - - var decimalPlaces = { - '0': ['BIF', 'CLP', 'DJF', 'GNF', 'ILS', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'UGX', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'], - '3': ['BHD', 'IQD', 'JOD', 'KWD', 'OMR', 'TND'], - '8': ['BCH', 'BTC'] - }; - - var numberWithCommas = function(x) { - return parseFloat(x).toLocaleString(); - }; - - var buildAmount = function(start, middle, end) { - $scope.start = start; - $scope.middle = middle; - $scope.end = end; - }; - - var getDecimalPlaces = function(currency) { - if (decimalPlaces['0'].indexOf($scope.currency.toUpperCase()) > -1) return '0'; - if (decimalPlaces['3'].indexOf($scope.currency.toUpperCase()) > -1) return '3'; - if (decimalPlaces['8'].indexOf($scope.currency.toUpperCase()) > -1) return '8'; - return '2'; - }; - - var formatNumbers = function(currency, value) { - switch (getDecimalPlaces(currency)) { - case '0': - var valueFormatted = numberWithCommas(Math.round(parseFloat(value))); - buildAmount(valueFormatted, '', ''); - break; - - case '2': - var valueProcessing = parseFloat(parseFloat(value).toFixed(2)); - var valueFormatted = numberWithCommas(valueProcessing); - buildAmount(valueFormatted, '', ''); - break; - - case '3': - var valueProcessing = parseFloat(parseFloat(value).toFixed(3)); - var valueFormatted = numberWithCommas(valueProcessing); - buildAmount(valueFormatted, '', ''); - break; - - case '8': - var valueFormatted = parseFloat(value).toFixed(8); - if (parseFloat(value) == 0) { - buildAmount('0', '', ''); - } else { - buildAmount(valueFormatted, '', ''); - var start = numberWithCommas(valueFormatted.slice(0, -5)); - var middle = valueFormatted.slice(-5, -2); - var end = valueFormatted.substr(valueFormatted.length - 2); - buildAmount(start, middle, end); - } - break; - } - } - - formatNumbers($scope.currency, $scope.value); - $scope.$watchGroup(['currency', 'value'], function() { - formatNumbers($scope.currency, $scope.value); - }); - }] - }; - } -]); \ No newline at end of file diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js new file mode 100644 index 000000000..ac74afd2b --- /dev/null +++ b/src/js/directives/formattedAmount.js @@ -0,0 +1,96 @@ +'use strict'; + +/** + * @desc amount directive that can be used to display formatted financial values + * size-equal attribute is optional, defaults to false. + * @example fee = { + * value: 12.49382901, + * currency: 'BCH' + * } + * @example + * @example + */ +angular.module('bitcoincom.directives') + .directive('formattedAmount', function(configService, uxLanguage) { + return { + restrict: 'E', + scope: { + value: '=', + currency: '=', + sizeEqual: '=' + }, + templateUrl: 'views/includes/formatted-amount.html', + controller: function($scope, $timeout) { + $scope.displaySizeEqual = !!$scope.sizeEqual; + + configService.whenAvailable(function(config) { + $timeout(function() { + var decimalPlaces = { + '0': ['BIF', 'CLP', 'DJF', 'GNF', 'ILS', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'UGX', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'], + '3': ['BHD', 'IQD', 'JOD', 'KWD', 'OMR', 'TND'], + '8': ['BCH', 'BTC'] + }; + var localizeNumbers = function(x, minimumFractionDigits = 0, useGrouping = true) { + return parseFloat(x).toLocaleString(uxLanguage.getCurrentLanguage(), { + minimumFractionDigits: minimumFractionDigits, + useGrouping: useGrouping + }); + }; + + var buildAmount = function(start, middle, end) { + $scope.start = start; + $scope.middle = middle; + $scope.end = end; + }; + + var getDecimalPlaces = function(currency) { + if (decimalPlaces['0'].indexOf($scope.currency.toUpperCase()) > -1) return '0'; + if (decimalPlaces['3'].indexOf($scope.currency.toUpperCase()) > -1) return '3'; + if (decimalPlaces['8'].indexOf($scope.currency.toUpperCase()) > -1) return '8'; + return '2'; + }; + + var formatNumbers = function(currency, value) { + switch (getDecimalPlaces(currency)) { + case '0': + var valueFormatted = localizeNumbers(Math.round(parseFloat(value))); + buildAmount(valueFormatted, '', ''); + break; + + case '3': + var valueProcessing = parseFloat(parseFloat(value).toFixed(3)); + var valueFormatted = localizeNumbers(valueProcessing); + buildAmount(valueFormatted, '', ''); + break; + + case '8': + var valueFormatted = parseFloat(value).toFixed(8); + if (parseFloat(value) == 0) { + buildAmount('0', '', ''); + } else { + var valueFormatted = localizeNumbers(valueFormatted, 8); + var start = valueFormatted.slice(0, -5); + var middle = valueFormatted.slice(-5, -2); + var end = valueFormatted.substr(valueFormatted.length - 2); + buildAmount(start, middle, end); + } + break; + + default: + var valueProcessing = parseFloat(parseFloat(value).toFixed(2)); + var valueFormatted = localizeNumbers(valueProcessing); + buildAmount(valueFormatted, '', ''); + break; + } + } + + formatNumbers($scope.currency, $scope.value); + $scope.$watchGroup(['currency', 'value'], function() { + formatNumbers($scope.currency, $scope.value); + }); + }); + }); + } + }; + } +); \ No newline at end of file diff --git a/www/views/includes/amount.html b/www/views/includes/formatted-amount.html similarity index 100% rename from www/views/includes/amount.html rename to www/views/includes/formatted-amount.html From 31d33ba65628e1cb14e10011b15a86e61617e7a2 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 1 Aug 2018 11:53:58 +0200 Subject: [PATCH 200/386] Shape shift track --- www/views/shapeshift.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/views/shapeshift.html b/www/views/shapeshift.html index 9f5a98423..2382f9897 100644 --- a/www/views/shapeshift.html +++ b/www/views/shapeshift.html @@ -27,7 +27,7 @@
- +
From 0caa3fb92afbdc9e5c918612b5945b009da2ff4d Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 2 Aug 2018 09:48:12 +1200 Subject: [PATCH 201/386] From wallet details. --- src/js/controllers/review.controller.js | 118 ++++++++++++++++++------ www/views/review.html | 14 +-- 2 files changed, 96 insertions(+), 36 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 4995e9dc2..a38084b91 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,68 +4,116 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController(configService, $log, $scope, txFormatService) { +function reviewController(configService, gettextCatalog, profileService, $scope, txFormatService) { var vm = this; + vm.origin = { + balanceAmount: '', + balanceCurrency: '', + color: '', + currency: '', + name: '', + }; vm.primaryAmount = ''; vm.primaryCurrency = ''; - vm.secondaryAmount = ''; vm.secondaryCurrency = ''; - var coin = ''; - //var config = null; + var originWalletId = ''; + var priceDisplayIsFiat = true; var satoshis = null; + var toAddress = ''; + var toWalletId = ''; - //var priceDisplayIsFiat = true; + + $scope.$on("$ionicView.beforeEnter", onBeforeEnter); function onBeforeEnter(event, data) { - satoshis = parseInt(data.stateParams.amount, 10); coin = data.stateParams.coin; - - updateAmount(); - - - /* - //amount.crypto.quantity = ; - amount.crypto.currency = data.stateParams.coin.toUpperCase(); - console.log('crypto:', JSON.stringify(amount.crypto)); - //vm.amount = cryptoAmount.toFixed(8); - console.log('vm.amount:', vm.amount); - - vm.secondaryAmount = amount.crypto.quantity; - vm.secondaryCurrency = amount.crypto.currency; + originWalletId = data.stateParams.fromWalletId; + satoshis = parseInt(data.stateParams.amount, 10); + toAddress = data.stateParams.toAddress; + + var originWallet = profileService.getWallet(originWalletId); + vm.origin.currency = originWallet.coin.toUpperCase(); + vm.origin.color = originWallet.color; + vm.origin.name = originWallet.name; configService.get(function onConfig(err, configCache) { if (err) { $log.err('Error getting config.', err); - return; } else { console.log('Got config.'); - config = configCache; + //config = configCache; // Use this later if have time - priceDisplayIsFiat = config.wallet.settings.priceDisplay === 'fiat'; + priceDisplayIsFiat = configCache.wallet.settings.priceDisplay === 'fiat'; } + updateSendAmounts(); + getOriginWalletBalance(originWallet); }); - */ } - function updateAmount() { + function getOriginWalletBalance(originWallet) { + console.log('origin wallet error:', originWallet.error); + var balanceCryptoAmount = ''; + var balanceCryptoCurrencyCode = ''; + var balanceFiatAmount = ''; + var balanceFiatCurrency = '' + + var originWalletStatus = null; + if (originWallet.status.isValid) { + originWalletStatus = originWallet.status; + } else if (originWallet.cachedStatus.isValid) { + originWalletStatus = originWallet.cachedStatus; + } else { + vm.origin.balanceAmount = ''; + vm.origin.balanceCurrency = ''; + return; + } + + if (originWalletStatus) { + var cryptoBalanceParts = originWalletStatus.spendableBalanceStr.split(' '); + balanceCryptoAmount = cryptoBalanceParts[0]; + balanceCryptoCurrencyCode = cryptoBalanceParts.length > 1 ? cryptoBalanceParts[1] : ''; + + if (originWalletStatus.alternativeBalanceAvailable) { + balanceFiatAmount = originWalletStatus.spendableBalanceAlternative; + balanceFiatCurrency = originWalletStatus.alternativeIsoCode; + } + } + + if (priceDisplayIsFiat) { + vm.origin.balanceAmount = balanceFiatAmount ? balanceFiatAmount : balanceCryptoAmount; + vm.origin.balanceCurrency = balanceFiatAmount ? balanceFiatCurrency : balanceCryptoCurrencyCode; + } else { + vm.origin.balanceAmount = balanceCryptoAmount; + vm.origin.balanceCurrency = balanceCryptoCurrencyCode; + } + } + + function updateSendAmounts() { if (typeof satoshis !== 'number') { return; } + var cryptoAmount = ''; + var cryptoCurrencyCode = ''; var amountStr = txFormatService.formatAmountStr(coin, satoshis); - var amountParts = amountStr.split(' '); - vm.primaryAmount = amountParts[0]; - vm.primaryCurrency = amountParts[1]; + if (amountStr) { + var amountParts = amountStr.split(' '); + cryptoAmount = amountParts[0]; + cryptoCurrencyCode = amountParts.length > 1 ? amountParts[1] : ''; + } + // Want to avoid flashing of amount strings so do all formatting after this has returned. txFormatService.formatAlternativeStr(coin, satoshis, function(v) { if (!v) { + vm.primaryAmount = cryptoAmount; + vm.primaryCurrency = cryptoCurrencyCode; vm.secondaryAmount = ''; vm.secondaryCurrency = ''; return; @@ -74,8 +122,20 @@ function reviewController(configService, $log, $scope, txFormatService) { vm.secondaryCurrency = vm.primaryCurrency; var fiatParts = v.split(' '); - vm.primaryAmount = fiatParts[0]; - vm.primaryCurrency = fiatParts[1]; + var fiatAmount = fiatParts[0]; + var fiatCurrency = fiatParts.length > 1 ? fiatParts[1] : ''; + + if (priceDisplayIsFiat) { + vm.primaryAmount = fiatAmount; + vm.primaryCurrency = fiatCurrency; + vm.secondaryAmount = cryptoAmount; + vm.secondaryCurrency = cryptoCurrencyCode; + } else { + vm.primaryAmount = cryptoAmount; + vm.primaryCurrency = cryptoCurrencyCode; + vm.secondaryAmount = fiatAmount; + vm.secondaryCurrency = fiatCurrency; + } }); } diff --git a/www/views/review.html b/www/views/review.html index ebec1581b..d75ce9e48 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -10,24 +10,24 @@
-
-

-

+
+

{{vm.primaryAmount}} {{vm.primaryCurrency}}

+

{{vm.secondaryAmount}} {{vm.secondaryCurrency}}

-
From:
+
From:
-

Personal Wallet (BCH)

-

128.67

+

{{vm.origin.name}} ({{vm.origin.currency}})

+

{{vm.origin.balanceAmount}} {{vm.origin.balanceCurrency}}

From e58c3bf438676226f44a140aba7630ef8d84a79d Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 2 Aug 2018 10:07:25 +1200 Subject: [PATCH 202/386] From wallet currency colour. --- src/js/controllers/review.controller.js | 6 ++++-- www/views/review.html | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index a38084b91..1e51bd5d0 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -12,6 +12,7 @@ function reviewController(configService, gettextCatalog, profileService, $scope, balanceCurrency: '', color: '', currency: '', + currencyColor: '', name: '', }; vm.primaryAmount = ''; @@ -44,14 +45,15 @@ function reviewController(configService, gettextCatalog, profileService, $scope, vm.origin.color = originWallet.color; vm.origin.name = originWallet.name; - configService.get(function onConfig(err, configCache) { + configService.get(function onConfig(err, config) { if (err) { $log.err('Error getting config.', err); } else { console.log('Got config.'); //config = configCache; // Use this later if have time - priceDisplayIsFiat = configCache.wallet.settings.priceDisplay === 'fiat'; + priceDisplayIsFiat = config.wallet.settings.priceDisplay === 'fiat'; + vm.origin.currencyColor = originWallet.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; } updateSendAmounts(); getOriginWalletBalance(originWallet); diff --git a/www/views/review.html b/www/views/review.html index d75ce9e48..2ee10e40a 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -26,7 +26,7 @@ style="background-color: {{vm.origin.color}}" >
-

{{vm.origin.name}} ({{vm.origin.currency}})

+

{{vm.origin.name}} ({{vm.origin.currency}})

{{vm.origin.balanceAmount}} {{vm.origin.balanceCurrency}}

From 438ab94404512feb5901f508d7f790af85d04000 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 2 Aug 2018 10:20:03 +1200 Subject: [PATCH 203/386] Strings for translation. --- i18n/po/template.pot | 25 +++++++++++++++++++++++++ src/js/controllers/review.controller.js | 5 ++--- www/views/review.html | 3 ++- 3 files changed, 29 insertions(+), 4 deletions(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index caa984046..7406fcb74 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -3702,4 +3702,29 @@ msgstr "" #: www/views/review.html:4 msgid "Review Transaction" +msgstr "" + +#: www/views/review.html:14 +msgid "You are sending" +msgstr "" + +#: www/views/review.html:22 +msgid "From:" +msgstr "" + +#: www/views/review.html:36 +msgid "To:" +msgstr "" + +#: www/views/review.html:53 +msgid "Add personal note" +msgstr "" + + +#: www/views/review.html:57 +msgid "Personal note:" +msgstr "" + +#: www/views/review.html:69 +msgid "Less than 1 cent" msgstr "" \ No newline at end of file diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 1e51bd5d0..f0c443e96 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -7,6 +7,8 @@ angular function reviewController(configService, gettextCatalog, profileService, $scope, txFormatService) { var vm = this; + vm.feeCrypto = ''; + vm.feeFiat = ''; vm.origin = { balanceAmount: '', balanceCurrency: '', @@ -49,9 +51,6 @@ function reviewController(configService, gettextCatalog, profileService, $scope, if (err) { $log.err('Error getting config.', err); } else { - console.log('Got config.'); - //config = configCache; - // Use this later if have time priceDisplayIsFiat = config.wallet.settings.priceDisplay === 'fiat'; vm.origin.currencyColor = originWallet.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; } diff --git a/www/views/review.html b/www/views/review.html index 2ee10e40a..15c6d5978 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -11,6 +11,7 @@ ng-init="memoExpanded = false">
+

You are sending

{{vm.primaryAmount}} {{vm.primaryCurrency}}

{{vm.secondaryAmount}} {{vm.secondaryCurrency}}

@@ -49,7 +50,7 @@ ng-class="{ 'expand-content-revealed': memoExpanded }" ng-click="memoExpanded = !memoExpanded"> - Add a personal note + Add personal note
From ff643bf479958364a4a82dae6b7de24d6c065ea9 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 2 Aug 2018 11:48:41 +1200 Subject: [PATCH 204/386] Starting on destination UI. --- src/js/controllers/review.controller.js | 17 ++++++++++++++++- www/views/review.html | 2 +- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index f0c443e96..9394b5ef2 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -7,6 +7,13 @@ angular function reviewController(configService, gettextCatalog, profileService, $scope, txFormatService) { var vm = this; + vm.destination = { + address: '', + balanceAmount: '', + balanceCurrecy: '', + color: '', + name: '' + }; vm.feeCrypto = ''; vm.feeFiat = ''; vm.origin = { @@ -27,7 +34,7 @@ function reviewController(configService, gettextCatalog, profileService, $scope, var priceDisplayIsFiat = true; var satoshis = null; var toAddress = ''; - var toWalletId = ''; + var destinationWalletId = ''; @@ -47,6 +54,14 @@ function reviewController(configService, gettextCatalog, profileService, $scope, vm.origin.color = originWallet.color; vm.origin.name = originWallet.name; + destinationWalletId = data.stateParams.toWalletId; + if (destinationWalletId) { + var destinationWallet = profileService.getWallet(destinationWalletId); + vm.destination.color = destinationWallet.color; + vm.destination.name = destinationWallet.name; + + } + configService.get(function onConfig(err, config) { if (err) { $log.err('Error getting config.', err); diff --git a/www/views/review.html b/www/views/review.html index 15c6d5978..0ec643b8b 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -37,7 +37,7 @@
-

Satoshi Nakamoto

+

{{vm.destination.name}}

128.67

From 927c1e947847eba1ef284d060a307832b7d92528 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 2 Aug 2018 15:44:59 +1200 Subject: [PATCH 205/386] Request Specifc Amount integrated into new send flow. --- src/js/controllers/amount.js | 225 ++++++++++++----------------- src/js/controllers/customAmount.js | 9 +- src/js/controllers/tab-receive.js | 3 +- src/js/routes.js | 4 +- 4 files changed, 99 insertions(+), 142 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index c50a949a0..4d8c8671b 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -2,7 +2,7 @@ angular.module('copayApp.controllers').controller('amountController', amountController); -function amountController(configService, $filter, $ionicHistory, $ionicModal, $ionicScrollDelegate, lodash, $log, nodeWebkitService, rateService, $scope, $state, $stateParams, $timeout, txFormatService, platformInfo, popupService, profileService, walletService, $window) { +function amountController(configService, $filter, $ionicHistory, $ionicModal, $ionicScrollDelegate, lodash, $log, nodeWebkitService, rateService, $scope, $state, $timeout, txFormatService, platformInfo, popupService, profileService, walletService, $window) { var vm = this; vm.allowSend = false; @@ -11,12 +11,10 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i vm.alternativeUnit = ''; vm.amount = '0'; vm.availableFunds = ''; - vm.fromWalletId = ''; // Use insufficient for logic, as when the amount is invalid, funds being // either sufficent or insufficient doesn't make sense. vm.fundsAreInsufficient = false; vm.globalResult = ''; - vm.hello = 'hi'; vm.isRequestingSpecificAmount = false; vm.listComplete = false; vm.lastUsedPopularList = []; @@ -44,33 +42,25 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i var LENGTH_BEFORE_COMMA_EXPRESSION_LIMIT = 8; var LENGTH_AFTER_COMMA_EXPRESSION_LIMIT = 8; - var _id; var altCurrencyModal = null; var altUnitIndex = 0; var availableFundsInCrypto = ''; var availableFundsInFiat = ''; var availableSatoshis = null; var availableUnits = []; - var displayAddress = null; var fiatCode; - var fixedUnit; var hasMaxAmount = true; var isNW = platformInfo.isNW; var isAndroid = platformInfo.isAndroid; var isIos = platformInfo.isIOS; var lastUsedAltCurrencyList = []; - var nextStep = null; - var unitToSatoshi; - var recipientType = null; + var passthroughParams = {}; var satToUnit; var showMenu = false; var showWarningMessage = false; - var toAddress = ''; - var toColor = null; - var toEmail = null; - var toName = null; var unitDecimals; var unitIndex = 0; + var unitToSatoshi; var useSendMax = false; function onLeave() { @@ -87,24 +77,11 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i vm.shapeshiftOrderId = data.stateParams.shapeshiftOrderId; } - // To get the wallet from with the new flow - vm.fromWalletId = data.stateParams.fromWalletId; + passthroughParams = data.stateParams; - if (data.stateParams.noPrefix) { - showWarningMessage = data.stateParams.noPrefix != 0; - if (showWarningMessage) { - var message = 'Address doesn\'t contain currency information, please make sure you are sending the correct currency.'; - popupService.showAlert('', message, function() {}, 'Ok'); - } - } - - vm.isRequestingSpecificAmount = !!data.stateParams.id; + vm.isRequestingSpecificAmount = !data.stateParams.fromWalletId; var config = configService.getSync().wallet.settings; - // Go to... - _id = data.stateParams.id; // Optional (BitPay Card ID or Wallet ID) - nextStep = data.stateParams.nextStep; - setAvailableUnits(); updateUnitUI(); @@ -112,19 +89,8 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i hasMaxAmount = false; } - showMenu = $ionicHistory.backView() && ($ionicHistory.backView().stateName == 'tabs.send' || $ionicHistory.backView().stateName == 'tabs.bitpayCard'); - recipientType = data.stateParams.recipientType || null; - toAddress = data.stateParams.toAddress; - displayAddress = data.stateParams.displayAddress; - toName = data.stateParams.toName; - toEmail = data.stateParams.toEmail; - toColor = data.stateParams.toColor; - - if (!nextStep && !data.stateParams.toAddress) { - $log.error('Bad params at amount') - throw ('bad params'); - } - + showMenu = $ionicHistory.backView() && ($ionicHistory.backView().stateName == 'tabs.send'); + var reNr = /^[1234567890\.]$/; var reOp = /^[\*\+\-\/]$/; @@ -158,11 +124,6 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i resetAmount(); - // in SAT ALWAYS - if ($stateParams.toAmount) { - vm.amount = (($stateParams.toAmount) * satToUnit).toFixed(unitDecimals); - } - processAmount(); $timeout(function() { @@ -174,11 +135,16 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i var configCache = configService.getSync(); availableUnits = []; - var hasBCHWallets = profileService.getWallets({ - coin: 'bch' - }).length; + var coinFromWallet = ''; + if (passthroughParams.fromWalletId) { + var fromWallet = profileService.getWallet(passthroughParams.fromWalletId); + coinFromWallet = fromWallet.coin; + } else { + var toWallet = profileService.getWallet(passthroughParams.toWalletId); + coinFromWallet = toWallet.coin; + } - if (hasBCHWallets) { + if (coinFromWallet === 'bch') { availableUnits.push({ name: 'Bitcoin Cash', id: 'bch', @@ -186,11 +152,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i }); }; - var hasBTCWallets = profileService.getWallets({ - coin: 'btc' - }).length; - - if (hasBTCWallets) { + if (coinFromWallet === 'btc') { availableUnits.push({ name: 'Bitcoin', id: 'btc', @@ -200,27 +162,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i unitIndex = 0; - if (data.stateParams.coin) { - var coins = data.stateParams.coin.split(','); - var newAvailableUnits = []; - - lodash.each(coins, function(c) { - var coin = lodash.find(availableUnits, { - id: c - }); - if (!coin) { - $log.warn('Could not find desired coin:' + data.stateParams.coin) - } else { - newAvailableUnits.push(coin); - } - }); - - if (newAvailableUnits.length > 0) { - availableUnits = newAvailableUnits; - } - } - - + // currency have preference var fiatName; if (data.stateParams.currency) { @@ -241,18 +183,14 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i isFiat: true, }); - if (data.stateParams.fixedUnit) { - fixedUnit = true; - } - unitIndex = lodash.findIndex(availableUnits, { isFiat: true }); altUnitIndex = 0; - if (vm.fromWalletId) { - var fromWallet = profileService.getWallet(vm.fromWalletId); + if (passthroughParams.fromWalletId) { + var fromWallet = profileService.getWallet(passthroughParams.fromWalletId); updateAvailableFundsFromWallet(fromWallet); } }; @@ -302,8 +240,6 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i vm.amount = '0'; - if (fixedUnit) return; - if (!(availableUnits[unitIndex].isFiat && availableUnits.length > 2 && altUnitIndex == 0)) { unitIndex++; if (unitIndex >= availableUnits.length) unitIndex = 0; @@ -405,7 +341,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i var a = fromFiat(result); if (a) { var amountInSatoshis = a * unitToSatoshi; - vm.fundsAreInsufficient = !!vm.fromWalletId + vm.fundsAreInsufficient = !!passthroughParams.fromWalletId && availableSatoshis !== null && availableSatoshis < amountInSatoshis; @@ -425,7 +361,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i vm.allowSend = false; } } else { - vm.fundsAreInsufficient = vm.fromWalletId + vm.fundsAreInsufficient = passthroughParams.fromWalletId && availableSatoshis !== null && availableSatoshis < result * unitToSatoshi; @@ -482,67 +418,88 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i function finish() { var unit = availableUnits[unitIndex]; - var _amount = evaluate(format(vm.amount)); - var coin = unit.id; + var uiAmount = evaluate(format(vm.amount)); + + var satoshis = 0; if (unit.isFiat) { - coin = availableUnits[altUnitIndex].id; + satoshis = (fromFiat(uiAmount) * unitToSatoshi).toFixed(0); + } else { + satoshis = (uiAmount * unitToSatoshi).toFixed(0); } - if (nextStep) { - $state.transitionTo(nextStep, { - id: _id, - amount: useSendMax ? null : _amount, - currency: unit.id.toUpperCase(), - coin: coin, - useSendMax: useSendMax, - fromWalletId: vm.fromWalletId - }); - } else { - var amount = _amount; + var confirmData = { + amount: useSendMax ? undefined : satoshis, + fromWalletId: passthroughParams.fromWalletId, + sendMax: useSendMax, + thirdParty: passthroughParams.thirdParty, + toAddr: passthroughParams.toAddress, + toWalletId: passthroughParams.toWalletId + }; + console.log('confirmData:', confirmData); + + if (!confirmData.fromWalletId) { + $state.transitionTo('tabs.paymentRequest.confirm', confirmData); + } else { + + + var coin = unit.id; if (unit.isFiat) { - amount = (fromFiat(amount) * unitToSatoshi).toFixed(0); - } else { - amount = (amount * unitToSatoshi).toFixed(0); + coin = availableUnits[altUnitIndex].id; } - var confirmData = { - recipientType: recipientType, - toAmount: amount, - toAddress: toAddress, - displayAddress: displayAddress || toAddress, - toName: toName, - toEmail: toEmail, - toColor: toColor, - coin: coin, - useSendMax: useSendMax, - fromWalletId: vm.fromWalletId - }; + if (nextStep) { + $state.transitionTo(nextStep, { + id: _id, + amount: useSendMax ? null : _amount, + currency: unit.id.toUpperCase(), + coin: coin, + useSendMax: useSendMax, + fromWalletId: passthroughParams.fromWalletId + }); + } else { + var amount = _amount; - if (vm.shapeshiftOrderId) { - var shapeshiftOrderUrl = 'https://www.shapeshift.io/#/status/'; - shapeshiftOrderUrl += vm.shapeshiftOrderId; - confirmData.description = shapeshiftOrderUrl; - confirmData.fromWalletId = vm.fromWalletId; + if (unit.isFiat) { + amount = (fromFiat(amount) * unitToSatoshi).toFixed(0); + } else { + amount = (amount * unitToSatoshi).toFixed(0); + } - if (confirmData.useSendMax) { - var wallet = lodash.find(profileService.getWallets({ coin: coin }), - function(w) { - return w.id == vm.fromWalletId; - }); + var confirmData = { + amount: useSendMax ? undefined : amount, + fromWalletId: passthroughParams.fromWalletId, + sendMax: useSendMax, + thirdParty: passthroughParams.thirdParty, + toAddr: passthroughParams.toAddress, + toWalletId: passthroughParams.toWalletId + }; - var balance = parseFloat(wallet.cachedBalance.substring(0, wallet.cachedBalance.length-4)); - if (balance < vm.minShapeshiftAmount * 1.04) { - confirmData.useSendMax = false; - confirmData.toAmount = vm.minShapeshiftAmount * unitToSatoshi; - } else if (balance > vm.maxShapeshiftAmount) { - confirmData.useSendMax = false; - confirmData.toAmount = vm.maxShapeshiftAmount * unitToSatoshi * 0.99; + if (vm.shapeshiftOrderId) { + var shapeshiftOrderUrl = 'https://www.shapeshift.io/#/status/'; + shapeshiftOrderUrl += vm.shapeshiftOrderId; + confirmData.description = shapeshiftOrderUrl; + + if (confirmData.useSendMax) { + var wallet = lodash.find(profileService.getWallets({ coin: coin }), + function(w) { + return w.id == vm.fromWalletId; + }); + + var balance = parseFloat(wallet.cachedBalance.substring(0, wallet.cachedBalance.length-4)); + if (balance < vm.minShapeshiftAmount * 1.04) { + confirmData.useSendMax = false; + confirmData.amount = vm.minShapeshiftAmount * unitToSatoshi; + } else if (balance > vm.maxShapeshiftAmount) { + confirmData.useSendMax = false; + confirmData.amount = vm.maxShapeshiftAmount * unitToSatoshi * 0.99; + } } } - } - $state.transitionTo('tabs.send.confirm', confirmData); + + $state.transitionTo('tabs.send.confirm', confirmData); + } } useSendMax = null; } diff --git a/src/js/controllers/customAmount.js b/src/js/controllers/customAmount.js index f6b96c22c..d74ebca30 100644 --- a/src/js/controllers/customAmount.js +++ b/src/js/controllers/customAmount.js @@ -17,7 +17,7 @@ angular.module('copayApp.controllers').controller('customAmountController', func } $scope.$on("$ionicView.beforeEnter", function(event, data) { - var walletId = data.stateParams.id; + var walletId = data.stateParams.toWalletId; if (!walletId) { showErrorAndBack('Error', 'No wallet selected'); @@ -53,11 +53,12 @@ angular.module('copayApp.controllers').controller('customAmountController', func $scope.address = bchAddresses[$scope.bchAddressType]; } - $scope.coin = data.stateParams.coin; + $scope.coin = $scope.wallet.coin; + var satoshis = parseInt(data.stateParams.amount, 10); var parsedAmount = txFormatService.parseAmount( $scope.wallet.coin, - data.stateParams.amount, - data.stateParams.currency); + satoshis, + 'sat'); // Amount in USD or BTC var amount = parsedAmount.amount; diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index 8f25412ec..3c48818b6 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -19,8 +19,7 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi $scope.requestSpecificAmount = function() { $state.go('tabs.paymentRequest.amount', { - id: $scope.wallet.credentials.walletId, - coin: $scope.wallet.coin + toWalletId: $scope.wallet.credentials.walletId }); }; diff --git a/src/js/routes.js b/src/js/routes.js index 234344d5f..e5430b5f5 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -723,7 +723,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr }) .state('tabs.paymentRequest.amount', { - url: '/amount/:coin', + url: '/amount/:toWalletId', views: { 'tab-receive@tabs': { controller: 'amountController', @@ -733,7 +733,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }) .state('tabs.paymentRequest.confirm', { - url: '/confirm/:amount/:currency/:coin', + url: '/confirm/:amount/:toWalletId', views: { 'tab-receive@tabs': { controller: 'customAmountController', From dc41aa604426866cb5a471dc4d170f52123a2309 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 2 Aug 2018 16:40:00 +1200 Subject: [PATCH 206/386] Warning messages for ShapeShift amounts. --- src/js/controllers/amount.js | 194 +++++++++++++---------------------- www/views/amount.html | 8 +- 2 files changed, 78 insertions(+), 124 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 4d8c8671b..309949f97 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -2,7 +2,7 @@ angular.module('copayApp.controllers').controller('amountController', amountController); -function amountController(configService, $filter, $ionicHistory, $ionicModal, $ionicScrollDelegate, lodash, $log, nodeWebkitService, rateService, $scope, $state, $timeout, txFormatService, platformInfo, popupService, profileService, walletService, $window) { +function amountController(configService, $filter, gettextCatalog, $ionicHistory, $ionicModal, $ionicScrollDelegate, lodash, $log, nodeWebkitService, rateService, $scope, $state, $timeout, txFormatService, platformInfo, profileService, walletService, $window) { var vm = this; vm.allowSend = false; @@ -18,8 +18,8 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i vm.isRequestingSpecificAmount = false; vm.listComplete = false; vm.lastUsedPopularList = []; - vm.maxShapeshiftAmount = 0; - vm.minShapeshiftAmount = 0; + vm.maxAmount = 0; + vm.minAmount = 0; vm.shapeshiftOrderId = ''; vm.unit = ''; @@ -34,6 +34,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i vm.removeDigit = removeDigit; vm.save = save; vm.sendMax = sendMax; + vm.errorMessage = ''; $scope.$on('$ionicView.beforeEnter', onBeforeEnter); $scope.$on('$ionicView.leave', onLeave); @@ -49,15 +50,12 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i var availableSatoshis = null; var availableUnits = []; var fiatCode; - var hasMaxAmount = true; var isNW = platformInfo.isNW; var isAndroid = platformInfo.isAndroid; var isIos = platformInfo.isIOS; var lastUsedAltCurrencyList = []; var passthroughParams = {}; var satToUnit; - var showMenu = false; - var showWarningMessage = false; var unitDecimals; var unitIndex = 0; var unitToSatoshi; @@ -70,26 +68,19 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i function onBeforeEnter(event, data) { initCurrencies(); - vm.hello = 'greetings'; - if (data.stateParams.shapeshiftOrderId && data.stateParams.shapeshiftOrderId.length > 0) { - vm.minShapeshiftAmount = parseFloat(data.stateParams.minShapeshiftAmount); - vm.maxShapeshiftAmount = parseFloat(data.stateParams.maxShapeshiftAmount); - vm.shapeshiftOrderId = data.stateParams.shapeshiftOrderId; - } + + vm.minAmount = parseFloat(data.stateParams.minShapeshiftAmount); + vm.maxAmount = parseFloat(data.stateParams.maxShapeshiftAmount); + vm.shapeshiftOrderId = data.stateParams.shapeshiftOrderId; passthroughParams = data.stateParams; + console.log('stateParams:', data.stateParams); vm.isRequestingSpecificAmount = !data.stateParams.fromWalletId; var config = configService.getSync().wallet.settings; setAvailableUnits(); updateUnitUI(); - - if ($ionicHistory.backView().stateName == 'tabs.receive') { - hasMaxAmount = false; - } - - showMenu = $ionicHistory.backView() && ($ionicHistory.backView().stateName == 'tabs.send'); var reNr = /^[1234567890\.]$/; var reOp = /^[\*\+\-\/]$/; @@ -333,6 +324,8 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i var formatedValue = format(vm.amount); var result = evaluate(formatedValue); + var amountInSatoshis = 0; + if (lodash.isNumber(result)) { vm.globalResult = isExpression(vm.amount) ? '= ' + processResult(result) : ''; @@ -340,7 +333,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i var a = fromFiat(result); if (a) { - var amountInSatoshis = a * unitToSatoshi; + amountInSatoshis = a * unitToSatoshi; vm.fundsAreInsufficient = !!passthroughParams.fromWalletId && availableSatoshis !== null && availableSatoshis < amountInSatoshis; @@ -349,7 +342,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i vm.allowSend = lodash.isNumber(a) && a > 0 && (!vm.shapeshiftOrderId - || (a >= vm.minShapeshiftAmount && a <= vm.maxShapeshiftAmount)) + || (a >= vm.minAmount && a <= vm.maxAmount)) && !vm.fundsAreInsufficient; } else { if (result) { @@ -361,6 +354,7 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i vm.allowSend = false; } } else { + amountInSatoshis = result; vm.fundsAreInsufficient = passthroughParams.fromWalletId && availableSatoshis !== null && availableSatoshis < result * unitToSatoshi; @@ -369,13 +363,27 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i vm.allowSend = lodash.isNumber(result) && result > 0 && (!vm.shapeshiftOrderId - || (result >= vm.minShapeshiftAmount && result <= vm.maxShapeshiftAmount)) + || (result >= vm.minAmount && result <= vm.maxAmount)) && !vm.fundsAreInsufficient; } } else { vm.fundsAreInsufficient = false; } + + if (vm.fundsAreInsufficient) { + vm.errorMessage = gettextCatalog.getString('Not enough available funds'); + } else if (amountInSatoshis && vm.shapeshiftOrderId) { + if (amountInSatoshis < (vm.minAmount * unitToSatoshi)) { + vm.errorMessage = gettextCatalog.getString('Amount is below minimum'); + } else if (amountInSatoshis > (vm.maxAmount * unitToSatoshi)) { + vm.errorMessage = gettextCatalog.getString('Amount is above maximum'); + } else { + vm.errorMessage = ''; + } + } else { + vm.errorMessage = ''; + } }; function processResult(val) { @@ -415,109 +423,55 @@ function amountController(configService, $filter, $ionicHistory, $ionicModal, $i }; function finish() { + var unit = availableUnits[unitIndex]; + var uiAmount = evaluate(format(vm.amount)); - function finish() { - var unit = availableUnits[unitIndex]; - var uiAmount = evaluate(format(vm.amount)); - - var satoshis = 0; - if (unit.isFiat) { - satoshis = (fromFiat(uiAmount) * unitToSatoshi).toFixed(0); - } else { - satoshis = (uiAmount * unitToSatoshi).toFixed(0); - } - - var confirmData = { - amount: useSendMax ? undefined : satoshis, - fromWalletId: passthroughParams.fromWalletId, - sendMax: useSendMax, - thirdParty: passthroughParams.thirdParty, - toAddr: passthroughParams.toAddress, - toWalletId: passthroughParams.toWalletId - }; - - console.log('confirmData:', confirmData); - - if (!confirmData.fromWalletId) { - $state.transitionTo('tabs.paymentRequest.confirm', confirmData); - } else { - - - var coin = unit.id; - if (unit.isFiat) { - coin = availableUnits[altUnitIndex].id; - } - - if (nextStep) { - $state.transitionTo(nextStep, { - id: _id, - amount: useSendMax ? null : _amount, - currency: unit.id.toUpperCase(), - coin: coin, - useSendMax: useSendMax, - fromWalletId: passthroughParams.fromWalletId - }); - } else { - var amount = _amount; - - if (unit.isFiat) { - amount = (fromFiat(amount) * unitToSatoshi).toFixed(0); - } else { - amount = (amount * unitToSatoshi).toFixed(0); - } - - var confirmData = { - amount: useSendMax ? undefined : amount, - fromWalletId: passthroughParams.fromWalletId, - sendMax: useSendMax, - thirdParty: passthroughParams.thirdParty, - toAddr: passthroughParams.toAddress, - toWalletId: passthroughParams.toWalletId - }; - - if (vm.shapeshiftOrderId) { - var shapeshiftOrderUrl = 'https://www.shapeshift.io/#/status/'; - shapeshiftOrderUrl += vm.shapeshiftOrderId; - confirmData.description = shapeshiftOrderUrl; - - if (confirmData.useSendMax) { - var wallet = lodash.find(profileService.getWallets({ coin: coin }), - function(w) { - return w.id == vm.fromWalletId; - }); - - var balance = parseFloat(wallet.cachedBalance.substring(0, wallet.cachedBalance.length-4)); - if (balance < vm.minShapeshiftAmount * 1.04) { - confirmData.useSendMax = false; - confirmData.amount = vm.minShapeshiftAmount * unitToSatoshi; - } else if (balance > vm.maxShapeshiftAmount) { - confirmData.useSendMax = false; - confirmData.amount = vm.maxShapeshiftAmount * unitToSatoshi * 0.99; - } - } - } - - - $state.transitionTo('tabs.send.confirm', confirmData); - } - } - useSendMax = null; - } - - if (showWarningMessage) { - var u = vm.unit == 'BCH' || vm.unit == 'BTC' ? vm.unit : vm.alternativeUnit; - var message = 'Are you sure you want to send ' + u.toUpperCase() + '?'; - popupService.showConfirm(message, '', 'Yes', 'No', function(res) { - if (!res) { - useSendMax = null; - return; - }; - finish(); - }); + var satoshis = 0; + if (unit.isFiat) { + satoshis = (fromFiat(uiAmount) * unitToSatoshi).toFixed(0); } else { - finish(); + satoshis = (uiAmount * unitToSatoshi).toFixed(0); } + var confirmData = { + amount: useSendMax ? undefined : satoshis, + fromWalletId: passthroughParams.fromWalletId, + sendMax: useSendMax, + thirdParty: passthroughParams.thirdParty, + toAddr: passthroughParams.toAddress, + toWalletId: passthroughParams.toWalletId + }; + + console.log('confirmData:', confirmData); + + if (!confirmData.fromWalletId) { + $state.transitionTo('tabs.paymentRequest.confirm', confirmData); + } else { + + if (vm.shapeshiftOrderId) { + var shapeshiftOrderUrl = 'https://www.shapeshift.io/#/status/'; + shapeshiftOrderUrl += vm.shapeshiftOrderId; + confirmData.description = shapeshiftOrderUrl; + + if (confirmData.sendMax) { + var wallet = lodash.find(profileService.getWallets({ coin: coin }), + function(w) { + return w.id == vm.fromWalletId; + }); + + var balance = parseFloat(wallet.cachedBalance.substring(0, wallet.cachedBalance.length-4)); + if (balance < vm.minAmount * 1.04) { + confirmData.sendMax = false; + confirmData.amount = vm.minAmount * unitToSatoshi; + } else if (balance > vm.maxAmount) { + confirmData.sendMax = false; + confirmData.amount = vm.maxAmount * unitToSatoshi * 0.99; + } + } + } + + $state.transitionTo('tabs.send.confirm', confirmData); + } }; diff --git a/www/views/amount.html b/www/views/amount.html index 77c52f96c..1757bf25a 100644 --- a/www/views/amount.html +++ b/www/views/amount.html @@ -12,8 +12,8 @@
@@ -29,8 +29,8 @@
From 1590a295da6d9380044a6722865ec6f9c34e68f4 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 2 Aug 2018 17:10:58 +1200 Subject: [PATCH 207/386] Bugfix for ShapeShift warnings. --- src/js/controllers/amount.js | 30 +++++++++++++++++------------- src/js/routes.js | 2 +- 2 files changed, 18 insertions(+), 14 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 309949f97..269ff1634 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -69,13 +69,13 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, initCurrencies(); - vm.minAmount = parseFloat(data.stateParams.minShapeshiftAmount); - vm.maxAmount = parseFloat(data.stateParams.maxShapeshiftAmount); - vm.shapeshiftOrderId = data.stateParams.shapeshiftOrderId; - passthroughParams = data.stateParams; console.log('stateParams:', data.stateParams); + vm.minAmount = parseFloat(data.stateParams.minAmount); + vm.maxAmount = parseFloat(data.stateParams.maxAmount); + vm.shapeshiftOrderId = data.stateParams.thirdPartyOrderId; + vm.isRequestingSpecificAmount = !data.stateParams.fromWalletId; var config = configService.getSync().wallet.settings; @@ -324,7 +324,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, var formatedValue = format(vm.amount); var result = evaluate(formatedValue); - var amountInSatoshis = 0; + var amountInCrypto = 0; if (lodash.isNumber(result)) { vm.globalResult = isExpression(vm.amount) ? '= ' + processResult(result) : ''; @@ -333,7 +333,8 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, var a = fromFiat(result); if (a) { - amountInSatoshis = a * unitToSatoshi; + amountInCrypto = a; + var amountInSatoshis = a * unitToSatoshi; vm.fundsAreInsufficient = !!passthroughParams.fromWalletId && availableSatoshis !== null && availableSatoshis < amountInSatoshis; @@ -354,7 +355,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, vm.allowSend = false; } } else { - amountInSatoshis = result; + amountInCrypto = result; vm.fundsAreInsufficient = passthroughParams.fromWalletId && availableSatoshis !== null && availableSatoshis < result * unitToSatoshi; @@ -373,11 +374,14 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, if (vm.fundsAreInsufficient) { vm.errorMessage = gettextCatalog.getString('Not enough available funds'); - } else if (amountInSatoshis && vm.shapeshiftOrderId) { - if (amountInSatoshis < (vm.minAmount * unitToSatoshi)) { + + } else if (amountInCrypto && vm.shapeshiftOrderId) { + if (amountInCrypto < vm.minAmount) { vm.errorMessage = gettextCatalog.getString('Amount is below minimum'); - } else if (amountInSatoshis > (vm.maxAmount * unitToSatoshi)) { + + } else if (amountInCrypto > vm.maxAmount) { vm.errorMessage = gettextCatalog.getString('Amount is above maximum'); + } else { vm.errorMessage = ''; } @@ -437,7 +441,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, amount: useSendMax ? undefined : satoshis, fromWalletId: passthroughParams.fromWalletId, sendMax: useSendMax, - thirdParty: passthroughParams.thirdParty, + thirdPartyOrderId: passthroughParams.thirdPartyOrderId, toAddr: passthroughParams.toAddress, toWalletId: passthroughParams.toWalletId }; @@ -456,7 +460,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, if (confirmData.sendMax) { var wallet = lodash.find(profileService.getWallets({ coin: coin }), function(w) { - return w.id == vm.fromWalletId; + return w.id == passthroughParams.fromWalletId; }); var balance = parseFloat(wallet.cachedBalance.substring(0, wallet.cachedBalance.length-4)); @@ -583,7 +587,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, }; function updateAvailableFundsStringIfNeeded() { - if (vm.fromWalletId && availableSatoshis !== null) { + if (passthroughParams.fromWalletId && availableSatoshis !== null) { availableFundsInFiat = ''; vm.availableFunds = availableFundsInCrypto; var coin = availableUnits[altUnitIndex].isFiat ? availableUnits[unitIndex].id : availableUnits[altUnitIndex].id; diff --git a/src/js/routes.js b/src/js/routes.js index e5430b5f5..7bb35a89f 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -287,7 +287,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr */ .state('tabs.send.amount', { - url: '/amount/:thirdParty/:fromWalletId/:toWalletId/:toAddress', + url: '/amount/:thirdPartyId/:thirdPartyOrderId/:fromWalletId/:maxAmount/:minAmount/:toWalletId/:toAddress', views: { 'tab-send@tabs': { controller: 'amountController', From e525b2e8addcb9fcd5d97c6a67c3cbc254c59c17 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 2 Aug 2018 18:14:54 +1200 Subject: [PATCH 208/386] UI for destination as wallet. --- src/js/controllers/review.controller.js | 85 ++++++++++++++++--------- src/js/routes.js | 2 +- www/views/review.html | 13 ++-- 3 files changed, 66 insertions(+), 34 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 9394b5ef2..686cb5787 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -10,8 +10,12 @@ function reviewController(configService, gettextCatalog, profileService, $scope, vm.destination = { address: '', balanceAmount: '', - balanceCurrecy: '', + balanceCurrency: '', + coin: '', color: '', + currency: '', + currencyColor: '', + kind: '', // 'address', 'contact', 'wallet' name: '' }; vm.feeCrypto = ''; @@ -29,6 +33,7 @@ function reviewController(configService, gettextCatalog, profileService, $scope, vm.secondaryAmount = ''; vm.secondaryCurrency = ''; + var config = null; var coin = ''; var originWalletId = ''; var priceDisplayIsFiat = true; @@ -54,61 +59,83 @@ function reviewController(configService, gettextCatalog, profileService, $scope, vm.origin.color = originWallet.color; vm.origin.name = originWallet.name; - destinationWalletId = data.stateParams.toWalletId; - if (destinationWalletId) { - var destinationWallet = profileService.getWallet(destinationWalletId); - vm.destination.color = destinationWallet.color; - vm.destination.name = destinationWallet.name; - - } - - configService.get(function onConfig(err, config) { + configService.get(function onConfig(err, configCache) { if (err) { $log.err('Error getting config.', err); } else { + config = configCache; priceDisplayIsFiat = config.wallet.settings.priceDisplay === 'fiat'; vm.origin.currencyColor = originWallet.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; } updateSendAmounts(); getOriginWalletBalance(originWallet); + handleDestinationAsWallet(data.stateParams.toWalletId); }); } function getOriginWalletBalance(originWallet) { - console.log('origin wallet error:', originWallet.error); + var balanceText = getWalletBalanceDisplayText(originWallet); + vm.origin.balanceAmount = balanceText.amount; + vm.origin.balanceCurrecny = balanceText.currency; + } + + function getWalletBalanceDisplayText(wallet) { var balanceCryptoAmount = ''; var balanceCryptoCurrencyCode = ''; var balanceFiatAmount = ''; var balanceFiatCurrency = '' + var displayAmount = ''; + var displayCurrency = ''; - var originWalletStatus = null; - if (originWallet.status.isValid) { - originWalletStatus = originWallet.status; - } else if (originWallet.cachedStatus.isValid) { - originWalletStatus = originWallet.cachedStatus; - } else { - vm.origin.balanceAmount = ''; - vm.origin.balanceCurrency = ''; - return; + var walletStatus = null; + if (wallet.status.isValid) { + walletStatus = wallet.status; + } else if (wallet.cachedStatus.isValid) { + walletStatus = wallet.cachedStatus; } - if (originWalletStatus) { - var cryptoBalanceParts = originWalletStatus.spendableBalanceStr.split(' '); + if (walletStatus) { + var cryptoBalanceParts = walletStatus.spendableBalanceStr.split(' '); balanceCryptoAmount = cryptoBalanceParts[0]; balanceCryptoCurrencyCode = cryptoBalanceParts.length > 1 ? cryptoBalanceParts[1] : ''; - if (originWalletStatus.alternativeBalanceAvailable) { - balanceFiatAmount = originWalletStatus.spendableBalanceAlternative; - balanceFiatCurrency = originWalletStatus.alternativeIsoCode; + if (walletStatus.alternativeBalanceAvailable) { + balanceFiatAmount = walletStatus.spendableBalanceAlternative; + balanceFiatCurrency = walletStatus.alternativeIsoCode; } } if (priceDisplayIsFiat) { - vm.origin.balanceAmount = balanceFiatAmount ? balanceFiatAmount : balanceCryptoAmount; - vm.origin.balanceCurrency = balanceFiatAmount ? balanceFiatCurrency : balanceCryptoCurrencyCode; + displayAmount = balanceFiatAmount ? balanceFiatAmount : balanceCryptoAmount; + displayCurrency = balanceFiatAmount ? balanceFiatCurrency : balanceCryptoCurrencyCode; } else { - vm.origin.balanceAmount = balanceCryptoAmount; - vm.origin.balanceCurrency = balanceCryptoCurrencyCode; + displayAmount = balanceCryptoAmount; + displayCurrency = balanceCryptoCurrencyCode; + } + + return { + amount: displayAmount, + currency: displayCurrency + }; + } + + function handleDestinationAsWallet(walletId) { + destinationWalletId = walletId; + if (destinationWalletId) { + var destinationWallet = profileService.getWallet(destinationWalletId); + vm.destination.coin = destinationWallet.coin; + vm.destination.color = destinationWallet.color; + vm.destination.currency = destinationWallet.coin.toUpperCase(); + vm.destination.kind = 'wallet'; + vm.destination.name = destinationWallet.name; + + if (config) { + vm.destination.currencyColor = vm.destination.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; + } + + var balanceText = getWalletBalanceDisplayText(destinationWallet); + vm.destination.balanceAmount = balanceText.amount; + vm.destination.balanceCurrency = balanceText.currency; } } diff --git a/src/js/routes.js b/src/js/routes.js index d38e0e0de..38941021c 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -317,7 +317,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }) .state('tabs.send.review', { - url: '/review/:coin/:fromWalletId/:amount/:useSendMax', + url: '/review/:amount/:fromWalletId/:sendMax/:toWalletId', views: { 'tab-send@tabs': { controller: 'reviewController', diff --git a/www/views/review.html b/www/views/review.html index 0ec643b8b..c1974a0dc 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -36,11 +36,16 @@
To:
- -

{{vm.destination.name}}

-

128.67

+ + +
+
+

{{vm.destination.name}} ({{vm.destination.currency}})

+

{{vm.destination.balanceAmount}} {{vm.destination.balanceCurrency}}

-
+
qz9cqq5pryv9hnqwa8q8mccmynk9uf4vlu5nxerpzmc
From aeb6efcdd0aef5153396b304564c31b391785cc1 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 2 Aug 2018 19:51:50 +1200 Subject: [PATCH 209/386] UI for sending to contact. --- src/js/controllers/review.controller.js | 71 +++++++++++++++++-------- src/js/routes.js | 2 +- 2 files changed, 51 insertions(+), 22 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 686cb5787..b81645488 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,7 +4,7 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController(configService, gettextCatalog, profileService, $scope, txFormatService) { +function reviewController(addressbookService, configService, profileService, $log, $scope, txFormatService) { var vm = this; vm.destination = { @@ -42,22 +42,20 @@ function reviewController(configService, gettextCatalog, profileService, $scope, var destinationWalletId = ''; - - $scope.$on("$ionicView.beforeEnter", onBeforeEnter); function onBeforeEnter(event, data) { - coin = data.stateParams.coin; originWalletId = data.stateParams.fromWalletId; satoshis = parseInt(data.stateParams.amount, 10); - toAddress = data.stateParams.toAddress; + toAddress = data.stateParams.toAddr; var originWallet = profileService.getWallet(originWalletId); vm.origin.currency = originWallet.coin.toUpperCase(); vm.origin.color = originWallet.color; vm.origin.name = originWallet.name; + coin = originWallet.coin; configService.get(function onConfig(err, configCache) { if (err) { @@ -69,6 +67,7 @@ function reviewController(configService, gettextCatalog, profileService, $scope, } updateSendAmounts(); getOriginWalletBalance(originWallet); + handleDestinationAsAddress(toAddress, coin); handleDestinationAsWallet(data.stateParams.toWalletId); }); } @@ -76,7 +75,7 @@ function reviewController(configService, gettextCatalog, profileService, $scope, function getOriginWalletBalance(originWallet) { var balanceText = getWalletBalanceDisplayText(originWallet); vm.origin.balanceAmount = balanceText.amount; - vm.origin.balanceCurrecny = balanceText.currency; + vm.origin.balanceCurrency = balanceText.currency; } function getWalletBalanceDisplayText(wallet) { @@ -119,24 +118,54 @@ function reviewController(configService, gettextCatalog, profileService, $scope, }; } + function handleDestinationAsAddress(address, originCoin) { + if (!address) { + return; + } + + // Check if the recipient is a contact + addressbookService.get(originCoin + address, function(err, contact) { + if (!err && contact) { + console.log('destination is contact'); + handleDestinationAsContact(contact); + } else { + console.log('destination is address'); + vm.destination.address = address; + vm.destination.kind = 'address'; + } + }); + + } + + function handleDestinationAsContact(contact) { + vm.destination.kind = 'contact'; + vm.destination.name = contact.name; + vm.destination.color = contact.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; + vm.destination.currency = contact.coin.toUpperCase(); + vm.destination.currencyColor = vm.destination.color; + } + function handleDestinationAsWallet(walletId) { destinationWalletId = walletId; - if (destinationWalletId) { - var destinationWallet = profileService.getWallet(destinationWalletId); - vm.destination.coin = destinationWallet.coin; - vm.destination.color = destinationWallet.color; - vm.destination.currency = destinationWallet.coin.toUpperCase(); - vm.destination.kind = 'wallet'; - vm.destination.name = destinationWallet.name; - - if (config) { - vm.destination.currencyColor = vm.destination.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; - } - - var balanceText = getWalletBalanceDisplayText(destinationWallet); - vm.destination.balanceAmount = balanceText.amount; - vm.destination.balanceCurrency = balanceText.currency; + if (!destinationWalletId) { + return; } + + console.log('destination is wallet'); + var destinationWallet = profileService.getWallet(destinationWalletId); + vm.destination.coin = destinationWallet.coin; + vm.destination.color = destinationWallet.color; + vm.destination.currency = destinationWallet.coin.toUpperCase(); + vm.destination.kind = 'wallet'; + vm.destination.name = destinationWallet.name; + + if (config) { + vm.destination.currencyColor = vm.destination.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; + } + + var balanceText = getWalletBalanceDisplayText(destinationWallet); + vm.destination.balanceAmount = balanceText.amount; + vm.destination.balanceCurrency = balanceText.currency; } function updateSendAmounts() { diff --git a/src/js/routes.js b/src/js/routes.js index 38941021c..4807fab5c 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -317,7 +317,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }) .state('tabs.send.review', { - url: '/review/:amount/:fromWalletId/:sendMax/:toWalletId', + url: '/review/:amount/:fromWalletId/:sendMax/:toAddr/:toWalletId', views: { 'tab-send@tabs': { controller: 'reviewController', From 4a1fd498f5952f18bb09f6e98ef13ba640477df4 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 2 Aug 2018 20:05:52 +1200 Subject: [PATCH 210/386] UI for sending to address. --- www/views/review.html | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/www/views/review.html b/www/views/review.html index c1974a0dc..36bb67410 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -35,7 +35,8 @@
To:
-
+
Date: Thu, 2 Aug 2018 20:43:18 +1200 Subject: [PATCH 211/386] UI for crypto fee. --- src/js/controllers/review.controller.js | 39 +++++++++++++++++++++++-- www/views/review.html | 7 ++--- 2 files changed, 38 insertions(+), 8 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index b81645488..f42d25350 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,7 +4,7 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController(addressbookService, configService, profileService, $log, $scope, txFormatService) { +function reviewController(addressbookService, configService, $ionicConfig, $log, profileService, $scope, txFormatService) { var vm = this; vm.destination = { @@ -18,7 +18,14 @@ function reviewController(addressbookService, configService, profileService, $lo kind: '', // 'address', 'contact', 'wallet' name: '' }; - vm.feeCrypto = ''; + vm.fee = { + cryptoAmount: '', + cryptoCurrencyCode: '', + cryptoDescription: '', + fiatAmount: '', + fiatCurrency: '' + }; + vm.fee vm.feeFiat = ''; vm.origin = { balanceAmount: '', @@ -34,6 +41,7 @@ function reviewController(addressbookService, configService, profileService, $lo vm.secondaryCurrency = ''; var config = null; + var configFeeLevel = ''; var coin = ''; var originWalletId = ''; var priceDisplayIsFiat = true; @@ -43,11 +51,25 @@ function reviewController(addressbookService, configService, profileService, $lo $scope.$on("$ionicView.beforeEnter", onBeforeEnter); + $scope.$on("$ionicView.beforeLeave", onBeforeLeave); + $scope.$on("$ionicView.enter", onEnter); + function onBeforeEnter(event, data) { + // Dummy values for testing + vm.fee = { + cryptoAmount: '0.00195823', + cryptoCurrencyCode: 'BCH', + cryptoDescription: 'Less than 1 cent', + fiatAmount: '', + fiatCurrency: '' + }; + originWalletId = data.stateParams.fromWalletId; + // For testing only + //originWalletId = data.stateParams.fromWalletId || 'bf00af8f-0788-4b57-b30a-0390747407e9'; satoshis = parseInt(data.stateParams.amount, 10); toAddress = data.stateParams.toAddr; @@ -65,12 +87,23 @@ function reviewController(addressbookService, configService, profileService, $lo priceDisplayIsFiat = config.wallet.settings.priceDisplay === 'fiat'; vm.origin.currencyColor = originWallet.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; } + + configFeeLevel = config.wallet.settings.feeLevel ? config.wallet.settings.feeLevel : 'normal'; + updateSendAmounts(); getOriginWalletBalance(originWallet); handleDestinationAsAddress(toAddress, coin); handleDestinationAsWallet(data.stateParams.toWalletId); }); - } + } + + function onBeforeLeave(event, data) { + $ionicConfig.views.swipeBackEnabled(true); + } + + function onEnter(event, data) { + $ionicConfig.views.swipeBackEnabled(false); + }; function getOriginWalletBalance(originWallet) { var balanceText = getWalletBalanceDisplayText(originWallet); diff --git a/www/views/review.html b/www/views/review.html index 36bb67410..f8b44c19a 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -73,11 +73,8 @@
Fee: Less than 1 cent
-
- +
+ {{vm.fee.cryptoAmount}} {{vm.fee.cryptoCurrencyCode}}
From 85a74bbd0e2f292035f471c591fc5cd3c5f1494c Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 2 Aug 2018 21:11:28 +1200 Subject: [PATCH 212/386] UI for crypto fee warning. --- src/js/controllers/review.controller.js | 10 ++++++---- www/views/review.html | 4 +++- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index f42d25350..5bf032fbd 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -21,9 +21,10 @@ function reviewController(addressbookService, configService, $ionicConfig, $log, vm.fee = { cryptoAmount: '', cryptoCurrencyCode: '', - cryptoDescription: '', + description: '', fiatAmount: '', - fiatCurrency: '' + fiatCurrency: '', + high: false }; vm.fee vm.feeFiat = ''; @@ -62,9 +63,10 @@ function reviewController(addressbookService, configService, $ionicConfig, $log, vm.fee = { cryptoAmount: '0.00195823', cryptoCurrencyCode: 'BCH', - cryptoDescription: 'Less than 1 cent', + description: 'Less than 1 cent', fiatAmount: '', - fiatCurrency: '' + fiatCurrency: '', + high: false }; originWalletId = data.stateParams.fromWalletId; diff --git a/www/views/review.html b/www/views/review.html index f8b44c19a..20cb2bd2d 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -72,7 +72,9 @@
-
Fee: Less than 1 cent
+
+ Fee: {{vm.fee.description}}{{vm.fee.fiatAmount}} {{vm.fee.fiatCurrency}} +
{{vm.fee.cryptoAmount}} {{vm.fee.cryptoCurrencyCode}}
From 01dd774faea3f2927379a89f8c2d55e37914c08c Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 2 Aug 2018 15:15:23 +0200 Subject: [PATCH 213/386] thirdParty updates + shapeshift screens + merged with review transaction --- src/js/controllers/amount.js | 46 +++++++-- src/js/routes.js | 2 +- src/js/services/incomingData.js | 2 +- src/js/services/shapeshiftService.js | 141 ++++++++++++++++++++++++++- src/sass/views/shapeshift.scss | 4 + www/img/shapeshift_swap.png | Bin 0 -> 209589 bytes www/views/amount.html | 8 +- www/views/shapeshift.html | 4 +- 8 files changed, 187 insertions(+), 20 deletions(-) create mode 100644 www/img/shapeshift_swap.png diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index b623aa592..88d4901e9 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -2,7 +2,7 @@ angular.module('copayApp.controllers').controller('amountController', amountController); -function amountController(configService, $filter, gettextCatalog, $ionicHistory, $ionicModal, $ionicScrollDelegate, lodash, $log, nodeWebkitService, rateService, $scope, $state, $timeout, txFormatService, platformInfo, profileService, walletService, $window) { +function amountController(configService, $filter, gettextCatalog, $ionicHistory, $ionicModal, $ionicScrollDelegate, lodash, $log, nodeWebkitService, rateService, $scope, $state, $timeout, shapeshiftService, txFormatService, platformInfo, profileService, walletService, $window) { var vm = this; vm.allowSend = false; @@ -21,6 +21,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, vm.maxAmount = 0; vm.minAmount = 0; vm.shapeshiftOrderId = ''; + vm.thirdParty = false; vm.unit = ''; vm.changeUnit = changeUnit; @@ -72,11 +73,39 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, passthroughParams = data.stateParams; console.log('stateParams:', data.stateParams); + vm.fromWalletId = data.stateParams.fromWalletId; + vm.toWalletId = data.stateParams.toWalletId; vm.minAmount = parseFloat(data.stateParams.minAmount); vm.maxAmount = parseFloat(data.stateParams.maxAmount); - vm.shapeshiftOrderId = data.stateParams.thirdPartyOrderId; + + if (passthroughParams.thirdParty) { + vm.thirdParty = JSON.parse(passthroughParams.thirdParty); // Parse stringified JSON-object + if (vm.thirdParty) { + if (vm.thirdParty.id === 'shapeshift') { + if (!vm.thirdParty.data) { + vm.thirdParty.data = {}; + } + vm.thirdParty.data['fromWalletId'] = vm.fromWalletId; + + vm.fromWallet = profileService.getWallet(vm.fromWalletId); + vm.toWallet = profileService.getWallet(vm.toWalletId); + + shapeshiftService.getMarketData(vm.fromWallet.coin, vm.toWallet.coin, function(data) { + console.log(data); + vm.thirdParty.data['minAmount'] = vm.minAmount = parseFloat(data.minimum); + vm.thirdParty.data['maxAmount'] = vm.maxAmount = parseFloat(data.maxLimit); + }); + + // if (vm.thirdParty.data['shapeshiftOrderId'] && data.stateParams.shapeshiftOrderId.length > 0) { + // vm.shapeshiftOrderId = vm.thirdParty.data['shapeshiftOrderId']; + // } + } + } + } + // vm.shapeshiftOrderId = data.stateParams.thirdPartyOrderId; vm.isRequestingSpecificAmount = !data.stateParams.fromWalletId; + var config = configService.getSync().wallet.settings; setAvailableUnits(); @@ -335,8 +364,8 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, if (a) { amountInCrypto = a; var amountInSatoshis = a * unitToSatoshi; - vm.fundsAreInsufficient = !!passthroughParams.fromWalletId - && availableSatoshis !== null + vm.fundsAreInsufficient = !!passthroughParams.fromWalletId + && availableSatoshis !== null && availableSatoshis < amountInSatoshis; vm.alternativeAmount = txFormatService.formatAmount(amountInSatoshis, true); @@ -356,8 +385,8 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, } } else { amountInCrypto = result; - vm.fundsAreInsufficient = passthroughParams.fromWalletId - && availableSatoshis !== null + vm.fundsAreInsufficient = passthroughParams.fromWalletId + && availableSatoshis !== null && availableSatoshis < result * unitToSatoshi; vm.alternativeAmount = $filter('formatFiatAmount')(toFiat(result)); @@ -441,11 +470,14 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, amount: useSendMax ? undefined : satoshis, fromWalletId: passthroughParams.fromWalletId, sendMax: useSendMax, - thirdPartyOrderId: passthroughParams.thirdPartyOrderId, toAddr: passthroughParams.toAddress, toWalletId: passthroughParams.toWalletId }; + if (vm.thirdParty) { + confirmData['thirdParty'] = JSON.stringify(this.thirdParty); + } + console.log('confirmData:', confirmData); if (!confirmData.fromWalletId) { diff --git a/src/js/routes.js b/src/js/routes.js index 286042266..d9c900e34 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -287,7 +287,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr */ .state('tabs.send.amount', { - url: '/amount/:thirdPartyId/:thirdPartyOrderId/:fromWalletId/:maxAmount/:minAmount/:toWalletId/:toAddress', + url: '/amount/:thirdParty/:fromWalletId/:maxAmount/:minAmount/:toWalletId/:toAddress', views: { 'tab-send@tabs': { controller: 'amountController', diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index 7a9e67fe7..fb8d8868a 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -86,7 +86,6 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat $state.transitionTo('tabs.send.origin', { amount: amount, toAddress: addr, - displayAddress: originalAddress ? originalAddress : addr, description: message, coin: coin }); @@ -109,6 +108,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat // params['thirdParty']['minShapeshiftAmount'] = serviceData.minAmount; // params['thirdParty']['maxShapeshiftAmount'] = serviceData.maxAmount; // params['thirdParty']['shapeshiftOrderId'] = serviceData.orderId; + params['thirdParty'] = JSON.stringify(params['thirdParty']); $state.transitionTo('tabs.send.amount', params); } else { $state.transitionTo('tabs.send.origin', params); diff --git a/src/js/services/shapeshiftService.js b/src/js/services/shapeshiftService.js index 8a9b8fcaa..41af14002 100644 --- a/src/js/services/shapeshiftService.js +++ b/src/js/services/shapeshiftService.js @@ -1,7 +1,143 @@ 'use strict'; -angular.module('copayApp.services').factory('shapeshiftService', function($http, $log, lodash, moment, storageService, configService, platformInfo, servicesService) { +angular.module('copayApp.services').factory('shapeshiftService', function($http, $log, lodash, moment, ongoingProcess, shapeshiftApiService, storageService, configService, platformInfo, servicesService) { var root = {}; - var credentials = {}; + root.ShiftState = 'Shift'; + root.withdrawalAddress = '' + root.returnAddress = '' + root.amount = ''; + root.marketData = {} + this.withdrawalAddress = function(address) { + root.withdrawalAddress = address; + }; + this.returnAddress = function(address) { + root.returnAddress = address; + }; + this.amount = function(amount) { + root.amount = amount; + }; + this.fromWalletId = function(id) { + root.fromWalletId = id; + }; + this.toWalletId = function(id) { + root.toWalletId = id; + }; + + root.getMarketDataIn = function(coin) { + if(coin === root.coinOut) return root.getMarketData(root.coinOut, root.coinIn); + return root.getMarketData(coin, root.coinOut); + }; + root.getMarketDataOut = function(coin) { + if(coin === root.coinIn) return root.getMarketData(root.coinOut, root.coinIn); + return root.getMarketData(root.coinIn, coin); + }; + root.getMarketData = function(coinIn, coinOut, cb) { + root.coinIn = coinIn; + root.coinOut= coinOut; + if(root.coinIn === undefined || root.coinOut === undefined) return; + shapeshiftApiService + .marketInfo(root.coinIn, root.coinOut) + .then(function(marketData){ + root.marketData = marketData; + root.rateString = root.marketData.rate.toString() + ' ' + coinOut.toUpperCase() + '/' + coinIn.toUpperCase(); + if (cb) { + cb(marketData); + } + }); + }; + + /*shapeshiftApiService.coins().then(function(coins){ + root.coins = coins; + root.coinIn = coins['BTC'].symbol; + root.coinOut = coins['BCH'].symbol; + root.getMarketData(root.coinIn, root.coinOut); + });*/ + + root.coins = { + 'BTC': { name: 'Bitcoin', symbol: 'BTC' }, + 'BCH': { name: 'Bitcoin Cash', symbol: 'BCH' } + }; + + function checkForError(data){ + if(data.error) return true; + return false; + } + + root.shiftIt = function(){ + ongoingProcess.set('connectingShapeshift', true); + var validate=shapeshiftApiService.ValidateAddress(root.withdrawalAddress, root.coinOut); + validate.then(function(valid){ + //console.log(root.withdrawalAddress) + //console.log(valid) + var tx = ShapeShift(); + tx.then(function(txData){ + if(txData['fixedTxData']){ + txData = txData.fixedTxData; + if(checkForError(txData)) return; + //console.log(txData) + var coinPair=txData.pair.split('_'); + txData.depositType = coinPair[0].toUpperCase(); + txData.withdrawalType = coinPair[1].toUpperCase(); + var coin = root.coins[txData.depositType].name.toLowerCase(); + //console.log(coin) + txData.depositQR = coin + ":" + txData.deposit + "?amount=" + txData.depositAmount + root.txFixedPending = true; + } else if(txData['normalTxData']){ + txData = txData.normalTxData; + if(checkForError(txData)) return; + var coin = root.coins[txData.depositType.toUpperCase()].name.toLowerCase(); + txData.depositQR = coin + ":" + txData.deposit; + } else if(txData['cancelTxData']){ + if(checkForError(txData.cancelTxData)) return; + if(root.txFixedPending) { + $interval.cancel(root.txInterval); + root.txFixedPending = false; + } + root.ShiftState = 'Shift'; + return; + } + root.depositInfo = txData; + //console.log(root.marketData); + //console.log(root.depositInfo); + var sendAddress = txData.depositQR; + if (sendAddress && sendAddress.indexOf('bitcoin cash') >= 0) + sendAddress = sendAddress.replace('bitcoin cash', 'bitcoincash'); + + var shapeshiftData = { + fromWalletId: root.fromWalletId, + minAmount: root.marketData.minimum, + maxAmount: root.marketData.maxLimit, + orderId: root.depositInfo.orderId + }; + + if (incomingData.redir(sendAddress, shapeshiftData)) { + ongoingProcess.set('connectingShapeshift', false); + return; + } + + /*root.ShiftState = 'Cancel'; + root.GetStatus(); + root.txInterval=$interval(root.GetStatus, 8000);*/ + }); + }) + }; + + function ShapeShift() { + if(root.ShiftState === 'Cancel') return shapeshiftApiService.CancelTx(root); + if(parseFloat(root.amount) > 0) return shapeshiftApiService.FixedAmountTx(root); + return shapeshiftApiService.NormalTx(root); + } + + root.GetStatus = function(){ + var address = root.depositInfo.deposit + shapeshiftApiService.GetStatusOfDepositToAddress(address).then(function(data){ + root.DepositStatus = data; + if(root.DepositStatus.status === 'complete'){ + $interval.cancel(root.txInterval); + root.depositInfo = null; + root.ShiftState = 'Shift' + } + }); + }; var servicesItem = { name: 'shapeshift', @@ -13,7 +149,6 @@ angular.module('copayApp.services').factory('shapeshiftService', function($http, var register = function() { servicesService.register(servicesItem); }; - register(); return root; }); diff --git a/src/sass/views/shapeshift.scss b/src/sass/views/shapeshift.scss index 8b4b941ab..1054fece2 100644 --- a/src/sass/views/shapeshift.scss +++ b/src/sass/views/shapeshift.scss @@ -1,4 +1,8 @@ #shapeshift { + .swap-image { + width: 70%; + max-width: 400px; + } .empty-case { @include empty-case(); } diff --git a/www/img/shapeshift_swap.png b/www/img/shapeshift_swap.png new file mode 100644 index 0000000000000000000000000000000000000000..83905b75141199bfdc0831c1a3cc309317da07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/views/amount.html index 1757bf25a..e5df7dc0f 100644 --- a/www/views/amount.html +++ b/www/views/amount.html @@ -6,15 +6,11 @@ - +

-
diff --git a/www/views/shapeshift.html b/www/views/shapeshift.html index 2382f9897..81e502631 100644 --- a/www/views/shapeshift.html +++ b/www/views/shapeshift.html @@ -11,8 +11,8 @@
-
- Your Bitcoin wallet is empty +
+
From aacc80ea218b678d6c26e9a591b44d118bf48e79 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 2 Aug 2018 15:42:35 +0200 Subject: [PATCH 214/386] shapeshift flow --- src/js/controllers/amount.js | 3 +-- src/js/controllers/review.controller.js | 17 ++++++++++++++++- src/js/routes.js | 2 +- src/sass/views/amount.scss | 3 +++ src/sass/views/shapeshift.scss | 3 +++ www/views/amount.html | 6 +++--- www/views/review.html | 3 ++- www/views/shapeshift.html | 4 +--- .../shapeshift-header.html} | 0 www/views/walletSelector.html | 2 +- 10 files changed, 31 insertions(+), 12 deletions(-) rename www/views/{header-thirdparty.html => thirdparty/shapeshift-header.html} (100%) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 88d4901e9..576fb4500 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -506,8 +506,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, } } - $state.transitionTo('tabs.send.review', confirmData); - } + $state.transitionTo('tabs.send.review', confirmData); $scope.useSendMax = null; } }; diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index b81645488..edf7787d5 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -6,7 +6,7 @@ angular function reviewController(addressbookService, configService, profileService, $log, $scope, txFormatService) { var vm = this; - + vm.destination = { address: '', balanceAmount: '', @@ -32,6 +32,7 @@ function reviewController(addressbookService, configService, profileService, $lo vm.primaryCurrency = ''; vm.secondaryAmount = ''; vm.secondaryCurrency = ''; + vm.thirdParty = false; var config = null; var coin = ''; @@ -57,6 +58,20 @@ function reviewController(addressbookService, configService, profileService, $lo vm.origin.name = originWallet.name; coin = originWallet.coin; + if (data.stateParams.thirdParty) { + vm.thirdParty = JSON.parse(data.stateParams.thirdParty); // Parse stringified JSON-object + if (vm.thirdParty) { + if (vm.thirdParty.id === 'shapeshift') { + if (!vm.thirdParty.data) { + vm.thirdParty.data = {}; + } + vm.thirdParty.data['fromWalletId'] = vm.fromWalletId; + vm.fromWallet = profileService.getWallet(vm.fromWalletId); + vm.toWallet = profileService.getWallet(vm.toWalletId); + } + } + } + configService.get(function onConfig(err, configCache) { if (err) { $log.err('Error getting config.', err); diff --git a/src/js/routes.js b/src/js/routes.js index d9c900e34..905683dcb 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -345,7 +345,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }) .state('tabs.send.review', { - url: '/review/:amount/:fromWalletId/:sendMax/:toAddr/:toWalletId', + url: '/review/:thirdParty/:amount/:fromWalletId/:sendMax/:toAddr/:toWalletId', views: { 'tab-send@tabs': { controller: 'reviewController', diff --git a/src/sass/views/amount.scss b/src/sass/views/amount.scss index daf6cf4fe..ca32c6ac4 100644 --- a/src/sass/views/amount.scss +++ b/src/sass/views/amount.scss @@ -254,6 +254,9 @@ padding: 0 6px 6px 6px; text-align: center; } + &__max { + float: right; + } } .send-amount-tool { diff --git a/src/sass/views/shapeshift.scss b/src/sass/views/shapeshift.scss index 1054fece2..158babb16 100644 --- a/src/sass/views/shapeshift.scss +++ b/src/sass/views/shapeshift.scss @@ -15,4 +15,7 @@ border: 0px; @include button-shadow(); } +} +.header.shapeshift { + background: #243F5D; } \ No newline at end of file diff --git a/www/views/amount.html b/www/views/amount.html index e5df7dc0f..48637ec1b 100644 --- a/www/views/amount.html +++ b/www/views/amount.html @@ -6,17 +6,17 @@ -
+
- {{vm.amount}} {{vm.unit}} + {{vm.amount || '0'}} {{vm.unit}}
{{vm.globalResult}} {{vm.unit}}
diff --git a/www/views/review.html b/www/views/review.html index 36bb67410..b9c190ab5 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -9,7 +9,8 @@ -
+
+

You are sending

{{vm.primaryAmount}} {{vm.primaryCurrency}}

diff --git a/www/views/shapeshift.html b/www/views/shapeshift.html index 81e502631..764ef8851 100644 --- a/www/views/shapeshift.html +++ b/www/views/shapeshift.html @@ -7,9 +7,7 @@ -
- -
+
diff --git a/www/views/header-thirdparty.html b/www/views/thirdparty/shapeshift-header.html similarity index 100% rename from www/views/header-thirdparty.html rename to www/views/thirdparty/shapeshift-header.html diff --git a/www/views/walletSelector.html b/www/views/walletSelector.html index a4cc4db81..49a7ba208 100644 --- a/www/views/walletSelector.html +++ b/www/views/walletSelector.html @@ -4,7 +4,7 @@ -
+
Paying
$... USD
From f49e8725e8543f852f612b069b561d23bbe4c833 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 2 Aug 2018 16:05:12 +0200 Subject: [PATCH 215/386] Translations additions + some (s)css + review transaction changes --- i18n/po/template.pot | 19 ++++++++++++++++++- src/js/controllers/review.controller.js | 4 +++- src/sass/views/review.scss | 4 ++++ src/sass/views/shapeshift.scss | 6 ++++-- www/views/review.html | 16 +++------------- www/views/shapeshift.html | 5 ++--- 6 files changed, 34 insertions(+), 20 deletions(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index 2e7cedcbe..ecf44efe9 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -2651,6 +2651,7 @@ msgid "You can receive bitcoin from any wallet or service." msgstr "" #: www/views/tab-send.html:72 +#: www/views/shapeshift.html:23 msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." msgstr "" @@ -3116,6 +3117,18 @@ msgstr "" msgid "Start ShapeShift" msgstr "" +#: www/views/shapeshift.html:30 +msgid "Exchange your BTC to BCH in minutes." +msgstr "" + +#: www/views/shapeshift.html:30 +msgid "To start the process you need to add funds to your wallet." +msgstr "" + +#: www/views/shapeshift.html:30 +msgid "he process is fast and you will receive the exchanged amount in your wallet." +msgstr "" + #: www/views/shapeshift.html:34 msgid "This service is provided by the third-party ShapeShift, who will charge a small fee for the service. The fee will be shown before you start the transaction." msgstr "" @@ -3720,10 +3733,14 @@ msgstr "" msgid "Review Transaction" msgstr "" -#: www/views/review.html:14 +#: src/js/controllers/review.controller.js:36 msgid "You are sending" msgstr "" +#: src/js/controllers/review.controller.js:66 +msgid "You are shifting" +msgstr "" + #: www/views/review.html:22 msgid "From:" msgstr "" diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index edf7787d5..473ac4452 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,7 +4,7 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController(addressbookService, configService, profileService, $log, $scope, txFormatService) { +function reviewController(addressbookService, configService, gettextCatalog, profileService, $log, $scope, txFormatService) { var vm = this; vm.destination = { @@ -33,6 +33,7 @@ function reviewController(addressbookService, configService, profileService, $lo vm.secondaryAmount = ''; vm.secondaryCurrency = ''; vm.thirdParty = false; + vm.sendingTitle = gettextCatalog.getString('You are sending'); var config = null; var coin = ''; @@ -62,6 +63,7 @@ function reviewController(addressbookService, configService, profileService, $lo vm.thirdParty = JSON.parse(data.stateParams.thirdParty); // Parse stringified JSON-object if (vm.thirdParty) { if (vm.thirdParty.id === 'shapeshift') { + vm.sendingTitle = gettextCatalog.getString('You are shifting'); if (!vm.thirdParty.data) { vm.thirdParty.data = {}; } diff --git a/src/sass/views/review.scss b/src/sass/views/review.scss index 67733fe22..22470a7b2 100644 --- a/src/sass/views/review.scss +++ b/src/sass/views/review.scss @@ -10,4 +10,8 @@ position: absolute; bottom: 92px; } + + .shapeshift-banner { + box-shadow: none; + } } \ No newline at end of file diff --git a/src/sass/views/shapeshift.scss b/src/sass/views/shapeshift.scss index 158babb16..ee4cd0b0f 100644 --- a/src/sass/views/shapeshift.scss +++ b/src/sass/views/shapeshift.scss @@ -1,7 +1,8 @@ #shapeshift { .swap-image { - width: 70%; + width: auto; max-width: 400px; + max-height: 25vh; } .empty-case { @include empty-case(); @@ -17,5 +18,6 @@ } } .header.shapeshift { - background: #243F5D; + background: url(../img/shapeshiftbg.jpg) center center no-repeat #28394d; + opacity: 0.99; } \ No newline at end of file diff --git a/www/views/review.html b/www/views/review.html index b9c190ab5..e398e68a1 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -12,7 +12,7 @@
-

You are sending

+

{{vm.sendingTitle}}

{{vm.primaryAmount}} {{vm.primaryCurrency}}

{{vm.secondaryAmount}} {{vm.secondaryCurrency}}

@@ -84,13 +84,13 @@ {{buttonText}} @@ -104,14 +104,4 @@ Proposal Created Transaction Created - - - - diff --git a/www/views/shapeshift.html b/www/views/shapeshift.html index 764ef8851..61ad0952e 100644 --- a/www/views/shapeshift.html +++ b/www/views/shapeshift.html @@ -13,12 +13,11 @@
+

Exchange your BTC to BCH in minutes.

-

Before exchanging your BTC to BCH, you will need to add funds to your wallet.

-

You can receive Bitcoin from any wallet or service.

+

To start the process you need to add funds to your wallet.

-

Using Shapeshift will allow you to exchange your BTC for BCH.

The process is fast and you will receive the exchanged amount in your wallet.

To get started, you'll need to create a bitcoin wallet and get some bitcoin.
From 66c9cefb0c539ed1817b3ecb7674082a5eb9f924 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 3 Aug 2018 01:15:54 +0900 Subject: [PATCH 216/386] Fix the tx history --- src/js/services/walletService.js | 42 +++++++++++++++++++++++++------- 1 file changed, 33 insertions(+), 9 deletions(-) diff --git a/src/js/services/walletService.js b/src/js/services/walletService.js index 774fa0906..7ea98600f 100644 --- a/src/js/services/walletService.js +++ b/src/js/services/walletService.js @@ -343,21 +343,23 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim if (err) return cb(err); if (!txsFromServer.length) - return cb(); + return cb(null, []); - var res = lodash.takeWhile(txsFromServer, function(tx) { + /*var res = lodash.takeWhile(txsFromServer, function(tx) { return tx.txid != endingTxid; - }); + });*/ - return cb(null, res, res.length >= limit); + return cb(null, txsFromServer); }); }; var removeAndMarkSoftConfirmedTx = function(txs) { return lodash.filter(txs, function(tx) { - if (tx.confirmations >= root.SOFT_CONFIRMATION_LIMIT) - return tx; - tx.recent = true; + var isConfirm = (tx.confirmations >= root.SOFT_CONFIRMATION_LIMIT); + if (!isConfirm) { + tx.recent = true; + } + return isConfirm; }); } @@ -437,12 +439,14 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim var endingTxid = confirmedTxs[0] ? confirmedTxs[0].txid : null; var endingTs = confirmedTxs[0] ? confirmedTxs[0].time : null; + $log.debug('Confirmed TXs. Got:' + confirmedTxs.length + '/' + txsFromLocal.length); + // First update progressFn(txsFromLocal, 0); wallet.completeHistory = txsFromLocal; function getNewTxs(newTxs, skip, next) { - getTxsFromServer(wallet, skip, endingTxid, requestLimit, function(err, res, shouldContinue) { + getTxsFromServer(wallet, skip, endingTxid, requestLimit, function(err, res) { if (err) { $log.warn(bwcError.msg(err, 'Server Error')); //TODO if (err instanceof errors.CONNECTION_ERROR || (err.message && err.message.match(/5../))) { @@ -454,7 +458,27 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim return next(err); } - newTxs = newTxs.concat(processNewTxs(wallet, lodash.compact(res))); + // Check if new txs are founds, if yes, lets investigate in the 50 next + // To be sure we are not missing txs by order (maybe a new tx is after the "endingTxid" + + var newDiscoveredTxs = res.filter(function (x) { + return confirmedTxs.filter(function (confX) { + return confX.txid == x.txid; + }).length == 0; + }); + + $log.debug('Discovering TXs. Got:' + newDiscoveredTxs.length); + + /*var newDiscoveredTxs = lodash.uniq(lodash.union(res, newTxs), function(x) { + return x.txid; + });*/ + + var shouldContinue = newDiscoveredTxs.length > 0; + + // If no new tx, no need to check + if (shouldContinue) { + newTxs = newTxs.concat(processNewTxs(wallet, lodash.compact(newDiscoveredTxs))); + } progressFn(newTxs.concat(txsFromLocal), newTxs.length); From 9c8ec7d3a21f890d73ac18dc84a82e76c99266fe Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 3 Aug 2018 01:17:01 +0900 Subject: [PATCH 217/386] Fix tx history --- src/js/services/walletService.js | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/src/js/services/walletService.js b/src/js/services/walletService.js index 7ea98600f..cb04ffbe3 100644 --- a/src/js/services/walletService.js +++ b/src/js/services/walletService.js @@ -345,10 +345,6 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim if (!txsFromServer.length) return cb(null, []); - /*var res = lodash.takeWhile(txsFromServer, function(tx) { - return tx.txid != endingTxid; - });*/ - return cb(null, txsFromServer); }); }; @@ -459,8 +455,7 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim } // Check if new txs are founds, if yes, lets investigate in the 50 next - // To be sure we are not missing txs by order (maybe a new tx is after the "endingTxid" - + // To be sure we are not missing txs by sorting (maybe a new tx is after the "endingTxid" var newDiscoveredTxs = res.filter(function (x) { return confirmedTxs.filter(function (confX) { return confX.txid == x.txid; @@ -469,10 +464,6 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim $log.debug('Discovering TXs. Got:' + newDiscoveredTxs.length); - /*var newDiscoveredTxs = lodash.uniq(lodash.union(res, newTxs), function(x) { - return x.txid; - });*/ - var shouldContinue = newDiscoveredTxs.length > 0; // If no new tx, no need to check From eef84b25f80063b547b078406247e4e10a350fee Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 2 Aug 2018 18:30:35 +0200 Subject: [PATCH 218/386] update to txp creation. merged and refactored many features from confirm.js --- src/js/controllers/confirm.js | 3 +- src/js/controllers/review.controller.js | 425 +++++++++++++++++++++- src/js/directives/shapeshiftCoinTrader.js | 2 +- src/js/services/shapeshiftService.js | 2 +- www/views/review.html | 16 +- 5 files changed, 428 insertions(+), 20 deletions(-) diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index 762bfe42b..07256c0b2 100644 --- a/src/js/controllers/confirm.js +++ b/src/js/controllers/confirm.js @@ -140,7 +140,7 @@ angular.module('copayApp.controllers').controller('confirmController', function( return cb(); }); - } + }; $scope.$on("$ionicView.beforeEnter", function(event, data) { $scope.fromWallet = profileService.getWallet(data.stateParams.fromWalletId); // Wallet to send from @@ -463,7 +463,6 @@ angular.module('copayApp.controllers').controller('confirmController', function( } }; - $scope.toggleAddress = function() { $scope.showAddress = !$scope.showAddress; }; diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 473ac4452..f0a0ec2ae 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,7 +4,7 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController(addressbookService, configService, gettextCatalog, profileService, $log, $scope, txFormatService) { +function reviewController($log, $scope, $ionicLoading, $ionicModal, $timeout, addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, configService, feeService, gettextCatalog, lodash, ongoingProcess, platformInfo, profileService, walletService, txFormatService) { var vm = this; vm.destination = { @@ -20,6 +20,8 @@ function reviewController(addressbookService, configService, gettextCatalog, pro }; vm.feeCrypto = ''; vm.feeFiat = ''; + vm.fiatCurrency = ''; + vm.feeLessThanACent = false; vm.origin = { balanceAmount: '', balanceCurrency: '', @@ -28,21 +30,30 @@ function reviewController(addressbookService, configService, gettextCatalog, pro currencyColor: '', name: '', }; + vm.isCordova = platformInfo.isCordova; vm.primaryAmount = ''; vm.primaryCurrency = ''; + vm.usingMerchantFee = false; vm.secondaryAmount = ''; vm.secondaryCurrency = ''; vm.thirdParty = false; vm.sendingTitle = gettextCatalog.getString('You are sending'); + vm.buttonText = ''; var config = null; var coin = ''; + var countDown = null; + var usingCustomFee = false; + var usingMerchantFee = false; + var destinationWalletId = ''; var originWalletId = ''; + var originWallet; var priceDisplayIsFiat = true; var satoshis = null; var toAddress = ''; - var destinationWalletId = ''; + var tx = {}; + var FEE_TOO_HIGH_LIMIT_PERCENTAGE = 15; $scope.$on("$ionicView.beforeEnter", onBeforeEnter); @@ -53,7 +64,7 @@ function reviewController(addressbookService, configService, gettextCatalog, pro satoshis = parseInt(data.stateParams.amount, 10); toAddress = data.stateParams.toAddr; - var originWallet = profileService.getWallet(originWalletId); + originWallet = profileService.getWallet(originWalletId); vm.origin.currency = originWallet.coin.toUpperCase(); vm.origin.color = originWallet.color; vm.origin.name = originWallet.name; @@ -68,8 +79,6 @@ function reviewController(addressbookService, configService, gettextCatalog, pro vm.thirdParty.data = {}; } vm.thirdParty.data['fromWalletId'] = vm.fromWalletId; - vm.fromWallet = profileService.getWallet(vm.fromWalletId); - vm.toWallet = profileService.getWallet(vm.toWalletId); } } } @@ -86,15 +95,186 @@ function reviewController(addressbookService, configService, gettextCatalog, pro getOriginWalletBalance(originWallet); handleDestinationAsAddress(toAddress, coin); handleDestinationAsWallet(data.stateParams.toWalletId); + createVanityTransaction(data); }); - } + } + vm.chooseFeeLevel = function(tx, wallet) { + + if (wallet.coin == 'bch') return; + if (usingMerchantFee) return; + + var scope = $rootScope.$new(true); + scope.network = tx.network; + scope.feeLevel = tx.feeLevel; + scope.noSave = true; + scope.coin = originWallet.coin; + + if (usingCustomFee) { + scope.customFeePerKB = tx.feeRate; + scope.feePerSatByte = tx.feeRate / 1000; + } + + $ionicModal.fromTemplateUrl('views/modals/chooseFeeLevel.html', { + scope: scope, + backdropClickToClose: false, + hardwareBackButtonClose: false + }).then(function(modal) { + scope.chooseFeeLevelModal = modal; + scope.openModal(); + }); + scope.openModal = function() { + scope.chooseFeeLevelModal.show(); + }; + + scope.hideModal = function(newFeeLevel, customFeePerKB) { + scope.chooseFeeLevelModal.hide(); + $log.debug('New fee level choosen:' + newFeeLevel + ' was:' + tx.feeLevel); + + usingCustomFee = newFeeLevel == 'custom' ? true : false; + + if (tx.feeLevel == newFeeLevel && !usingCustomFee) return; + + tx.feeLevel = newFeeLevel; + if (usingCustomFee) tx.feeRate = parseInt(customFeePerKB); + + updateTx(tx, originWallet, { + clearCache: true, + dryRun: true + }, function() {}); + }; + }; + + function createVanityTransaction(data) { + var configFeeLevel = config.wallet.settings.feeLevel ? config.wallet.settings.feeLevel : 'normal'; + + // Grab stateParams + tx = { + amount: parseInt(data.stateParams.amount), + sendMax: data.stateParams.useSendMax == 'true' ? true : false, + fromWalletId: data.stateParams.fromWalletId, + toAddress: data.stateParams.toAddress, + feeLevel: configFeeLevel, + spendUnconfirmed: config.wallet.spendUnconfirmed, + + // Vanity tx info (not in the real tx) + recipientType: vm.destination.kind || null, + toName: vm.destination.name || null, + toEmail: vm.destination.email || null, + toColor: vm.destination.color || null, + network: false, + coin: originWallet.coin, + txp: {}, + }; + + if (data.stateParams.requiredFeeRate) { + vm.usingMerchantFee = true; + tx.feeRate = parseInt(data.stateParams.requiredFeeRate); + } + + if (tx.coin && tx.coin === 'bch') { + tx.feeLevel = 'normal'; + } + + var B = data.stateParams.coin === 'bch' ? bitcoreCash : bitcore; + var networkName; + try { + if (vm.destination.kind === 'wallet') { // There is a wallet-to-wallet transfer + $ionicLoading.show(); + var toWallet = profileService.getWallet(data.stateParams.toWalletId); + + // We need an address to send to, so we ask the walletService to create a new address for the toWallet. + walletService.getAddress(toWallet, true, function (err, addr) { + $ionicLoading.hide(); + tx.toAddress = addr; + networkName = (new B.Address(tx.toAddress)).network.name; + tx.network = networkName; + setupTx(tx); + }); + } else { // This is a Wallet-to-address transfer + networkName = (new B.Address(tx.toAddress)).network.name; + tx.network = networkName; + setupTx(tx); + } + } catch (e) { + var message = gettextCatalog.getString('Invalid address'); + popupService.showAlert(null, message, function () { + $ionicHistory.nextViewOptions({ + disableAnimate: true, + historyRoot: true + }); + $state.go('tabs.send').then(function () { + $ionicHistory.clearHistory(); + }); + }); + return; + } + } function getOriginWalletBalance(originWallet) { var balanceText = getWalletBalanceDisplayText(originWallet); vm.origin.balanceAmount = balanceText.amount; vm.origin.balanceCurrency = balanceText.currency; } + function getSendMaxInfo(tx, wallet, cb) { + if (!tx.sendMax) return cb(); + + //ongoingProcess.set('retrievingInputs', true); + walletService.getSendMaxInfo(wallet, { + feePerKb: tx.feeRate, + excludeUnconfirmedUtxos: !tx.spendUnconfirmed, + returnInputs: true, + }, cb); + }; + + function getTxp(tx, wallet, dryRun, cb) { + + // ToDo: use a credential's (or fc's) function for this + if (tx.description && !wallet.credentials.sharedEncryptingKey) { + var msg = gettextCatalog.getString('Could not add message to imported wallet without shared encrypting key'); + $log.warn(msg); + return setSendError(msg); + } + + if (tx.amount > Number.MAX_SAFE_INTEGER) { + var msg = gettextCatalog.getString('Amount too big'); + $log.warn(msg); + return setSendError(msg); + } + + var txp = {}; + + txp.outputs = [{ + 'toAddress': tx.toAddress, + 'amount': tx.amount, + 'message': tx.description + }]; + + if (tx.sendMaxInfo) { + txp.inputs = tx.sendMaxInfo.inputs; + txp.fee = tx.sendMaxInfo.fee; + } else { + if (usingCustomFee || usingMerchantFee) { + txp.feePerKb = tx.feeRate; + } else txp.feeLevel = tx.feeLevel; + } + + txp.message = tx.description; + + if (tx.paypro) { + txp.payProUrl = tx.paypro.url; + } + txp.excludeUnconfirmedUtxos = !tx.spendUnconfirmed; + txp.dryRun = dryRun; + walletService.createTx(wallet, txp, function(err, ctxp) { + if (err) { + setSendError(err); + return cb(err); + } + return cb(null, ctxp); + }); + }; + function getWalletBalanceDisplayText(wallet) { var balanceCryptoAmount = ''; var balanceCryptoCurrencyCode = ''; @@ -157,7 +337,8 @@ function reviewController(addressbookService, configService, gettextCatalog, pro function handleDestinationAsContact(contact) { vm.destination.kind = 'contact'; vm.destination.name = contact.name; - vm.destination.color = contact.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; + vm.destination.email = contact.email; + vm.destination.color = contact.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; vm.destination.currency = contact.coin.toUpperCase(); vm.destination.currencyColor = vm.destination.color; } @@ -228,4 +409,234 @@ function reviewController(addressbookService, configService, gettextCatalog, pro }); } + function setButtonText(isMultisig, isPayPro) { + if (isPayPro) { + if (vm.isCordova) { + vm.buttonText = gettextCatalog.getString('Slide to pay'); + } else { + vm.buttonText = gettextCatalog.getString('Click to pay'); + } + } else if (isMultisig) { + if (vm.isCordova) { + vm.buttonText = gettextCatalog.getString('Slide to accept'); + } else { + vm.buttonText = gettextCatalog.getString('Click to accept'); + } + } else { + if (vm.isCordova) { + vm.buttonText = gettextCatalog.getString('Slide to send'); + } else { + vm.buttonText = gettextCatalog.getString('Click to send'); + } + } + } + + function setupTx(tx) { + if (tx.coin === 'bch') { + tx.displayAddress = bitcoinCashJsService.readAddress(tx.toAddress).cashaddr; + } else { + tx.displayAddress = entry.address; + } + + addressbookService.get(tx.coin+tx.toAddress, function(err, addr) { // Check if the recipient is a contact + if (!err && addr) { + tx.toName = addr.name; + tx.toEmail = addr.email; + tx.recipientType = 'contact'; + } + }); + + // Other Scope vars + vm.showAddress = false; + + + setButtonText(originWallet.credentials.m > 1, !!tx.paypro); + + if (tx.paypro) + _paymentTimeControl(tx.paypro.expires); + + updateTx(tx, originWallet, { + dryRun: true + }, function(err) { + $timeout(function() { + $scope.$apply(); + }, 10); + + }); + + // setWalletSelector(tx.coin, tx.network, tx.amount, function(err) { + // if (err) { + // return exitWithError('Could not update wallets'); + // } + // + // if (vm.wallets.length > 1) { + // vm.showWalletSelector(); + // } else if (vm.wallets.length) { + // setWallet(vm.wallets[0], tx); + // } + // }); + } + function updateTx(tx, wallet, opts, cb) { + ongoingProcess.set('calculatingFee', true); + + if (opts.clearCache) { + tx.txp = {}; + } + + // $scope.tx = tx; + + // function updateAmount() { + // if (!tx.amount) return; + // + // // Amount + // tx.amountStr = txFormatService.formatAmountStr(originWallet.coin, tx.amount); + // tx.amountValueStr = tx.amountStr.split(' ')[0]; + // tx.amountUnitStr = tx.amountStr.split(' ')[1]; + // txFormatService.formatAlternativeStr(wallet.coin, tx.amount, function(v) { + // var parts = v.split(' '); + // tx.alternativeAmountStr = v; + // tx.alternativeAmountValueStr = parts[0]; + // tx.alternativeAmountUnitStr = (parts.length > 0) ? parts[1] : ''; + // }); + // } + // + // updateAmount(); + // refresh(); + + // End of quick refresh, before wallet is selected. + if (!wallet) { + ongoingProcess.set('calculatingFee', false); + return cb(); + } + + var feeServiceLevel = usingMerchantFee && originWallet.coin == 'btc' ? 'urgent' : tx.feeLevel; + feeService.getFeeRate(originWallet.coin, tx.network, feeServiceLevel, function(err, feeRate) { + if (err) { + ongoingProcess.set('calculatingFee', false); + return cb(err); + } + + var msg; + if (usingCustomFee) { + msg = gettextCatalog.getString('Custom'); + tx.feeLevelName = msg; + } else if (usingMerchantFee) { + $log.info('Using Merchant Fee:' + tx.feeRate + ' vs. Urgent level:' + feeRate); + msg = gettextCatalog.getString('Suggested by Merchant'); + tx.feeLevelName = msg; + } else { + tx.feeLevelName = feeService.feeOpts[tx.feeLevel]; + tx.feeRate = feeRate; + } + + getSendMaxInfo(lodash.clone(tx), wallet, function(err, sendMaxInfo) { + if (err) { + ongoingProcess.set('calculatingFee', false); + var msg = gettextCatalog.getString('Error getting SendMax information'); + return setSendError(msg); + } + + if (sendMaxInfo) { + + $log.debug('Send max info', sendMaxInfo); + + if (tx.sendMax && sendMaxInfo.amount == 0) { + ongoingProcess.set('calculatingFee', false); + setNoWallet(gettextCatalog.getString('Insufficient confirmed funds')); + popupService.showAlert(gettextCatalog.getString('Error'), gettextCatalog.getString('Not enough funds for fee')); + return cb('no_funds'); + } + + tx.sendMaxInfo = sendMaxInfo; + tx.amount = tx.sendMaxInfo.amount; + updateAmount(); + ongoingProcess.set('calculatingFee', false); + $timeout(function() { + showSendMaxWarning(wallet, sendMaxInfo); + }, 200); + } + + // txp already generated for this wallet? + if (tx.txp[wallet.id]) { + ongoingProcess.set('calculatingFee', false); + updateSendAmounts(); + return cb(); + } + + getTxp(lodash.clone(tx), wallet, opts.dryRun, function(err, txp) { + ongoingProcess.set('calculatingFee', false); + if (err) { + if (err.message == 'Insufficient funds') { + setNoWallet(gettextCatalog.getString('Insufficient funds')); + popupService.showAlert(gettextCatalog.getString('Error'), gettextCatalog.getString('Not enough funds for fee')); + return cb('no_funds'); + } else + return cb(err); + } + + txp.feeStr = txFormatService.formatAmountStr(wallet.coin, txp.fee); + txFormatService.formatAlternativeStr(wallet.coin, txp.fee, function(v) { + // txp.alternativeFeeStr = v; + // if (txp.alternativeFeeStr.substring(0, 4) == '0.00') + // txp.alternativeFeeStr = '< ' + txp.alternativeFeeStr; + vm.feeFiat = v; + vm.fiatCurrency = config.wallet.settings.alternativeIsoCode; + if (v.substring(0, 1) === "<") { + vm.feeLessThanACent = true; + } + + console.log("fiat", vm.feeFiat); + + }); + + var per = (txp.fee / (txp.amount + txp.fee) * 100); + var perString = per.toFixed(2); + txp.feeRatePerStr = (perString == '0.00' ? '< ' : '') + perString + '%'; + txp.feeToHigh = per > FEE_TOO_HIGH_LIMIT_PERCENTAGE; + vm.feeCrypto = txp.fee; + console.log("crypto", vm.feeCrypto); + + + tx.txp[wallet.id] = txp; + $log.debug('Confirm. TX Fully Updated for wallet:' + wallet.id, tx); + updateSendAmounts(); + + return cb(); + }); + }); + }); + } + + function _paymentTimeControl(expirationTime) { + $scope.paymentExpired = false; + setExpirationTime(); + + countDown = $interval(function() { + setExpirationTime(); + }, 1000); + + function setExpirationTime() { + var now = Math.floor(Date.now() / 1000); + + if (now > expirationTime) { + setExpiredValues(); + return; + } + + var totalSecs = expirationTime - now; + var m = Math.floor(totalSecs / 60); + var s = totalSecs % 60; + $scope.remainingTimeStr = ('0' + m).slice(-2) + ":" + ('0' + s).slice(-2); + }; + + function setExpiredValues() { + $scope.paymentExpired = true; + $scope.remainingTimeStr = gettextCatalog.getString('Expired'); + if (countDown) $interval.cancel(countDown); + $timeout(function() { + $scope.$apply(); + }); + }; + }; + } diff --git a/src/js/directives/shapeshiftCoinTrader.js b/src/js/directives/shapeshiftCoinTrader.js index d5c62f431..60cc66bdf 100644 --- a/src/js/directives/shapeshiftCoinTrader.js +++ b/src/js/directives/shapeshiftCoinTrader.js @@ -111,7 +111,7 @@ angular.module('copayApp.directives').directive('shapeshiftCoinTrader', function orderId: $scope.depositInfo.orderId }; - if (incomingData.redir(sendAddress, shapeshiftData)) { + if (incomingData.redir(sendAddress, 'shapeshift', shapeshiftData)) { ongoingProcess.set('connectingShapeshift', false); return; } diff --git a/src/js/services/shapeshiftService.js b/src/js/services/shapeshiftService.js index 41af14002..131df0cd0 100644 --- a/src/js/services/shapeshiftService.js +++ b/src/js/services/shapeshiftService.js @@ -109,7 +109,7 @@ angular.module('copayApp.services').factory('shapeshiftService', function($http, orderId: root.depositInfo.orderId }; - if (incomingData.redir(sendAddress, shapeshiftData)) { + if (incomingData.redir(sendAddress, 'shapeshift', shapeshiftData)) { ongoingProcess.set('connectingShapeshift', false); return; } diff --git a/www/views/review.html b/www/views/review.html index e398e68a1..a26143d2c 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -13,7 +13,7 @@

{{vm.sendingTitle}}

-

{{vm.primaryAmount}} {{vm.primaryCurrency}}

+

{{vm.primaryAmount}} {{vm.primaryCurrency}}

{{vm.secondaryAmount}} {{vm.secondaryCurrency}}

@@ -73,24 +73,22 @@
-
Fee: Less than 1 cent
-
- +
Fee: Less than 1 cent
+
Fee:
+
+
{{buttonText}} From f75866839523806056403e01be65f65584aa2550 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 3 Aug 2018 08:48:24 +1200 Subject: [PATCH 219/386] Title on wallet-to-wallet destination screen. --- src/js/controllers/walletSelectorController.js | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index 4f0533084..f73bd4830 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -5,9 +5,17 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.$on("$ionicView.beforeEnter", function(event, data) { var config = configService.getSync().wallet.settings; - $scope.sendFlowTitle = ""; - if ($state.current.name === 'tabs.send.wallet-to-wallet') { - $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); + switch($state.current.name) { + case 'tabs.send.wallet-to-wallet': + $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); + break; + case 'tabs.send.destination': + if (data.stateParams.fromWalletId) { + $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); + } + break; + default: + // nop } $scope.params = $state.params; From 6626663a313d6d90c6066f8481eb04777492a7b8 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 3 Aug 2018 10:41:21 +1200 Subject: [PATCH 220/386] Displays error when transaction amount too low. Reinstated warning colour for transactions with high fees. --- src/js/controllers/review.controller.js | 18 +++++++++++++++--- www/views/review.html | 6 +++--- 2 files changed, 18 insertions(+), 6 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index f0a0ec2ae..85950a8aa 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,7 +4,7 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController($log, $scope, $ionicLoading, $ionicModal, $timeout, addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, configService, feeService, gettextCatalog, lodash, ongoingProcess, platformInfo, profileService, walletService, txFormatService) { +function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, configService, feeService, gettextCatalog, $ionicLoading, $ionicModal, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, $timeout, txFormatService, walletService) { var vm = this; vm.destination = { @@ -21,6 +21,7 @@ function reviewController($log, $scope, $ionicLoading, $ionicModal, $timeout, ad vm.feeCrypto = ''; vm.feeFiat = ''; vm.fiatCurrency = ''; + vm.feeIsHigh = false; vm.feeLessThanACent = false; vm.origin = { balanceAmount: '', @@ -52,6 +53,7 @@ function reviewController($log, $scope, $ionicLoading, $ionicModal, $timeout, ad var satoshis = null; var toAddress = ''; var tx = {}; + var unitFromSat = 0; var FEE_TOO_HIGH_LIMIT_PERCENTAGE = 15; @@ -89,7 +91,8 @@ function reviewController($log, $scope, $ionicLoading, $ionicModal, $timeout, ad } else { config = configCache; priceDisplayIsFiat = config.wallet.settings.priceDisplay === 'fiat'; - vm.origin.currencyColor = originWallet.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; + vm.origin.currencyColor = originWallet.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; + unitFromSat = 1 / config.wallet.settings.unitToSatoshi; } updateSendAmounts(); getOriginWalletBalance(originWallet); @@ -431,6 +434,14 @@ function reviewController($log, $scope, $ionicLoading, $ionicModal, $timeout, ad } } + function setSendError(msg) { + $scope.sendStatus = ''; + $timeout(function() { + $scope.$apply(); + }); + popupService.showAlert(gettextCatalog.getString('Error at confirm'), bwcError.msg(msg)); + }; + function setupTx(tx) { if (tx.coin === 'bch') { tx.displayAddress = bitcoinCashJsService.readAddress(tx.toAddress).cashaddr; @@ -593,7 +604,8 @@ function reviewController($log, $scope, $ionicLoading, $ionicModal, $timeout, ad var perString = per.toFixed(2); txp.feeRatePerStr = (perString == '0.00' ? '< ' : '') + perString + '%'; txp.feeToHigh = per > FEE_TOO_HIGH_LIMIT_PERCENTAGE; - vm.feeCrypto = txp.fee; + vm.feeCrypto = (unitFromSat * txp.fee).toFixed(8); + vm.feeIsHigh = txp.feeToHigh; console.log("crypto", vm.feeCrypto); diff --git a/www/views/review.html b/www/views/review.html index a26143d2c..c1f37baf9 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -73,10 +73,10 @@
-
Fee: Less than 1 cent
-
Fee:
+
Fee: Less than 1 cent
+
Fee: {{vm.feeFiat}} {{vm.feeCurrency}}
- + {{vm.feeCrypto}} {{vm.origin.currency}}
From 9e5bd663a7c7146729de82d8d5772c2d361b3954 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 3 Aug 2018 10:37:49 +0900 Subject: [PATCH 221/386] Update appConfig.json --- app-template/bitcoincom/appConfig.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app-template/bitcoincom/appConfig.json b/app-template/bitcoincom/appConfig.json index 238f38002..084a586ce 100644 --- a/app-template/bitcoincom/appConfig.json +++ b/app-template/bitcoincom/appConfig.json @@ -24,9 +24,9 @@ "windowsAppId": "804636ee-b017-4cad-8719-e58ac97ffa5c", "pushSenderId": "1036948132229", "description": "A Secure Bitcoin Wallet", - "version": "4.13.1", - "fullVersion": "4.13-rc2", - "androidVersion": "413100", + "version": "4.13.2", + "fullVersion": "4.13-rc3", + "androidVersion": "413200", "_extraCSS": "", "_enabledExtensions": { "coinbase": false, From e649da69ef124605199f3d69085a739fb176f53f Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 3 Aug 2018 17:11:47 +1200 Subject: [PATCH 222/386] In WalletService, createAddress now terminated properly, preventing double callback. --- src/js/services/walletService.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/js/services/walletService.js b/src/js/services/walletService.js index 774fa0906..a69b505c1 100644 --- a/src/js/services/walletService.js +++ b/src/js/services/walletService.js @@ -884,7 +884,7 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim var createAddress = function(wallet, cb) { $log.debug('Creating address for wallet:', wallet.id); - wallet.createAddress({}, function(err, addr) { + wallet.createAddress({}, function onWalletCreatedAddress(err, addr) { if (err) { var prefix = gettextCatalog.getString('Could not create address'); if (err instanceof errors.CONNECTION_ERROR || (err.message && err.message.match(/5../))) { @@ -902,6 +902,7 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim if (err) return cb(err); return cb(null, addr[0].address); }); + return; } return bwcError.cb(err, prefix, cb); } From f96610a66b7016e1e65b65e87ea44ff670ae6acd Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Fri, 3 Aug 2018 13:34:09 +0800 Subject: [PATCH 223/386] Removes border and background from Paste Address button for send tab page --- src/sass/views/tab-send.scss | 2 + www/css/main.css | 1524 ++++++++++++++++++++++------------ 2 files changed, 982 insertions(+), 544 deletions(-) diff --git a/src/sass/views/tab-send.scss b/src/sass/views/tab-send.scss index 4fbe8e531..82b6f8d02 100644 --- a/src/sass/views/tab-send.scss +++ b/src/sass/views/tab-send.scss @@ -88,6 +88,8 @@ &.contains-address { .address { display: inline; + border: none; + background-color: transparent; } .non-address { display: none; diff --git a/www/css/main.css b/www/css/main.css index b4e67edac..e39d96cf3 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -9970,7 +9970,7 @@ ion-nav-bar.hide { .card { margin: 20px 14px; } -ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm:before, ion-view#copayers-invitation:before, ion-view#tab-home:before, ion-view#tab-receive:before, ion-view#tab-send:before, ion-view.settings:before, ion-view#bitpayCard:before, ion-view#bitpayCard-intro:before, ion-view#view-address-book:before, ion-view#addresses:before, ion-view#send-feedback:before, ion-view#choose-fee-level:before, ion-view#txp-details:before, ion-view#coinbase:before, ion-view#glidera:before, ion-view#amazon:before, ion-view#mercadolibre:before, ion-view#custom-amount:before { +ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm:before, ion-view#copayers-invitation:before, ion-view#tab-home:before, ion-view#tab-receive:before, ion-view#tab-send:before, ion-view.settings:before, ion-view#bitpayCard:before, ion-view#bitpayCard-intro:before, ion-view#view-address-book:before, ion-view#addresses:before, ion-view#choose-fee-level:before, ion-view#txp-details:before, ion-view#coinbase:before, ion-view#glidera:before, ion-view#amazon:before, ion-view#mercadolibre:before, ion-view#custom-amount:before { content: " "; display: block; position: absolute; @@ -9980,7 +9980,7 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm height: 44px; background-color: #fab915; } -.platform-ios.platform-cordova:not(.fullscreen) ion-view.deflash-blue:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-amount:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-confirm:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#copayers-invitation:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-home:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-receive:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-send:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view.settings:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#bitpayCard:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#bitpayCard-intro:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-address-book:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#addresses:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#send-feedback:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#choose-fee-level:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#txp-details:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#coinbase:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#glidera:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#amazon:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#mercadolibre:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#custom-amount:before { +.platform-ios.platform-cordova:not(.fullscreen) ion-view.deflash-blue:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-amount:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-confirm:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#copayers-invitation:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-home:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-receive:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#tab-send:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view.settings:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#bitpayCard:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#bitpayCard-intro:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#view-address-book:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#addresses:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#choose-fee-level:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#txp-details:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#coinbase:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#glidera:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#amazon:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#mercadolibre:before, .platform-ios.platform-cordova:not(.fullscreen) ion-view#custom-amount:before { height: 64px; } .just-a-hint, .icon.bp-arrow-right, .icon.bp-arrow-down, .icon.bp-arrow-up { @@ -10037,6 +10037,11 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm .big-icon-svg.theme-circle > .bg.icon-faucet { background-image: url("../img/icon-faucet.svg"); background-size: 70%; } + .big-icon-svg.theme-circle > .bg.icon-wallet { + background-color: #FAB915; + background-image: url("../img/icon-wallet.svg"); + border: none; + box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.3) inset; } .big-icon-svg.theme-circle-services > .bg { border: 1px solid #191919; } .big-icon-svg.theme-circle-community > .bg { @@ -10071,11 +10076,13 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm .loading .spinner svg { margin-top: 0; } -.button.button-primary.button-standard, .button.button-secondary.button-standard, .button.button-light.button-standard, .button.button-assertive.button-standard, +.button.button-primary.button-standard, .button.button-secondary.button-standard, .button.button-light.button-standard, .button.button-white.button-standard, .button.button-green.button-standard, .button.button-assertive.button-standard, .onboarding .button.button-primary.button-standard, .onboarding .button.button-secondary.button-standard, .onboarding .button.button-light.button-standard, -.onboarding .button.button-assertive.button-standard { +.onboarding .button.button-white.button-standard, +.onboarding .button.button-green.button-standard, +.onboarding .button.button-assertive.button-standard, #shapeshift .button-shapeshift { width: 85%; max-width: 300px; margin-left: auto; @@ -10118,10 +10125,12 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm box-shadow: none; color: #fff; } -.button.button-primary.button-standard + .button-standard, .button.button-secondary.button-standard + .button-standard, .button.button-light.button-standard + .button-standard, .button.button-assertive.button-standard + .button-standard, +.button.button-primary.button-standard + .button-standard, .button.button-secondary.button-standard + .button-standard, .button.button-light.button-standard + .button-standard, .button.button-white.button-standard + .button-standard, .button.button-green.button-standard + .button-standard, .button.button-assertive.button-standard + .button-standard, .onboarding .button.button-primary.button-standard + .button-standard, .onboarding .button.button-secondary.button-standard + .button-standard, .onboarding .button.button-light.button-standard + .button-standard, +.onboarding .button.button-white.button-standard + .button-standard, +.onboarding .button.button-green.button-standard + .button-standard, .onboarding .button.button-assertive.button-standard + .button-standard { margin-top: 1rem; } @@ -10183,8 +10192,67 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm font-size: 0.7em !important; display: inline !important; } -.button.button-full { - display: block; } +.button { + border-radius: 6px; } + .button.button-full { + display: block; } + .button-green { + border-color: #FFF; + background-color: #719561; + color: #FFF; + border: 0px; + box-shadow: 0 2px 11px 0 #C1C1C1; } + .button-green:hover { + color: #FFF; + text-decoration: none; } + .button-green.active, .button-green.activated { + border-color: #FFF; + background-color: #606060; } + .button-green.button-clear { + border-color: transparent; + background: none; + box-shadow: none; + color: #FFF; } + .button-green.button-icon { + border-color: transparent; + background: none; } + .button-green.button-outline { + border-color: #C1C1C1; + background: transparent; + color: #C1C1C1; } + .button-green.button-outline.active, .button-green.button-outline.activated { + background-color: #C1C1C1; + box-shadow: none; + color: #fff; } + .button-white { + border-color: #C1C1C1; + background-color: #FFF; + color: #606060; + box-shadow: 0 2px 11px 0 #C1C1C1; } + .button-white:hover { + color: #606060; + text-decoration: none; } + .button-white.active, .button-white.activated { + border-color: #FFF; + background-color: #C1C1C1; } + .button-white.button-clear { + border-color: transparent; + background: none; + box-shadow: none; + color: #FFF; } + .button-white.button-icon { + border-color: transparent; + background: none; } + .button-white.button-outline { + border-color: #C1C1C1; + background: transparent; + color: #C1C1C1; } + .button-white.button-outline.active, .button-white.button-outline.activated { + background-color: #C1C1C1; + box-shadow: none; + color: #fff; } + .button-white.activated { + color: #FFF; } .button-clear { background: none !important; } @@ -10197,6 +10265,22 @@ textarea.d-block { display: block; width: 100%; } +qrcode { + position: relative; } + qrcode.qr-overlay::before { + content: ""; + background-size: 100% 100%; + display: block; + left: 88px; + margin-top: 88px; + width: 44px; + height: 44px; + position: absolute; } + qrcode.qr-overlay--bch::before { + background-image: url("../img/qr-overlay-bch.png"); } + qrcode.qr-overlay--btc::before { + background-image: url("../img/qr-overlay-btc.png"); } + .center-block { float: none; margin: 0 auto; } @@ -10208,6 +10292,15 @@ textarea.d-block { top: 50%; left: 50%; } +.third-party-notice { + font-size: 12px; + margin: 0px 14px; + font-weight: 600; + color: #6F6F70; } + @media (min-width: 768px) { + .third-party-notice { + text-align: center; } } + .tabs .tab-item .icon { background-repeat: no-repeat; background-position: center; @@ -10237,6 +10330,10 @@ textarea.d-block { font-weight: 700; } #tab-home .card > .item-heading .icon, #tab-home .list > .item-heading .icon, #tab-send .card > .item-heading .icon, #tab-send .list > .item-heading .icon { color: #667; } + #tab-home .card > .item-heading .subtitle, #tab-home .list > .item-heading .subtitle, #tab-send .card > .item-heading .subtitle, #tab-send .list > .item-heading .subtitle { + color: #667; + font-size: 12px; + font-weight: 300; } #view-add .item { margin-bottom: 10px; @@ -10260,349 +10357,397 @@ textarea.d-block { #view-add .bg.join { padding: 10px; } -#view-amount .recipient-label { - font-size: 14px; - padding-bottom: 0; - color: #667; } - -#view-amount .item-no-bottom-border + .item { - border-top: 0; } - -#view-amount .icon-bitpay-card { - background-image: url("../img/icon-bitpay.svg"); } - -#view-amount .icon-amazon { - background-image: url("../img/icon-amazon.svg"); } - -@media (max-width: 480px) { - #view-amount .bitcoin-address { - font-size: 13px; - padding-left: 48px; } - #view-amount .bitcoin-address .icon { - left: 8px; - font-size: 24px; } - #view-amount .bitcoin-address .big-icon-svg { - left: 5px; } - #view-amount .bitcoin-address .big-icon-svg > .bg { - width: 30px; - height: 30px; - box-shadow: none; } } - -@media (max-width: 320px) { - #view-amount .bitcoin-address > span:last-child { - margin-left: -2px; } } - -#view-amount .send-gravatar { - left: 11px; - position: absolute; - top: 10px; } - -#view-amount .amount span input { - display: inline; - width: 120px; } - -#view-amount .amount-pane-recipient { - position: absolute; - top: 95px; - bottom: 0; - width: 100%; - background-color: #fff; - padding: 0 16px; } - #view-amount .amount-pane-recipient .amount-bar { - padding: 24px 0; - font-size: 18px; } - @media (max-height: 480px) { - #view-amount .amount-pane-recipient .amount-bar { - padding: 0px; } } - @media (max-width: 320px) { - #view-amount .amount-pane-recipient .amount-bar { - padding: 0px; } } - #view-amount .amount-pane-recipient .amount-bar .title { - float: left; - padding-top: 10px; - color: #445; - font-weight: bold; } +#view-amount { + background: #f2f2f2; } + #view-amount .recipient-label { + font-size: 14px; + padding-bottom: 0; + color: #667; } + #view-amount .item-no-bottom-border + .item { + border-top: 0; } + #view-amount .icon-bitpay-card { + background-image: url("../img/icon-bitpay.svg"); } + #view-amount .icon-amazon { + background-image: url("../img/icon-amazon.svg"); } + @media (max-width: 480px) { + #view-amount .bitcoin-address { + font-size: 13px; + padding-left: 48px; } + #view-amount .bitcoin-address .icon { + left: 8px; + font-size: 24px; } + #view-amount .bitcoin-address .big-icon-svg { + left: 5px; } + #view-amount .bitcoin-address .big-icon-svg > .bg { + width: 30px; + height: 30px; + box-shadow: none; } } + @media (max-width: 320px) { + #view-amount .bitcoin-address > span:last-child { + margin-left: -2px; } } + #view-amount .send-gravatar { + left: 11px; + position: absolute; + top: 10px; } + #view-amount .amount span input { + display: inline; + width: 120px; } + #view-amount .amount-pane-recipient { + position: absolute; + top: 95px; + bottom: 0; + width: 100%; + background-color: #fff; + padding: 0 16px; } + #view-amount .amount-pane-recipient .amount-bar { + padding: 24px 0; + font-size: 18px; } @media (max-height: 480px) { - #view-amount .amount-pane-recipient .amount-bar .title { + #view-amount .amount-pane-recipient .amount-bar { padding: 0px; } } - @media (max-height: 480px) { - #view-amount .amount-pane-recipient .amount-bar { - padding-top: 3px; } } - #view-amount .amount-pane-recipient .amount { - display: flex; - flex-direction: column; - justify-content: center; - flex-grow: 1; + @media (max-width: 320px) { + #view-amount .amount-pane-recipient .amount-bar { + padding: 0px; } } + #view-amount .amount-pane-recipient .amount-bar .title { + float: left; + padding-top: 10px; + color: #445; + font-weight: bold; } + @media (max-height: 480px) { + #view-amount .amount-pane-recipient .amount-bar .title { + padding: 0px; } } + @media (max-height: 480px) { + #view-amount .amount-pane-recipient .amount-bar { + padding-top: 3px; } } + #view-amount .amount-pane-recipient .amount { + display: flex; + flex-direction: column; + justify-content: center; + flex-grow: 1; + position: absolute; + bottom: 254px; + top: 66px; } + #view-amount .amount-pane-recipient .amount .light { + color: #9b9bab; } + @media (max-height: 480px) { + #view-amount .amount-pane-recipient .amount { + top: 45px; } } + @media (max-width: 320px) { + #view-amount .amount-pane-recipient .amount { + bottom: 276px; + top: 60px; } + #view-amount .amount-pane-recipient .amount > div { + display: inline-block; } + #view-amount .amount-pane-recipient .amount > div:first-child { + display: inherit; } } + #view-amount .amount-pane-no-recipient { position: absolute; - bottom: 254px; - top: 66px; } - #view-amount .amount-pane-recipient .amount .light { - color: #9b9bab; } - @media (max-height: 480px) { - #view-amount .amount-pane-recipient .amount { - top: 45px; } } - @media (max-width: 320px) { - #view-amount .amount-pane-recipient .amount { - bottom: 276px; - top: 60px; } - #view-amount .amount-pane-recipient .amount > div { - display: inline-block; } - #view-amount .amount-pane-recipient .amount > div:first-child { - display: inherit; } } - -#view-amount .amount-pane-no-recipient { - position: absolute; - top: 0; - bottom: 0; - width: 100%; - background-color: #fff; - padding: 0 16px; } - #view-amount .amount-pane-no-recipient .amount-bar { - padding: 24px 0; - font-size: 18px; } - #view-amount .amount-pane-no-recipient .amount-bar .title { - padding-top: 10px; + top: 0; + bottom: 0; + width: 100%; + background-color: #fff; + padding: 0 16px; } + #view-amount .amount-pane-no-recipient .amount-bar { + padding: 24px 0; + font-size: 18px; } + #view-amount .amount-pane-no-recipient .amount-bar .title { + padding-top: 10px; + color: #445; + font-weight: bold; } + #view-amount .amount-pane-no-recipient .amount-bar .title .limits { + margin-top: 10px; + color: #9b9bab; + font-size: 12px; } + #view-amount .amount-pane-no-recipient .amount-bar .title .select { + margin: 10px 1px; } + #view-amount .amount-pane-no-recipient .amount { + display: flex; + flex-direction: column; + justify-content: center; + flex-grow: 1; + position: absolute; + bottom: 254px; + top: 66px; } + #view-amount .amount-pane-no-recipient .amount .light { + color: #9b9bab; } + #view-amount .amount { + padding-top: 10px; + padding-bottom: 10px; } + #view-amount .amount .icon-toggle { + font-size: 1.2em; + width: auto; + margin: 0.8em auto; + border: 1px solid #f2f2f2; color: #445; - font-weight: bold; } - #view-amount .amount-pane-no-recipient .amount-bar .title .limits { - margin-top: 10px; - color: #9b9bab; - font-size: 12px; } - #view-amount .amount-pane-no-recipient .amount-bar .title .select { - margin: 10px 1px; } - #view-amount .amount-pane-no-recipient .amount { - display: flex; - flex-direction: column; - justify-content: center; - flex-grow: 1; - position: absolute; - bottom: 254px; - top: 66px; } - #view-amount .amount-pane-no-recipient .amount .light { + border-radius: 3px; + padding: 0 10px; + cursor: pointer; } + @media (max-height: 280px) { + #view-amount .amount .icon-toggle { + margin: 0.1em auto; } } + #view-amount .amount__editable--minimize { + font-size: 22px; } + #view-amount .amount__editable--standard { + font-size: 42px; } + @media (max-height: 480px) { + #view-amount .amount__editable--standard { + font-size: 26px; + padding-top: 10px; } } + #view-amount .amount__editable--placeholder { color: #9b9bab; } - -#view-amount .amount { - padding-top: 10px; - padding-bottom: 10px; } - #view-amount .amount .icon-toggle { - font-size: 1.2em; - width: auto; - margin: 0.8em auto; - border: 1px solid #f2f2f2; - color: #445; - border-radius: 3px; - padding: 0 10px; - cursor: pointer; } - @media (max-height: 280px) { - #view-amount .amount .icon-toggle { - margin: 0.1em auto; } } - #view-amount .amount__editable--minimize { - font-size: 22px; } - #view-amount .amount__editable--standard { - font-size: 42px; } - @media (max-height: 480px) { - #view-amount .amount__editable--standard { - font-size: 26px; - padding-top: 10px; } } - #view-amount .amount__editable--placeholder { - color: #9b9bab; } - #view-amount .amount__number { - color: #445; } - #view-amount .amount__currency-toggle { - border: 1px solid #f2f2f2; - color: #445; - border-radius: 3px; - padding: 0 10px; - cursor: pointer; - font-size: .6em; - position: relative; - top: -3px; - line-height: 1; } - @media (max-width: 320px) { - #view-amount .amount__currency-toggle { - line-height: 30px; - height: 30px; } } - #view-amount .amount__currency-toggle-mobile { - border: 1px solid #f2f2f2; - color: #445; - border-radius: 3px; - cursor: pointer; - position: relative; - line-height: 1; } - @media (max-width: 320px) { - #view-amount .amount__currency-toggle-mobile { - line-height: 30px; - height: 30px; } } - #view-amount .amount__results--minimize { - font-size: 12px; } - #view-amount .amount__results--standard { - font-size: 18px; - padding: 10px 0; } - #view-amount .amount__results--placeholder { - color: #9b9bab; } - #view-amount .amount__result { - color: #9b9bab; - font-size: .9em; - line-height: 1; } - @media (max-height: 480px) { - #view-amount .amount__result { - margin-bottom: 0; } } - #view-amount .amount__result-equiv { - color: #667; - font-size: 1.2em; } - @media (max-height: 480px) { - #view-amount .amount__result-equiv { - margin-top: 0; - font-size: 16px; } } - -#view-amount .scroll-content { - display: flex; - flex-direction: column; } - #view-amount .scroll-content .send-amount { - flex: 1 1 auto; + #view-amount .amount__number { + color: #445; } + #view-amount .amount__currency-toggle { + border: 1px solid #f2f2f2; + color: #445; + border-radius: 3px; + padding: 0 10px; + cursor: pointer; + font-size: .6em; + position: relative; + top: -3px; + line-height: 1; } + @media (max-width: 320px) { + #view-amount .amount__currency-toggle { + line-height: 30px; + height: 30px; } } + #view-amount .amount__currency-toggle-mobile { + border: 1px solid #f2f2f2; + color: #445; + border-radius: 3px; + cursor: pointer; + position: relative; + line-height: 1; } + @media (max-width: 320px) { + #view-amount .amount__currency-toggle-mobile { + line-height: 30px; + height: 30px; } } + #view-amount .amount__results--minimize { + font-size: 12px; } + #view-amount .amount__results--standard { + font-size: 18px; + padding: 10px 0; } + #view-amount .amount__results--placeholder { + color: #9b9bab; } + #view-amount .amount__result { + color: #9b9bab; + font-size: .9em; + line-height: 1; } + @media (max-height: 480px) { + #view-amount .amount__result { + margin-bottom: 0; } } + #view-amount .amount__result-equiv { + color: #667; + font-size: 1.2em; } + @media (max-height: 480px) { + #view-amount .amount__result-equiv { + margin-top: 0; + font-size: 16px; } } + #view-amount .scroll-content { display: flex; - flex-direction: column; - justify-content: center; } - #view-amount .scroll-content .send-amount .send-amount-tool { - flex: 0 1 auto; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input { - text-align: center; - position: relative; - padding: 10px 30px; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .text-selectable { - -webkit-user-select: text; - -moz-user-select: text; - -ms-user-select: text; - user-select: text; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - font-size: 1.8em; } - @media (min-width: 375px) { + flex-direction: column; } + #view-amount .scroll-content .send-amount { + flex: 1 1 auto; + display: flex; + flex-direction: column; + justify-content: center; } + #view-amount .scroll-content .send-amount .send-amount-header-footer { + flex: 1 1 auto; + min-height: 20px; } + #view-amount .scroll-content .send-amount .send-amount-header-footer .warning { + font-weight: bold; + font-size: 12px; + padding: 0 6px 6px 6px; + text-align: center; } + #view-amount .scroll-content .send-amount .send-amount-header-footer__max { + float: right; } + #view-amount .scroll-content .send-amount .send-amount-tool { + flex: 0 1 auto; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input { + text-align: center; + position: relative; + padding: 10px 30px; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .text-selectable { + -webkit-user-select: text; + -moz-user-select: text; + -ms-user-select: text; + user-select: text; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount { + color: #333; + font-weight: bold; } #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - font-size: 2.1em; } } - @media (min-width: 414px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - font-size: 2.4em; } } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { - font-size: 1.6em; } - @media (min-width: 375px) { + font-size: 1.8em; } + @media (min-width: 375px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + font-size: 2.1em; } } + @media (min-width: 414px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + font-size: 2.4em; } } #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { - font-size: 1.8em; } } - @media (min-width: 414px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { - font-size: 2em; } } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { - font-size: 0.9em; } - @media (min-width: 375px) { + font-size: 1.6em; } + @media (min-width: 375px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { + font-size: 1.8em; } } + @media (min-width: 414px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.long .primary-amount-display { + font-size: 2em; } } #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { - font-size: 1.3em; } } - @media (min-width: 414px) { - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { - font-size: 1.4em; } } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input { - border: 0; - padding: 0; - white-space: normal; - background: none; - line-height: 1; - box-sizing: content-box; - display: inline-block; - vertical-align: middle; - margin: 0; - height: 1em; - margin-right: 5px; - font-family: 'ProximaNova'; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - display: inline-block; - vertical-align: middle; - line-height: 1em; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit { - font-weight: bold; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { - margin-right: 5px; - word-break: break-all; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .switch-currencies { - position: absolute; - right: 0; - top: 50%; - transform: translate(0, -50%); - padding: 15px; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .switch-currencies img { - width: 18px; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions { - margin-top: 15px; + font-size: 0.9em; } + @media (min-width: 375px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { + font-size: 1.3em; } } + @media (min-width: 414px) { + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long input, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .unit, #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount.very-long .primary-amount-display { + font-size: 1.4em; } } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount input { + border: 0; + padding: 0; + white-space: normal; + background: none; + line-height: 1; + box-sizing: content-box; + display: inline-block; + vertical-align: middle; + margin: 0; + height: 1em; + margin-right: 5px; + font-family: 'ProximaNova'; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .unit, + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + display: inline-block; + vertical-align: middle; + line-height: 1em; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .primary-amount .primary-amount-display { + margin-right: 5px; + word-break: break-all; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .alternative-amount { + color: #6F6F70; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .switch-currencies { + position: absolute; + right: 0; + top: 50%; + transform: translate(0, -50%); + padding: 15px; } + #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-tool-input .switch-currencies img { + width: 18px; } + #view-amount .scroll-content .send-amount-extras { + display: flex; + flex: 0 0 auto; + /* So that if only one item is present, it appears on the right. */ + flex-direction: row-reverse; + font-size: 12px; + align-items: center; + justify-content: space-between; + margin: 0 14px; } + #view-amount .scroll-content .send-amount-extras .available-funds { + color: #6F6F70; } + #view-amount .scroll-content .send-amount-extras .warning { + color: #b7664d; } + #view-amount .scroll-content .send-amount-extras .extra, + #view-amount .scroll-content .send-amount-extras button.extra { + /*display: flex;*/ + flex: 0 1 auto; } + #view-amount .scroll-content .send-amount-extras button.extra { + background: none; + border: none; + color: #000; + font-family: 'ProximaNova'; + font-size: 14px; + line-height: normal; + min-height: auto; + min-width: auto; + padding: 0; } + #view-amount .scroll-content .send-amount-extras .button .icon:before { + font-size: 14px; + line-height: normal; } + #view-amount .scroll-content .send-amount-extras .button span { display: flex; align-items: center; justify-content: center; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button { - flex: 1 1 auto; - line-height: 1.2em; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button + .button { - margin-left: 10px; } - #view-amount .scroll-content .send-amount .send-amount-tool .send-amount-actions .button span { - display: flex; - align-items: center; - justify-content: center; } - #view-amount .scroll-content .button.no-margin { - margin: 0; } - #view-amount .scroll-content .notification-warning { - display: block; - padding: .75rem 1.25rem; - color: #856404; - background-color: #fff3cd; - border: 1px solid #ffeeba; - line-height: 1.4em; - margin-bottom: 20px; } - #view-amount .scroll-content .keypad-container { - position: relative; } - #view-amount .scroll-content .keypad-container .keypad { - text-align: center; + #view-amount .scroll-content .button.no-margin { + margin: 0; } + #view-amount .scroll-content .notification-warning { + display: block; + padding: .75rem 1.25rem; + color: #856404; + background-color: #fff3cd; + border: 1px solid #ffeeba; + line-height: 1.4em; + margin-bottom: 20px; } + #view-amount .scroll-content .keypad-container { + position: relative; font-size: 18px; - font-weight: lighter; - position: absolute; - bottom: 0; - width: 100%; - color: #667; } + line-height: 2em; } @media (min-height: 667px) { - #view-amount .scroll-content .keypad-container .keypad { + #view-amount .scroll-content .keypad-container { font-size: 24px; } } - #view-amount .scroll-content .keypad-container .keypad .row { - padding: 0 !important; - margin: 0 !important; } - #view-amount .scroll-content .keypad-container .keypad .col { - line-height: 38px; } - @media (min-height: 667px) { - #view-amount .scroll-content .keypad-container .keypad .col { - line-height: 45px; } } - #view-amount .scroll-content .keypad-container .keypad .row:last-child .col { - padding-bottom: 10px; } - #view-amount .scroll-content .keypad-container .keypad .operator { - background-color: #f2f2f2; - font-weight: normal; - cursor: pointer; } - #view-amount .scroll-content .keypad-container .keypad .operator:active { - background-color: #9b9bab; } - #view-amount .scroll-content .keypad-container .keypad .operator-send { - font-weight: bolder; - color: #fff; - background-color: #494949; - font-size: 36px; - cursor: pointer; } - #view-amount .scroll-content .keypad-container .keypad .operator-send:active { - background-color: #eaeaea; } - #view-amount .scroll-content .keypad-container .keypad .digit { - cursor: pointer; - border-top: 1px solid #f2f2f2; - border-left: 1px solid #f2f2f2; - transition: all 0.1s ease; } - #view-amount .scroll-content .keypad-container .keypad .digit:active { - background-color: #f2f2f2; } @media (max-height: 480px) { - #view-amount .scroll-content .keypad-container .keypad { + #view-amount .scroll-content .keypad-container { font-size: 12px; } } + #view-amount .scroll-content .keypad-container .sendmax { + background: #262424; } + #view-amount .scroll-content .keypad-container .sendmax .button { + color: white; + background: black; + border: 1px solid #262424; + border-radius: 0; + font-size: 0.8em; + line-height: 2em; + width: 100%; } + #view-amount .scroll-content .keypad-container .sendmax .button .available-funds-amount { + color: #C9C9C9; } + #view-amount .scroll-content .keypad-container .sendmax .button:active { + background-color: #445; } + #view-amount .scroll-content .keypad-container .keypad { + text-align: center; + font-weight: lighter; + position: absolute; + bottom: 0; + width: 100%; + color: #fff; } + #view-amount .scroll-content .keypad-container .keypad .row { + padding: 0 !important; + margin: 0 !important; } + #view-amount .scroll-content .keypad-container .keypad .row:last-child .col { + padding-bottom: 10px; } + #view-amount .scroll-content .keypad-container .keypad .operator { + background-color: #f2f2f2; + font-weight: normal; + cursor: pointer; } + #view-amount .scroll-content .keypad-container .keypad .operator:active { + background-color: #9b9bab; } + #view-amount .scroll-content .keypad-container .keypad .operator-send { + font-weight: bolder; + color: #fff; + background-color: #494949; + font-size: 36px; + cursor: pointer; } + #view-amount .scroll-content .keypad-container .keypad .operator-send:active { + background-color: #eaeaea; } + #view-amount .scroll-content .keypad-container .keypad .digit { + cursor: pointer; + background-color: #000; + border: 1px solid #262424; + transition: all 0.1s ease; } + #view-amount .scroll-content .keypad-container .keypad .digit:active { + background-color: #445; } + #view-amount .scroll-content .button-primary { + background-color: #fab915; + border-radius: 0; + font-weight: bold; } + #view-amount .scroll-content .button-primary[disabled] { + background-color: #667; + opacity: 1; } + #view-amount .warning { + color: #b7664d; } + #view-amount ion-content { + margin-bottom: constant(safe-area-inset-bottom); + /* iOS 11.0 */ + margin-bottom: env(safe-area-inset-bottom); + /* iOS 11.2 */ } #view-confirm { - background-color: #ffffff; } + background-color: #494949; } #view-confirm .item-note { float: none; } #view-confirm .item-note .fee-rate { @@ -10622,6 +10767,13 @@ textarea.d-block { margin-top: -3px; } #view-confirm .toggle { cursor: pointer; } + #view-confirm ion-content { + background-color: #ffffff; } + #view-confirm slide-to-accept, #view-confirm slide-to-accept-success { + margin-bottom: constant(safe-area-inset-bottom); + /* iOS 11.0 */ + margin-bottom: env(safe-area-inset-bottom); + /* iOS 11.2 */ } #copayers-invitation .button-share { color: #fff; @@ -10728,6 +10880,8 @@ textarea.d-block { #tab-home .card-banner { padding: 0; } + #tab-home .card-banner svg { + margin: 40px auto 40px; } #tab-home .card-banner__img { width: 100%; display: block; } @@ -10951,123 +11105,156 @@ textarea.d-block { #cordova-plugin-qrscanner-still, #cordova-plugin-qrscanner-video-preview { background-color: #fab915 !important; } -#tab-send .input input { - width: 100%; - height: auto; } +#tab-send-header { + height: 300px; + width: 100%; } -#tab-send .input.item { - height: 55px; } +#tab-send-contacts { + height: calc(100vh - 300px - 50px - 44px); + /* screen size - button container - bottom-tab-menu - header top */ + overflow: scroll; } + #tab-send-contacts.ios { + height: calc(100vh - 300px - 50px - 44px - 18px); } -#tab-send .input i.left { - padding-left: 15px; } +#tab-send .input { + width: 100%; } + #tab-send .input input { + width: 100%; + height: 57px; + background: #FFF; + border: 1px #D9D9D9 solid; } + #tab-send .input input::placeholder { + color: #DCDCDC; } + #tab-send .input i.left { + padding-left: 15px; } + #tab-send .input i.qr { + cursor: pointer; + cursor: hand; + padding-right: 5px; } -#tab-send .input i.qr { - cursor: pointer; - cursor: hand; - padding-right: 5px; } - -#tab-send .qr-scan-icon { - cursor: pointer; - cursor: hand; - border-left: 1px solid #e4e4e4; - padding-left: 10px; } - -#tab-send .qr-icon { - line-height: 20px; } - -#tab-send .zero-state-cta { - padding-bottom: 3vh; - left: 0; } - -#tab-send .send-heading { - font-size: 14px; - font-weight: bold; - padding: 0 0 16px 0; - border: none; } - -#tab-send .send-header-wrapper { - padding: 10px; - background-color: white; - box-shadow: 0px 5px 10px 0px #cccccc; } - -#tab-send .search-wrapper { +#tab-send .send-wrapper { + padding: 18px 9px 9px 9px; background-color: #f2f2f2; border-radius: 3px; border: none; } - #tab-send .search-wrapper .svg#Bitcoin_Symbol { - width: 14px; } - #tab-send .search-wrapper .svg#Bitcoin_Symbol .st0 { - fill: #cccccc; } - #tab-send .search-wrapper.focus { - background: none; } - #tab-send .search-wrapper.focus .svg#Bitcoin_Symbol { - display: none; } - #tab-send .search-wrapper.focus .search-input { - padding-left: 30px; } - #tab-send .search-wrapper.focus .search-input:focus::-webkit-input-placeholder { - opacity: 0; } - -#tab-send .abs-v-center { - position: absolute; - top: 50%; - transform: translateY(-50%); } + #tab-send .send-wrapper:after { + display: block; + position: relative; + height: 1px; + background: #DEDEDE; + bottom: 0; + content: ''; + margin: 10px 6px 0px; } + #tab-send .send-wrapper.focus .search-input { + padding-left: 30px; } + #tab-send .send-wrapper.focus .search-input:focus::-webkit-input-placeholder { + opacity: 0; } + #tab-send .send-wrapper .buttons { + margin: auto; + margin-top: 18px; } + #tab-send .send-wrapper .buttons .button { + height: 60px; + line-height: 16px; + margin-right: 0px; + width: 95%; + max-width: none; + padding: 2px; } + #tab-send .send-wrapper .buttons .button-clipboard-paste { + margin-left: 0; } + #tab-send .send-wrapper .buttons .button-clipboard-paste .address { + display: none; } + #tab-send .send-wrapper .buttons .button-clipboard-paste .icon { + background: url(../img/icon-clipboard-paste.svg); + width: 15px; + height: 19px; + display: inline-block; + margin-bottom: 4px; } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content { + background: #FAB915; + color: #FFF !important; + border: 0; + box-shadow: 0 2px 11px 0 #C1C1C1; } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address .address, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content .address { + display: none; } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address .icon, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content .icon { + background: url(../img/icon-clipboard-paste-white.svg); } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address.contains-address .address, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content.contains-address .address { + display: inline; + border: none; + background-color: transparent; } + #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-address.contains-address .non-address, #tab-send .send-wrapper .buttons .button-clipboard-paste.contains-content.contains-address .non-address { + display: none; } + #tab-send .send-wrapper .buttons .button span { + font-size: 14px; } + #tab-send .send-wrapper .buttons .button img { + height: 16px; + width: auto; + margin: 2px 0 4px; } + #tab-send .send-wrapper .buttons .button-qr { + font-weight: bold; + max-width: none; + width: 100%; + height: 95px; + margin-top: 20px; } + #tab-send .send-wrapper .buttons .button-qr img { + vertical-align: middle; + margin-right: 12px; + width: 43px; + height: 43px; } + #tab-send .send-wrapper .buttons .button-qr span { + font-size: 19px; } #tab-send .search-input { background-color: transparent; padding-left: 30px; } -#tab-send .separator-left { - border-left: 1px solid #d9d9df; - padding-left: 10px; - height: 70%; } - -#tab-send .bitcoin-address { - border-top: none; - padding-bottom: .5rem; } - @media (max-width: 480px) { - #tab-send .bitcoin-address input { - font-size: 14px; } } - #tab-send .bitcoin-address .icon { - line-height: 31px; - padding-top: 2px; - padding-bottom: 1px; } - -#tab-send .show-more { - text-align: center; - padding: 20px; - font-size: 16px; - color: #387ef5; - font-weight: bold; } - #tab-send .sendTip { + padding-top: 5vh; text-align: center; } - #tab-send .sendTip > .item-heading { - margin-top: 10px; - background: 0 none; } - #tab-send .sendTip img { - content: url("../img/app/tab-icons/ico-send-selected.svg"); } #tab-send .sendTip .item { border-style: none; } #tab-send .sendTip > .title { font-size: 20px; - font-weight: bold; color: #445; margin: 20px 10px; } #tab-send .sendTip > .subtitle { font-size: 1rem; line-height: 1.5em; font-weight: 300; - color: #445; + color: #6F6F70; margin: 20px 1em 2.5em; } #tab-send .sendTip .big-icon-svg .bg.green { padding: 0 10px; box-shadow: none; } + #tab-send .sendTip .buttons { + margin-top: 18px; } + #tab-send .sendTip .buttons .button { + font-weight: bold; + font-size: 19px; } + #tab-send .sendTip .button-first-contact img { + height: 19px; + width: 19px; + margin-right: 6px; + vertical-align: sub; } + +#tab-send .item-heading { + line-height: 16px; + font-size: 14px; + font-weight: bold; } + #tab-send .item-heading .subtitle { + color: #B5B2B2; + font-size: 12px; + font-weight: 300; } #tab-send .list .item { + font-weight: 600; color: #444; - border-top: none; - padding-top: 1.5rem; - padding-bottom: 1.5rem; } + padding-top: 0.6rem; + padding-bottom: 0.6rem; } + #tab-send .list .item p { + font-weight: normal; } + #tab-send .list .item.item-icon-left { + padding-left: 64px; } #tab-send .list .item .big-icon-svg { left: 5px; } #tab-send .list .item .big-icon-svg > .bg { @@ -11077,7 +11264,7 @@ textarea.d-block { #tab-send .list .item:before { display: block; position: absolute; - width: 80%; + width: 100%; height: 1px; background: rgba(221, 221, 221, 0.3); top: 0; @@ -11096,6 +11283,83 @@ textarea.d-block { #tab-send .scroll { height: 100%; } +#tab-send .card.contacts { + margin: 4px 4px 16px 4px; + border-radius: 6px; + box-shadow: 0px 2px 1px 0 #C1C1C1; } + #tab-send .card.contacts .gravatar { + border-radius: 30px; + height: 40px; + width: 40px; } + +@media only screen and (min-device-width: 320px) and (max-device-width: 568px) { + #tab-send .send-wrapper .buttons .button-qr { + height: 60px; } + #tab-send .send-wrapper .buttons .button-qr span { + font-size: 16px; } + #tab-send #tab-send-header { + height: 270px; } + #tab-send #tab-send-contacts { + height: calc(100vh - 270px - 50px - 44px); + /* screen size - button container - bottom-tab-menu - header top */ } + #tab-send #tab-send-contacts.ios { + height: calc(100vh - 270px - 50px - 44px - 18px); } } + +#wallet-origin-destination .header--request { + padding: 30px 24px; + width: 100%; + height: 139px; + background-color: #fff; } + #wallet-origin-destination .header--request__title { + width: 46px; + height: 20px; + font-size: 16px; + font-weight: 600; + letter-spacing: -0.4px; + color: #000000; } + #wallet-origin-destination .header--request__amount { + font-size: 29px; + font-weight: 600; + letter-spacing: -0.7px; + color: #000000; + margin: 11px 0 2px; } + #wallet-origin-destination .header--request__amount-alt { + opacity: 0.45; + font-size: 16px; + font-weight: 600; + letter-spacing: -0.4px; + color: #000000; } + +#wallet-origin-destination .wallets-header { + margin: 20px 14px 0px; } + #wallet-origin-destination .wallets-header .title { + font-size: 16px; + font-weight: bold; + color: #445; + margin-bottom: -12px; } + +#wallet-origin-destination .card { + font-size: 12px; + margin: 20px 14px 0px; } + #wallet-origin-destination .card .item-heading { + font-weight: 600; } + #wallet-origin-destination .card .item-heading .subtitle { + font-size: 12px; } + #wallet-origin-destination .card-insufficient .wallet { + opacity: 0.4; } + #wallet-origin-destination .card-insufficient .item-heading { + font-size: 12px; } + #wallet-origin-destination .card-insufficient .item-heading > div { + display: inline-block; + vertical-align: text-bottom; } + #wallet-origin-destination .card-insufficient__dot { + display: inline-block; + width: 16px; + height: 16px; + background-color: #ec5959; + border-radius: 8px; + margin: 2px 6px 2px 2px; } + .settings .icon-bitpay { background-image: url("../img/icon-bitpay.svg"); } @@ -11604,7 +11868,8 @@ textarea.d-block { fill: white; } #walletDetails .bp-content { position: relative; - height: 100%; } + height: 100%; + height: calc(100% - env(safe-area-inset-bottom) * 2); } #walletDetails .bp-content.status-bar { margin-top: 20px; } #walletDetails .bar-header { @@ -11618,7 +11883,8 @@ textarea.d-block { background-color: inherit !important; } #walletDetails ion-content { padding-top: 0; - top: 0; } + top: 0; + margin-bottom: 16px; } #walletDetails ion-content.collapsible { margin-top: 210px; } #walletDetails ion-content .scroll { @@ -11763,6 +12029,73 @@ a.item { color: #667; font-size: 0.9em; } +#shapeshift .swap-image { + width: auto; + max-width: 400px; + max-height: 25vh; } + +#shapeshift .empty-case { + padding-top: 5vh; + text-align: center; } + #shapeshift .empty-case .item { + border-style: none; } + #shapeshift .empty-case > .title { + font-size: 20px; + color: #445; + margin: 20px 10px; } + #shapeshift .empty-case > .subtitle { + font-size: 1rem; + line-height: 1.5em; + font-weight: 300; + color: #6F6F70; + margin: 20px 1em 2.5em; } + #shapeshift .empty-case .big-icon-svg .bg.green { + padding: 0 10px; + box-shadow: none; } + #shapeshift .empty-case .buttons { + margin-top: 18px; } + #shapeshift .empty-case .buttons .button { + font-weight: bold; + font-size: 19px; } + #shapeshift .empty-case .button-first-contact img { + height: 19px; + width: 19px; + margin-right: 6px; + vertical-align: sub; } + +#shapeshift .button-shapeshift { + border-color: #FFF; + background-color: #243F5D; + color: #FFF; + border: 0px; + box-shadow: 0 2px 11px 0 #C1C1C1; } + #shapeshift .button-shapeshift:hover { + color: #FFF; + text-decoration: none; } + #shapeshift .button-shapeshift.active, #shapeshift .button-shapeshift.activated { + border-color: #FFF; + background-color: #606060; } + #shapeshift .button-shapeshift.button-clear { + border-color: transparent; + background: none; + box-shadow: none; + color: #FFF; } + #shapeshift .button-shapeshift.button-icon { + border-color: transparent; + background: none; } + #shapeshift .button-shapeshift.button-outline { + border-color: #C1C1C1; + background: transparent; + color: #C1C1C1; } + #shapeshift .button-shapeshift.button-outline.active, #shapeshift .button-shapeshift.button-outline.activated { + background-color: #C1C1C1; + box-shadow: none; + color: #fff; } + +.header.shapeshift { + background: url(../img/shapeshiftbg.jpg) center center no-repeat #28394d; + opacity: 0.99; } + #bitpayCard { background: white; } #bitpayCard .status-label { @@ -12211,7 +12544,6 @@ a.item { position: relative; height: 70px; border-color: #fab915; - background-color: #fab915; padding-top: 20px; margin-bottom: 50px; text-align: center; } @@ -13013,74 +13345,13 @@ a.item { .onboarding-illustration-backup-warning { background-image: url(../img/app/backup-warning.svg); } -#rate-card .item-heading { - font-weight: 700; } - -#rate-card .row { - border: none; } - -#rate-card .item-icon-right { - margin: 0; } - -#rate-card .feedback-flow-button { - margin-bottom: 20px; } - -#rate-card .icon-svg > img { - height: 1.8rem; - margin-bottom: 5px; } - -#send-feedback { - background-color: #ffffff; } - #send-feedback .row { - border: none; } - #send-feedback .skip { - color: rgba(255, 255, 255, 0.3); } - #send-feedback .feedback-heading { - padding-top: 20px; } - #send-feedback .feedback-title { - padding-left: 10px; - font-size: 20px; - font-weight: bold; - color: #445; } - #send-feedback .rating { - text-align: right; - padding-right: 15px; } - #send-feedback .comment { - padding: 0 20px 20px; - font-size: 1rem; - line-height: 1.5em; - font-weight: 300; - color: #445; } - #send-feedback .user-feedback { - border-top: 1px solid #f2f2f2; - border-bottom: 1px solid #f2f2f2; - padding: 20px; - width: 100%; - margin-bottom: 20px; - -webkit-appearance: none; } - #send-feedback .send-feedback-star { - height: 1rem; - margin-left: 5px; } - #send-feedback .form-fade-in { - opacity: 0; - animation-name: fadeIn; - animation-duration: .5s; - animation-fill-mode: forwards; - animation-timing-function: ease-in; } - -@keyframes fadeIn { - from { - opacity: 0; } - to { - opacity: 1; } } - -#complete { +#share-app { background-color: #fff; } - #complete .complete-layout { + #share-app .share-app-layout { display: flex; flex-direction: column; height: 100%; } - #complete .complete-layout__expand { + #share-app .share-app-layout__expand { display: flex; flex-direction: column; flex-grow: 1; @@ -13089,36 +13360,27 @@ a.item { text-align: center; opacity: 0; transition: opacity .3s; } - #complete .complete-layout__expand.fade-in { + #share-app .share-app-layout__expand.fade-in { opacity: 1; } - #complete .share-the-love-illustration { + #share-app .share-the-love-illustration { width: 5rem; margin: 1rem; } - #complete .send-feedback-illustration { - height: 16rem; - margin: 1rem; } - #complete .feedback-title { - font-size: 20px; - font-weight: bold; - color: #445; - margin: 20px 10px; - text-align: center; } - #complete .subtitle { + #share-app .subtitle { padding: 10px 30px 20px; text-align: center; color: #667; } - #complete .icon-svg > img { + #share-app .icon-svg > img { height: 16rem; width: 16rem; margin: 10px; } - #complete .socialsharing-icon { + #share-app .socialsharing-icon { display: inline-block; width: 60px; } - #complete .addressbook-icon-svg { + #share-app .addressbook-icon-svg { display: inline-block; width: 50px; height: 50px; } - #complete .share-buttons { + #share-app .share-buttons { padding: 50px 10px 30px; background-color: #f2f2f2; text-align: center; @@ -13130,7 +13392,7 @@ a.item { animation-fill-mode: forwards; animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1); animation-delay: .2s; } - #complete .share-buttons__action { + #share-app .share-buttons__action { display: inline-block; color: #667; font-size: .9rem; @@ -13148,38 +13410,6 @@ a.item { transform: translateY(0); opacity: 1; } } -#rate-app { - background-color: #ffffff; - text-align: center; } - #rate-app .skip-rating { - color: #445; - position: absolute; - top: 5px; - right: 10px; - padding: 15px; } - #rate-app .icon-svg > img { - width: 80px; - height: 80px; - margin-top: 15px; } - #rate-app .feedback-title { - font-size: 20px; - font-weight: bold; - color: #445; - margin: 80px 50px 10px; - text-align: center; } - #rate-app .share-the-love-illustration { - width: 5rem; - margin: 1rem; } - #rate-app .subtitle { - padding: 10px 30px 20px 40px; - color: #667; } - #rate-app .rate-buttons { - bottom: 0; - width: 100%; - position: absolute; - background-color: #f2f2f2; - padding: 30px 0 15px; } - action-sheet .bp-action-sheet__sheet { background: #fff; width: calc(100% + 1px); @@ -13800,7 +14030,11 @@ slide-to-accept-success { transform: translateY(5rem); opacity: 0; transition: transform 400ms ease, opacity 400ms ease; - transition-delay: 250ms; } + transition-delay: 250ms; + margin-bottom: constant(safe-area-inset-bottom); + /* iOS 11.0 */ + margin-bottom: env(safe-area-inset-bottom); + /* iOS 11.2 */ } slide-to-accept-success .slide-success__footer.reveal { -webkit-transform: translateY(0); transform: translateY(0); @@ -13858,16 +14092,16 @@ slide-to-accept-success { line-height: 30px; } #txp-details .head .amount-label .amount, #view-confirm .head .amount-label .amount { - font-size: 38px; - margin-bottom: .5rem; } - #txp-details .head .amount-label .amount > .unit, - #view-confirm .head .amount-label .amount > .unit { - font-family: "Roboto-Light"; } + font-size: 16px; + color: #9B9B9B; + font-family: "Roboto-Light"; } #txp-details .head .amount-label .alternative, #view-confirm .head .amount-label .alternative { - font-size: 16px; - font-family: "Roboto-Light"; - color: #9B9B9B; } + font-size: 38px; + margin-bottom: .5rem; } + #txp-details .head .amount-label .alternative > .unit, + #view-confirm .head .amount-label .alternative > .unit { + font-family: "Roboto-Light"; } #txp-details .item, #view-confirm .item { border-color: #EFEFEF; } @@ -14155,6 +14389,10 @@ wallet-selector .subheader { font-weight: bold; padding-bottom: 10px; border-bottom: 1px solid #EFEFEF; } + wallet-selector .subheader .subtitle { + color: #667; + font-size: 12px; + font-weight: 300; } wallet-selector .subheader .wallet-coin-logo { vertical-align: middle; margin-right: 5px; } @@ -15014,10 +15252,208 @@ log-options #check-bar .checkbox-icon { #cash-scan a { cursor: pointer; } +#view-review { + background-color: #494949; } + #view-review slide-to-accept, #view-review slide-to-accept-success { + margin-bottom: constant(safe-area-inset-bottom); + /* iOS 11.0 */ + margin-bottom: env(safe-area-inset-bottom); + /* iOS 11.2 */ } + #view-review .fee-summary { + position: absolute; + bottom: 92px; } + #view-review .shapeshift-banner { + box-shadow: none; } + .gravatar { border-radius: 3px; display: inline-block; } +.elastic { + width: 100%; + font-size: 14px; } + +/* +* Extends Ionic v1 item +*/ +.item.item-compact { + padding: 11px 13px; } + +.item.item-gutterless { + padding: 0; } + +.item .item-content.item-content-avatar { + min-height: 69px; + padding: 13px 11px 13px 68px; } + .item .item-content.item-content-avatar > img:first-child, + .item .item-content.item-content-avatar > i:first-child { + position: absolute; + max-width: 40px; + max-height: 40px; + width: 100%; + height: 100%; + border-radius: 50%; + left: 13px; + top: 50%; + padding: 0; + transform: translate(0, -50%); } + +.item .item-content.item-content-compact { + min-height: 0; + padding: 13px 11px; } + +.item .item-content .highlight { + color: #FAB915; } + +.item .item-content + .item-content { + padding-top: 0; } + +/* +* Extends Ionic v1 ion-content +*/ +ion-content.bg-neutral { + background-color: #F2F2F2; } + +ion-content.padded-bottom-cta { + bottom: 92px; } + +ion-content.padded-bottom-cta-with-summary { + bottom: 134px; } + +.card.card-gutter-compact { + margin: 10px 12px; } + +.header { + padding: 29px 12px 61px; + background-color: #FAB915; + color: #FFFFFF; } + .header .title { + font-size: 18px; + font-weight: 400; + line-height: 1em; + color: #FFFFFF; + text-align: center; } + .header .title + .content { + margin-top: 23px; } + .header .content { + text-align: center; } + .header .content p { + margin: 0; + line-height: 1em; + font-size: 18px; } + .header .content p.large { + font-size: 29px; + font-weight: 600; } + .header .content p + p { + margin-top: 8px; } + +.content-frame.negative-top { + margin-top: -40px; } + .content-frame.negative-top .card:first-child { + margin-top: 0; } + +.address { + background-color: #F8F8F8; + border: 0.5px solid #EDEBEB; + border-radius: 3px; + padding: 9px; + text-align: center; + font-size: 14px; + overflow: hidden; + text-overflow: ellipsis; } + .address.expanded { + white-space: pre-wrap; + word-break: break-all; } + .address .prefix { + color: #000000; } + .address .mid { + color: #919191; } + .address .suffix { + color: #000000; } + +.action-minor { + margin: 20px 14px; + font-size: 14px; } + .action-minor.mt-negative { + margin-top: 0; } + .action-minor.text-right { + text-align: right; } + .action-minor > .action-icon { + width: 15px; + height: 15px; + vertical-align: middle; + margin-right: 3px; } + .action-minor > .action-text { + vertical-align: middle; + color: #444444; } + +.expand-content-frame { + position: relative; } + .expand-content-frame .expand-content-trigger { + position: absolute; + top: 0; + transition: opacity 0.3s ease; + right: 0; } + .expand-content-frame .expand-content-trigger.expand-content-revealed { + opacity: 0; } + .expand-content-frame .expand-content { + opacity: 0; + transform-origin: 100% 0%; + transform: scale(0, 0); + transition: opacity 0.3s ease, transform 0.3s ease; } + .expand-content-frame .expand-content.expand-content-revealed { + opacity: 1; + transform: scale(1, 1); } + +.fee-summary { + position: relative; + display: flex; + justify-content: space-between; + width: 100%; + padding: 5px 12px 15px; + box-sizing: border-box; + background-color: #F2F2F2; } + .fee-summary:before { + content: ''; + position: absolute; + left: 0; + top: -15px; + width: 100%; + height: 15px; + background: linear-gradient(to bottom, rgba(242, 242, 242, 0) 0%, #f2f2f2 100%); } + .fee-summary .fee-fiat.positive { + color: #70955F; } + .fee-summary .fee-fiat.negative { + color: #C24633; } + .fee-summary .fee-crypto { + color: #A7A7A7; } + +.amount .start, +.amount .middle, +.amount .end, +.amount .currency { + display: inline-block; } + +.amount .start { + font-size: 1em; } + +.amount .middle { + font-size: 0.7857em; + margin-left: 5px; } + +.amount .end { + font-size: 0.7857em; + margin-left: 5px; } + +.amount.size-equal .middle, +.amount.size-equal .end { + font-size: 1em; } + +.amount .currency { + font-size: 1em; + margin-left: 5px; + text-transform: uppercase; } + /* This is for rules that don't yet have a home. * Our goal is to delete this file. Search the regex: /class=".*CLASS.*?"/ */ From 3ca95d6d407304f6a4789cbe38b3ad4a882d6236 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 3 Aug 2018 17:56:46 +1200 Subject: [PATCH 224/386] Wallet to wallet transaction sent successfully. The UI for it is still incomplete. --- src/js/controllers/review.controller.js | 109 ++++++++++++++++++++---- www/views/review.html | 2 +- 2 files changed, 93 insertions(+), 18 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 85950a8aa..e487c6bfc 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -7,6 +7,7 @@ angular function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, configService, feeService, gettextCatalog, $ionicLoading, $ionicModal, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, $timeout, txFormatService, walletService) { var vm = this; + vm.buttonText = ''; vm.destination = { address: '', balanceAmount: '', @@ -32,15 +33,16 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit name: '', }; vm.isCordova = platformInfo.isCordova; + vm.notReadyMessage = ''; vm.primaryAmount = ''; vm.primaryCurrency = ''; vm.usingMerchantFee = false; + vm.readyToSend = false; vm.secondaryAmount = ''; vm.secondaryCurrency = ''; - vm.thirdParty = false; vm.sendingTitle = gettextCatalog.getString('You are sending'); - vm.buttonText = ''; - + vm.thirdParty = false; + var config = null; var coin = ''; var countDown = null; @@ -102,6 +104,65 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit }); } + vm.approve = function(onSendStatusChange) { + + if (!tx || !originWallet) return; + + if ($scope.paymentExpired) { + popupService.showAlert(null, gettextCatalog.getString('This bitcoin payment request has expired.')); + $scope.sendStatus = ''; + $timeout(function() { + $scope.$apply(); + }); + return; + } + + ongoingProcess.set('creatingTx', true, onSendStatusChange); + getTxp(lodash.clone(tx), originWallet, false, function(err, txp) { + ongoingProcess.set('creatingTx', false, onSendStatusChange); + if (err) return; + + // confirm txs for more that 20usd, if not spending/touchid is enabled + function confirmTx(cb) { + if (walletService.isEncrypted(originWallet)) + return cb(); + + var amountUsd = parseFloat(txFormatService.formatToUSD(originWallet.coin, txp.amount)); + return cb(); + }; + + function publishAndSign() { + if (!originWallet.canSign() && !originWallet.isPrivKeyExternal()) { + $log.info('No signing proposal: No private key'); + + return walletService.onlyPublish(originWallet, txp, function(err) { + if (err) setSendError(err); + }, onSendStatusChange); + } + + walletService.publishAndSign(originWallet, txp, function(err, txp) { + if (err) return setSendError(err); + if (config.confirmedTxsNotifications && config.confirmedTxsNotifications.enabled) { + txConfirmNotification.subscribe(originWallet, { + txid: txp.txid + }); + } + }, onSendStatusChange); + }; + + confirmTx(function(nok) { + if (nok) { + $scope.sendStatus = ''; + $timeout(function() { + $scope.$apply(); + }); + return; + } + publishAndSign(); + }); + }); + }; + vm.chooseFeeLevel = function(tx, wallet) { if (wallet.coin == 'bch') return; @@ -149,12 +210,13 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit }; function createVanityTransaction(data) { + console.log('createVanityTransaction()'); var configFeeLevel = config.wallet.settings.feeLevel ? config.wallet.settings.feeLevel : 'normal'; // Grab stateParams tx = { amount: parseInt(data.stateParams.amount), - sendMax: data.stateParams.useSendMax == 'true' ? true : false, + sendMax: data.stateParams.sendMax === 'true' ? true : false, fromWalletId: data.stateParams.fromWalletId, toAddress: data.stateParams.toAddress, feeLevel: configFeeLevel, @@ -182,24 +244,29 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit var B = data.stateParams.coin === 'bch' ? bitcoreCash : bitcore; var networkName; try { - if (vm.destination.kind === 'wallet') { // There is a wallet-to-wallet transfer + if (vm.destination.kind === 'wallet') { // This is a wallet-to-wallet transfer $ionicLoading.show(); var toWallet = profileService.getWallet(data.stateParams.toWalletId); // We need an address to send to, so we ask the walletService to create a new address for the toWallet. - walletService.getAddress(toWallet, true, function (err, addr) { + console.log('Getting address for wallet...'); + walletService.getAddress(toWallet, true, function onWalletAddress(err, addr) { + console.log('getAddress cb called', err); $ionicLoading.hide(); tx.toAddress = addr; networkName = (new B.Address(tx.toAddress)).network.name; tx.network = networkName; + console.log('calling setupTx() for wallet.'); setupTx(tx); }); } else { // This is a Wallet-to-address transfer networkName = (new B.Address(tx.toAddress)).network.name; tx.network = networkName; + console.log('calling setupTx() for address.'); setupTx(tx); } } catch (e) { + console.error('Error setting up tx', e); var message = gettextCatalog.getString('Invalid address'); popupService.showAlert(null, message, function () { $ionicHistory.nextViewOptions({ @@ -326,10 +393,8 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit // Check if the recipient is a contact addressbookService.get(originCoin + address, function(err, contact) { if (!err && contact) { - console.log('destination is contact'); handleDestinationAsContact(contact); } else { - console.log('destination is address'); vm.destination.address = address; vm.destination.kind = 'address'; } @@ -352,7 +417,6 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit return; } - console.log('destination is wallet'); var destinationWallet = profileService.getWallet(destinationWalletId); vm.destination.coin = destinationWallet.coin; vm.destination.color = destinationWallet.color; @@ -434,8 +498,19 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } } + function setNotReady(msg, criticalError) { + vn.readyToSend = false; + vm.notReadyMessage = msg; + $scope.criticalError = criticalError; + $log.warn('Not ready to make the payment:' + msg); + $timeout(function() { + $scope.$apply(); + }); + }; + function setSendError(msg) { $scope.sendStatus = ''; + vm.readyToSend = false; $timeout(function() { $scope.$apply(); }); @@ -514,12 +589,6 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit // updateAmount(); // refresh(); - // End of quick refresh, before wallet is selected. - if (!wallet) { - ongoingProcess.set('calculatingFee', false); - return cb(); - } - var feeServiceLevel = usingMerchantFee && originWallet.coin == 'btc' ? 'urgent' : tx.feeLevel; feeService.getFeeRate(originWallet.coin, tx.network, feeServiceLevel, function(err, feeRate) { if (err) { @@ -553,7 +622,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit if (tx.sendMax && sendMaxInfo.amount == 0) { ongoingProcess.set('calculatingFee', false); - setNoWallet(gettextCatalog.getString('Insufficient confirmed funds')); + setNotReady(gettextCatalog.getString('Insufficient confirmed funds')); popupService.showAlert(gettextCatalog.getString('Error'), gettextCatalog.getString('Not enough funds for fee')); return cb('no_funds'); } @@ -570,15 +639,18 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit // txp already generated for this wallet? if (tx.txp[wallet.id]) { ongoingProcess.set('calculatingFee', false); + vm.readyToSend = true; updateSendAmounts(); + $scope.$apply(); return cb(); } + console.log('calling getTxp() from getSendMaxInfo cb.'); getTxp(lodash.clone(tx), wallet, opts.dryRun, function(err, txp) { ongoingProcess.set('calculatingFee', false); if (err) { if (err.message == 'Insufficient funds') { - setNoWallet(gettextCatalog.getString('Insufficient funds')); + setNotReady(gettextCatalog.getString('Insufficient funds')); popupService.showAlert(gettextCatalog.getString('Error'), gettextCatalog.getString('Not enough funds for fee')); return cb('no_funds'); } else @@ -611,7 +683,10 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit tx.txp[wallet.id] = txp; $log.debug('Confirm. TX Fully Updated for wallet:' + wallet.id, tx); + vm.readyToSend = true; updateSendAmounts(); + console.log('readyToSend:', vm.readyToSend); + $scope.$apply(); return cb(); }); diff --git a/www/views/review.html b/www/views/review.html index c1f37baf9..0b20bd7fc 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -73,7 +73,7 @@
-
Fee: Less than 1 cent
+
Fee: Less than 1 cent
Fee: {{vm.feeFiat}} {{vm.feeCurrency}}
{{vm.feeCrypto}} {{vm.origin.currency}} From 5973b30551fe3c50820c1b2ca720813163590263 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 3 Aug 2018 19:14:33 +1200 Subject: [PATCH 225/386] Sends wallet to wallet transaction with sound. --- src/js/controllers/review.controller.js | 117 +++++++++++++++++------- www/views/review.html | 34 +++---- 2 files changed, 99 insertions(+), 52 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index e487c6bfc..833c8a330 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,7 +4,7 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, configService, feeService, gettextCatalog, $ionicLoading, $ionicModal, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, $timeout, txFormatService, walletService) { +function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, configService, feeService, gettextCatalog, $ionicLoading, $ionicModal, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, soundService, $state, $timeout, txConfirmNotification, txFormatService, walletService) { var vm = this; vm.buttonText = ''; @@ -24,16 +24,15 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit vm.fiatCurrency = ''; vm.feeIsHigh = false; vm.feeLessThanACent = false; + vm.isCordova = platformInfo.isCordova; + vm.notReadyMessage = ''; vm.origin = { balanceAmount: '', balanceCurrency: '', - color: '', currency: '', currencyColor: '', - name: '', }; - vm.isCordova = platformInfo.isCordova; - vm.notReadyMessage = ''; + vm.originWallet = null; vm.primaryAmount = ''; vm.primaryCurrency = ''; vm.usingMerchantFee = false; @@ -41,7 +40,9 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit vm.secondaryAmount = ''; vm.secondaryCurrency = ''; vm.sendingTitle = gettextCatalog.getString('You are sending'); + vm.sendStatus = ''; vm.thirdParty = false; + vm.wallet = null; var config = null; var coin = ''; @@ -50,7 +51,6 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit var usingMerchantFee = false; var destinationWalletId = ''; var originWalletId = ''; - var originWallet; var priceDisplayIsFiat = true; var satoshis = null; var toAddress = ''; @@ -68,11 +68,9 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit satoshis = parseInt(data.stateParams.amount, 10); toAddress = data.stateParams.toAddr; - originWallet = profileService.getWallet(originWalletId); - vm.origin.currency = originWallet.coin.toUpperCase(); - vm.origin.color = originWallet.color; - vm.origin.name = originWallet.name; - coin = originWallet.coin; + vm.originWallet = profileService.getWallet(originWalletId); + vm.origin.currency = vm.originWallet.coin.toUpperCase(); + coin = vm.originWallet.coin; if (data.stateParams.thirdParty) { vm.thirdParty = JSON.parse(data.stateParams.thirdParty); // Parse stringified JSON-object @@ -93,20 +91,20 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } else { config = configCache; priceDisplayIsFiat = config.wallet.settings.priceDisplay === 'fiat'; - vm.origin.currencyColor = originWallet.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; + vm.origin.currencyColor = vm.originWallet.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; unitFromSat = 1 / config.wallet.settings.unitToSatoshi; } updateSendAmounts(); - getOriginWalletBalance(originWallet); + getOriginWalletBalance(vm.originWallet); handleDestinationAsAddress(toAddress, coin); handleDestinationAsWallet(data.stateParams.toWalletId); createVanityTransaction(data); }); } - vm.approve = function(onSendStatusChange) { + vm.approve = function() { - if (!tx || !originWallet) return; + if (!tx || !vm.originWallet) return; if ($scope.paymentExpired) { popupService.showAlert(null, gettextCatalog.getString('This bitcoin payment request has expired.')); @@ -117,42 +115,42 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit return; } - ongoingProcess.set('creatingTx', true, onSendStatusChange); - getTxp(lodash.clone(tx), originWallet, false, function(err, txp) { - ongoingProcess.set('creatingTx', false, onSendStatusChange); + ongoingProcess.set('creatingTx', true, statusChangeHandler); + getTxp(lodash.clone(tx), vm.originWallet, false, function(err, txp) { + ongoingProcess.set('creatingTx', false, statusChangeHandler); if (err) return; // confirm txs for more that 20usd, if not spending/touchid is enabled function confirmTx(cb) { - if (walletService.isEncrypted(originWallet)) + if (walletService.isEncrypted(vm.originWallet)) return cb(); - var amountUsd = parseFloat(txFormatService.formatToUSD(originWallet.coin, txp.amount)); + var amountUsd = parseFloat(txFormatService.formatToUSD(vm.originWallet.coin, txp.amount)); return cb(); }; function publishAndSign() { - if (!originWallet.canSign() && !originWallet.isPrivKeyExternal()) { + if (!vm.originWallet.canSign() && !vm.originWallet.isPrivKeyExternal()) { $log.info('No signing proposal: No private key'); - return walletService.onlyPublish(originWallet, txp, function(err) { + return walletService.onlyPublish(vm.originWallet, txp, function(err) { if (err) setSendError(err); - }, onSendStatusChange); + }, statusChangeHandler); } - walletService.publishAndSign(originWallet, txp, function(err, txp) { + walletService.publishAndSign(vm.originWallet, txp, function(err, txp) { if (err) return setSendError(err); if (config.confirmedTxsNotifications && config.confirmedTxsNotifications.enabled) { - txConfirmNotification.subscribe(originWallet, { + txConfirmNotification.subscribe(vm.originWallet, { txid: txp.txid }); } - }, onSendStatusChange); + }, statusChangeHandler); }; confirmTx(function(nok) { if (nok) { - $scope.sendStatus = ''; + vm.sendStatus = ''; $timeout(function() { $scope.$apply(); }); @@ -172,7 +170,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit scope.network = tx.network; scope.feeLevel = tx.feeLevel; scope.noSave = true; - scope.coin = originWallet.coin; + scope.coin = vm.originWallet.coin; if (usingCustomFee) { scope.customFeePerKB = tx.feeRate; @@ -202,7 +200,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit tx.feeLevel = newFeeLevel; if (usingCustomFee) tx.feeRate = parseInt(customFeePerKB); - updateTx(tx, originWallet, { + updateTx(tx, vm.originWallet, { clearCache: true, dryRun: true }, function() {}); @@ -228,7 +226,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit toEmail: vm.destination.email || null, toColor: vm.destination.color || null, network: false, - coin: originWallet.coin, + coin: vm.originWallet.coin, txp: {}, }; @@ -281,7 +279,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } } function getOriginWalletBalance(originWallet) { - var balanceText = getWalletBalanceDisplayText(originWallet); + var balanceText = getWalletBalanceDisplayText(vm.originWallet); vm.origin.balanceAmount = balanceText.amount; vm.origin.balanceCurrency = balanceText.currency; } @@ -476,6 +474,18 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit }); } + vm.onSuccessConfirm = function() { + vm.sendStatus = ''; + $ionicHistory.nextViewOptions({ + disableAnimate: true, + historyRoot: true + }); + $state.go('tabs.send').then(function() { + $ionicHistory.clearHistory(); + $state.transitionTo('tabs.home'); + }); + }; + function setButtonText(isMultisig, isPayPro) { if (isPayPro) { if (vm.isCordova) { @@ -536,12 +546,12 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit vm.showAddress = false; - setButtonText(originWallet.credentials.m > 1, !!tx.paypro); + setButtonText(vm.originWallet.credentials.m > 1, !!tx.paypro); if (tx.paypro) _paymentTimeControl(tx.paypro.expires); - updateTx(tx, originWallet, { + updateTx(tx, vm.originWallet, { dryRun: true }, function(err) { $timeout(function() { @@ -562,6 +572,43 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit // } // }); } + + function statusChangeHandler(processName, showName, isOn) { + $log.debug('statusChangeHandler: ', processName, showName, isOn); + if ( + ( + processName === 'broadcastingTx' || + ((processName === 'signingTx') && vm.originWallet.m > 1) || + (processName == 'sendingTx' && !vm.originWallet.canSign() && !vm.originWallet.isPrivKeyExternal()) + ) && !isOn) { + $scope.sendStatus = 'success'; + + if ($state.current.name === "tabs.send.review") { // XX SP: Otherwise all open wallets on other devices play this sound if you have been in a send flow before on that device. + soundService.play('misc/payment_sent.mp3'); + } + + var channel = "firebase"; + if (platformInfo.isNW) { + channel = "ga"; + } + // When displaying Fiat, if the formatting fails, the crypto will be the primary amount. + var amount = priceDisplayIsFiat ? vm.secondaryAmount || vm.primaryAmount : vm.primaryAmount; + var log = new window.BitAnalytics.LogEvent("transfer_success", [{ + "coin": vm.originWallet.coin, + "type": "outgoing", + "amount": amount, + "fees": vm.feeCrypto + }], [channel, "adjust"]); + window.BitAnalytics.LogEventHandlers.postEvent(log); + + $timeout(function() { + $scope.$digest(); + }, 100); + } else if (showName) { + $scope.sendStatus = showName; + } + }; + function updateTx(tx, wallet, opts, cb) { ongoingProcess.set('calculatingFee', true); @@ -589,8 +636,8 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit // updateAmount(); // refresh(); - var feeServiceLevel = usingMerchantFee && originWallet.coin == 'btc' ? 'urgent' : tx.feeLevel; - feeService.getFeeRate(originWallet.coin, tx.network, feeServiceLevel, function(err, feeRate) { + var feeServiceLevel = usingMerchantFee && vm.originWallet.coin == 'btc' ? 'urgent' : tx.feeLevel; + feeService.getFeeRate(vm.originWallet.coin, tx.network, feeServiceLevel, function(err, feeRate) { if (err) { ongoingProcess.set('calculatingFee', false); return cb(err); diff --git a/www/views/review.html b/www/views/review.html index 0b20bd7fc..4b1b47a98 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -25,10 +25,10 @@
-

{{vm.origin.name}} ({{vm.origin.currency}})

+

{{vm.originWallet.name}} ({{vm.origin.currency}})

{{vm.origin.balanceAmount}} {{vm.origin.balanceCurrency}}

@@ -73,7 +73,7 @@
-
Fee: Less than 1 cent
+
Fee: Less than 1 cent
Fee: {{vm.feeFiat}} {{vm.feeCurrency}}
{{vm.feeCrypto}} {{vm.origin.currency}} @@ -81,25 +81,25 @@
- {{buttonText}} + ng-click="vm.approve()" + ng-if="!vm.isCordova" + click-send-status="vm.sendStatus" + is-disabled="!vm.readyToSend"> + {{vm.buttonText}} - {{buttonText}} + slide-on-confirm="vm.approve()" + slide-send-status="vm.sendStatus" + is-disabled="!vm.readyToSend"> + {{vm.buttonText}} - Payment Sent - Proposal Created - Transaction Created + Payment Sent + Proposal Created + Transaction Created From 671b46da41867e08de840abc643cfcf411f0fa92 Mon Sep 17 00:00:00 2001 From: Sam Cheng Hung Date: Fri, 3 Aug 2018 15:32:54 +0800 Subject: [PATCH 226/386] Changes address component name to address-frame --- .../components/{address.scss => address-frame.scss} | 2 +- src/sass/components/components.scss | 2 +- www/css/main.css | 10 +++++----- www/views/review.html | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) rename src/sass/components/{address.scss => address-frame.scss} (95%) diff --git a/src/sass/components/address.scss b/src/sass/components/address-frame.scss similarity index 95% rename from src/sass/components/address.scss rename to src/sass/components/address-frame.scss index 2848deb82..b06ce8bea 100644 --- a/src/sass/components/address.scss +++ b/src/sass/components/address-frame.scss @@ -1,4 +1,4 @@ -.address { +.address-frame { background-color: #F8F8F8; border: 0.5px solid #EDEBEB; border-radius: 3px; diff --git a/src/sass/components/components.scss b/src/sass/components/components.scss index eae56e786..0af55e5be 100644 --- a/src/sass/components/components.scss +++ b/src/sass/components/components.scss @@ -4,7 +4,7 @@ @import "header"; @import "content-frame"; -@import "address"; +@import "address-frame"; @import "action-minor"; @import "expand-content"; @import "fee-summary"; diff --git a/www/css/main.css b/www/css/main.css index e39d96cf3..df39fda50 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -15352,7 +15352,7 @@ ion-content.padded-bottom-cta-with-summary { .content-frame.negative-top .card:first-child { margin-top: 0; } -.address { +.address-frame { background-color: #F8F8F8; border: 0.5px solid #EDEBEB; border-radius: 3px; @@ -15361,14 +15361,14 @@ ion-content.padded-bottom-cta-with-summary { font-size: 14px; overflow: hidden; text-overflow: ellipsis; } - .address.expanded { + .address-frame.expanded { white-space: pre-wrap; word-break: break-all; } - .address .prefix { + .address-frame .prefix { color: #000000; } - .address .mid { + .address-frame .mid { color: #919191; } - .address .suffix { + .address-frame .suffix { color: #000000; } .action-minor { diff --git a/www/views/review.html b/www/views/review.html index 4b1b47a98..2e7823f69 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -48,7 +48,7 @@

{{vm.destination.balanceAmount}} {{vm.destination.balanceCurrency}}

-
qz9cqq5pryv9hnqwa8q8mccmynk9uf4vlu5nxerpzmc
+
qz9cqq5pryv9hnqwa8q8mccmynk9uf4vlu5nxerpzmc
From 2f62092fd8994941dc3252aaad48e45aeea33aab Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 3 Aug 2018 19:59:25 +1200 Subject: [PATCH 227/386] Payment sent message is displayed. --- src/js/controllers/review.controller.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 833c8a330..9285436f5 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,7 +4,7 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, configService, feeService, gettextCatalog, $ionicLoading, $ionicModal, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, soundService, $state, $timeout, txConfirmNotification, txFormatService, walletService) { +function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, configService, feeService, gettextCatalog, $ionicHistory, $ionicLoading, $ionicModal, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, soundService, $state, $timeout, txConfirmNotification, txFormatService, walletService) { var vm = this; vm.buttonText = ''; @@ -581,7 +581,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit ((processName === 'signingTx') && vm.originWallet.m > 1) || (processName == 'sendingTx' && !vm.originWallet.canSign() && !vm.originWallet.isPrivKeyExternal()) ) && !isOn) { - $scope.sendStatus = 'success'; + vm.sendStatus = 'success'; if ($state.current.name === "tabs.send.review") { // XX SP: Otherwise all open wallets on other devices play this sound if you have been in a send flow before on that device. soundService.play('misc/payment_sent.mp3'); @@ -605,7 +605,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit $scope.$digest(); }, 100); } else if (showName) { - $scope.sendStatus = showName; + vm.sendStatus = showName; } }; From 8148ad66b4c8647af82c93a2d4faff07d835bf4b Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 3 Aug 2018 20:11:14 +1200 Subject: [PATCH 228/386] Payments to contacts now work. --- src/js/controllers/review.controller.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 9285436f5..b3addc64f 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -216,7 +216,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit amount: parseInt(data.stateParams.amount), sendMax: data.stateParams.sendMax === 'true' ? true : false, fromWalletId: data.stateParams.fromWalletId, - toAddress: data.stateParams.toAddress, + toAddress: data.stateParams.toAddr, feeLevel: configFeeLevel, spendUnconfirmed: config.wallet.spendUnconfirmed, From cebe9507f169d42451c5a16391e0e260dfb8b325 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 3 Aug 2018 13:13:29 +0200 Subject: [PATCH 229/386] Make the "to"-address field work in new style + BTC transactions fix --- src/js/controllers/review.controller.js | 2 +- src/js/services/incomingData.js | 2 +- www/views/review.html | 4 +++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index b3addc64f..7d8efbfac 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -531,7 +531,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit if (tx.coin === 'bch') { tx.displayAddress = bitcoinCashJsService.readAddress(tx.toAddress).cashaddr; } else { - tx.displayAddress = entry.address; + tx.displayAddress = tx.toAddress; } addressbookService.get(tx.coin+tx.toAddress, function(err, addr) { // Check if the recipient is a contact diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index fb8d8868a..55a453dab 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -386,7 +386,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat 'notify': $state.current.name == 'tabs.send' ? false : true }); $timeout(function() { - $state.transitionTo('tabs.send.amount', { + $state.transitionTo('tabs.send.origin', { toAddress: toAddress, coin: coin, noPrefix: 1 diff --git a/www/views/review.html b/www/views/review.html index 2e7823f69..2f8a4ee3a 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -48,7 +48,9 @@

{{vm.destination.balanceAmount}} {{vm.destination.balanceCurrency}}

-
qz9cqq5pryv9hnqwa8q8mccmynk9uf4vlu5nxerpzmc
+
+ {{vm.destination.address.substring(0,5)}}{{vm.destination.address.substring(5,vm.destination.address.length-4)}}{{vm.destination.address.substring(vm.destination.address.length-4)}} +
From d7fabc36422ae698fa56fd86163e1c053376e5fd Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 3 Aug 2018 14:28:56 +0200 Subject: [PATCH 230/386] header + default colors --- src/js/controllers/review.controller.js | 12 +++++++----- src/sass/components/header.scss | 5 ++++- src/sass/variables.scss | 1 + www/views/review.html | 4 ++-- 4 files changed, 14 insertions(+), 8 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 7d8efbfac..82ef2aa30 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -45,6 +45,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit vm.wallet = null; var config = null; + var defaults = {}; var coin = ''; var countDown = null; var usingCustomFee = false; @@ -63,7 +64,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit function onBeforeEnter(event, data) { - + defaults = configService.getDefaults(); originWalletId = data.stateParams.fromWalletId; satoshis = parseInt(data.stateParams.amount, 10); toAddress = data.stateParams.toAddr; @@ -91,7 +92,8 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } else { config = configCache; priceDisplayIsFiat = config.wallet.settings.priceDisplay === 'fiat'; - vm.origin.currencyColor = vm.originWallet.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; + vm.origin.currencyColor = (vm.originWallet.coin === 'btc' ? defaults.bitcoinWalletColor : defaults.bitcoinCashWalletColor); + console.log("coin", vm.originWallet.coin, vm.origin.currencyColor, config.bitcoinWalletColor, vm.originWallet.coin === 'btc'); unitFromSat = 1 / config.wallet.settings.unitToSatoshi; } updateSendAmounts(); @@ -404,7 +406,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit vm.destination.kind = 'contact'; vm.destination.name = contact.name; vm.destination.email = contact.email; - vm.destination.color = contact.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; + vm.destination.color = contact.coin === 'btc' ? defaults.bitcoinWalletColor : defaults.bitcoinCashWalletColor; vm.destination.currency = contact.coin.toUpperCase(); vm.destination.currencyColor = vm.destination.color; } @@ -422,8 +424,8 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit vm.destination.kind = 'wallet'; vm.destination.name = destinationWallet.name; - if (config) { - vm.destination.currencyColor = vm.destination.coin === 'btc' ? config.bitcoinWalletColor : config.bitcoinCashWalletColor; + if (defaults) { + vm.destination.currencyColor = vm.destination.coin === 'btc' ? defaults.bitcoinWalletColor : defaults.bitcoinCashWalletColor; } var balanceText = getWalletBalanceDisplayText(destinationWallet); diff --git a/src/sass/components/header.scss b/src/sass/components/header.scss index fad1f1812..d44c93b60 100644 --- a/src/sass/components/header.scss +++ b/src/sass/components/header.scss @@ -1,6 +1,9 @@ .header { padding: 29px 12px 61px; - background-color: #FAB915; + background-color: $v-bitcoin-orange; + &.btc { + background-color: $v-bitcoin-core; + } color: #FFFFFF; .title { diff --git a/src/sass/variables.scss b/src/sass/variables.scss index 67d5a044b..49ee6ae89 100644 --- a/src/sass/variables.scss +++ b/src/sass/variables.scss @@ -8,6 +8,7 @@ $v-font-family-light: "Roboto-Light", sans-serif- /* Colors */ $v-bitcoin-orange: #fab915 !default; +$v-bitcoin-core: #535353 !default; $v-off-black: #262424; $v-dark-gray: #445 !default; diff --git a/www/views/review.html b/www/views/review.html index 2f8a4ee3a..631d1bec4 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -1,5 +1,5 @@ - + {{'Review Transaction' | translate}} @@ -10,7 +10,7 @@
-
+

{{vm.sendingTitle}}

{{vm.primaryAmount}} {{vm.primaryCurrency}}

From fb4bc1563c6b9cc378a184aa4bf5221bd55f26eb Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 6 Aug 2018 12:04:14 +1200 Subject: [PATCH 231/386] Starting to integrate BIP70 payment protocol into new send flow. --- i18n/po/template.pot | 6 +- .../controllers/walletSelectorController.js | 35 ++++++--- src/js/services/incomingData.js | 22 ++++-- src/js/services/paypro.service.js | 76 +++++++++++++++++++ src/js/services/payproService.js | 69 ----------------- 5 files changed, 120 insertions(+), 88 deletions(-) create mode 100644 src/js/services/paypro.service.js delete mode 100644 src/js/services/payproService.js diff --git a/i18n/po/template.pot b/i18n/po/template.pot index ecf44efe9..358145a1c 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -2179,7 +2179,7 @@ msgid "Payment details" msgstr "" #: www/views/modals/paypro.html:6 -msgid "Payment request" +msgid "Payment Request" msgstr "" #: www/views/mercadoLibreCards.html:22 @@ -3760,4 +3760,8 @@ msgstr "" #: www/views/review.html:69 msgid "Less than 1 cent" +msgstr "" + +#: src/js/services/incomingData.js:129 +msgid "This invoice is no longer accepting payments" msgstr "" \ No newline at end of file diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index f73bd4830..667bff3cb 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -26,8 +26,8 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.coin = $scope.params.coin; // Contacts have a coin embedded } - if ($scope.params.amount) { // There is an amount, so presume that it a payment request - $scope.sendFlowTitle = gettextCatalog.getString('Payment request'); + if ($scope.params.amount) { // There is an amount, so presume that it is a payment request + $scope.sendFlowTitle = gettextCatalog.getString('Payment Request'); $scope.specificAmount = $scope.specificAlternativeAmount = ''; $scope.requestAmount = (($state.params.amount) * (1 / config.unitToSatoshi)).toFixed(config.unitDecimals); $scope.isPaymentRequest = true; @@ -54,16 +54,9 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu } if ($scope.thirdParty) { - // Third party services specific logic - - if ($scope.thirdParty.id === 'shapeshift' && $scope.type === 'destination') { // Shapeshift wants to know the - if ($scope.coin === 'bch') { - $scope.coin = 'btc'; - } else { - $scope.coin = 'bch'; - } - } + handleThirdPartyIfBip70PaymentProtocol(); + handleThirdPartyIfShapeshift(); } if (!$scope.coin || $scope.coin === 'bch') { // if no specific coin is set or coin is set to bch @@ -87,6 +80,26 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu } } + function handleThirdPartyIfBip70PaymentProtocol() { + if ($scope.thirdParty.id === 'bip70PaymentProtocol') { + $scope.coin = $scope.thirdParty.coin; + $scope.requestAmount = $scope.thirdParty.details. + console.log('paypro details:', $scope.thirdParty.details); + } + } + + function handleThirdPartyIfShapeshift() { + if ($scope.thirdParty.id === 'shapeshift' && $scope.type === 'destination') { // Shapeshift wants to know the + if ($scope.coin === 'bch') { + $scope.coin = 'btc'; + } else { + $scope.coin = 'bch'; + } + } + } + + + $scope.useWallet = function(wallet) { if ($scope.type === 'origin') { // we're on the origin screen, set wallet to send from $scope.params['fromWalletId'] = wallet.id; diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index 55a453dab..72b1a70b5 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -121,9 +121,14 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat var coin = data.indexOf('bitcoincash') >= 0 ? 'bch' : 'btc'; data = decodeURIComponent(data.replace(/bitcoin(cash)?:\?r=/, '')); if (coin == 'bch') { - payproService.getPayProDetailsViaHttp(data, function(err, details) { + payproService.getPayProDetailsViaHttp(data, function onGetPayProDetailsViaHttp(err, details) { if (err) { - popupService.showAlert(gettextCatalog.getString('Error'), err) + var message = err.toString(); + if (typeof err.data === 'string') { + // i.e. 'This invoice is no longer accepting payments' + message = gettextCatalog.getString(err.data); + } + popupService.showAlert(gettextCatalog.getString('Error'), message) } else { handlePayPro(createBchPayProObject(details), coin); } @@ -415,12 +420,15 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat } function handlePayPro(payProDetails, coin) { + var thirdPartyData = { + id: 'bip70PaymentProtocol', + coin: coin, + details: payProDetails + }; var stateParams = { amount: payProDetails.amount, - toAddress: payProDetails.toAddress, - description: payProDetails.memo, - paypro: payProDetails, - coin: coin, + toAddr: payProDetails.toAddress, + thirdParty: JSON.stringify(thirdPartyData) }; // fee @@ -434,7 +442,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat 'notify': $state.current.name == 'tabs.send' ? false : true }).then(function() { $timeout(function() { - $state.transitionTo('tabs.send.confirm', stateParams); + $state.transitionTo('tabs.send.origin', stateParams); }); }); } diff --git a/src/js/services/paypro.service.js b/src/js/services/paypro.service.js new file mode 100644 index 000000000..4cdc78e7c --- /dev/null +++ b/src/js/services/paypro.service.js @@ -0,0 +1,76 @@ +'use strict'; + +angular + .module('copayApp.services') + .factory('payproService', payproService); + +function payproService(gettextCatalog, $http, $log, ongoingProcess, platformInfo, profileService) { + + var service = { + getPayProDetails: getPayProDetails, + getPayProDetailsViaHttp: getPayProDetailsViaHttp, + broadcastBchTx: broadcastBchTx + }; + + return service; + + function getPayProDetails(uri, coin, cb, disableLoader) { + if (!cb) cb = function() {}; + + var wallet = profileService.getWallets({ + onlyComplete: true, + coin: coin + })[0]; + + if (!wallet) return cb(); + + if (platformInfo.isChromeApp) { + return cb(gettextCatalog.getString('Payment Protocol not supported on Chrome App')); + } + + $log.debug('Fetch PayPro Request...', uri); + + if (!disableLoader) ongoingProcess.set('fetchingPayPro', true); + + wallet.fetchPayPro({ + payProUrl: uri, + }, function(err, paypro) { + if (!disableLoader) ongoingProcess.set('fetchingPayPro', false); + if (err) return cb(gettextCatalog.getString('Could Not Fetch Payment: Check if it is still valid')); + else if (!paypro.verified) { + $log.warn('Failed to verify payment protocol signatures'); + return cb(gettextCatalog.getString('Payment Protocol Invalid')); + } + return cb(null, paypro); + }); + } + + function getPayProDetailsViaHttp(uri, cb) { + var config = { + headers: {'Accept': 'application/payment-request'} + }; + $http.get(uri, config).then(function onGetPayProDetailsSuccess(response) { + return cb(null, response.data); + }, function onGetPayProDetailsError(error) { + return cb(error, null); + }); + } + + function broadcastBchTx(signedTxp, cb) { + var config = { + headers: {'Content-Type': 'application/payment'} + }; + + var data = { + currency: 'BCH', + transactions: [signedTxp.raw] + }; + + $http.post(signedTxp.payProUrl, data, config).then(function(response) { + signedTxp.response = response.data; + return cb(null, signedTxp); + }, function(error) { + return cb(error.data, null); + }); + } +} diff --git a/src/js/services/payproService.js b/src/js/services/payproService.js deleted file mode 100644 index f0814cc0f..000000000 --- a/src/js/services/payproService.js +++ /dev/null @@ -1,69 +0,0 @@ -'use strict'; - -angular.module('copayApp.services').factory('payproService', - function(profileService, platformInfo, gettextCatalog, ongoingProcess, $log, $http) { - - var ret = {}; - - ret.getPayProDetails = function(uri, coin, cb, disableLoader) { - if (!cb) cb = function() {}; - - var wallet = profileService.getWallets({ - onlyComplete: true, - coin: coin - })[0]; - - if (!wallet) return cb(); - - if (platformInfo.isChromeApp) { - return cb(gettextCatalog.getString('Payment Protocol not supported on Chrome App')); - } - - $log.debug('Fetch PayPro Request...', uri); - - if (!disableLoader) ongoingProcess.set('fetchingPayPro', true); - - wallet.fetchPayPro({ - payProUrl: uri, - }, function(err, paypro) { - if (!disableLoader) ongoingProcess.set('fetchingPayPro', false); - if (err) return cb(gettextCatalog.getString('Could Not Fetch Payment: Check if it is still valid')); - else if (!paypro.verified) { - $log.warn('Failed to verify payment protocol signatures'); - return cb(gettextCatalog.getString('Payment Protocol Invalid')); - } - return cb(null, paypro); - }); - }; - - ret.getPayProDetailsViaHttp = function(uri, cb) { - var config = { - headers: {'Accept': 'application/payment-request'} - }; - $http.get(uri, config).then(function(response) { - return cb(null, response.data); - }, function(error) { - return cb(error, null); - }); - } - - ret.broadcastBchTx = function(signedTxp, cb) { - var config = { - headers: {'Content-Type': 'application/payment'} - }; - - var data = { - currency: 'BCH', - transactions: [signedTxp.raw] - }; - - $http.post(signedTxp.payProUrl, data, config).then(function(response) { - signedTxp.response = response.data; - return cb(null, signedTxp); - }, function(error) { - return cb(error.data, null); - }); - } - - return ret; - }); From 4203a449d98827efdb8f12e156708d1536f27d5e Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 6 Aug 2018 13:39:03 +1200 Subject: [PATCH 232/386] Displaying requested amount in origin screen. --- .../controllers/walletSelectorController.js | 46 +++++++++++++++++-- src/js/services/paypro.service.js | 2 + www/views/walletSelector.html | 4 +- 3 files changed, 47 insertions(+), 5 deletions(-) diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index 667bff3cb..541794b22 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -1,9 +1,17 @@ 'use strict'; -angular.module('copayApp.controllers').controller('walletSelectorController', function($scope, $rootScope, $state, $log, $ionicHistory, configService, gettextCatalog, profileService) { +angular.module('copayApp.controllers').controller('walletSelectorController', function($scope, $rootScope, $state, $log, $ionicHistory, configService, gettextCatalog, profileService, txFormatService) { + + var priceDisplayAsFiat = false; + var requestedSatoshis = 0; + var unitDecimals = 0; + var unitsFromSatoshis = 0; $scope.$on("$ionicView.beforeEnter", function(event, data) { var config = configService.getSync().wallet.settings; + priceDisplayAsFiat = config.priceDisplay === 'fiat'; + unitDecimals = config.unitDecimals; + unitsFromSatoshis = 1 / config.unitToSatoshi; switch($state.current.name) { case 'tabs.send.wallet-to-wallet': @@ -29,7 +37,8 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu if ($scope.params.amount) { // There is an amount, so presume that it is a payment request $scope.sendFlowTitle = gettextCatalog.getString('Payment Request'); $scope.specificAmount = $scope.specificAlternativeAmount = ''; - $scope.requestAmount = (($state.params.amount) * (1 / config.unitToSatoshi)).toFixed(config.unitDecimals); + //requestedAmountCrypto = (($state.params.amount) * (1 / config.unitToSatoshi)).toFixed(config.unitDecimals); + requestedSatoshis = $state.params.amount; $scope.isPaymentRequest = true; } if ($scope.params.thirdParty) { @@ -65,8 +74,39 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu if (!$scope.coin || $scope.coin === 'btc') { // if no specific coin is set or coin is set btc $scope.walletsBtc = profileService.getWallets({coin: 'btc', hasFunds: $scope.type === 'origin'}); } + + formatRequestedAmount(); }); + function formatRequestedAmount() { + if (requestedSatoshis) { + var cryptoAmount = (unitsFromSatoshis * requestedSatoshis).toFixed(unitDecimals); + var cryptoCoin = $scope.coin.toUpperCase(); + + txFormatService.formatAlternativeStr($scope.coin, requestedSatoshis, function onFormatAlternativeStr(formatted){ + if (formatted) { + var fiatParts = formatted.split(' '); + var fiatAmount = fiatParts[0]; + var fiatCurrrency = fiatParts.length > 1 ? fiatParts[1] : ''; + + if (priceDisplayAsFiat) { + $scope.requestAmount = fiatAmount; + $scope.requestCurrency = fiatCurrrency; + + $scope.requestAmountSecondary = cryptoAmount; + $scope.requestCurrencySecondary = cryptoCoin; + } else { + $scope.requestAmount = cryptoAmount; + $scope.requestCurrency = cryptoCoin; + + $scope.requestAmountSecondary = fiatAmount; + $scope.requestCurrencySecondary = fiatCurrrency; + } + } + }); + } + } + function getNextStep() { if ($scope.thirdParty) { $scope.params.thirdParty = JSON.stringify($scope.thirdParty) // re-stringify JSON-object @@ -83,7 +123,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu function handleThirdPartyIfBip70PaymentProtocol() { if ($scope.thirdParty.id === 'bip70PaymentProtocol') { $scope.coin = $scope.thirdParty.coin; - $scope.requestAmount = $scope.thirdParty.details. + $scope.requestAmount = unitsFromSatoshis * $scope.thirdParty.details.amount; console.log('paypro details:', $scope.thirdParty.details); } } diff --git a/src/js/services/paypro.service.js b/src/js/services/paypro.service.js index 4cdc78e7c..8f8db5f5b 100644 --- a/src/js/services/paypro.service.js +++ b/src/js/services/paypro.service.js @@ -1,5 +1,7 @@ 'use strict'; +// For BIP70 Payment Protocol + angular .module('copayApp.services') .factory('payproService', payproService); diff --git a/www/views/walletSelector.html b/www/views/walletSelector.html index 49a7ba208..3eecb1204 100644 --- a/www/views/walletSelector.html +++ b/www/views/walletSelector.html @@ -7,8 +7,8 @@
Paying
-
$... USD
-
{{requestAmount}} {{coin.toUpperCase()}}
+
{{requestAmount}} {{requestCurrency}}
+
{{requestAmountSecondary}} {{requestCurrencySecondary}}
From b0e46f18a1acda441d32b1e99f3bbfd73aec96a9 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 6 Aug 2018 16:45:00 +1200 Subject: [PATCH 233/386] The Origin screen can now display payment requests properly. --- .../controllers/walletSelectorController.js | 88 ++++++++++++++----- src/js/services/incomingData.js | 2 +- www/views/walletSelector.html | 4 +- 3 files changed, 71 insertions(+), 23 deletions(-) diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index 541794b22..1d52a715a 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -2,6 +2,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', function($scope, $rootScope, $state, $log, $ionicHistory, configService, gettextCatalog, profileService, txFormatService) { + var fromWalletId = ''; var priceDisplayAsFiat = false; var requestedSatoshis = 0; var unitDecimals = 0; @@ -29,6 +30,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.params = $state.params; $scope.coin = false; // Wallets to show (for destination screen or contacts) $scope.type = data.stateParams && data.stateParams['fromWalletId'] ? 'destination' : 'origin'; // origin || destination + fromWalletId = data.stateParams && data.stateParams.fromWalletId; if ($scope.params.coin) { $scope.coin = $scope.params.coin; // Contacts have a coin embedded @@ -51,30 +53,13 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.selectedPriceDisplay = config.wallet.settings.priceDisplay; }); - $scope.walletsEmpty = []; // empty wallets for origin screen - - if ($scope.type === 'origin') { - $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send from'); - $scope.walletsEmpty = profileService.getWallets({coin: $scope.coin, hasNoFunds: true}); - } else if ($scope.type === 'destination') { - $scope.fromWallet = profileService.getWallet(data.stateParams.fromWalletId); - $scope.coin = $scope.fromWallet.coin; // Only show wallets with the select origin wallet coin - $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send to'); - } - if ($scope.thirdParty) { // Third party services specific logic handleThirdPartyIfBip70PaymentProtocol(); handleThirdPartyIfShapeshift(); } - if (!$scope.coin || $scope.coin === 'bch') { // if no specific coin is set or coin is set to bch - $scope.walletsBch = profileService.getWallets({coin: 'bch', hasFunds: $scope.type==='origin'}); - } - if (!$scope.coin || $scope.coin === 'btc') { // if no specific coin is set or coin is set btc - $scope.walletsBtc = profileService.getWallets({coin: 'btc', hasFunds: $scope.type === 'origin'}); - } - + prepareWalletLists(); formatRequestedAmount(); }); @@ -116,14 +101,17 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu } else if (!$scope.params.amount) { // If we have no amount return 'tabs.send.amount'; } else { // If we do have them - return 'tabs.send.confirm'; + return 'tabs.send.review'; } } function handleThirdPartyIfBip70PaymentProtocol() { if ($scope.thirdParty.id === 'bip70PaymentProtocol') { + requestedSatoshis = $scope.thirdParty.details.amount; $scope.coin = $scope.thirdParty.coin; - $scope.requestAmount = unitsFromSatoshis * $scope.thirdParty.details.amount; + $scope.requestAmount = unitsFromSatoshis * requestedSatoshis; + $scope.params.amount = requestedSatoshis; + $scope.params.toAddr = $scope.thirdParty.details.toAddress; console.log('paypro details:', $scope.thirdParty.details); } } @@ -138,6 +126,66 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu } } + function prepareWalletLists() { + var walletsAll = []; + var walletsSufficientFunds = []; + $scope.walletsInsufficientFunds = []; // For origin screen + + if ($scope.type === 'origin') { + $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send from'); + + if ($scope.params.amount) { + + walletsAll = profileService.getWallets({coin: $scope.coin}); + + walletsAll.forEach(function forWallet(wallet){ + if (wallet.status.availableBalanceSat > $scope.params.amount) { + walletsSufficientFunds.push(wallet); + } else { + $scope.walletsInsufficientFunds.push(wallet); + } + }); + + if ($scope.coin === 'btc') { + $scope.walletsBtc = walletsSufficientFunds; + } else { + $scope.walletsBch = walletsSufficientFunds; + } + + } else if ($scope.coin) { + walletsAll = profileService.getWallets({coin: $scope.coin}); + walletsAll.forEach(function forWallet(wallet){ + if (wallet.status.availableBalanceSat > 0) { + walletsSufficientFunds.push(wallet); + } else { + $scope.walletsInsufficientFunds.push(wallet); + } + }); + + if ($scope.coin === 'btc') { + $scope.walletsBtc = walletsSufficientFunds; + } else { + $scope.walletsBch = walletsSufficientFunds; + } + } else { + $scope.walletsBch = profileService.getWallets({coin: 'bch', hasFunds: true}); + $scope.walletsBtc = profileService.getWallets({coin: 'btc', hasFunds: true}); + $scope.walletsInsufficientFunds = profileService.getWallets({coin: $scope.coin, hasNoFunds: true}); + } + + } else if ($scope.type === 'destination') { + $scope.fromWallet = profileService.getWallet(fromWalletId); + $scope.coin = $scope.fromWallet.coin; // Only show wallets with the select origin wallet coin + $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send to'); + + if ($scope.coin === 'btc') { // if no specific coin is set or coin is set btc + $scope.walletsBtc = profileService.getWallets({coin: $scope.coin}); + } else { + $scope.walletsBch = profileService.getWallets({coin: $scope.coin}); + } + } + } + $scope.useWallet = function(wallet) { diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index 72b1a70b5..fa5abd56b 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -427,7 +427,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat }; var stateParams = { amount: payProDetails.amount, - toAddr: payProDetails.toAddress, + toAddress: payProDetails.toAddress, thirdParty: JSON.stringify(thirdPartyData) }; diff --git a/www/views/walletSelector.html b/www/views/walletSelector.html index 3eecb1204..c863f4ea7 100644 --- a/www/views/walletSelector.html +++ b/www/views/walletSelector.html @@ -42,12 +42,12 @@
-
+
Insufficient funds
- From f1f8f6e0f51026b0c8b624c9eca9f25ffd8d1f71 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 6 Aug 2018 20:31:06 +1200 Subject: [PATCH 234/386] Tidied up third party data from BIP70 Payment Protocol. --- src/js/controllers/amount.js | 2 +- src/js/controllers/review.controller.js | 4 ++-- src/js/controllers/walletSelectorController.js | 16 +++++----------- src/js/routes.js | 2 +- src/js/services/incomingData.js | 15 +++++++++++++-- 5 files changed, 22 insertions(+), 17 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 576fb4500..db1bb52fe 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -470,7 +470,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, amount: useSendMax ? undefined : satoshis, fromWalletId: passthroughParams.fromWalletId, sendMax: useSendMax, - toAddr: passthroughParams.toAddress, + toAddress: passthroughParams.toAddress, toWalletId: passthroughParams.toWalletId }; diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 82ef2aa30..5c05ea6fa 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -67,7 +67,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit defaults = configService.getDefaults(); originWalletId = data.stateParams.fromWalletId; satoshis = parseInt(data.stateParams.amount, 10); - toAddress = data.stateParams.toAddr; + toAddress = data.stateParams.toAddress; vm.originWallet = profileService.getWallet(originWalletId); vm.origin.currency = vm.originWallet.coin.toUpperCase(); @@ -218,7 +218,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit amount: parseInt(data.stateParams.amount), sendMax: data.stateParams.sendMax === 'true' ? true : false, fromWalletId: data.stateParams.fromWalletId, - toAddress: data.stateParams.toAddr, + toAddress: data.stateParams.toAddress, feeLevel: configFeeLevel, spendUnconfirmed: config.wallet.spendUnconfirmed, diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index 1d52a715a..df733e11f 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -4,7 +4,6 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu var fromWalletId = ''; var priceDisplayAsFiat = false; - var requestedSatoshis = 0; var unitDecimals = 0; var unitsFromSatoshis = 0; @@ -39,8 +38,6 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu if ($scope.params.amount) { // There is an amount, so presume that it is a payment request $scope.sendFlowTitle = gettextCatalog.getString('Payment Request'); $scope.specificAmount = $scope.specificAlternativeAmount = ''; - //requestedAmountCrypto = (($state.params.amount) * (1 / config.unitToSatoshi)).toFixed(config.unitDecimals); - requestedSatoshis = $state.params.amount; $scope.isPaymentRequest = true; } if ($scope.params.thirdParty) { @@ -64,11 +61,11 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu }); function formatRequestedAmount() { - if (requestedSatoshis) { - var cryptoAmount = (unitsFromSatoshis * requestedSatoshis).toFixed(unitDecimals); + if ($scope.params.amount) { + var cryptoAmount = (unitsFromSatoshis * $scope.params.amount).toFixed(unitDecimals); var cryptoCoin = $scope.coin.toUpperCase(); - txFormatService.formatAlternativeStr($scope.coin, requestedSatoshis, function onFormatAlternativeStr(formatted){ + txFormatService.formatAlternativeStr($scope.coin, $scope.params.amount, function onFormatAlternativeStr(formatted){ if (formatted) { var fiatParts = formatted.split(' '); var fiatAmount = fiatParts[0]; @@ -107,12 +104,9 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu function handleThirdPartyIfBip70PaymentProtocol() { if ($scope.thirdParty.id === 'bip70PaymentProtocol') { - requestedSatoshis = $scope.thirdParty.details.amount; $scope.coin = $scope.thirdParty.coin; - $scope.requestAmount = unitsFromSatoshis * requestedSatoshis; - $scope.params.amount = requestedSatoshis; - $scope.params.toAddr = $scope.thirdParty.details.toAddress; - console.log('paypro details:', $scope.thirdParty.details); + $scope.requestAmount = unitsFromSatoshis * $scope.params.amount; + console.log('paypro details:', $scope.thirdParty); } } diff --git a/src/js/routes.js b/src/js/routes.js index 905683dcb..8a8adc964 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -345,7 +345,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }) .state('tabs.send.review', { - url: '/review/:thirdParty/:amount/:fromWalletId/:sendMax/:toAddr/:toWalletId', + url: '/review/:thirdParty/:amount/:fromWalletId/:sendMax/:toAddress/:toWalletId', views: { 'tab-send@tabs': { controller: 'reviewController', diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index fa5abd56b..3b4b024c4 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -421,9 +421,20 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat function handlePayPro(payProDetails, coin) { var thirdPartyData = { - id: 'bip70PaymentProtocol', + caName: payProDetails.caName, + caTrusted: payProDetails.caTrusted, coin: coin, - details: payProDetails + domain: payProDetails.domain, + expires: payProDetails.expires, + id: 'bip70PaymentProtocol', + memo: payProDetails.memo, + merchant_data: payProDetails.merchant_data, + network: payProDetails.network, + requiredFeeRate: payProDetails.requiredFeeRate, + selfSigned: payProDetails.selfSigned, + time: payProDetails.time, + url: payProDetails.url, + verified: payProDetails.verified }; var stateParams = { amount: payProDetails.amount, From 731cfebc8a336e91e107570e2bbf031b68f22375 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 6 Aug 2018 20:39:59 +1200 Subject: [PATCH 235/386] Fixed destination coin for Shapeshift. --- src/js/controllers/walletSelectorController.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index df733e11f..e603032bd 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -168,8 +168,10 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu } } else if ($scope.type === 'destination') { - $scope.fromWallet = profileService.getWallet(fromWalletId); - $scope.coin = $scope.fromWallet.coin; // Only show wallets with the select origin wallet coin + if (!$scope.coin) { // Allow for the coin to be set by a third party + $scope.fromWallet = profileService.getWallet(fromWalletId); + $scope.coin = $scope.fromWallet.coin; // Only show wallets with the select origin wallet coin + } $scope.headerTitle = gettextCatalog.getString('Choose a wallet to send to'); if ($scope.coin === 'btc') { // if no specific coin is set or coin is set btc From ec354bd340414dda1f7271dfe0492a2946cc7a6d Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 6 Aug 2018 11:25:29 +0200 Subject: [PATCH 236/386] header css --- src/js/controllers/review.controller.js | 4 ++++ src/js/services/shapeshiftService.js | 19 +++++++++++++------ src/sass/views/shapeshift.scss | 2 +- 3 files changed, 18 insertions(+), 7 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 5c05ea6fa..c2e6be3de 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -105,6 +105,10 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } vm.approve = function() { + if (vm.thirdParty.id === 'shapeshift') { + shapeshiftService.shiftIt(); + return; + } if (!tx || !vm.originWallet) return; diff --git a/src/js/services/shapeshiftService.js b/src/js/services/shapeshiftService.js index 131df0cd0..317e72394 100644 --- a/src/js/services/shapeshiftService.js +++ b/src/js/services/shapeshiftService.js @@ -1,26 +1,32 @@ 'use strict'; -angular.module('copayApp.services').factory('shapeshiftService', function($http, $log, lodash, moment, ongoingProcess, shapeshiftApiService, storageService, configService, platformInfo, servicesService) { +angular.module('copayApp.services').factory('shapeshiftService', function($http, $interval, $log, lodash, moment, ongoingProcess, shapeshiftApiService, storageService, configService, incomingData, platformInfo, servicesService) { var root = {}; root.ShiftState = 'Shift'; root.withdrawalAddress = '' root.returnAddress = '' root.amount = ''; root.marketData = {} - this.withdrawalAddress = function(address) { + root.withdrawalAddress = function(address) { root.withdrawalAddress = address; }; - this.returnAddress = function(address) { + root.returnAddress = function(address) { root.returnAddress = address; }; - this.amount = function(amount) { + root.amount = function(amount) { root.amount = amount; }; - this.fromWalletId = function(id) { + root.fromWalletId = function(id) { root.fromWalletId = id; }; - this.toWalletId = function(id) { + root.toWalletId = function(id) { root.toWalletId = id; }; + root.coinIn = function(coinIn) { + root.coinIn = coinIn.toUpperCase(); + }; + root.coinOut = function(coinOut) { + root.coinOut = coinOut.toUpperCase(); + }; root.getMarketDataIn = function(coin) { if(coin === root.coinOut) return root.getMarketData(root.coinOut, root.coinIn); @@ -104,6 +110,7 @@ angular.module('copayApp.services').factory('shapeshiftService', function($http, var shapeshiftData = { fromWalletId: root.fromWalletId, + toWalletId: root.toWalletId, minAmount: root.marketData.minimum, maxAmount: root.marketData.maxLimit, orderId: root.depositInfo.orderId diff --git a/src/sass/views/shapeshift.scss b/src/sass/views/shapeshift.scss index ee4cd0b0f..5b63c0354 100644 --- a/src/sass/views/shapeshift.scss +++ b/src/sass/views/shapeshift.scss @@ -18,6 +18,6 @@ } } .header.shapeshift { - background: url(../img/shapeshiftbg.jpg) center center no-repeat #28394d; + background: url(../img/shapeshiftbg.jpg) center center repeat #28394d; opacity: 0.99; } \ No newline at end of file From cea77e910f2342a973f919a83278d72c8026b526 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 6 Aug 2018 21:46:03 +1200 Subject: [PATCH 237/386] One step closer to getting send max working. --- src/js/controllers/review.controller.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 5c05ea6fa..4fcb447e2 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -594,7 +594,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit channel = "ga"; } // When displaying Fiat, if the formatting fails, the crypto will be the primary amount. - var amount = priceDisplayIsFiat ? vm.secondaryAmount || vm.primaryAmount : vm.primaryAmount; + var amount = unitFromSat * satoshis; var log = new window.BitAnalytics.LogEvent("transfer_success", [{ "coin": vm.originWallet.coin, "type": "outgoing", @@ -678,7 +678,8 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit tx.sendMaxInfo = sendMaxInfo; tx.amount = tx.sendMaxInfo.amount; - updateAmount(); + satoshis = tx.amount; + updateSendAmounts(); ongoingProcess.set('calculatingFee', false); $timeout(function() { showSendMaxWarning(wallet, sendMaxInfo); From cc213956d08793bca81b7e8282d381515738c31b Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 6 Aug 2018 22:12:33 +0900 Subject: [PATCH 238/386] header bitpay on the wallet selector, incoming data fix, clean a bit --- app-template/bitcoincom/css/bitcoin.com.css | 23 ++++++++++++++++++- .../controllers/walletSelectorController.js | 7 +----- src/js/services/incomingData.js | 7 +++--- src/sass/views/review.scss | 2 +- www/css/bitcoin.com.css | 16 ++++++++++++- www/css/main.css | 6 +++-- www/img/bitpay_banner.svg | 13 +++++++++++ www/views/thirdparty/bitpay-header.html | 3 +++ www/views/walletSelector.html | 1 + 9 files changed, 64 insertions(+), 14 deletions(-) create mode 100644 www/img/bitpay_banner.svg create mode 100644 www/views/thirdparty/bitpay-header.html diff --git a/app-template/bitcoincom/css/bitcoin.com.css b/app-template/bitcoincom/css/bitcoin.com.css index e9b316761..19113dd2c 100644 --- a/app-template/bitcoincom/css/bitcoin.com.css +++ b/app-template/bitcoincom/css/bitcoin.com.css @@ -264,9 +264,30 @@ div.onboarding-topic { height: 5em; } +.shapeshift-banner { + background: url(../img/shapeshiftbg.jpg) center center no-repeat #28394d; + padding: 10px; + box-shadow: 0px 5px 10px 0px #cccccc; + height: 5em; +} + +.bitpay-banner { + background: center center no-repeat #1A3A8B; + padding: 10px; + box-shadow: 0px 5px 10px 0px #cccccc; + height: 5em; +} + +.bitpay-logo { + display: block; + max-height: 100%; + width: 100%; + height: 4em; +} + .shapeshift-logo { display: block; float: left; max-height: 100%; - max-width: 100%; + max-width: 100%; } diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index 1d52a715a..fd5b4f1cd 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -106,12 +106,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu } function handleThirdPartyIfBip70PaymentProtocol() { - if ($scope.thirdParty.id === 'bip70PaymentProtocol') { - requestedSatoshis = $scope.thirdParty.details.amount; - $scope.coin = $scope.thirdParty.coin; - $scope.requestAmount = unitsFromSatoshis * requestedSatoshis; - $scope.params.amount = requestedSatoshis; - $scope.params.toAddr = $scope.thirdParty.details.toAddress; + if ($scope.thirdParty.id === 'bitpay') { console.log('paypro details:', $scope.thirdParty.details); } } diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index fa5abd56b..e76627fcf 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -405,6 +405,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat return { amount: payProData.outputs[0].amount, caTrusted: true, + name: 'bitpay', domain: 'bitpay.com', expires: Math.floor(new Date(payProData.expires).getTime() / 1000), memo: payProData.memo, @@ -421,13 +422,13 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat function handlePayPro(payProDetails, coin) { var thirdPartyData = { - id: 'bip70PaymentProtocol', - coin: coin, + id: payProDetails.name, details: payProDetails }; var stateParams = { amount: payProDetails.amount, - toAddress: payProDetails.toAddress, + toAddr: payProDetails.toAddress, + coin: coin, thirdParty: JSON.stringify(thirdPartyData) }; diff --git a/src/sass/views/review.scss b/src/sass/views/review.scss index 22470a7b2..8bda83890 100644 --- a/src/sass/views/review.scss +++ b/src/sass/views/review.scss @@ -11,7 +11,7 @@ bottom: 92px; } - .shapeshift-banner { + .shapeshift-banner, .bitpay-banner { box-shadow: none; } } \ No newline at end of file diff --git a/www/css/bitcoin.com.css b/www/css/bitcoin.com.css index 9b69005c4..59e503ac7 100644 --- a/www/css/bitcoin.com.css +++ b/www/css/bitcoin.com.css @@ -314,9 +314,23 @@ div.slide-success__background.fill-screen { height: 5em; } +.bitpay-banner { + background: #1A3A8B; + padding: 10px; + box-shadow: 0px 5px 10px 0px #cccccc; + height: 5em; +} + +.bitpay-logo { + display: block; + max-height: 100%; + width: 100%; + height: 4em; +} + .shapeshift-logo { display: block; float: left; max-height: 100%; - max-width: 100%; + max-width: 100%; } diff --git a/www/css/main.css b/www/css/main.css index df39fda50..c2e4325f9 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -15262,7 +15262,7 @@ log-options #check-bar .checkbox-icon { #view-review .fee-summary { position: absolute; bottom: 92px; } - #view-review .shapeshift-banner { + #view-review .shapeshift-banner, #view-review .bitpay-banner { box-shadow: none; } .gravatar { @@ -15325,8 +15325,10 @@ ion-content.padded-bottom-cta-with-summary { .header { padding: 29px 12px 61px; - background-color: #FAB915; + background-color: #fab915; color: #FFFFFF; } + .header.btc { + background-color: #535353; } .header .title { font-size: 18px; font-weight: 400; diff --git a/www/img/bitpay_banner.svg b/www/img/bitpay_banner.svg new file mode 100644 index 000000000..cf5829899 --- /dev/null +++ b/www/img/bitpay_banner.svg @@ -0,0 +1,13 @@ + + + + Artboard + Created with Sketch. + + + + + + + + \ No newline at end of file diff --git a/www/views/thirdparty/bitpay-header.html b/www/views/thirdparty/bitpay-header.html new file mode 100644 index 000000000..a5ffcb3a5 --- /dev/null +++ b/www/views/thirdparty/bitpay-header.html @@ -0,0 +1,3 @@ +
+ +
\ No newline at end of file diff --git a/www/views/walletSelector.html b/www/views/walletSelector.html index c863f4ea7..15b4935fa 100644 --- a/www/views/walletSelector.html +++ b/www/views/walletSelector.html @@ -5,6 +5,7 @@
+
Paying
{{requestAmount}} {{requestCurrency}}
From bb3b00ae8d54b89103346bf2ff35715c27a8c88b Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 6 Aug 2018 22:20:51 +0900 Subject: [PATCH 239/386] Fix incomingData toAddress, mistake --- src/js/services/incomingData.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index f541deb58..cfa6f0a03 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -438,10 +438,10 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat url: payProDetails.url, verified: payProDetails.verified }; - + var stateParams = { amount: payProDetails.amount, - toAddr: payProDetails.toAddress, + toAddress: payProDetails.toAddress, coin: coin, thirdParty: JSON.stringify(thirdPartyData) }; From 3652419b0dc681dfc6b6f404c1c5e01e29ae89cb Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 6 Aug 2018 22:21:40 +0900 Subject: [PATCH 240/386] Fix double id --- src/js/services/incomingData.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index cfa6f0a03..ffa3e95f1 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -428,7 +428,6 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat coin: coin, domain: payProDetails.domain, expires: payProDetails.expires, - id: 'bip70PaymentProtocol', memo: payProDetails.memo, merchant_data: payProDetails.merchant_data, network: payProDetails.network, From 470868ade9baf9cca2f9a9ef65d8258e1cdb6e0e Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 6 Aug 2018 23:19:46 +0900 Subject: [PATCH 241/386] Review screen, cleaning in the same time --- src/js/controllers/review.controller.js | 11 +++++++++-- src/js/services/incomingData.js | 3 ++- www/css/main.css | 2 +- www/views/review.html | 19 ++++++++++++------- www/views/walletSelector.html | 2 +- 5 files changed, 25 insertions(+), 12 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 1a52fb56a..3143fabcf 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -43,6 +43,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit vm.sendStatus = ''; vm.thirdParty = false; vm.wallet = null; + vm.memoExpanded = false; var config = null; var defaults = {}; @@ -83,6 +84,12 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } vm.thirdParty.data['fromWalletId'] = vm.fromWalletId; } + if (vm.thirdParty.id === 'bip70') { + if (vm.thirdParty.memo) { + vm.memo = 'Payment request for BitPay invoice.\n' + toAddress + ' for merchant'; + vm.memoExpanded = true; + } + } } } @@ -321,7 +328,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit txp.outputs = [{ 'toAddress': tx.toAddress, 'amount': tx.amount, - 'message': tx.description + 'message': vm.memo }]; if (tx.sendMaxInfo) { @@ -333,7 +340,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } else txp.feeLevel = tx.feeLevel; } - txp.message = tx.description; + txp.message = vm.memo; if (tx.paypro) { txp.payProUrl = tx.paypro.url; diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index ffa3e95f1..be391edc3 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -422,7 +422,8 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat function handlePayPro(payProDetails, coin) { var thirdPartyData = { - id: payProDetails.name, + id: 'bip70', + name: payProDetails.name, caName: payProDetails.caName, caTrusted: payProDetails.caTrusted, coin: coin, diff --git a/www/css/main.css b/www/css/main.css index c2e4325f9..87333d1a6 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -12093,7 +12093,7 @@ a.item { color: #fff; } .header.shapeshift { - background: url(../img/shapeshiftbg.jpg) center center no-repeat #28394d; + background: url(../img/shapeshiftbg.jpg) center center repeat #28394d; opacity: 0.99; } #bitpayCard { diff --git a/www/views/review.html b/www/views/review.html index 631d1bec4..0ad5e2148 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -7,8 +7,7 @@ - +
@@ -47,7 +46,13 @@

{{vm.destination.name}} ({{vm.destination.currency}})

{{vm.destination.balanceAmount}} {{vm.destination.balanceCurrency}}

-
+
+ +

BitPay

+

Payment expired in XX:XX

+
+
{{vm.destination.address.substring(0,5)}}{{vm.destination.address.substring(5,vm.destination.address.length-4)}}{{vm.destination.address.substring(vm.destination.address.length-4)}}
@@ -56,17 +61,17 @@
+ ng-class="{ 'expand-content-revealed': vm.memoExpanded }" + ng-click="vm.memoExpanded = !vm.memoExpanded"> Add personal note
+ ng-class="{ 'expand-content-revealed': vm.memoExpanded }">
Personal Note:
- +
diff --git a/www/views/walletSelector.html b/www/views/walletSelector.html index 15b4935fa..eeb7591a8 100644 --- a/www/views/walletSelector.html +++ b/www/views/walletSelector.html @@ -5,7 +5,7 @@
-
+
Paying
{{requestAmount}} {{requestCurrency}}
From caafec4625bb6bca860cd41c082bd98738f48f3f Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 6 Aug 2018 18:06:10 +0200 Subject: [PATCH 242/386] shapeshift controller --- src/js/controllers/amount.js | 25 +--- src/js/controllers/review.controller.js | 19 ++- .../controllers/walletSelectorController.js | 1 + src/js/services/shapeshiftService.js | 131 ++++++++++-------- www/views/review.html | 3 +- 5 files changed, 89 insertions(+), 90 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index db1bb52fe..c8b7722f9 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -217,7 +217,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, }; function goBack() { - if (vm.shapeshiftOrderId) { + if (vm.thirdParty && vm.thirdParty.id === 'shapeshift') { $state.go('tabs.send').then(function() { $ionicHistory.clearHistory(); $state.go('tabs.home').then(function() { @@ -483,29 +483,6 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, if (!confirmData.fromWalletId) { $state.transitionTo('tabs.paymentRequest.confirm', confirmData); } else { - - if (vm.shapeshiftOrderId) { - var shapeshiftOrderUrl = 'https://www.shapeshift.io/#/status/'; - shapeshiftOrderUrl += vm.shapeshiftOrderId; - confirmData.description = shapeshiftOrderUrl; - - if (confirmData.sendMax) { - var wallet = lodash.find(profileService.getWallets({ coin: coin }), - function(w) { - return w.id == passthroughParams.fromWalletId; - }); - - var balance = parseFloat(wallet.cachedBalance.substring(0, wallet.cachedBalance.length-4)); - if (balance < vm.minAmount * 1.04) { - confirmData.sendMax = false; - confirmData.amount = vm.minAmount * unitToSatoshi; - } else if (balance > vm.maxAmount) { - confirmData.sendMax = false; - confirmData.amount = vm.maxAmount * unitToSatoshi * 0.99; - } - } - } - $state.transitionTo('tabs.send.review', confirmData); $scope.useSendMax = null; } diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 3143fabcf..13f6e6cb1 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,7 +4,7 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, configService, feeService, gettextCatalog, $ionicHistory, $ionicLoading, $ionicModal, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, soundService, $state, $timeout, txConfirmNotification, txFormatService, walletService) { +function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, configService, feeService, gettextCatalog, $ionicHistory, $ionicLoading, $ionicModal, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, shapeshiftService, soundService, $state, $timeout, txConfirmNotification, txFormatService, walletService) { var vm = this; vm.buttonText = ''; @@ -82,7 +82,20 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit if (!vm.thirdParty.data) { vm.thirdParty.data = {}; } - vm.thirdParty.data['fromWalletId'] = vm.fromWalletId; + + var toWallet = profileService.getWallet(data.stateParams.toWalletId); + $ionicLoading.show(); + walletService.getAddress(vm.originWallet, false, function onWalletAddress(err, returnAddr) { + walletService.getAddress(toWallet, false, function onWalletAddress(err, withdrawalAddr) { + $ionicLoading.hide(); + shapeshiftService.shiftIt(vm.originWallet.coin, toWallet.coin, withdrawalAddr, returnAddr, function(shapeshiftData) { + vm.memo = 'ShapeShift Order:\nhttps://www.shapeshift.io/#/status/'+shapeshiftData.orderId; + toAddress = shapeshiftData.toAddress; + vm.destination.address = toAddress; + vm.destination.kind = 'shapeshift'; + }); + }); + }); } if (vm.thirdParty.id === 'bip70') { if (vm.thirdParty.memo) { @@ -115,8 +128,6 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit if (vm.thirdParty.id === 'shapeshift') { shapeshiftService.shiftIt(); return; - } - if (!tx || !vm.originWallet) return; if ($scope.paymentExpired) { diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index b251da987..824d0e6ca 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -103,6 +103,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu function handleThirdPartyIfShapeshift() { if ($scope.thirdParty.id === 'shapeshift' && $scope.type === 'destination') { // Shapeshift wants to know the + $scope.coin = profileService.getWallet(fromWalletId).coin; if ($scope.coin === 'bch') { $scope.coin = 'btc'; } else { diff --git a/src/js/services/shapeshiftService.js b/src/js/services/shapeshiftService.js index 317e72394..b3e307667 100644 --- a/src/js/services/shapeshiftService.js +++ b/src/js/services/shapeshiftService.js @@ -1,48 +1,44 @@ 'use strict'; -angular.module('copayApp.services').factory('shapeshiftService', function($http, $interval, $log, lodash, moment, ongoingProcess, shapeshiftApiService, storageService, configService, incomingData, platformInfo, servicesService) { +angular.module('copayApp.services').factory('shapeshiftService', function ($http, $interval, $log, lodash, moment, ongoingProcess, shapeshiftApiService, storageService, configService, incomingData, platformInfo, servicesService) { var root = {}; root.ShiftState = 'Shift'; - root.withdrawalAddress = '' - root.returnAddress = '' + root.coinIn = ''; + root.coinOut = ''; + root.withdrawalAddress = ''; + root.returnAddress = ''; root.amount = ''; - root.marketData = {} - root.withdrawalAddress = function(address) { + root.marketData = {}; + root.withdrawalAddress = function (address) { root.withdrawalAddress = address; }; - root.returnAddress = function(address) { + root.returnAddress = function (address) { root.returnAddress = address; }; - root.amount = function(amount) { + root.amount = function (amount) { root.amount = amount; }; - root.fromWalletId = function(id) { - root.fromWalletId = id; - }; - root.toWalletId = function(id) { - root.toWalletId = id; - }; - root.coinIn = function(coinIn) { + root.coinIn = function (coinIn) { root.coinIn = coinIn.toUpperCase(); }; - root.coinOut = function(coinOut) { + root.coinOut = function (coinOut) { root.coinOut = coinOut.toUpperCase(); }; - root.getMarketDataIn = function(coin) { - if(coin === root.coinOut) return root.getMarketData(root.coinOut, root.coinIn); + root.getMarketDataIn = function (coin) { + if (coin === root.coinOut) return root.getMarketData(root.coinOut, root.coinIn); return root.getMarketData(coin, root.coinOut); }; - root.getMarketDataOut = function(coin) { - if(coin === root.coinIn) return root.getMarketData(root.coinOut, root.coinIn); + root.getMarketDataOut = function (coin) { + if (coin === root.coinIn) return root.getMarketData(root.coinOut, root.coinIn); return root.getMarketData(root.coinIn, coin); }; - root.getMarketData = function(coinIn, coinOut, cb) { + root.getMarketData = function (coinIn, coinOut, cb) { root.coinIn = coinIn; - root.coinOut= coinOut; - if(root.coinIn === undefined || root.coinOut === undefined) return; + root.coinOut = coinOut; + if (root.coinIn === undefined || root.coinOut === undefined) return; shapeshiftApiService .marketInfo(root.coinIn, root.coinOut) - .then(function(marketData){ + .then(function (marketData) { root.marketData = marketData; root.rateString = root.marketData.rate.toString() + ' ' + coinOut.toUpperCase() + '/' + coinIn.toUpperCase(); if (cb) { @@ -59,43 +55,50 @@ angular.module('copayApp.services').factory('shapeshiftService', function($http, });*/ root.coins = { - 'BTC': { name: 'Bitcoin', symbol: 'BTC' }, - 'BCH': { name: 'Bitcoin Cash', symbol: 'BCH' } + 'BTC': {name: 'Bitcoin', symbol: 'BTC'}, + 'BCH': {name: 'Bitcoin Cash', symbol: 'BCH'} }; - function checkForError(data){ - if(data.error) return true; + function checkForError(data) { + if (data.error) return true; return false; } - root.shiftIt = function(){ + root.shiftIt = function (coinIn, coinOut, withdrawalAddress, returnAddress, cb) { ongoingProcess.set('connectingShapeshift', true); - var validate=shapeshiftApiService.ValidateAddress(root.withdrawalAddress, root.coinOut); - validate.then(function(valid){ - //console.log(root.withdrawalAddress) - //console.log(valid) + root.withdrawalAddress(withdrawalAddress); + root.returnAddress(returnAddress); + var validate = shapeshiftApiService.ValidateAddress(withdrawalAddress, coinOut); + validate.then(function (valid) { var tx = ShapeShift(); - tx.then(function(txData){ - if(txData['fixedTxData']){ + var coin; + console.log("Starting"); + tx.then(function (txData) { + console.log("Got txData", txData); + if (txData['fixedTxData']) { txData = txData.fixedTxData; - if(checkForError(txData)) return; + if (checkForError(txData)) return; //console.log(txData) - var coinPair=txData.pair.split('_'); + var coinPair = txData.pair.split('_'); txData.depositType = coinPair[0].toUpperCase(); txData.withdrawalType = coinPair[1].toUpperCase(); - var coin = root.coins[txData.depositType].name.toLowerCase(); - //console.log(coin) - txData.depositQR = coin + ":" + txData.deposit + "?amount=" + txData.depositAmount + coin = root.coins[txData.depositType].name.toLowerCase(); + + txData.depositQR = coin + ":" + txData.deposit + "?amount=" + txData.depositAmount; + root.txFixedPending = true; - } else if(txData['normalTxData']){ + + } else if (txData['normalTxData']) { + txData = txData.normalTxData; - if(checkForError(txData)) return; - var coin = root.coins[txData.depositType.toUpperCase()].name.toLowerCase(); + if (checkForError(txData)) return; + coin = root.coins[txData.depositType.toUpperCase()].name.toLowerCase(); txData.depositQR = coin + ":" + txData.deposit; - } else if(txData['cancelTxData']){ - if(checkForError(txData.cancelTxData)) return; - if(root.txFixedPending) { - $interval.cancel(root.txInterval); + + } else if (txData['cancelTxData']) { + + if (checkForError(txData.cancelTxData)) return; + if (root.txFixedPending) { root.txFixedPending = false; } root.ShiftState = 'Shift'; @@ -108,37 +111,43 @@ angular.module('copayApp.services').factory('shapeshiftService', function($http, if (sendAddress && sendAddress.indexOf('bitcoin cash') >= 0) sendAddress = sendAddress.replace('bitcoin cash', 'bitcoincash'); + ongoingProcess.set('connectingShapeshift', false); + + root.ShiftState = 'Cancel'; + root.GetStatus(); + root.txInterval=$interval(root.GetStatus, 8000); + var shapeshiftData = { - fromWalletId: root.fromWalletId, + coinIn: coinIn, + coinOut: coinOut, toWalletId: root.toWalletId, minAmount: root.marketData.minimum, maxAmount: root.marketData.maxLimit, - orderId: root.depositInfo.orderId + orderId: root.depositInfo.orderId, + toAddress: txData.deposit }; - - if (incomingData.redir(sendAddress, 'shapeshift', shapeshiftData)) { + // + // if (incomingData.redir(sendAddress, 'shapeshift', shapeshiftData)) { ongoingProcess.set('connectingShapeshift', false); - return; - } + // return; + // } + cb(shapeshiftData); - /*root.ShiftState = 'Cancel'; - root.GetStatus(); - root.txInterval=$interval(root.GetStatus, 8000);*/ }); }) }; function ShapeShift() { - if(root.ShiftState === 'Cancel') return shapeshiftApiService.CancelTx(root); - if(parseFloat(root.amount) > 0) return shapeshiftApiService.FixedAmountTx(root); + if (root.ShiftState === 'Cancel') return shapeshiftApiService.CancelTx(root); + if (parseFloat(root.amount) > 0) return shapeshiftApiService.FixedAmountTx(root); return shapeshiftApiService.NormalTx(root); } - root.GetStatus = function(){ + root.GetStatus = function () { var address = root.depositInfo.deposit - shapeshiftApiService.GetStatusOfDepositToAddress(address).then(function(data){ + shapeshiftApiService.GetStatusOfDepositToAddress(address).then(function (data) { root.DepositStatus = data; - if(root.DepositStatus.status === 'complete'){ + if (root.DepositStatus.status === 'complete') { $interval.cancel(root.txInterval); root.depositInfo = null; root.ShiftState = 'Shift' @@ -153,7 +162,7 @@ angular.module('copayApp.services').factory('shapeshiftService', function($http, sref: 'tabs.shapeshift', }; - var register = function() { + var register = function () { servicesService.register(servicesItem); }; register(); diff --git a/www/views/review.html b/www/views/review.html index 0ad5e2148..7317d7b68 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -32,13 +32,14 @@
+
To:
- +
From 5b6f48e6a2d8bb34a8d94fd197386f1ef3f04d24 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 6 Aug 2018 18:11:37 +0200 Subject: [PATCH 243/386] Check min max on shapeshift flow --- src/js/controllers/amount.js | 14 +++----------- src/js/controllers/review.controller.js | 3 +-- src/js/controllers/walletSelectorController.js | 1 + 3 files changed, 5 insertions(+), 13 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index c8b7722f9..c53d49061 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -20,7 +20,6 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, vm.lastUsedPopularList = []; vm.maxAmount = 0; vm.minAmount = 0; - vm.shapeshiftOrderId = ''; vm.thirdParty = false; vm.unit = ''; @@ -95,14 +94,9 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, vm.thirdParty.data['minAmount'] = vm.minAmount = parseFloat(data.minimum); vm.thirdParty.data['maxAmount'] = vm.maxAmount = parseFloat(data.maxLimit); }); - - // if (vm.thirdParty.data['shapeshiftOrderId'] && data.stateParams.shapeshiftOrderId.length > 0) { - // vm.shapeshiftOrderId = vm.thirdParty.data['shapeshiftOrderId']; - // } } } } - // vm.shapeshiftOrderId = data.stateParams.thirdPartyOrderId; vm.isRequestingSpecificAmount = !data.stateParams.fromWalletId; @@ -371,8 +365,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, vm.alternativeAmount = txFormatService.formatAmount(amountInSatoshis, true); vm.allowSend = lodash.isNumber(a) && a > 0 - && (!vm.shapeshiftOrderId - || (a >= vm.minAmount && a <= vm.maxAmount)) + && (a >= vm.minAmount && a <= vm.maxAmount) && !vm.fundsAreInsufficient; } else { if (result) { @@ -392,8 +385,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, vm.alternativeAmount = $filter('formatFiatAmount')(toFiat(result)); vm.allowSend = lodash.isNumber(result) && result > 0 - && (!vm.shapeshiftOrderId - || (result >= vm.minAmount && result <= vm.maxAmount)) + && (result >= vm.minAmount && result <= vm.maxAmount) && !vm.fundsAreInsufficient; } @@ -404,7 +396,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, if (vm.fundsAreInsufficient) { vm.errorMessage = gettextCatalog.getString('Not enough available funds'); - } else if (amountInCrypto && vm.shapeshiftOrderId) { + } else if (amountInCrypto && vm.thirdParty && vm.thirdParty.id === 'shapeshift') { if (amountInCrypto < vm.minAmount) { vm.errorMessage = gettextCatalog.getString('Amount is below minimum'); diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 13f6e6cb1..19bab5a2e 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -125,8 +125,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } vm.approve = function() { - if (vm.thirdParty.id === 'shapeshift') { - shapeshiftService.shiftIt(); + if (vm.thirdParty.id === 'shapeshift') return; if (!tx || !vm.originWallet) return; diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index 824d0e6ca..a4ff3ab3e 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -102,6 +102,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu } function handleThirdPartyIfShapeshift() { + console.log($scope.thirdParty, $scope.coin); if ($scope.thirdParty.id === 'shapeshift' && $scope.type === 'destination') { // Shapeshift wants to know the $scope.coin = profileService.getWallet(fromWalletId).coin; if ($scope.coin === 'bch') { From d183077a203d36a1482631fc167bb4092ca77a4b Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 7 Aug 2018 09:39:48 +1200 Subject: [PATCH 244/386] Countdown timer for BIP70 invoices. --- src/js/controllers/review.controller.js | 154 ++++++++++++++---------- src/js/services/incomingData.js | 2 +- www/views/review.html | 2 +- 3 files changed, 94 insertions(+), 64 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 19bab5a2e..5785ee831 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,7 +4,7 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, configService, feeService, gettextCatalog, $ionicHistory, $ionicLoading, $ionicModal, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, shapeshiftService, soundService, $state, $timeout, txConfirmNotification, txFormatService, walletService) { +function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, configService, feeService, gettextCatalog, $interval, $ionicHistory, $ionicLoading, $ionicModal, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, shapeshiftService, soundService, $state, $timeout, txConfirmNotification, txFormatService, walletService) { var vm = this; vm.buttonText = ''; @@ -33,19 +33,27 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit currencyColor: '', }; vm.originWallet = null; + vm.paymentExpired = false; vm.primaryAmount = ''; vm.primaryCurrency = ''; vm.usingMerchantFee = false; vm.readyToSend = false; + vm.remainingTimeStr = ''; vm.secondaryAmount = ''; vm.secondaryCurrency = ''; vm.sendingTitle = gettextCatalog.getString('You are sending'); vm.sendStatus = ''; + vm.showAddress = true; vm.thirdParty = false; vm.wallet = null; vm.memoExpanded = false; + + // Functions + vm.onSuccessConfirm = onSuccessConfirm; + var config = null; + var countDown = null; var defaults = {}; var coin = ''; var countDown = null; @@ -57,6 +65,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit var satoshis = null; var toAddress = ''; var tx = {}; + var txPayproData = null; var unitFromSat = 0; var FEE_TOO_HIGH_LIMIT_PERCENTAGE = 15; @@ -77,32 +86,8 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit if (data.stateParams.thirdParty) { vm.thirdParty = JSON.parse(data.stateParams.thirdParty); // Parse stringified JSON-object if (vm.thirdParty) { - if (vm.thirdParty.id === 'shapeshift') { - vm.sendingTitle = gettextCatalog.getString('You are shifting'); - if (!vm.thirdParty.data) { - vm.thirdParty.data = {}; - } - - var toWallet = profileService.getWallet(data.stateParams.toWalletId); - $ionicLoading.show(); - walletService.getAddress(vm.originWallet, false, function onWalletAddress(err, returnAddr) { - walletService.getAddress(toWallet, false, function onWalletAddress(err, withdrawalAddr) { - $ionicLoading.hide(); - shapeshiftService.shiftIt(vm.originWallet.coin, toWallet.coin, withdrawalAddr, returnAddr, function(shapeshiftData) { - vm.memo = 'ShapeShift Order:\nhttps://www.shapeshift.io/#/status/'+shapeshiftData.orderId; - toAddress = shapeshiftData.toAddress; - vm.destination.address = toAddress; - vm.destination.kind = 'shapeshift'; - }); - }); - }); - } - if (vm.thirdParty.id === 'bip70') { - if (vm.thirdParty.memo) { - vm.memo = 'Payment request for BitPay invoice.\n' + toAddress + ' for merchant'; - vm.memoExpanded = true; - } - } + handleThirdPartyInitIfBip70(); + handleThirdPartyInitIfShapeshift(); } } @@ -240,6 +225,8 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit sendMax: data.stateParams.sendMax === 'true' ? true : false, fromWalletId: data.stateParams.fromWalletId, toAddress: data.stateParams.toAddress, + paypro: txPayproData, + feeLevel: configFeeLevel, spendUnconfirmed: config.wallet.spendUnconfirmed, @@ -253,6 +240,8 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit txp: {}, }; + + if (data.stateParams.requiredFeeRate) { vm.usingMerchantFee = true; tx.feeRate = parseInt(data.stateParams.requiredFeeRate); @@ -454,6 +443,80 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit vm.destination.balanceCurrency = balanceText.currency; } + function handleThirdPartyInitIfBip70() { + if (vm.thirdParty.id === 'bip70') { + if (vm.thirdParty.memo) { + // Why not the whole memo? + vm.memo = 'Payment request for BitPay invoice.\n' + toAddress + ' for merchant'; + vm.memoExpanded = true; + } + txPayproData = { + caTrusted: vm.thirdParty.caTrusted, + domain: vm.thirdParty.domain, + expires: vm.thirdParty.expires, + toAddress: toAddress, + url: vm.thirdParty.url, + verified: vm.thirdParty.verified, + }; + } + } + + function handleThirdPartyInitIfShapeshift() { + if (vm.thirdParty.id === 'shapeshift') { + vm.sendingTitle = gettextCatalog.getString('You are shifting'); + if (!vm.thirdParty.data) { + vm.thirdParty.data = {}; + } + + var toWallet = profileService.getWallet(data.stateParams.toWalletId); + $ionicLoading.show(); + walletService.getAddress(vm.originWallet, false, function onWalletAddress(err, returnAddr) { + walletService.getAddress(toWallet, false, function onWalletAddress(err, withdrawalAddr) { + $ionicLoading.hide(); + shapeshiftService.shiftIt(vm.originWallet.coin, toWallet.coin, withdrawalAddr, returnAddr, function(shapeshiftData) { + vm.memo = 'ShapeShift Order:\nhttps://www.shapeshift.io/#/status/' + shapeshiftData.orderId; + toAddress = shapeshiftData.toAddress; + vm.destination.address = toAddress; + vm.destination.kind = 'shapeshift'; + }); + }); + }); + } + } + + function startExpirationTimer(expirationTime) { + vm.paymentExpired = false; + setExpirationTime(); + + countDown = $interval(function() { + setExpirationTime(); + }, 1000); + + function setExpirationTime() { + console.log('setExpirationTime()'); + var now = Math.floor(Date.now() / 1000); + + if (now > expirationTime) { + setExpiredValues(); + return; + } + + var totalSecs = expirationTime - now; + var m = Math.floor(totalSecs / 60); + var s = totalSecs % 60; + vm.remainingTimeStr = m + ":" + ('0' + s).slice(-2); + }; + + function setExpiredValues() { + vm.paymentExpired = true; + vm.remainingTimeStr = gettextCatalog.getString('Expired'); + if (countDown) $interval.cancel(countDown); + $timeout(function() { + $scope.$apply(); + }); + }; + }; + function updateSendAmounts() { if (typeof satoshis !== 'number') { return; @@ -497,7 +560,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit }); } - vm.onSuccessConfirm = function() { + function onSuccessConfirm() { vm.sendStatus = ''; $ionicHistory.nextViewOptions({ disableAnimate: true, @@ -565,14 +628,13 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } }); - // Other Scope vars vm.showAddress = false; setButtonText(vm.originWallet.credentials.m > 1, !!tx.paypro); if (tx.paypro) - _paymentTimeControl(tx.paypro.expires); + startExpirationTimer(tx.paypro.expires); updateTx(tx, vm.originWallet, { dryRun: true @@ -765,36 +827,4 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit }); } - function _paymentTimeControl(expirationTime) { - $scope.paymentExpired = false; - setExpirationTime(); - - countDown = $interval(function() { - setExpirationTime(); - }, 1000); - - function setExpirationTime() { - var now = Math.floor(Date.now() / 1000); - - if (now > expirationTime) { - setExpiredValues(); - return; - } - - var totalSecs = expirationTime - now; - var m = Math.floor(totalSecs / 60); - var s = totalSecs % 60; - $scope.remainingTimeStr = ('0' + m).slice(-2) + ":" + ('0' + s).slice(-2); - }; - - function setExpiredValues() { - $scope.paymentExpired = true; - $scope.remainingTimeStr = gettextCatalog.getString('Expired'); - if (countDown) $interval.cancel(countDown); - $timeout(function() { - $scope.$apply(); - }); - }; - }; - } diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index be391edc3..703056f03 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -134,7 +134,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat } }); } else { - payproService.getPayProDetails(data, coin, function(err, details) { + payproService.getPayProDetails(data, coin, function onGetPayProDetails(err, details) { if (err) { popupService.showAlert(gettextCatalog.getString('Error'), err); } else { diff --git a/www/views/review.html b/www/views/review.html index 7317d7b68..c401b8c34 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -51,7 +51,7 @@ ng-if="vm.thirdParty && vm.thirdParty.id === 'bip70' && vm.thirdParty.name === 'bitpay'">

BitPay

-

Payment expired in XX:XX

+

Payment expires: {{vm.remainingTimeStr}}

From e29f97eddf4564322d912ab0a964049394aec84c Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 7 Aug 2018 11:07:19 +1200 Subject: [PATCH 245/386] Payment request expiration. --- src/js/controllers/review.controller.js | 1 + www/views/review.html | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 5785ee831..fe1eac2cd 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -510,6 +510,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit function setExpiredValues() { vm.paymentExpired = true; vm.remainingTimeStr = gettextCatalog.getString('Expired'); + vm.readyToSend = false; if (countDown) $interval.cancel(countDown); $timeout(function() { $scope.$apply(); diff --git a/www/views/review.html b/www/views/review.html index c401b8c34..c6631fd19 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -51,7 +51,8 @@ ng-if="vm.thirdParty && vm.thirdParty.id === 'bip70' && vm.thirdParty.name === 'bitpay'">

BitPay

-

Payment expires: {{vm.remainingTimeStr}}

+

Payment expires: {{vm.remainingTimeStr}}

+

Payment request has expired

From 09f627ea5118b0dfdd2b18601e73958fb02f8a52 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 7 Aug 2018 11:27:05 +1200 Subject: [PATCH 246/386] Suggested by merchant. --- src/sass/components/fee-summary.scss | 26 ++++++++++++++++---------- src/sass/views/review.scss | 4 ++++ www/views/review.html | 11 +++++++---- 3 files changed, 27 insertions(+), 14 deletions(-) diff --git a/src/sass/components/fee-summary.scss b/src/sass/components/fee-summary.scss index 404643a82..47fe2f6d1 100644 --- a/src/sass/components/fee-summary.scss +++ b/src/sass/components/fee-summary.scss @@ -1,7 +1,7 @@ .fee-summary { position: relative; display: flex; - justify-content: space-between; + flex-direction: column; width: 100%; padding: 5px 12px 15px; box-sizing: border-box; @@ -17,17 +17,23 @@ background: linear-gradient(to bottom, rgba(242,242,242,0) 0%,rgba(242,242,242,1) 100%); } - .fee-fiat { - &.positive { - color: #70955F; + .amount { + display: flex; + flex-direction: row; + justify-content: space-between; + + .fee-fiat { + &.positive { + color: #70955F; + } + + &.negative { + color: #C24633; + } } - &.negative { - color: #C24633; + .fee-crypto { + color: #A7A7A7; } } - - .fee-crypto { - color: #A7A7A7; - } } \ No newline at end of file diff --git a/src/sass/views/review.scss b/src/sass/views/review.scss index 8bda83890..44b634697 100644 --- a/src/sass/views/review.scss +++ b/src/sass/views/review.scss @@ -14,4 +14,8 @@ .shapeshift-banner, .bitpay-banner { box-shadow: none; } + + .warning { + color: $v-warning-color-2; + } } \ No newline at end of file diff --git a/www/views/review.html b/www/views/review.html index c6631fd19..4eb4763d7 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -82,10 +82,13 @@
-
Fee: Less than 1 cent
-
Fee: {{vm.feeFiat}} {{vm.feeCurrency}}
-
- {{vm.feeCrypto}} {{vm.origin.currency}} +
Suggested by merchant:
+
+
Fee: Less than 1 cent
+
Fee: {{vm.feeFiat}} {{vm.feeCurrency}}
+
+ {{vm.feeCrypto}} {{vm.origin.currency}} +
From 7d1fff424ac68fa75fd5e6f5d90eb9fba0316596 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 7 Aug 2018 11:34:35 +1200 Subject: [PATCH 247/386] Streamlined display of memo. --- src/js/controllers/review.controller.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index fe1eac2cd..49c4d51ab 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -445,11 +445,9 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit function handleThirdPartyInitIfBip70() { if (vm.thirdParty.id === 'bip70') { - if (vm.thirdParty.memo) { - // Why not the whole memo? - vm.memo = 'Payment request for BitPay invoice.\n' + toAddress + ' for merchant'; - vm.memoExpanded = true; - } + vm.memo = vm.thirdParty.memo; + vm.memoExpanded = !!vm.memo; + txPayproData = { caTrusted: vm.thirdParty.caTrusted, domain: vm.thirdParty.domain, From 38852d32d4b300d82e8251b5a28a0f26cdc8b6f6 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 7 Aug 2018 11:59:36 +1200 Subject: [PATCH 248/386] Sending BIP70 payments. --- src/js/controllers/amount.js | 6 ++++-- src/js/controllers/review.controller.js | 6 ++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index c53d49061..e6913a2cb 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -365,7 +365,8 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, vm.alternativeAmount = txFormatService.formatAmount(amountInSatoshis, true); vm.allowSend = lodash.isNumber(a) && a > 0 - && (a >= vm.minAmount && a <= vm.maxAmount) + && (!vm.minAmount || a >= vm.minAmount) + && (!vm.maxAmount || a <= vm.maxAmount) && !vm.fundsAreInsufficient; } else { if (result) { @@ -385,7 +386,8 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, vm.alternativeAmount = $filter('formatFiatAmount')(toFiat(result)); vm.allowSend = lodash.isNumber(result) && result > 0 - && (result >= vm.minAmount && result <= vm.maxAmount) + && (!vm.minAmount || result >= vm.minAmount) + && (!vm.maxAmount || result <= vm.maxAmount) && !vm.fundsAreInsufficient; } diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 49c4d51ab..73af91188 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -110,13 +110,14 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } vm.approve = function() { + if (vm.thirdParty.id === 'shapeshift') return; if (!tx || !vm.originWallet) return; - if ($scope.paymentExpired) { + if (vm.paymentExpired) { popupService.showAlert(null, gettextCatalog.getString('This bitcoin payment request has expired.')); - $scope.sendStatus = ''; + vm.sendStatus = ''; $timeout(function() { $scope.$apply(); }); @@ -445,6 +446,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit function handleThirdPartyInitIfBip70() { if (vm.thirdParty.id === 'bip70') { + vm.sendingTitle = gettextCatalog.getString('You are paying'); vm.memo = vm.thirdParty.memo; vm.memoExpanded = !!vm.memo; From 6dfbbb15d44b8e612ba6427eee4af7ffb116095f Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 7 Aug 2018 12:16:59 +1200 Subject: [PATCH 249/386] Added showSendMaxWarning(). --- src/js/controllers/review.controller.js | 40 +++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 73af91188..7c8bd784d 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -659,6 +659,46 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit // }); } + function showSendMaxWarning(wallet, sendMaxInfo) { + var feeAlternative = '', + msg = ''; + + function verifyExcludedUtxos() { + var warningMsg = []; + if (sendMaxInfo.utxosBelowFee > 0) { + warningMsg.push(gettextCatalog.getString("A total of {{amountBelowFeeStr}} were excluded. These funds come from UTXOs smaller than the network fee provided.", { + amountBelowFeeStr: txFormatService.formatAmountStr(wallet.coin, sendMaxInfo.amountBelowFee) + })); + } + + if (sendMaxInfo.utxosAboveMaxSize > 0) { + warningMsg.push(gettextCatalog.getString("A total of {{amountAboveMaxSizeStr}} were excluded. The maximum size allowed for a transaction was exceeded.", { + amountAboveMaxSizeStr: txFormatService.formatAmountStr(vm.originWallet.coin, sendMaxInfo.amountAboveMaxSize) + })); + } + return warningMsg.join('\n'); + }; + + feeAlternative = txFormatService.formatAlternativeStr(vm.originWallet.coin, sendMaxInfo.fee); + if (feeAlternative) { + msg = gettextCatalog.getString("{{feeAlternative}} will be deducted for bitcoin networking fees ({{fee}}).", { + fee: txFormatService.formatAmountStr(vm.originWallet.coin, sendMaxInfo.fee), + feeAlternative: feeAlternative + }); + } else { + msg = gettextCatalog.getString("{{fee}} will be deducted for bitcoin networking fees).", { + fee: txFormatService.formatAmountStr(vm.originWallet.coin, sendMaxInfo.fee) + }); + } + + var warningMsg = verifyExcludedUtxos(); + + if (!lodash.isEmpty(warningMsg)) + msg += '\n' + warningMsg; + + popupService.showAlert(null, msg, function() {}); + }; + function statusChangeHandler(processName, showName, isOn) { $log.debug('statusChangeHandler: ', processName, showName, isOn); if ( From 6c46ec2bcab7315df92dbefd417bd13682e3ee09 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 7 Aug 2018 14:23:53 +1200 Subject: [PATCH 250/386] Fix for some changes which broke Shapeshift flow. --- src/js/controllers/review.controller.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 7c8bd784d..ce453cd8a 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -78,6 +78,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit originWalletId = data.stateParams.fromWalletId; satoshis = parseInt(data.stateParams.amount, 10); toAddress = data.stateParams.toAddress; + destinationWalletId = data.stateParams.toWalletId; vm.originWallet = profileService.getWallet(originWalletId); vm.origin.currency = vm.originWallet.coin.toUpperCase(); @@ -257,7 +258,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit try { if (vm.destination.kind === 'wallet') { // This is a wallet-to-wallet transfer $ionicLoading.show(); - var toWallet = profileService.getWallet(data.stateParams.toWalletId); + var toWallet = profileService.getWallet(destinationWalletId); // We need an address to send to, so we ask the walletService to create a new address for the toWallet. console.log('Getting address for wallet...'); @@ -468,7 +469,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit vm.thirdParty.data = {}; } - var toWallet = profileService.getWallet(data.stateParams.toWalletId); + var toWallet = profileService.getWallet(destinationWalletId); $ionicLoading.show(); walletService.getAddress(vm.originWallet, false, function onWalletAddress(err, returnAddr) { walletService.getAddress(toWallet, false, function onWalletAddress(err, withdrawalAddr) { From db7eee984bfe8304c309c32600171e61b18d5997 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 7 Aug 2018 14:48:43 +1200 Subject: [PATCH 251/386] Error handling for Shapeshift, and UI for destination wallet. --- src/js/controllers/review.controller.js | 21 ++++++++++++++++++--- www/views/review.html | 2 +- 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index ce453cd8a..6ae2a51c0 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -470,11 +470,26 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } var toWallet = profileService.getWallet(destinationWalletId); + vm.destination.name = toWallet.name; + vm.destination.color = toWallet.color; + vm.destination.currency = toWallet.coin.toUpperCase(); + $ionicLoading.show(); - walletService.getAddress(vm.originWallet, false, function onWalletAddress(err, returnAddr) { - walletService.getAddress(toWallet, false, function onWalletAddress(err, withdrawalAddr) { + walletService.getAddress(vm.originWallet, false, function onReturnWalletAddress(err, returnAddr) { + if (err) { $ionicLoading.hide(); - shapeshiftService.shiftIt(vm.originWallet.coin, toWallet.coin, withdrawalAddr, returnAddr, function(shapeshiftData) { + popupService.showAlert(gettextCatalog.getString('Shapeshift Error'), err.toString()); + return; + } + walletService.getAddress(toWallet, false, function onWithdrawalWalletAddress(err, withdrawalAddr) { + if (err) { + $ionicLoading.hide(); + popupService.showAlert(gettextCatalog.getString('Shapeshift Error'), err.toString()); + return; + } + + $ionicLoading.hide(); + shapeshiftService.shiftIt(vm.originWallet.coin, toWallet.coin, withdrawalAddr, returnAddr, function onShiftIt(shapeshiftData) { vm.memo = 'ShapeShift Order:\nhttps://www.shapeshift.io/#/status/' + shapeshiftData.orderId; toAddress = shapeshiftData.toAddress; vm.destination.address = toAddress; diff --git a/www/views/review.html b/www/views/review.html index 4eb4763d7..9edd672ec 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -37,7 +37,7 @@
To:
+ ng-if="vm.destination.kind === 'contact' || vm.destination.kind === 'wallet' || vm.destination.kind == 'shapeshift'">
Date: Tue, 7 Aug 2018 13:56:56 +0900 Subject: [PATCH 252/386] incomingData, bip70 & bitpay --- src/js/services/incomingData.js | 116 +++++++++++++++----------------- 1 file changed, 54 insertions(+), 62 deletions(-) diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index 703056f03..a41fcb5f4 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -82,37 +82,33 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat }); // Timeout is required to enable the "Back" button $timeout(function() { + var params = {}; + if (amount) { - $state.transitionTo('tabs.send.origin', { - amount: amount, - toAddress: addr, - description: message, - coin: coin - }); - } else { - var params = { - toAddress: addr, - coin: coin, - displayAddress: originalAddress ? originalAddress : addr, - noPrefix: noPrefixInAddress - }; - if (serviceId) { - if (!params['thirdParty']) { - params['thirdParty'] = []; - } - params['thirdParty']['id'] = serviceId; - } + params.amount = amount; + } - if (serviceData) { - params['thirdParty']['data'] = serviceData; - // params['thirdParty']['minShapeshiftAmount'] = serviceData.minAmount; - // params['thirdParty']['maxShapeshiftAmount'] = serviceData.maxAmount; - // params['thirdParty']['shapeshiftOrderId'] = serviceData.orderId; - params['thirdParty'] = JSON.stringify(params['thirdParty']); - $state.transitionTo('tabs.send.amount', params); - } else { - $state.transitionTo('tabs.send.origin', params); - } + if (addr) { + params.toAddress = addr; + params.displayAddress = originalAddress ? originalAddress : addr; + } + + if (coin) { + params.coin = coin; + } + + if (noPrefixInAddress) { + params.noPrefixInAddress = noPrefixInAddress; + } + + if (serviceId) { + params.thirdParty = []; + params.thirdParty.id = serviceId; + params.thirdParty.data = serviceData; + params.thirdParty = JSON.stringify(params.thirdParty); + $state.transitionTo('tabs.send.amount', params); + } else { + $state.transitionTo('tabs.send.origin', params); } }, 100); } @@ -130,7 +126,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat } popupService.showAlert(gettextCatalog.getString('Error'), message) } else { - handlePayPro(createBchPayProObject(details), coin); + handlePayPro(details, coin); } }); } else { @@ -399,14 +395,30 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat }, 100); } - function createBchPayProObject(payProData) { - var displayAddr = payProData.outputs[0].address; - var toAddr = bitcoinCashJsService.readAddress('bitcoincash:' + displayAddr).legacy; - return { - amount: payProData.outputs[0].amount, + function handlePayPro(payProData, coin) { + + var toAddr = payProData.toAddress; + var amount = payProData.amount; + var paymentUrl = payProData.url; + + if (coin === 'bch') { + var displayAddr = payProData.outputs[0].address; + toAddr = bitcoinCashJsService.readAddress('bitcoincash:' + displayAddr).legacy; + amount = payProData.outputs[0].amount; + paymentUrl = payProData.paymentUrl; + } + + var name = payProData.domain; + if (paymentUrl.indexOf('https://bitpay.com') > -1) { + name = 'bitpay'; + } + + var thirdPartyData = { + id: 'bip70', + amount: amount, caTrusted: true, - name: 'bitpay', - domain: 'bitpay.com', + name: name, + domain: payProData.domain, expires: Math.floor(new Date(payProData.expires).getTime() / 1000), memo: payProData.memo, network: 'livenet', @@ -415,40 +427,20 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat time: Math.ceil(new Date(payProData.time).getTime() / 1000), displayAddress: displayAddr, toAddress: toAddr, - url: payProData.paymentUrl, + url: paymentUrl, verified: true }; - } - - function handlePayPro(payProDetails, coin) { - var thirdPartyData = { - id: 'bip70', - name: payProDetails.name, - caName: payProDetails.caName, - caTrusted: payProDetails.caTrusted, - coin: coin, - domain: payProDetails.domain, - expires: payProDetails.expires, - memo: payProDetails.memo, - merchant_data: payProDetails.merchant_data, - network: payProDetails.network, - requiredFeeRate: payProDetails.requiredFeeRate, - selfSigned: payProDetails.selfSigned, - time: payProDetails.time, - url: payProDetails.url, - verified: payProDetails.verified - }; var stateParams = { - amount: payProDetails.amount, - toAddress: payProDetails.toAddress, + amount: thirdPartyData.amount, + toAddress: thirdPartyData.toAddress, coin: coin, thirdParty: JSON.stringify(thirdPartyData) }; // fee - if (payProDetails.requiredFeeRate) { - stateParams.requiredFeeRate = payProDetails.requiredFeeRate * 1024; + if (thirdPartyData.requiredFeeRate) { + stateParams.requiredFeeRate = thirdPartyData.requiredFeeRate * 1024; } scannerService.pausePreview(); From a9711c257537bbbf7278ca96905f13773898efca Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 7 Aug 2018 14:02:53 +0900 Subject: [PATCH 253/386] Fix incomingData, expires different depending on btc or bch (bitpay...) --- src/js/services/incomingData.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index a41fcb5f4..e42661115 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -400,12 +400,14 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat var toAddr = payProData.toAddress; var amount = payProData.amount; var paymentUrl = payProData.url; + var expires = payProData.expires if (coin === 'bch') { var displayAddr = payProData.outputs[0].address; toAddr = bitcoinCashJsService.readAddress('bitcoincash:' + displayAddr).legacy; amount = payProData.outputs[0].amount; paymentUrl = payProData.paymentUrl; + expires = Math.floor(new Date(expires).getTime() / 1000) } var name = payProData.domain; @@ -419,7 +421,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat caTrusted: true, name: name, domain: payProData.domain, - expires: Math.floor(new Date(payProData.expires).getTime() / 1000), + expires: expires, memo: payProData.memo, network: 'livenet', requiredFeeRate: payProData.requiredFeeRate, From 886204d8b02ae067ea8c1e60a0e8e8a5a2c99de1 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 7 Aug 2018 14:34:02 +0900 Subject: [PATCH 254/386] incomingData time for bch --- src/js/services/incomingData.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index e42661115..2b9f5db25 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -400,7 +400,8 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat var toAddr = payProData.toAddress; var amount = payProData.amount; var paymentUrl = payProData.url; - var expires = payProData.expires + var expires = payProData.expires; + var time = payProData.time; if (coin === 'bch') { var displayAddr = payProData.outputs[0].address; @@ -408,6 +409,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat amount = payProData.outputs[0].amount; paymentUrl = payProData.paymentUrl; expires = Math.floor(new Date(expires).getTime() / 1000) + time = Math.ceil(new Date(time).getTime() / 1000) } var name = payProData.domain; @@ -426,7 +428,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat network: 'livenet', requiredFeeRate: payProData.requiredFeeRate, selfSigned: 0, - time: Math.ceil(new Date(payProData.time).getTime() / 1000), + time: time, displayAddress: displayAddr, toAddress: toAddr, url: paymentUrl, From 59d1704673266051a3f0c3cdae61e8c0ac0c8fbb Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 7 Aug 2018 17:34:28 +1200 Subject: [PATCH 255/386] Fix for display of fee when not for a BIP70 invoice. --- src/sass/components/fee-summary.scss | 1 + 1 file changed, 1 insertion(+) diff --git a/src/sass/components/fee-summary.scss b/src/sass/components/fee-summary.scss index 47fe2f6d1..e09af4be3 100644 --- a/src/sass/components/fee-summary.scss +++ b/src/sass/components/fee-summary.scss @@ -21,6 +21,7 @@ display: flex; flex-direction: row; justify-content: space-between; + width: 100%; .fee-fiat { &.positive { From 91487cf74c9f10d0a0796e9620d0f480c6bc7fd8 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 7 Aug 2018 15:02:29 +0900 Subject: [PATCH 256/386] shapeshift add the toAddress in the tx. Sending works. --- src/js/controllers/review.controller.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 6ae2a51c0..eb3fde53e 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -111,9 +111,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } vm.approve = function() { - - if (vm.thirdParty.id === 'shapeshift') - return; + if (!tx || !vm.originWallet) return; if (vm.paymentExpired) { @@ -491,7 +489,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit $ionicLoading.hide(); shapeshiftService.shiftIt(vm.originWallet.coin, toWallet.coin, withdrawalAddr, returnAddr, function onShiftIt(shapeshiftData) { vm.memo = 'ShapeShift Order:\nhttps://www.shapeshift.io/#/status/' + shapeshiftData.orderId; - toAddress = shapeshiftData.toAddress; + tx.toAddress = shapeshiftData.toAddress; vm.destination.address = toAddress; vm.destination.kind = 'shapeshift'; }); From d26a96500b73c6ebf81cba9fd38e279adc795d34 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 7 Aug 2018 15:30:28 +0900 Subject: [PATCH 257/386] eGifter incomingData --- src/js/services/incomingData.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index 1a2601fda..946144dce 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -397,6 +397,8 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat function handlePayPro(payProData, coin) { + console.log(payProData); + var toAddr = payProData.toAddress; var amount = payProData.amount; var paymentUrl = payProData.url; @@ -413,7 +415,10 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat } var name = payProData.domain; - if (paymentUrl.indexOf('https://bitpay.com') > -1) { + + if (payProData.memo.indexOf('eGifter') > -1) { + name = 'eGifter' + } else if (paymentUrl.indexOf('https://bitpay.com') > -1) { name = 'BitPay'; } From 1aa31b69352e49ba1207f9d68e346b1508028600 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 7 Aug 2018 16:36:33 +0900 Subject: [PATCH 258/386] egifter template, waiting the logo in svg. --- app-template/bitcoincom/css/bitcoin.com.css | 29 +++++++++++++-------- src/sass/views/review.scss | 2 +- www/css/bitcoin.com.css | 24 +++++++++++++---- www/css/main.css | 23 ++++++++++------ www/views/thirdparty/egifter-header.html | 3 +++ www/views/walletSelector.html | 3 ++- 6 files changed, 58 insertions(+), 26 deletions(-) create mode 100644 www/views/thirdparty/egifter-header.html diff --git a/app-template/bitcoincom/css/bitcoin.com.css b/app-template/bitcoincom/css/bitcoin.com.css index 19113dd2c..793276e25 100644 --- a/app-template/bitcoincom/css/bitcoin.com.css +++ b/app-template/bitcoincom/css/bitcoin.com.css @@ -264,15 +264,15 @@ div.onboarding-topic { height: 5em; } -.shapeshift-banner { - background: url(../img/shapeshiftbg.jpg) center center no-repeat #28394d; - padding: 10px; - box-shadow: 0px 5px 10px 0px #cccccc; - height: 5em; +.shapeshift-logo { + display: block; + float: left; + max-height: 100%; + max-width: 100%; } .bitpay-banner { - background: center center no-repeat #1A3A8B; + background: #1A3A8B; padding: 10px; box-shadow: 0px 5px 10px 0px #cccccc; height: 5em; @@ -285,9 +285,16 @@ div.onboarding-topic { height: 4em; } -.shapeshift-logo { - display: block; - float: left; - max-height: 100%; - max-width: 100%; +.egifter-banner { + background: #1A3A8B; + padding: 10px; + box-shadow: 0px 5px 10px 0px #cccccc; + height: 5em; +} + +.egifter-logo { + display: block; + max-height: 100%; + width: 100%; + height: 4em; } diff --git a/src/sass/views/review.scss b/src/sass/views/review.scss index 44b634697..79bca1896 100644 --- a/src/sass/views/review.scss +++ b/src/sass/views/review.scss @@ -11,7 +11,7 @@ bottom: 92px; } - .shapeshift-banner, .bitpay-banner { + .shapeshift-banner, .bitpay-banner, .egifter-banner { box-shadow: none; } diff --git a/www/css/bitcoin.com.css b/www/css/bitcoin.com.css index 59e503ac7..0cb170440 100644 --- a/www/css/bitcoin.com.css +++ b/www/css/bitcoin.com.css @@ -314,6 +314,13 @@ div.slide-success__background.fill-screen { height: 5em; } +.shapeshift-logo { + display: block; + float: left; + max-height: 100%; + max-width: 100%; +} + .bitpay-banner { background: #1A3A8B; padding: 10px; @@ -328,9 +335,16 @@ div.slide-success__background.fill-screen { height: 4em; } -.shapeshift-logo { - display: block; - float: left; - max-height: 100%; - max-width: 100%; +.egifter-banner { + background: #1A3A8B; + padding: 10px; + box-shadow: 0px 5px 10px 0px #cccccc; + height: 5em; +} + +.egifter-logo { + display: block; + max-height: 100%; + width: 100%; + height: 4em; } diff --git a/www/css/main.css b/www/css/main.css index 87333d1a6..350d5bbce 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -15262,8 +15262,10 @@ log-options #check-bar .checkbox-icon { #view-review .fee-summary { position: absolute; bottom: 92px; } - #view-review .shapeshift-banner, #view-review .bitpay-banner { + #view-review .shapeshift-banner, #view-review .bitpay-banner, #view-review .egifter-banner { box-shadow: none; } + #view-review .warning { + color: #b7664d; } .gravatar { border-radius: 3px; @@ -15410,7 +15412,7 @@ ion-content.padded-bottom-cta-with-summary { .fee-summary { position: relative; display: flex; - justify-content: space-between; + flex-direction: column; width: 100%; padding: 5px 12px 15px; box-sizing: border-box; @@ -15423,12 +15425,17 @@ ion-content.padded-bottom-cta-with-summary { width: 100%; height: 15px; background: linear-gradient(to bottom, rgba(242, 242, 242, 0) 0%, #f2f2f2 100%); } - .fee-summary .fee-fiat.positive { - color: #70955F; } - .fee-summary .fee-fiat.negative { - color: #C24633; } - .fee-summary .fee-crypto { - color: #A7A7A7; } + .fee-summary .amount { + display: flex; + flex-direction: row; + justify-content: space-between; + width: 100%; } + .fee-summary .amount .fee-fiat.positive { + color: #70955F; } + .fee-summary .amount .fee-fiat.negative { + color: #C24633; } + .fee-summary .amount .fee-crypto { + color: #A7A7A7; } .amount .start, .amount .middle, diff --git a/www/views/thirdparty/egifter-header.html b/www/views/thirdparty/egifter-header.html new file mode 100644 index 000000000..97d38603f --- /dev/null +++ b/www/views/thirdparty/egifter-header.html @@ -0,0 +1,3 @@ +
+ +
\ No newline at end of file diff --git a/www/views/walletSelector.html b/www/views/walletSelector.html index eeb7591a8..b375ddb8c 100644 --- a/www/views/walletSelector.html +++ b/www/views/walletSelector.html @@ -5,7 +5,8 @@
-
+
+
Paying
{{requestAmount}} {{requestCurrency}}
From 37614f08118cecc86dd5ff29c1b25b843da7d65a Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 7 Aug 2018 16:45:58 +0900 Subject: [PATCH 259/386] Change to svg for egifter --- www/views/thirdparty/egifter-header.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/views/thirdparty/egifter-header.html b/www/views/thirdparty/egifter-header.html index 97d38603f..a260e0726 100644 --- a/www/views/thirdparty/egifter-header.html +++ b/www/views/thirdparty/egifter-header.html @@ -1,3 +1,3 @@
- +
\ No newline at end of file From 83b1977a6f93922b9ee67730c1559fae6ed67b02 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 7 Aug 2018 09:47:37 +0200 Subject: [PATCH 260/386] Shapeshift controller useless functions removed --- src/js/services/shapeshiftService.js | 21 ++++----------------- 1 file changed, 4 insertions(+), 17 deletions(-) diff --git a/src/js/services/shapeshiftService.js b/src/js/services/shapeshiftService.js index b3e307667..329cadbb3 100644 --- a/src/js/services/shapeshiftService.js +++ b/src/js/services/shapeshiftService.js @@ -8,21 +8,6 @@ angular.module('copayApp.services').factory('shapeshiftService', function ($http root.returnAddress = ''; root.amount = ''; root.marketData = {}; - root.withdrawalAddress = function (address) { - root.withdrawalAddress = address; - }; - root.returnAddress = function (address) { - root.returnAddress = address; - }; - root.amount = function (amount) { - root.amount = amount; - }; - root.coinIn = function (coinIn) { - root.coinIn = coinIn.toUpperCase(); - }; - root.coinOut = function (coinOut) { - root.coinOut = coinOut.toUpperCase(); - }; root.getMarketDataIn = function (coin) { if (coin === root.coinOut) return root.getMarketData(root.coinOut, root.coinIn); @@ -66,8 +51,10 @@ angular.module('copayApp.services').factory('shapeshiftService', function ($http root.shiftIt = function (coinIn, coinOut, withdrawalAddress, returnAddress, cb) { ongoingProcess.set('connectingShapeshift', true); - root.withdrawalAddress(withdrawalAddress); - root.returnAddress(returnAddress); + root.withdrawalAddress = withdrawalAddress; + root.returnAddress = returnAddress; + root.coinIn = coinIn; + root.coinOut = coinOut; var validate = shapeshiftApiService.ValidateAddress(withdrawalAddress, coinOut); validate.then(function (valid) { var tx = ShapeShift(); From 485039223fa72ce6bde1f70a18cbfe405c135588 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 7 Aug 2018 17:37:23 +0900 Subject: [PATCH 261/386] egifter template --- app-template/bitcoincom/css/bitcoin.com.css | 6 +++--- www/css/bitcoin.com.css | 8 ++++---- www/img/egifter_banner.png | Bin 0 -> 9837 bytes www/img/icon-egifter.png | Bin 0 -> 8025 bytes www/views/review.html | 6 ++++-- www/views/thirdparty/egifter-header.html | 2 +- 6 files changed, 12 insertions(+), 10 deletions(-) create mode 100644 www/img/egifter_banner.png create mode 100644 www/img/icon-egifter.png diff --git a/app-template/bitcoincom/css/bitcoin.com.css b/app-template/bitcoincom/css/bitcoin.com.css index 793276e25..cb20ff48d 100644 --- a/app-template/bitcoincom/css/bitcoin.com.css +++ b/app-template/bitcoincom/css/bitcoin.com.css @@ -289,12 +289,12 @@ div.onboarding-topic { background: #1A3A8B; padding: 10px; box-shadow: 0px 5px 10px 0px #cccccc; - height: 5em; + height: 5em; + text-align: center; } .egifter-logo { - display: block; max-height: 100%; - width: 100%; + max-width: 100%; height: 4em; } diff --git a/www/css/bitcoin.com.css b/www/css/bitcoin.com.css index 0cb170440..f0d7eab30 100644 --- a/www/css/bitcoin.com.css +++ b/www/css/bitcoin.com.css @@ -336,15 +336,15 @@ div.slide-success__background.fill-screen { } .egifter-banner { - background: #1A3A8B; + background: #066EAA; padding: 10px; box-shadow: 0px 5px 10px 0px #cccccc; - height: 5em; + height: 5em; + text-align: center; } .egifter-logo { - display: block; max-height: 100%; - width: 100%; + max-width: 100%; height: 4em; } diff --git a/www/img/egifter_banner.png b/www/img/egifter_banner.png new file mode 100644 index 0000000000000000000000000000000000000000..cb2e7c11e4a793788a9420258fae00c48b5c0f91 GIT binary patch literal 9837 zcmYLPcRbtQ*GJQowkl}VrWCb05PQ}tYE?z-po+vOirURrhpo$~+0s&C6MI(ey%N<5 zwFzRy9#5>_^ABF1d)#yG8TX#^J|{#^N1gg2^F=Z;GHQ(nDv!v>D4?XjcPW9SpCzvI zXwol$oszZ^8CgNpr9G?jWMsTIHB^)yzaU>sT8#f&mZj!3-MT-zD%J4#0cxbAMv?AA zY~aIaTPh2NA+9BzY3$(@=>x)O8c(9-A-nL}=S$?2iewa^mt+7qrQ-;!So|>$reF|)cSdcD^>N2Lyj-p{@e>7FxRo4?iZst3v4e^`f>hI{PpVIxOyS!phs8Aubjxi zsLkmZ1WwbRea%u(AJ-|!6@>FEymBlb=a@FLF!zq!xZ!B8W5@HlJAN8 zVOP}{(q#t>Vv;y7e|&B-3J8T24yNkDuK7hB&*4;il>>X@NFk&n{@??p*Js7DdQJb} zwf|)9@}Y8eJ(9)uL^Vi3B#0WL!BXTUgxknHUnh0KiHza^aDVSgj2Hd;U2{$sOI`j} zhZiR9Y$@M~^H`rH+DgN7_|yFbsaOYLXvYQ7_*e!xELYrD!hApeFI{OYaN*Qe5W21E zzVZwLM%#Qw-SLT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g;cZmlS;9qWUKKrTf(G~ z`P7i5=AeH5f1s1Agj9u!fsS0qdTcY#?RnX$OTVmxQ<#cFQD6TZ!L}#jOj7p1re>c} z|L?hJj& z|F<;{D7RiZMhtnThGk|_4VI??Mjm(INk_RGRwqu)P&+1%y19HZ071egqeYaT!cBOF_P?x}k iy|Wu~Olj$-NKz@BaWAaL>H} literal 0 HcmV?d00001 diff --git a/www/img/icon-egifter.png b/www/img/icon-egifter.png new file mode 100644 index 0000000000000000000000000000000000000000..42ebb25c5cf0aa23812f3380c950fdccb44f6326 GIT binary patch literal 8025 zcmV-fAEw}mP)lakCUw+F;fMP)}xmKw^EHC(nz;U~Lzz~d7`IHXzUo4lsDxD!MHdTK!cH|Uw7mx4&WV$4nQ#N@cRDqnhP@}*GNj1^5ml<)sb6wla$ z5Hxn>CR*q@N6jf-8xI>jy&}A%s_X}V?OHSF|E2;1eFFN&1y*iN_F573YR0fOUr<)| z_3vGA)N@E#W%>D_8A*?O3)3sY97s9-8f;!ey{+UwJ-n{e2YG{sIxqe~vzCpP ztE?-%0sh~-4h%pTNDmA%_bPaG!UadH=chW&n2;Gs(X!S0iDxkSr9kwix?K9z=pRVv zRjcyi%0=i~ohC!Agh@z{O_29K$GQ?_WEWIoD0Q%Ih6_Zhc5ytXY6vJIG(Xz3+MYGV z41YwEM+VPIo>iBMYNcM#%w>;Zwk)U%Fkka9@*IJQLDacvI1TUGoc=nxCk0webn-$W zJ@@rq+I&2lGV;r?vB)JH&4;Efh~)%_UjQoz0X$6Lvy_o&Mo-Q&O`Xd#a0!&?M z+i-KV%uQqJJ@sXi@`|cd^tgeWWL=^hL{SJ58DgRT8`XoR4v3|Yfa=nGRzWE(+H#y; z|NbBql&MJ8c0+*!Uo#rkxfzY?*@_0WYfJ%Vg*og#lS^OhJVjsaO$ULvoTIEtJY70g z0}xg|%jQoWS3?#}tK8%Yj89sO=s&ti(k)6MjDk!H%uAo$Kaj@vimny@wv#zD?bEGv zIIF;hU=#ru{^=JTNw1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seO#mCl>I*W0%H+}oh|q=gvg4|!Xm zYkozS;Tgjzd>0R(g+dTPq-&Ef6%Z!Jl+BG>Z6Mu8= zh4*iQS$JQpdWql}%O14KR+iSFn*Zko%#xF`WEoMOIN^{Uz4w`wxmI2}Z_)>lKyHTo zbjmgD_x_GPuLuqa?V}e_7+<>07!~>a#qHAKl8>>;Hdc-M9p5WpW_cQx;#!T8-r_)a z!l(^^I6VW}`zw%tL)Ez7(;ciU6(+bTC3EAp8PPA@Sea|%%I3$-GfQ%3p60G;*YrEi zut1i5p?xIvFp4OQAH!yh7WqLllSabA_IId`ZME^&+B1;#jbsXlFHIbO(&)DPg)rO+ z{?t=O?uCaSR?o)z)5_?M=?Nc5+JKoqr*!`0pY()V6D+?GMr}mbgrvZupwmyRy z)J~1R8t>4dR-54WRg=?%QSJ6SVbqRHPD(Pb*kl?f$=0bL&|QeXD)b*L>NzA!OD!h( zqoTyPJ!*UXeZOLa(RQ@nb4iUWN~C*WznlVA*H4?~r{_`-0xLcRl)$abvo}b!b zujZ;CjJ-8@2%DYM%vxa@0?+=T5KV@{R1>RB*X0>TMht)**pyobgZ8>cW_fe^+_(~5 zVCw|rsw0eRzxYqqTP5la_R0!b2g(J(QdPn2eW{Qw;5C)M bn$!LbT?UmdRe+dG00000NkvXXu0mjf^}=3S literal 0 HcmV?d00001 diff --git a/www/views/review.html b/www/views/review.html index 69c0c31f0..e9e5c6d7c 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -48,8 +48,10 @@

{{vm.destination.balanceAmount}} {{vm.destination.balanceCurrency}}

- + ng-if="vm.thirdParty && vm.thirdParty.id === 'bip70' + && (vm.thirdParty.name === 'BitPay' || vm.thirdParty.name === 'eGifter')"> + +

{{vm.destination.name}}

Payment expires: {{vm.remainingTimeStr}}

Payment request has expired

diff --git a/www/views/thirdparty/egifter-header.html b/www/views/thirdparty/egifter-header.html index a260e0726..97d38603f 100644 --- a/www/views/thirdparty/egifter-header.html +++ b/www/views/thirdparty/egifter-header.html @@ -1,3 +1,3 @@
- +
\ No newline at end of file From 9420b6372825ee6e01ae4af41c7dc3662cb23a23 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 7 Aug 2018 20:11:21 +0900 Subject: [PATCH 262/386] Fix shapeshift, remove the cancelTx. Remove the timer with the getStatus --- src/js/controllers/review.controller.js | 16 ++++++++++------ src/js/services/shapeshiftService.js | 24 +++++++++--------------- 2 files changed, 19 insertions(+), 21 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 919ac3542..62b5fa1b6 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -487,12 +487,16 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit return; } - $ionicLoading.hide(); - shapeshiftService.shiftIt(vm.originWallet.coin, toWallet.coin, withdrawalAddr, returnAddr, function onShiftIt(shapeshiftData) { - vm.memo = 'ShapeShift Order:\nhttps://www.shapeshift.io/#/status/' + shapeshiftData.orderId; - tx.toAddress = shapeshiftData.toAddress; - vm.destination.address = toAddress; - vm.destination.kind = 'shapeshift'; + shapeshiftService.shiftIt(vm.originWallet.coin, toWallet.coin, withdrawalAddr, returnAddr, function onShiftIt(err, shapeshiftData) { + if (err && err != null) { + $ionicLoading.hide(); + popupService.showAlert(gettextCatalog.getString('Shapeshift Error'), err.toString()); + } else { + vm.memo = 'ShapeShift Order:\nhttps://www.shapeshift.io/#/status/' + shapeshiftData.orderId; + tx.toAddress = shapeshiftData.toAddress; + vm.destination.address = toAddress; + vm.destination.kind = 'shapeshift'; + } }); }); }); diff --git a/src/js/services/shapeshiftService.js b/src/js/services/shapeshiftService.js index 329cadbb3..4a77d8db0 100644 --- a/src/js/services/shapeshiftService.js +++ b/src/js/services/shapeshiftService.js @@ -45,7 +45,7 @@ angular.module('copayApp.services').factory('shapeshiftService', function ($http }; function checkForError(data) { - if (data.error) return true; + if (data.err) return true; return false; } @@ -55,8 +55,7 @@ angular.module('copayApp.services').factory('shapeshiftService', function ($http root.returnAddress = returnAddress; root.coinIn = coinIn; root.coinOut = coinOut; - var validate = shapeshiftApiService.ValidateAddress(withdrawalAddress, coinOut); - validate.then(function (valid) { + shapeshiftApiService.ValidateAddress(withdrawalAddress, coinOut).then(function (valid) { var tx = ShapeShift(); var coin; console.log("Starting"); @@ -64,7 +63,7 @@ angular.module('copayApp.services').factory('shapeshiftService', function ($http console.log("Got txData", txData); if (txData['fixedTxData']) { txData = txData.fixedTxData; - if (checkForError(txData)) return; + if (checkForError(txData)) return cb(txData.err); //console.log(txData) var coinPair = txData.pair.split('_'); txData.depositType = coinPair[0].toUpperCase(); @@ -76,20 +75,17 @@ angular.module('copayApp.services').factory('shapeshiftService', function ($http root.txFixedPending = true; } else if (txData['normalTxData']) { - txData = txData.normalTxData; - if (checkForError(txData)) return; + if (checkForError(txData)) return cb(txData.err); coin = root.coins[txData.depositType.toUpperCase()].name.toLowerCase(); txData.depositQR = coin + ":" + txData.deposit; - } else if (txData['cancelTxData']) { - - if (checkForError(txData.cancelTxData)) return; + txData = txData.cancelTxData; + if (checkForError(txData)) return cb(txData.err); if (root.txFixedPending) { root.txFixedPending = false; } root.ShiftState = 'Shift'; - return; } root.depositInfo = txData; //console.log(root.marketData); @@ -101,8 +97,8 @@ angular.module('copayApp.services').factory('shapeshiftService', function ($http ongoingProcess.set('connectingShapeshift', false); root.ShiftState = 'Cancel'; - root.GetStatus(); - root.txInterval=$interval(root.GetStatus, 8000); + //root.GetStatus(); + //root.txInterval=$interval(root.GetStatus, 8000); var shapeshiftData = { coinIn: coinIn, @@ -118,14 +114,12 @@ angular.module('copayApp.services').factory('shapeshiftService', function ($http ongoingProcess.set('connectingShapeshift', false); // return; // } - cb(shapeshiftData); - + cb(null, shapeshiftData); }); }) }; function ShapeShift() { - if (root.ShiftState === 'Cancel') return shapeshiftApiService.CancelTx(root); if (parseFloat(root.amount) > 0) return shapeshiftApiService.FixedAmountTx(root); return shapeshiftApiService.NormalTx(root); } From af90c53e502759a1432360338082f1d77fd0d432 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 7 Aug 2018 20:14:48 +0900 Subject: [PATCH 263/386] Add memo expended --- src/js/controllers/review.controller.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 62b5fa1b6..bb160b3d1 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -492,6 +492,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit $ionicLoading.hide(); popupService.showAlert(gettextCatalog.getString('Shapeshift Error'), err.toString()); } else { + vm.memoExpanded = !!vm.memo; vm.memo = 'ShapeShift Order:\nhttps://www.shapeshift.io/#/status/' + shapeshiftData.orderId; tx.toAddress = shapeshiftData.toAddress; vm.destination.address = toAddress; From 07ac4e77387dedf63b871bc3b65eae82ad5ad441 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 7 Aug 2018 20:50:56 +0900 Subject: [PATCH 264/386] Show memo for shapeshift --- src/js/controllers/review.controller.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index bb160b3d1..9004ce585 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -492,8 +492,8 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit $ionicLoading.hide(); popupService.showAlert(gettextCatalog.getString('Shapeshift Error'), err.toString()); } else { - vm.memoExpanded = !!vm.memo; vm.memo = 'ShapeShift Order:\nhttps://www.shapeshift.io/#/status/' + shapeshiftData.orderId; + vm.memoExpanded = !!vm.memo; tx.toAddress = shapeshiftData.toAddress; vm.destination.address = toAddress; vm.destination.kind = 'shapeshift'; From 9f418583abd989dfbc98452cbdc46cfb036e1494 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 7 Aug 2018 16:11:47 +0200 Subject: [PATCH 265/386] formatted amount controller update + css + renames + included in views --- src/js/directives/formattedAmount.js | 29 +++++++++++++------ src/sass/components/components.scss | 2 +- .../{amount.scss => formatted-amount.scss} | 4 ++- www/views/amount.html | 12 ++++---- www/views/includes/formatted-amount.html | 2 +- www/views/includes/walletHistory.html | 5 ++-- www/views/includes/walletList.html | 8 +++-- www/views/tx-details.html | 8 ++--- www/views/walletDetails.html | 27 ++++++++--------- 9 files changed, 58 insertions(+), 39 deletions(-) rename src/sass/components/{amount.scss => formatted-amount.scss} (89%) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index ac74afd2b..3c787521a 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -15,16 +15,27 @@ angular.module('bitcoincom.directives') return { restrict: 'E', scope: { - value: '=', - currency: '=', - sizeEqual: '=' + value: '@', + currency: '@', + sizeEqual: '@' }, templateUrl: 'views/includes/formatted-amount.html', controller: function($scope, $timeout) { + if (!$scope.currency && $scope.value) { // If there is no currency available.. + // Try to extract currency from value.. + var currencySplit = $scope.value.split(" "); + if (currencySplit.length === 2) { + $scope.value = currencySplit[0]; + $scope.currency = currencySplit[1]; + } + } + $scope.displaySizeEqual = !!$scope.sizeEqual; configService.whenAvailable(function(config) { + console.log("WAIT!!"); $timeout(function() { + console.log("FIRED!!"); var decimalPlaces = { '0': ['BIF', 'CLP', 'DJF', 'GNF', 'ILS', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'UGX', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'], '3': ['BHD', 'IQD', 'JOD', 'KWD', 'OMR', 'TND'], @@ -44,9 +55,9 @@ angular.module('bitcoincom.directives') }; var getDecimalPlaces = function(currency) { - if (decimalPlaces['0'].indexOf($scope.currency.toUpperCase()) > -1) return '0'; - if (decimalPlaces['3'].indexOf($scope.currency.toUpperCase()) > -1) return '3'; - if (decimalPlaces['8'].indexOf($scope.currency.toUpperCase()) > -1) return '8'; + if (decimalPlaces['0'].indexOf(currency.toUpperCase()) > -1) return '0'; + if (decimalPlaces['3'].indexOf(currency.toUpperCase()) > -1) return '3'; + if (decimalPlaces['8'].indexOf(currency.toUpperCase()) > -1) return '8'; return '2'; }; @@ -59,7 +70,7 @@ angular.module('bitcoincom.directives') case '3': var valueProcessing = parseFloat(parseFloat(value).toFixed(3)); - var valueFormatted = localizeNumbers(valueProcessing); + var valueFormatted = localizeNumbers(valueProcessing, 3); buildAmount(valueFormatted, '', ''); break; @@ -78,11 +89,11 @@ angular.module('bitcoincom.directives') default: var valueProcessing = parseFloat(parseFloat(value).toFixed(2)); - var valueFormatted = localizeNumbers(valueProcessing); + var valueFormatted = localizeNumbers(valueProcessing, 2); buildAmount(valueFormatted, '', ''); break; } - } + }; formatNumbers($scope.currency, $scope.value); $scope.$watchGroup(['currency', 'value'], function() { diff --git a/src/sass/components/components.scss b/src/sass/components/components.scss index 0af55e5be..fb53508b0 100644 --- a/src/sass/components/components.scss +++ b/src/sass/components/components.scss @@ -8,4 +8,4 @@ @import "action-minor"; @import "expand-content"; @import "fee-summary"; -@import "amount.scss"; +@import "formatted-amount"; diff --git a/src/sass/components/amount.scss b/src/sass/components/formatted-amount.scss similarity index 89% rename from src/sass/components/amount.scss rename to src/sass/components/formatted-amount.scss index 363d38a20..6678572c9 100644 --- a/src/sass/components/amount.scss +++ b/src/sass/components/formatted-amount.scss @@ -1,4 +1,6 @@ -.amount { +.formatted-amount { + display: inline-block; + .start, .middle, .end, diff --git a/www/views/amount.html b/www/views/amount.html index 48637ec1b..ee969762a 100644 --- a/www/views/amount.html +++ b/www/views/amount.html @@ -16,11 +16,13 @@
- {{vm.amount || '0'}} {{vm.unit}} + + +
- {{vm.globalResult}} {{vm.unit}} +
- {{vm.alternativeAmount || '0.00'}} {{vm.alternativeUnit}} +
@@ -43,7 +45,7 @@
- Available Funds:{{vm.availableFunds}} + Available Funds:
@@ -53,7 +55,7 @@
diff --git a/www/views/includes/formatted-amount.html b/www/views/includes/formatted-amount.html index 361dededc..20063458d 100644 --- a/www/views/includes/formatted-amount.html +++ b/www/views/includes/formatted-amount.html @@ -1,4 +1,4 @@ -
{{start}}{{middle}}{{end}}{{currency}}
\ No newline at end of file diff --git a/www/views/includes/walletHistory.html b/www/views/includes/walletHistory.html index 4a40e93d8..296b35b1a 100644 --- a/www/views/includes/walletHistory.html +++ b/www/views/includes/walletHistory.html @@ -64,17 +64,16 @@ - (possible double spend) - {{btx.amountValueStr}} {{btx.amountUnitStr}} +
- {{btx.alternativeAmountStr}} +
diff --git a/www/views/includes/walletList.html b/www/views/includes/walletList.html index f7a061740..d5fb65302 100644 --- a/www/views/includes/walletList.html +++ b/www/views/includes/walletList.html @@ -7,8 +7,12 @@ Incomplete - {{wallet.status.totalBalanceStr ? wallet.status.totalBalanceStr : ( wallet.cachedBalance ? wallet.cachedBalance + (wallet.cachedBalanceUpdatedOn ? ' · ' + ( wallet.cachedBalanceUpdatedOn * 1000 | amTimeAgo) : '') : '' ) }} - {{wallet.status.totalBalanceAlternative ? wallet.status.totalBalanceAlternative : ( wallet.cachedBalance ? wallet.cachedBalance + (wallet.cachedBalanceUpdatedOn ? ' · ' + ( wallet.cachedBalanceUpdatedOn * 1000 | amTimeAgo) : '') : '' ) }} {{wallet.status.alternativeIsoCode}} + + + + + + Scanning funds... [Balance Hidden] diff --git a/www/views/tx-details.html b/www/views/tx-details.html index e3a7a06b4..467ce28e3 100644 --- a/www/views/tx-details.html +++ b/www/views/tx-details.html @@ -24,13 +24,13 @@ Receiving
-
{{btx.amountValueStr}} {{btx.amountUnitStr}}
+
- {{btx.alternativeAmountStr}} + ... - {{rate| currency:'':2}} {{alternativeIsoCode}} ({{rateDate | amDateFormat:'MM/DD/YYYY HH:mm a'}}) + ({{rateDate | amDateFormat:'MM/DD/YYYY HH:mm a'}})
@@ -115,7 +115,7 @@ Fee {{btx.feeStr || '...'}} - {{btx.feeFiatStr || '...'}} - {{btx.feeRateStr}} of the transaction + ...- {{btx.feeRateStr}} of the transaction
diff --git a/www/views/walletDetails.html b/www/views/walletDetails.html index 0f9e4961c..12506e05d 100644 --- a/www/views/walletDetails.html +++ b/www/views/walletDetails.html @@ -34,12 +34,12 @@ on-hold="hideToggle()" ng-style="{'transform': amountScale}" ng-class="{amount__balance: amountIsCollapsible}"> - {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}} +
- {{status.totalBalanceStr}} +
@@ -47,13 +47,14 @@ ng-show="selectedPriceDisplay=='crypto' && !updateStatusError && !wallet.balanceHidden && !wallet.scanning" on-hold="hideToggle()" ng-style="{'transform': amountScale}" + ng-if="status.totalBalanceStr" ng-class="{amount__balance: amountIsCollapsible}"> - {{status.totalBalanceStr}} +
- {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}} +
@@ -86,7 +87,7 @@   - {{status.spendableBalanceAlternative}} {{status.alternativeIsoCode}} +
@@ -127,12 +128,12 @@ on-hold="hideToggle()" ng-style="{'transform': amountScale}" ng-class="{amount__balance: amountIsCollapsible}"> - {{status.totalBalanceStr}} +
- {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}} +
@@ -142,12 +143,12 @@ on-hold="hideToggle()" ng-style="{'transform': amountScale}" ng-class="{amount__balance: amountIsCollapsible}"> - {{status.totalBalanceAlternative}} {{status.alternativeIsoCode}} +
- {{status.totalBalanceStr}} +
@@ -180,7 +181,7 @@   - {{status.spendableBalanceAlternative}} {{status.alternativeIsoCode}} +
@@ -189,7 +190,7 @@
@@ -95,8 +95,8 @@ {{wallet.name || wallet.id}}

- {{wallet.status.totalBalanceAlternative}} {{wallet.status.alternativeIsoCode}} - {{wallet.status.totalBalanceStr}} + + [Balance Hidden] From 29a5a37c0274e8d81f011f9060c0981a6e875d11 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 8 Aug 2018 12:24:13 +1200 Subject: [PATCH 267/386] Formatter displays blank amount when value is NaN. --- src/js/directives/formattedAmount.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index 3c787521a..e223a8fd5 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -62,6 +62,11 @@ angular.module('bitcoincom.directives') }; var formatNumbers = function(currency, value) { + if (isNaN(parseFloat($scope.value))) { + buildAmount('', '', ''); + return; + } + switch (getDecimalPlaces(currency)) { case '0': var valueFormatted = localizeNumbers(Math.round(parseFloat(value))); From 12aa9a3b18f51937b890f6801376d1a7da1cf269 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 8 Aug 2018 13:28:44 +1200 Subject: [PATCH 268/386] formatted-amount displays "-.--" when it does not have a value. --- src/js/directives/formattedAmount.js | 56 +++++++++++++++++++--------- 1 file changed, 39 insertions(+), 17 deletions(-) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index e223a8fd5..ccf6c1963 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -60,46 +60,68 @@ angular.module('bitcoincom.directives') if (decimalPlaces['8'].indexOf(currency.toUpperCase()) > -1) return '8'; return '2'; }; + + var getDecimalSeparator = function() { + var testNum = 1.5; + var testString = testNum.toLocaleString(uxLanguage.getCurrentLanguage()); + // Some environments let you set decimal separators that are more than one character + var separator = /^1(.+)5$/.exec(testString)[1] + return separator; + }; var formatNumbers = function(currency, value) { - if (isNaN(parseFloat($scope.value))) { - buildAmount('', '', ''); - return; - } + var parsed = parseFloat(value); + var valueFormatted = ''; + var valueProcessing = ''; switch (getDecimalPlaces(currency)) { case '0': - var valueFormatted = localizeNumbers(Math.round(parseFloat(value))); - buildAmount(valueFormatted, '', ''); + if (isNaN(parsed)) { + buildAmount('-', '', ''); + } else { + valueFormatted = localizeNumbers(Math.round(parsed)); + buildAmount(valueFormatted, '', ''); + } break; case '3': - var valueProcessing = parseFloat(parseFloat(value).toFixed(3)); - var valueFormatted = localizeNumbers(valueProcessing, 3); - buildAmount(valueFormatted, '', ''); + if (isNaN(parsed)) { + buildAmount('-' + getDecimalSeparator() + '---', '', ''); + } else { + valueProcessing = parsed.toFixed(3); + valueFormatted = localizeNumbers(valueProcessing, 3); + buildAmount(valueFormatted, '', ''); + } break; case '8': - var valueFormatted = parseFloat(value).toFixed(8); - if (parseFloat(value) == 0) { + if (isNaN(parsed)) { + buildAmount('-' + getDecimalSeparator() + '---', '', ''); + } else if (parsed === 0) { buildAmount('0', '', ''); } else { - var valueFormatted = localizeNumbers(valueFormatted, 8); + valueFormatted = parsed.toFixed(8); + valueFormatted = localizeNumbers(valueFormatted, 8); var start = valueFormatted.slice(0, -5); var middle = valueFormatted.slice(-5, -2); var end = valueFormatted.substr(valueFormatted.length - 2); buildAmount(start, middle, end); + } break; - default: - var valueProcessing = parseFloat(parseFloat(value).toFixed(2)); - var valueFormatted = localizeNumbers(valueProcessing, 2); - buildAmount(valueFormatted, '', ''); + default: // 2 + if (isNaN(parsed)) { + buildAmount('-' + getDecimalSeparator() + '--', '', ''); + } else { + valueProcessing = parseFloat(parsed.toFixed(2)); + valueFormatted = localizeNumbers(valueProcessing, 2); + buildAmount(valueFormatted, '', ''); + } break; } }; - + formatNumbers($scope.currency, $scope.value); $scope.$watchGroup(['currency', 'value'], function() { formatNumbers($scope.currency, $scope.value); From 820c1a393358900820dd7f21d4d355177687a900 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 8 Aug 2018 13:31:02 +1200 Subject: [PATCH 269/386] Wallet details does not display any balance text if it does not have balance yet. --- www/views/walletDetails.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/www/views/walletDetails.html b/www/views/walletDetails.html index 12506e05d..1ebc5929f 100644 --- a/www/views/walletDetails.html +++ b/www/views/walletDetails.html @@ -30,7 +30,7 @@

@@ -44,7 +44,7 @@
Date: Wed, 8 Aug 2018 13:38:43 +1200 Subject: [PATCH 270/386] More selective display of balances Wallet Details screen when fiat balance isn't available. --- www/views/walletDetails.html | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/www/views/walletDetails.html b/www/views/walletDetails.html index 1ebc5929f..74ac4da7b 100644 --- a/www/views/walletDetails.html +++ b/www/views/walletDetails.html @@ -30,11 +30,13 @@
- + + +
- + + +
Date: Wed, 8 Aug 2018 15:36:18 +1200 Subject: [PATCH 271/386] ShapeshiftService fix for app startup. --- src/js/services/shapeshiftService.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/js/services/shapeshiftService.js b/src/js/services/shapeshiftService.js index 5396f4fa5..1ce9672ce 100644 --- a/src/js/services/shapeshiftService.js +++ b/src/js/services/shapeshiftService.js @@ -136,4 +136,6 @@ angular.module('copayApp.services').factory('shapeshiftService', function ($http } }); }; + + return root; }); From 5d3e11b7bbb0a48f1ecd3eae76ecf1b7ffabd22c Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 8 Aug 2018 16:10:58 +1200 Subject: [PATCH 272/386] Fixed alignment of buttons in Wallet Details on wide screens.. --- src/sass/views/walletDetails.scss | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/sass/views/walletDetails.scss b/src/sass/views/walletDetails.scss index 6b760bbc4..0843a1c07 100644 --- a/src/sass/views/walletDetails.scss +++ b/src/sass/views/walletDetails.scss @@ -193,7 +193,10 @@ } .send-receive-buttons { - max-width: 600px; + display: flex; + flex-direction: row; + justify-content: space-evenly; + width: 100%; position: absolute; bottom: 20px; @@ -207,6 +210,7 @@ padding: 0 15px 0 15px; text-align: center; width: 100%; + max-width: 300px; font-size: 19px; font-weight: bolder; min-height: auto; From 939263c3856a8fbeb8d2aa4183350ec4f70baa61 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 8 Aug 2018 16:30:57 +1200 Subject: [PATCH 273/386] Alignment and size of Receive and Send buttons on the Home tab matches the Wallet Details tab: equal spacing. --- src/sass/views/tab-home.scss | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/sass/views/tab-home.scss b/src/sass/views/tab-home.scss index 708ff4fad..55080ab7b 100644 --- a/src/sass/views/tab-home.scss +++ b/src/sass/views/tab-home.scss @@ -70,8 +70,12 @@ } } .buttons { + display: flex; + flex-direction: row; + justify-content: space-evenly; margin: 6px auto -12px; - max-width: 600px; + text-align: center; + width: 100%; >.col { padding: 5px 10px; margin-bottom: 0; @@ -82,6 +86,7 @@ padding: 0 15px 0 15px; text-align: center; width: 100%; + max-width: 300px; font-size: 19px; font-weight: bolder; min-height: auto; From fcb4d4b004e4ccede6874b9dd088f332ac4d1e69 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 8 Aug 2018 18:22:43 +1200 Subject: [PATCH 274/386] Text is now visible on Send and Receive buttons in Wallet Details screen when activated. --- src/sass/views/walletDetails.scss | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/sass/views/walletDetails.scss b/src/sass/views/walletDetails.scss index 0843a1c07..79326951e 100644 --- a/src/sass/views/walletDetails.scss +++ b/src/sass/views/walletDetails.scss @@ -261,6 +261,12 @@ .no-alternative { padding-top: 45px; } + + .button-white-outline.button-outline.activated { + color: $v-primary-color; + border-color: white; + } + .item.item-footer { font-weight: lighter; } From 6981a5af9fd44bc72f5ff7306b58aa5238cca14e Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Wed, 8 Aug 2018 15:52:20 +0900 Subject: [PATCH 275/386] show only when it is ready --- src/js/directives/formattedAmount.js | 3 +++ www/views/includes/formatted-amount.html | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index ccf6c1963..b990596c4 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -21,6 +21,8 @@ angular.module('bitcoincom.directives') }, templateUrl: 'views/includes/formatted-amount.html', controller: function($scope, $timeout) { + $scope.canShow = false; + if (!$scope.currency && $scope.value) { // If there is no currency available.. // Try to extract currency from value.. var currencySplit = $scope.value.split(" "); @@ -120,6 +122,7 @@ angular.module('bitcoincom.directives') } break; } + $scope.canShow = true; }; formatNumbers($scope.currency, $scope.value); diff --git a/www/views/includes/formatted-amount.html b/www/views/includes/formatted-amount.html index 20063458d..24149849d 100644 --- a/www/views/includes/formatted-amount.html +++ b/www/views/includes/formatted-amount.html @@ -1,4 +1,4 @@
+ ng-class="{ 'size-equal': displaySizeEqual }" ng-show="canShow"> {{start}}{{middle}}{{end}}{{currency}}
\ No newline at end of file From 3d9b24575b44de7912fc9dd110f5d35a2024f057 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 8 Aug 2018 18:57:55 +1200 Subject: [PATCH 276/386] In Review Transaction screen, the note is now visible above the fees. --- src/sass/views/review.scss | 4 ++++ www/views/review.html | 1 + 2 files changed, 5 insertions(+) diff --git a/src/sass/views/review.scss b/src/sass/views/review.scss index 79bca1896..110090ebc 100644 --- a/src/sass/views/review.scss +++ b/src/sass/views/review.scss @@ -11,6 +11,10 @@ bottom: 92px; } + .fee-summary-spacer { + height: 15px; + } + .shapeshift-banner, .bitpay-banner, .egifter-banner { box-shadow: none; } diff --git a/www/views/review.html b/www/views/review.html index e9e5c6d7c..8444142d1 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -80,6 +80,7 @@
+
From ae6dcea81a378613a7fefc7439ccf8a2f71eadb1 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 8 Aug 2018 18:58:26 +1200 Subject: [PATCH 277/386] Fix for getting Shapeshift working. --- src/js/services/shapeshiftService.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/js/services/shapeshiftService.js b/src/js/services/shapeshiftService.js index 5396f4fa5..1ce9672ce 100644 --- a/src/js/services/shapeshiftService.js +++ b/src/js/services/shapeshiftService.js @@ -136,4 +136,6 @@ angular.module('copayApp.services').factory('shapeshiftService', function ($http } }); }; + + return root; }); From ab13478f799af7f763233bcd4ca3a8b28c7a3a6a Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Wed, 8 Aug 2018 16:03:34 +0900 Subject: [PATCH 278/386] Add shapeshift service item --- src/js/services/shapeshiftService.js | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/js/services/shapeshiftService.js b/src/js/services/shapeshiftService.js index 1ce9672ce..7cf6b4e03 100644 --- a/src/js/services/shapeshiftService.js +++ b/src/js/services/shapeshiftService.js @@ -137,5 +137,17 @@ angular.module('copayApp.services').factory('shapeshiftService', function ($http }); }; + var servicesItem = { + name: 'shapeshift', + title: 'Shapeshift', + icon: 'icon-shapeshift', + sref: 'tabs.shapeshift', + }; + + var register = function() { + servicesService.register(servicesItem); + }; + + register(); return root; }); From 644b3e6113b3d67bded857339cd4a0b8e2d61572 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Wed, 8 Aug 2018 16:24:47 +0900 Subject: [PATCH 279/386] height space in the bottom (wallet selection & review) --- src/sass/shame.scss | 4 + src/sass/views/review.scss | 4 - www/css/main.css | 174 ++++++++++++++++++++++++++++------ www/views/review.html | 2 +- www/views/walletSelector.html | 1 + 5 files changed, 153 insertions(+), 32 deletions(-) diff --git a/src/sass/shame.scss b/src/sass/shame.scss index 5a17c5f1f..dbbc222d7 100644 --- a/src/sass/shame.scss +++ b/src/sass/shame.scss @@ -468,3 +468,7 @@ input[type=file] { .white-space-initial { white-space: initial; } + +.height-spacer { + height: 15px; +} diff --git a/src/sass/views/review.scss b/src/sass/views/review.scss index 110090ebc..79bca1896 100644 --- a/src/sass/views/review.scss +++ b/src/sass/views/review.scss @@ -11,10 +11,6 @@ bottom: 92px; } - .fee-summary-spacer { - height: 15px; - } - .shapeshift-banner, .bitpay-banner, .egifter-banner { box-shadow: none; } diff --git a/www/css/main.css b/www/css/main.css index 350d5bbce..9845340ae 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -10253,6 +10253,46 @@ ion-view.deflash-blue:before, ion-view#view-amount:before, ion-view#view-confirm color: #fff; } .button-white.activated { color: #FFF; } + .button-white-outline { + border-color: #FFFFFF; + background-color: transparent; + color: #FFFFFF; + background: none; + box-shadow: none; } + .button-white-outline:hover { + color: #FFFFFF; + text-decoration: none; } + .button-white-outline.active, .button-white-outline.activated { + border-color: #FFF; + background-color: #FAFAFA; } + .button-white-outline.button-outline { + border-color: #FFFFFF; + background: transparent; + color: #FFFFFF; } + .button-white-outline.button-outline.active, .button-white-outline.button-outline.activated { + background-color: #FFFFFF; + box-shadow: none; + color: #fff; } + .button-grey-outline { + border-color: #727272; + background-color: transparent; + color: #727272; + background: none; + box-shadow: none; } + .button-grey-outline:hover { + color: #727272; + text-decoration: none; } + .button-grey-outline.active, .button-grey-outline.activated { + border-color: #727272; + background-color: #FAFAFA; } + .button-grey-outline.button-outline { + border-color: #727272; + background: transparent; + color: #727272; } + .button-grey-outline.button-outline.active, .button-grey-outline.button-outline.activated { + background-color: #727272; + box-shadow: none; + color: #fff; } .button-clear { background: none !important; } @@ -10271,8 +10311,8 @@ qrcode { content: ""; background-size: 100% 100%; display: block; - left: 88px; - margin-top: 88px; + left: calc(50% - 22px); + margin-top: calc(50% - 22px); width: 44px; height: 44px; position: absolute; } @@ -10886,6 +10926,28 @@ qrcode { width: 100%; display: block; } +#tab-home .buttons { + display: flex; + flex-direction: row; + justify-content: space-evenly; + margin: 6px auto -12px; + text-align: center; + width: 100%; } + #tab-home .buttons > .col { + padding: 5px 10px; + margin-bottom: 0; } + #tab-home .buttons .button { + border: 2px solid; + border-radius: 47px; + padding: 0 15px 0 15px; + text-align: center; + width: 100%; + max-width: 300px; + font-size: 19px; + font-weight: bolder; + min-height: auto; + line-height: 36px; } + #tab-home .wallet-coin-logo { vertical-align: middle; margin-right: 5px; } @@ -11871,10 +11933,11 @@ qrcode { height: 100%; height: calc(100% - env(safe-area-inset-bottom) * 2); } #walletDetails .bp-content.status-bar { - margin-top: 20px; } + margin-top: 20px; + margin-top: env(safe-area-inset-top); } #walletDetails .bar-header { border: 0; - background: none; } + background: #eeb640; } #walletDetails .bar-header .title, #walletDetails .bar-header .button { color: #fff; } #walletDetails .bar-header .button { @@ -11886,7 +11949,7 @@ qrcode { top: 0; margin-bottom: 16px; } #walletDetails ion-content.collapsible { - margin-top: 210px; } + margin-top: 230px; } #walletDetails ion-content .scroll { background: #f8f8f9; min-height: 300px; } @@ -11911,11 +11974,32 @@ qrcode { height: 200px; -webkit-transform: translateY(100px); transform: translateY(100px); } + #walletDetails .amount-wrapper .send-receive-buttons { + display: flex; + flex-direction: row; + justify-content: space-evenly; + width: 100%; + position: absolute; + bottom: 20px; } + #walletDetails .amount-wrapper .send-receive-buttons > .col { + padding: 5px 10px; + margin-bottom: 0; } + #walletDetails .amount-wrapper .send-receive-buttons .button { + border: 2px solid; + border-radius: 47px; + padding: 0 15px 0 15px; + text-align: center; + width: 100%; + max-width: 300px; + font-size: 19px; + font-weight: bolder; + min-height: auto; + line-height: 36px; } #walletDetails .amount { width: 100%; text-align: center; color: #fff; - height: 210px; + height: 230px; padding-top: 40px; display: block; align-items: center; @@ -13975,11 +14059,6 @@ slide-to-accept-success { display: flex; align-items: center; justify-content: center; } - slide-to-accept-success .slide-success__windows-background { - background: #11D1A6; - height: 100%; - width: 100%; - position: fixed; } slide-to-accept-success .slide-success__background { height: 10vmax; width: 10vmax; @@ -13996,8 +14075,10 @@ slide-to-accept-success { slide-to-accept-success .slide-success__content { position: relative; z-index: 1; - margin-top: -20vh; } + margin-top: -10vh; } slide-to-accept-success .slide-success__content > img { + width: 45vw; + max-width: 166px; margin-bottom: 1.8rem; -webkit-transform: translateY(5rem); transform: translateY(5rem); @@ -14010,7 +14091,7 @@ slide-to-accept-success { opacity: 1; } slide-to-accept-success .slide-success__content__header { color: #FFFFFF; - font-size: 26px; + font-size: 29px; -webkit-transform: translateY(5rem); transform: translateY(5rem); opacity: 0; @@ -14020,6 +14101,22 @@ slide-to-accept-success { -webkit-transform: translateY(0); transform: translateY(0); opacity: 1; } + slide-to-accept-success .slide-success__content__share { + transition: transform 400ms ease, opacity 400ms ease; + transition-delay: 600ms; + opacity: 0; + margin-top: 15vh; } + slide-to-accept-success .slide-success__content__share span { + color: #FFF; + font-size: 22px; + height: 28px; } + slide-to-accept-success .slide-success__content__share img { + height: 28px; + width: auto; + vertical-align: bottom; + margin-right: 4px; } + slide-to-accept-success .slide-success__content__share.reveal { + opacity: 0.79; } slide-to-accept-success .slide-success__footer { position: absolute; left: 0; @@ -14042,11 +14139,11 @@ slide-to-accept-success { slide-to-accept-success .slide-success__footer__btn { display: block; color: #FFFFFF; - font-size: 18px; + font-size: 22px; font-weight: 600; letter-spacing: 2.86px; - padding: 1rem 0 1.1rem; - border-top: 1px solid rgba(255, 255, 255, 0.45); + padding: 2rem 0 2.1rem; + border-top: 1px solid rgba(255, 255, 255, 0.25); cursor: pointer; } #tx-details .action-created.action-accepted { @@ -14988,17 +15085,10 @@ account-selector { height: 100%; } #custom-amount .address .qr-code { text-align: center; - margin-top: 24vh; - margin-bottom: 7vh; } - @media (max-height: 800px) { - #custom-amount .address .qr-code { - margin-top: 18vh; } } - @media (max-height: 700px) { - #custom-amount .address .qr-code { - margin-top: 14vh; } } - @media (max-height: 600px) { - #custom-amount .address .qr-code { - margin-top: 8vh; } } + margin-top: 6px; } + #custom-amount .address .qr-code qrcode canvas { + height: 30vh; + max-height: 220px; } #custom-amount .address .info { position: absolute; width: 100%; @@ -15038,6 +15128,28 @@ account-selector { margin-left: 10px; } #custom-amount .address .address-types { text-align: center; } + #custom-amount .address .amount { + margin-top: 20vh; + margin-bottom: 4vh; + width: 100%; + text-align: center; + display: block; + align-items: center; + justify-content: center; } + @media (max-height: 800px) { + #custom-amount .address .amount { + margin-top: 12vh; + margin-bottom: 6vh; } } + @media (max-height: 700px) { + #custom-amount .address .amount { + margin-top: 10vh; + margin-bottom: 4vh; } } + @media (max-height: 600px) { + #custom-amount .address .amount { + margin-top: 6vh; + margin-bottom: 2vh; } } + #custom-amount .address .amount-alternative { + line-height: 36px; } #pin { background-color: #FAFAFA; @@ -15262,6 +15374,8 @@ log-options #check-bar .checkbox-icon { #view-review .fee-summary { position: absolute; bottom: 92px; } + #view-review .fee-summary-spacer { + height: 15px; } #view-review .shapeshift-banner, #view-review .bitpay-banner, #view-review .egifter-banner { box-shadow: none; } #view-review .warning { @@ -15644,6 +15758,9 @@ input[type=number]::-webkit-inner-spin-button, input[type=number]::-webkit-outer .size-24 { font-size: 24px; } +.size-25 { + font-size: 25px; } + .size-28 { font-size: 28px; } @@ -15818,3 +15935,6 @@ input[type=file] { .white-space-initial { white-space: initial; } + +.height-spacer { + height: 15px; } diff --git a/www/views/review.html b/www/views/review.html index 8444142d1..2349c315d 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -80,7 +80,7 @@
-
+
diff --git a/www/views/walletSelector.html b/www/views/walletSelector.html index b375ddb8c..2da97eadb 100644 --- a/www/views/walletSelector.html +++ b/www/views/walletSelector.html @@ -55,5 +55,6 @@
+
\ No newline at end of file From 60028c44bba14440c26c55a6f552ac71a1d88020 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Wed, 8 Aug 2018 16:59:00 +0900 Subject: [PATCH 280/386] remove the header for shapeshift in the amount view --- www/views/amount.html | 1 - 1 file changed, 1 deletion(-) diff --git a/www/views/amount.html b/www/views/amount.html index 48637ec1b..270dbb3fb 100644 --- a/www/views/amount.html +++ b/www/views/amount.html @@ -6,7 +6,6 @@ -
From 753d2aea69a2e1daed1e244a0abea2062778eb96 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 8 Aug 2018 15:31:36 +0200 Subject: [PATCH 284/386] remove bottom menu on wallet selector + remove swipe back feature on review screen --- www/views/review.html | 2 +- www/views/walletSelector.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/www/views/review.html b/www/views/review.html index 2349c315d..cb7f21fbc 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -1,4 +1,4 @@ - + {{'Review Transaction' | translate}} diff --git a/www/views/walletSelector.html b/www/views/walletSelector.html index 2da97eadb..2e4c4bc31 100644 --- a/www/views/walletSelector.html +++ b/www/views/walletSelector.html @@ -1,4 +1,4 @@ - + {{sendFlowTitle}} From 51921a1a1d4207013a9fa89bdc5340ab6e3bead4 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Wed, 8 Aug 2018 22:32:18 +0900 Subject: [PATCH 285/386] Fix shapeshift flow go back available --- src/js/controllers/shapeshift.js | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/shapeshift.js b/src/js/controllers/shapeshift.js index ade7afb5b..4bf3db764 100644 --- a/src/js/controllers/shapeshift.js +++ b/src/js/controllers/shapeshift.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('shapeshiftController', function($scope, $state, $interval, profileService, walletService, popupService, lodash, $ionicNavBarDelegate) { +angular.module('copayApp.controllers').controller('shapeshiftController', function($scope, $state, $timeout, $ionicHistory, profileService, walletService, popupService, lodash, $ionicNavBarDelegate) { var walletsBtc = []; var walletsBch = []; @@ -66,8 +66,14 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi var params = { thirdParty: JSON.stringify({id: 'shapeshift'}) }; + $state.go('tabs.home').then(function() { - $state.transitionTo('tabs.send.origin', params); + $ionicHistory.clearHistory(); + $state.go('tabs.send').then(function() { + $timeout(function () { + $state.transitionTo('tabs.send.origin', params); + }, 60); + }); }); } }); From 8229d51fdd4590ce932ae57d7bfbd23e57602a11 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 8 Aug 2018 16:35:49 +0200 Subject: [PATCH 286/386] sendflow service --- src/js/services/sendFlowService.js | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 src/js/services/sendFlowService.js diff --git a/src/js/services/sendFlowService.js b/src/js/services/sendFlowService.js new file mode 100644 index 000000000..d5c4df109 --- /dev/null +++ b/src/js/services/sendFlowService.js @@ -0,0 +1,24 @@ +'use strict'; + +angular.module('copayApp.services').factory('sendFlowService', function ($log) { + var vm = this; + + vm.amount = false; + vm.fromWalletId = false; + vm.thirdParty = false; + vm.sendMax = false; + vm.toAddress = false; + vm.toWalletId = false; + + vm.initialize = function() { + $log.debug("Reinitialize Send Flow variables"); + vm.amount = false; + vm.fromWalletId = false; + vm.thirdParty = false; + vm.sendMax = false; + vm.toAddress = false; + vm.toWalletId = false; + }; + + return vm; +}); \ No newline at end of file From f7ecdb2f2fee02c47b38c4c54fbadee711a9b9fa Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 8 Aug 2018 17:10:47 +0200 Subject: [PATCH 287/386] sendflow service integrated into flow --- src/js/controllers/amount.js | 69 ++++++++++--------- src/js/controllers/review.controller.js | 30 ++++---- src/js/controllers/tab-send.js | 2 +- src/js/controllers/walletDetails.js | 7 +- .../controllers/walletSelectorController.js | 12 ++-- src/js/services/incomingData.js | 6 +- src/js/services/sendFlowService.js | 7 ++ 7 files changed, 73 insertions(+), 60 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 8438260bc..68d4e869b 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -2,7 +2,7 @@ angular.module('copayApp.controllers').controller('amountController', amountController); -function amountController(configService, $filter, gettextCatalog, $ionicHistory, $ionicModal, $ionicScrollDelegate, lodash, $log, nodeWebkitService, rateService, $scope, $state, $timeout, shapeshiftService, txFormatService, platformInfo, profileService, walletService, $window) { +function amountController(configService, $filter, gettextCatalog, $ionicHistory, $ionicModal, $ionicScrollDelegate, lodash, $log, nodeWebkitService, rateService, $scope, $state, $timeout, sendFlowService, shapeshiftService, txFormatService, platformInfo, profileService, walletService, $window) { var vm = this; vm.allowSend = false; @@ -69,12 +69,12 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, initCurrencies(); - passthroughParams = data.stateParams; + passthroughParams = sendFlowService; - vm.fromWalletId = data.stateParams.fromWalletId; - vm.toWalletId = data.stateParams.toWalletId; - vm.minAmount = parseFloat(data.stateParams.minAmount); - vm.maxAmount = parseFloat(data.stateParams.maxAmount); + vm.fromWalletId = passthroughParams.fromWalletId; + vm.toWalletId = passthroughParams.toWalletId; + vm.minAmount = parseFloat(passthroughParams.minAmount); + vm.maxAmount = parseFloat(passthroughParams.maxAmount); if (passthroughParams.thirdParty) { vm.thirdParty = JSON.parse(passthroughParams.thirdParty); // Parse stringified JSON-object @@ -96,7 +96,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, } } - vm.isRequestingSpecificAmount = !data.stateParams.fromWalletId; + vm.isRequestingSpecificAmount = !passthroughParams.fromWalletId; var config = configService.getSync().wallet.settings; @@ -177,8 +177,8 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, // currency have preference var fiatName; - if (data.stateParams.currency) { - fiatCode = data.stateParams.currency; + if (passthroughParams.currency) { + fiatCode = passthroughParams.currency; altUnitIndex = unitIndex unitIndex = availableUnits.length; } else { @@ -205,8 +205,8 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, var fromWallet = profileService.getWallet(passthroughParams.fromWalletId); updateAvailableFundsFromWallet(fromWallet); } - }; - }; + } + } function goBack() { if (vm.thirdParty && vm.thirdParty.id === 'shapeshift') { @@ -227,18 +227,18 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, $timeout(function() { $scope.$apply(); }); - }; + } function processClipboard() { if (!isNW) return; var value = nodeWebkitService.readFromClipboard(); if (value && evaluate(value) > 0) paste(evaluate(value)); - }; + } function sendMax() { useSendMax = true; finish(); - }; + } function updateUnitUI() { vm.unit = availableUnits[unitIndex].shortName; @@ -246,7 +246,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, processAmount(); $log.debug('Update unit coin @amount unit:' + vm.unit + " alternativeUnit:" + vm.alternativeUnit); - }; + } function changeUnit() { @@ -267,7 +267,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, updateAvailableFundsStringIfNeeded(); updateUnitUI(); - }; + } function pushDigit(digit) { if (vm.amount && digit != '.') { @@ -291,7 +291,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, vm.amount = (vm.amount + digit).replace('..', '.'); processAmount(); - }; + } function pushOperator(operator) { if (!vm.amount || vm.amount.length == 0) return; @@ -303,18 +303,18 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, } else { return val.slice(0, -1) + operator; } - }; - }; + } + } function isOperator(val) { var regex = /[\/\-\+\x\*]/; return regex.test(val); - }; + } function isExpression(val) { var regex = /^\.?\d+(\.?\d+)?([\/\-\+\*x]\d?\.?\d+)+$/; return regex.test(val); - }; + } function removeDigit() { vm.amount = (vm.amount).toString().slice(0, -1); @@ -339,7 +339,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, function close() { altCurrencyModal.remove(); altCurrencyModal = null; - }; + } function processAmount() { var formatedValue = format(vm.amount); @@ -409,22 +409,22 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, } else { vm.errorMessage = ''; } - }; + } function processResult(val) { if (availableUnits[unitIndex].isFiat) return $filter('formatFiatAmount')(val); else return txFormatService.formatAmount(val.toFixed(unitDecimals) * unitToSatoshi, true); - }; + } function fromFiat(val) { return parseFloat((rateService.fromFiat(val, fiatCode, availableUnits[altUnitIndex].id) * satToUnit).toFixed(unitDecimals)); - }; + } function toFiat(val) { if (!rateService.getRate(fiatCode)) return; return parseFloat((rateService.toFiat(val * unitToSatoshi, fiatCode, availableUnits[unitIndex].id)).toFixed(2)); - }; + } function evaluate(val) { var result; @@ -435,7 +435,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, } if (!lodash.isFinite(result)) return 0; return result; - }; + } function format(val) { if (!val) return; @@ -445,7 +445,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, if (isOperator(lodash.last(val))) result = result.slice(0, -1); return result.replace('x', '*'); - }; + } function finish() { var unit = availableUnits[unitIndex]; @@ -467,16 +467,18 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, }; if (vm.thirdParty) { - confirmData['thirdParty'] = JSON.stringify(this.thirdParty); + confirmData['thirdParty'] = this.thirdParty; } + sendFlowService.map(confirmData); + if (!confirmData.fromWalletId) { $state.transitionTo('tabs.paymentRequest.confirm', confirmData); } else { $state.transitionTo('tabs.send.review', confirmData); $scope.useSendMax = null; } - }; + } // Currency @@ -495,7 +497,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, {isoCode: 'CNY', order: 7}, {isoCode: 'KRW', order: 8}, {isoCode: 'HKD', order: 9}, - ] + ]; function initCurrencies() { var unusedCurrencyList = [{ @@ -558,7 +560,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, $timeout(function() { $scope.$apply(); }); - }; + } function save(newAltCurrency) { var opts = { @@ -584,7 +586,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, updateUnitUI(); close(); }); - }; + } function updateAvailableFundsStringIfNeeded() { if (passthroughParams.fromWalletId && availableSatoshis !== null) { @@ -639,5 +641,4 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, vm.availableFunds = availableFundsInCrypto; } } - } diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index f565448ee..858e115c1 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,7 +4,7 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, configService, feeService, gettextCatalog, $interval, $ionicHistory, $ionicModal, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, shapeshiftService, soundService, $state, $timeout, txConfirmNotification, txFormatService, walletService) { +function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, configService, feeService, gettextCatalog, $interval, $ionicHistory, $ionicModal, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, sendFlowService, shapeshiftService, soundService, $state, $timeout, txConfirmNotification, txFormatService, walletService) { var vm = this; vm.buttonText = ''; @@ -51,7 +51,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit // Functions vm.onSuccessConfirm = onSuccessConfirm; - + var sendFlowData; var config = null; var countDown = null; var defaults = {}; @@ -75,17 +75,18 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit function onBeforeEnter(event, data) { defaults = configService.getDefaults(); - originWalletId = data.stateParams.fromWalletId; - satoshis = parseInt(data.stateParams.amount, 10); - toAddress = data.stateParams.toAddress; - destinationWalletId = data.stateParams.toWalletId; + sendFlowData = sendFlowService; + originWalletId = sendFlowData.fromWalletId; + satoshis = parseInt(sendFlowData.amount, 10); + toAddress = sendFlowData.toAddress; + destinationWalletId = sendFlowData.toWalletId; vm.originWallet = profileService.getWallet(originWalletId); vm.origin.currency = vm.originWallet.coin.toUpperCase(); coin = vm.originWallet.coin; - if (data.stateParams.thirdParty) { - vm.thirdParty = JSON.parse(data.stateParams.thirdParty); // Parse stringified JSON-object + if (sendFlowData.thirdParty) { + // vm.thirdParty = JSON.parse(sendFlowData.thirdParty); // Parse stringified JSON-object if (vm.thirdParty) { handleThirdPartyInitIfBip70(); handleThirdPartyInitIfShapeshift(); @@ -105,7 +106,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit updateSendAmounts(); getOriginWalletBalance(vm.originWallet); handleDestinationAsAddress(toAddress, coin); - handleDestinationAsWallet(data.stateParams.toWalletId); + handleDestinationAsWallet(sendFlowData.toWalletId); createVanityTransaction(data); }); } @@ -221,10 +222,10 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit // Grab stateParams tx = { - amount: parseInt(data.stateParams.amount), - sendMax: data.stateParams.sendMax === 'true' ? true : false, - fromWalletId: data.stateParams.fromWalletId, - toAddress: data.stateParams.toAddress, + amount: parseInt(sendFlowData.amount), + sendMax: sendFlowData.sendMax === 'true' ? true : false, + fromWalletId: sendFlowData.fromWalletId, + toAddress: sendFlowData.toAddress, paypro: txPayproData, feeLevel: configFeeLevel, @@ -241,7 +242,6 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit }; - if (data.stateParams.requiredFeeRate) { vm.usingMerchantFee = true; tx.feeRate = parseInt(data.stateParams.requiredFeeRate); @@ -251,7 +251,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit tx.feeLevel = 'normal'; } - var B = data.stateParams.coin === 'bch' ? bitcoreCash : bitcore; + var B = tx.coin === 'bch' ? bitcoreCash : bitcore; var networkName; try { if (vm.destination.kind === 'wallet') { // This is a wallet-to-wallet transfer diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 465941c35..0c0c1bfe1 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('tabSendController', function($scope, $rootScope, $log, $timeout, $ionicScrollDelegate, $ionicLoading, addressbookService, profileService, lodash, $state, walletService, incomingData, popupService, platformInfo, bwcError, gettextCatalog, scannerService, configService, bitcoinCashJsService, $ionicPopup, $ionicNavBarDelegate, clipboardService) { +angular.module('copayApp.controllers').controller('tabSendController', function($scope, $rootScope, $log, $timeout, $ionicScrollDelegate, $ionicLoading, addressbookService, profileService, lodash, $state, walletService, incomingData, popupService, platformInfo, sendFlowService, bwcError, gettextCatalog, scannerService, configService, bitcoinCashJsService, $ionicPopup, $ionicNavBarDelegate, clipboardService) { var clipboardHasAddress = false; var clipboardHasContent = false; var originalList; diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index d3308ff1e..9eef7a5c9 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('walletDetailsController', function($scope, $rootScope, $interval, $timeout, $filter, $log, $ionicModal, $ionicPopover, $state, $stateParams, $ionicHistory, profileService, lodash, configService, platformInfo, walletService, txpModalService, externalLinkService, popupService, addressbookService, storageService, $ionicScrollDelegate, $window, bwcError, gettextCatalog, timeService, feeService, appConfigService, rateService) { +angular.module('copayApp.controllers').controller('walletDetailsController', function($scope, $rootScope, $interval, $timeout, $filter, $log, $ionicModal, $ionicPopover, $state, $stateParams, $ionicHistory, profileService, lodash, configService, platformInfo, walletService, txpModalService, externalLinkService, popupService, addressbookService, sendFlowService, storageService, $ionicScrollDelegate, $window, bwcError, gettextCatalog, timeService, feeService, appConfigService, rateService) { var HISTORY_SHOW_LIMIT = 10; var currentTxHistoryPage = 0; @@ -471,9 +471,8 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun return "#" + componentToHex(r) + componentToHex(g) + componentToHex(b); } $scope.goToSend = function() { - $state.go('tabs.home', { - walletId: $scope.wallet.id - }).then(function () { + sendFlowService.fromWalletId = $scope.wallet.id; + $state.go('tabs.home').then(function () { $ionicHistory.clearHistory(); $state.go('tabs.send'); }); diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index a4ff3ab3e..a26e07d8f 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('walletSelectorController', function($scope, $rootScope, $state, $log, $ionicHistory, configService, gettextCatalog, profileService, txFormatService) { +angular.module('copayApp.controllers').controller('walletSelectorController', function($scope, $rootScope, $state, $log, $ionicHistory, sendFlowService, configService, gettextCatalog, profileService, txFormatService) { var fromWalletId = ''; var priceDisplayAsFiat = false; @@ -26,10 +26,14 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu // nop } - $scope.params = $state.params; + $scope.params = sendFlowService; $scope.coin = false; // Wallets to show (for destination screen or contacts) - $scope.type = data.stateParams && data.stateParams['fromWalletId'] ? 'destination' : 'origin'; // origin || destination - fromWalletId = data.stateParams && data.stateParams.fromWalletId; + $scope.type = $scope.params['fromWalletId'] ? 'destination' : 'origin'; // origin || destination + fromWalletId = $scope.params['fromWalletId']; + + if ($scope.type === 'destination' && $scope.params.toAddress) { + $state.transitionTo(getNextStep()); + } if ($scope.params.coin) { $scope.coin = $scope.params.coin; // Contacts have a coin embedded diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index 946144dce..91de99cf3 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.services').factory('incomingData', function($log, $state, $timeout, $ionicHistory, bitcore, bitcoreCash, $rootScope, payproService, scannerService, appConfigService, popupService, gettextCatalog, bitcoinCashJsService) { +angular.module('copayApp.services').factory('incomingData', function($log, $state, $timeout, $ionicHistory, bitcore, bitcoreCash, $rootScope, payproService, scannerService, sendFlowService, appConfigService, popupService, gettextCatalog, bitcoinCashJsService) { var root = {}; @@ -105,9 +105,10 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat params.thirdParty = []; params.thirdParty.id = serviceId; params.thirdParty.data = serviceData; - params.thirdParty = JSON.stringify(params.thirdParty); + sendFlowService.map(params); $state.transitionTo('tabs.send.amount', params); } else { + sendFlowService.map(params); $state.transitionTo('tabs.send.origin', params); } }, 100); @@ -458,6 +459,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat 'notify': $state.current.name == 'tabs.send' ? false : true }).then(function() { $timeout(function() { + sendFlowService.map(stateParams); $state.transitionTo('tabs.send.origin', stateParams); }); }); diff --git a/src/js/services/sendFlowService.js b/src/js/services/sendFlowService.js index d5c4df109..09e55e7ec 100644 --- a/src/js/services/sendFlowService.js +++ b/src/js/services/sendFlowService.js @@ -20,5 +20,12 @@ angular.module('copayApp.services').factory('sendFlowService', function ($log) { vm.toWalletId = false; }; + vm.map = function(params) { + Object.keys(params).map(function(key, index) { + vm[key] = params[key]; + }); + console.log(vm); + }; + return vm; }); \ No newline at end of file From 220610271558cff7fe347da994eedc0319108fdc Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 8 Aug 2018 17:27:15 +0200 Subject: [PATCH 288/386] sendflow service integrated into flow --- .../controllers/walletSelectorController.js | 1 + src/js/services/sendFlowService.js | 21 +++++++++++++++++-- 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index a26e07d8f..69430dbb9 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -191,6 +191,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu }; $scope.goBack = function() { + sendFlowService.previousState(); $ionicHistory.goBack(); } diff --git a/src/js/services/sendFlowService.js b/src/js/services/sendFlowService.js index 09e55e7ec..58b457b3a 100644 --- a/src/js/services/sendFlowService.js +++ b/src/js/services/sendFlowService.js @@ -4,13 +4,15 @@ angular.module('copayApp.services').factory('sendFlowService', function ($log) { var vm = this; vm.amount = false; + vm.fromWalletId = false; + vm.previousStates = []; vm.thirdParty = false; vm.sendMax = false; vm.toAddress = false; vm.toWalletId = false; - vm.initialize = function() { + vm.clear = function() { $log.debug("Reinitialize Send Flow variables"); vm.amount = false; vm.fromWalletId = false; @@ -18,13 +20,28 @@ angular.module('copayApp.services').factory('sendFlowService', function ($log) { vm.sendMax = false; vm.toAddress = false; vm.toWalletId = false; + vm.previousStates = []; }; vm.map = function(params) { + + var tempState = {}; + Object.keys(vm).map(function(key, index) { + if (typeof vm[key] !== 'function' && key !== 'previousStates') { + tempState[key] = vm[key]; + } + }); + vm.previousStates.push(tempState); + Object.keys(params).map(function(key, index) { vm[key] = params[key]; }); - console.log(vm); + }; + + vm.previousState = function() { + if (vm.previousStates.length) { + vm.map(vm.previousStates.pop()); + } }; return vm; From 02e8e0fbf026f44f5e999eaabb867ae835fa231f Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Wed, 8 Aug 2018 17:29:28 +0200 Subject: [PATCH 289/386] clear send flow on home and wallet details --- src/js/controllers/tab-home.js | 4 +++- src/js/controllers/walletDetails.js | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/tab-home.js b/src/js/controllers/tab-home.js index 07b01b974..7671d524a 100644 --- a/src/js/controllers/tab-home.js +++ b/src/js/controllers/tab-home.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.controllers').controller('tabHomeController', - function($rootScope, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, bannerService, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, storageService, txpModalService, appConfigService, startupService, addressbookService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { + function($rootScope, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, bannerService, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, sendFlowService, storageService, txpModalService, appConfigService, startupService, addressbookService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { var wallet; var listeners = []; var notifications = []; @@ -31,6 +31,8 @@ angular.module('copayApp.controllers').controller('tabHomeController', }); $scope.$on("$ionicView.beforeEnter", function(event, data) { + sendFlowService.clear(); + if (!$scope.homeTip) { storageService.getHomeTipAccepted(function(error, value) { $scope.homeTip = (value == 'accepted') ? false : true; diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index 9eef7a5c9..5200c5987 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -374,6 +374,7 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun }); $scope.$on("$ionicView.beforeEnter", function(event, data) { + sendFlowService.clear(); configService.whenAvailable(function (config) { $scope.selectedPriceDisplay = config.wallet.settings.priceDisplay; From d81f194f87a262d4de7b43e2fa3401c7cdc52017 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 07:35:47 +1200 Subject: [PATCH 290/386] Fix for when an amount changes from having a separate currency value, to the currency being one string with the amount. --- src/js/directives/formattedAmount.js | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index c5b2dfcd4..c39007d66 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -63,14 +63,15 @@ angular.module('bitcoincom.directives') }; var formatNumbers = function() { - - if (!$scope.currency && $scope.value) { // If there is no currency available.. - // Try to extract currency from value.. - var currencySplit = $scope.value.split(" "); - if (currencySplit.length === 2) { - $scope.currency = currencySplit[1]; - } + + // During watch, may be changed from having a separate currency value, + // to both being in value. Don't want to use previous currency value. + // Try to extract currency from value.. + var currencySplit = $scope.value.split(" "); + if (currencySplit.length === 2) { + $scope.currency = currencySplit[1]; } + var parsed = parseFloat($scope.value); var valueFormatted = ''; From 1c3b11322238da4677371833f18b32fee368a814 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 07:49:13 +1200 Subject: [PATCH 291/386] Removed unused config service. --- src/js/directives/formattedAmount.js | 203 +++++++++++++-------------- 1 file changed, 100 insertions(+), 103 deletions(-) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index c39007d66..6269954fb 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -11,7 +11,7 @@ * @example */ angular.module('bitcoincom.directives') - .directive('formattedAmount', function(configService, uxLanguage) { + .directive('formattedAmount', function(uxLanguage) { return { restrict: 'E', scope: { @@ -25,110 +25,107 @@ angular.module('bitcoincom.directives') $scope.displaySizeEqual = !!$scope.sizeEqual; - configService.whenAvailable(function onConfigServiceAvailable(config) { + $timeout(function onFormattedAmountTimeout() { - $timeout(function onFormattedAmountTimeout() { - - var decimalPlaces = { - '0': ['BIF', 'CLP', 'DJF', 'GNF', 'ILS', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'UGX', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'], - '3': ['BHD', 'IQD', 'JOD', 'KWD', 'OMR', 'TND'], - '8': ['BCH', 'BTC'] - }; - var localizeNumbers = function(x, minimumFractionDigits = 0, useGrouping = true) { - return parseFloat(x).toLocaleString(uxLanguage.getCurrentLanguage(), { - minimumFractionDigits: minimumFractionDigits, - useGrouping: useGrouping - }); - }; - - var buildAmount = function(start, middle, end) { - $scope.start = start; - $scope.middle = middle; - $scope.end = end; - }; - - var getDecimalPlaces = function(currency) { - if (decimalPlaces['0'].indexOf(currency.toUpperCase()) > -1) return '0'; - if (decimalPlaces['3'].indexOf(currency.toUpperCase()) > -1) return '3'; - if (decimalPlaces['8'].indexOf(currency.toUpperCase()) > -1) return '8'; - return '2'; - }; - - var getDecimalSeparator = function() { - var testNum = 1.5; - var testString = testNum.toLocaleString(uxLanguage.getCurrentLanguage()); - // Some environments let you set decimal separators that are more than one character - var separator = /^1(.+)5$/.exec(testString)[1] - return separator; - }; - - var formatNumbers = function() { - - // During watch, may be changed from having a separate currency value, - // to both being in value. Don't want to use previous currency value. - // Try to extract currency from value.. - var currencySplit = $scope.value.split(" "); - if (currencySplit.length === 2) { - $scope.currency = currencySplit[1]; - } - - - var parsed = parseFloat($scope.value); - var valueFormatted = ''; - var valueProcessing = ''; - switch (getDecimalPlaces($scope.currency)) { - case '0': - if (isNaN(parsed)) { - buildAmount('-', '', ''); - } else { - valueFormatted = localizeNumbers(Math.round(parsed)); - buildAmount(valueFormatted, '', ''); - } - break; - - case '3': - if (isNaN(parsed)) { - buildAmount('-' + getDecimalSeparator() + '---', '', ''); - } else { - valueProcessing = parsed.toFixed(3); - valueFormatted = localizeNumbers(valueProcessing, 3); - buildAmount(valueFormatted, '', ''); - } - break; - - case '8': - if (isNaN(parsed)) { - buildAmount('-' + getDecimalSeparator() + '---', '', ''); - } else if (parsed === 0) { - buildAmount('0', '', ''); - } else { - valueFormatted = parsed.toFixed(8); - valueFormatted = localizeNumbers(valueFormatted, 8); - var start = valueFormatted.slice(0, -5); - var middle = valueFormatted.slice(-5, -2); - var end = valueFormatted.substr(valueFormatted.length - 2); - buildAmount(start, middle, end); - - } - break; - - default: // 2 - if (isNaN(parsed)) { - buildAmount('-' + getDecimalSeparator() + '--', '', ''); - } else { - valueProcessing = parseFloat(parsed.toFixed(2)); - valueFormatted = localizeNumbers(valueProcessing, 2); - buildAmount(valueFormatted, '', ''); - } - break; - } - $scope.canShow = true; - }; - - formatNumbers(); - $scope.$watchGroup(['currency', 'value'], function onFormattedAmountWatch() { - formatNumbers(); + var decimalPlaces = { + '0': ['BIF', 'CLP', 'DJF', 'GNF', 'ILS', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'UGX', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'], + '3': ['BHD', 'IQD', 'JOD', 'KWD', 'OMR', 'TND'], + '8': ['BCH', 'BTC'] + }; + var localizeNumbers = function(x, minimumFractionDigits = 0, useGrouping = true) { + return parseFloat(x).toLocaleString(uxLanguage.getCurrentLanguage(), { + minimumFractionDigits: minimumFractionDigits, + useGrouping: useGrouping }); + }; + + var buildAmount = function(start, middle, end) { + $scope.start = start; + $scope.middle = middle; + $scope.end = end; + }; + + var getDecimalPlaces = function(currency) { + if (decimalPlaces['0'].indexOf(currency.toUpperCase()) > -1) return '0'; + if (decimalPlaces['3'].indexOf(currency.toUpperCase()) > -1) return '3'; + if (decimalPlaces['8'].indexOf(currency.toUpperCase()) > -1) return '8'; + return '2'; + }; + + var getDecimalSeparator = function() { + var testNum = 1.5; + var testString = testNum.toLocaleString(uxLanguage.getCurrentLanguage()); + // Some environments let you set decimal separators that are more than one character + var separator = /^1(.+)5$/.exec(testString)[1] + return separator; + }; + + var formatNumbers = function() { + + // During watch, may be changed from having a separate currency value, + // to both being in value. Don't want to use previous currency value. + // Try to extract currency from value.. + var currencySplit = $scope.value.split(" "); + if (currencySplit.length === 2) { + $scope.currency = currencySplit[1]; + } + + + var parsed = parseFloat($scope.value); + var valueFormatted = ''; + var valueProcessing = ''; + switch (getDecimalPlaces($scope.currency)) { + case '0': + if (isNaN(parsed)) { + buildAmount('-', '', ''); + } else { + valueFormatted = localizeNumbers(Math.round(parsed)); + buildAmount(valueFormatted, '', ''); + } + break; + + case '3': + if (isNaN(parsed)) { + buildAmount('-' + getDecimalSeparator() + '---', '', ''); + } else { + valueProcessing = parsed.toFixed(3); + valueFormatted = localizeNumbers(valueProcessing, 3); + buildAmount(valueFormatted, '', ''); + } + break; + + case '8': + if (isNaN(parsed)) { + buildAmount('-' + getDecimalSeparator() + '---', '', ''); + } else if (parsed === 0) { + buildAmount('0', '', ''); + } else { + valueFormatted = parsed.toFixed(8); + valueFormatted = localizeNumbers(valueFormatted, 8); + var start = valueFormatted.slice(0, -5); + var middle = valueFormatted.slice(-5, -2); + var end = valueFormatted.substr(valueFormatted.length - 2); + buildAmount(start, middle, end); + + } + break; + + default: // 2 + if (isNaN(parsed)) { + buildAmount('-' + getDecimalSeparator() + '--', '', ''); + } else { + valueProcessing = parseFloat(parsed.toFixed(2)); + valueFormatted = localizeNumbers(valueProcessing, 2); + buildAmount(valueFormatted, '', ''); + } + break; + } + $scope.canShow = true; + }; + + formatNumbers(); + $scope.$watchGroup(['currency', 'value'], function onFormattedAmountWatch() { + formatNumbers(); }); }); } From 58d99231ae449d140e01a6b5cd5722fc973c570a Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 10:46:07 +1200 Subject: [PATCH 292/386] Handle undefined currency. --- src/js/directives/formattedAmount.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index 6269954fb..5bd307de3 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -69,6 +69,7 @@ angular.module('bitcoincom.directives') if (currencySplit.length === 2) { $scope.currency = currencySplit[1]; } + $scope.currency = $scope.currency || ''; var parsed = parseFloat($scope.value); From dff0d51ef3699df1d5ccaa5299637510b63c0ab6 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 11:10:26 +1200 Subject: [PATCH 293/386] Refactored sendFlowService and cleared its state before entering the send tab. --- src/js/controllers/addressbookView.js | 3 +- src/js/controllers/amount.js | 1 + src/js/controllers/shapeshift.js | 3 +- src/js/controllers/tab-home.js | 8 +- src/js/controllers/tab-send.js | 7 ++ src/js/controllers/tabsController.js | 9 ++- src/js/controllers/walletDetails.js | 10 ++- src/js/services/sendFlowService.js | 106 +++++++++++++++++--------- www/views/tab-home.html | 2 +- www/views/tab-send.html | 21 ++++- www/views/tabs.html | 2 +- 11 files changed, 124 insertions(+), 48 deletions(-) diff --git a/src/js/controllers/addressbookView.js b/src/js/controllers/addressbookView.js index aab6fb5b4..5f6881d10 100644 --- a/src/js/controllers/addressbookView.js +++ b/src/js/controllers/addressbookView.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('addressbookViewController', function($scope, $state, $timeout, lodash, addressbookService, popupService, $ionicHistory, platformInfo, gettextCatalog, configService, bitcoinCashJsService) { +angular.module('copayApp.controllers').controller('addressbookViewController', function($scope, sendFlowService, $state, $timeout, lodash, addressbookService, popupService, $ionicHistory, platformInfo, gettextCatalog, configService, bitcoinCashJsService) { var config = configService.getSync(); var defaults = configService.getDefaults(); @@ -22,6 +22,7 @@ angular.module('copayApp.controllers').controller('addressbookViewController', f $scope.sendTo = function() { $ionicHistory.removeBackView(); + sendFlowService.clear(); $state.go('tabs.send'); $timeout(function() { var to = ''; diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 68d4e869b..8ff214d87 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -209,6 +209,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, } function goBack() { + sendFlowService.previousState(); if (vm.thirdParty && vm.thirdParty.id === 'shapeshift') { $state.go('tabs.send').then(function() { $ionicHistory.clearHistory(); diff --git a/src/js/controllers/shapeshift.js b/src/js/controllers/shapeshift.js index 4bf3db764..fcb43026d 100644 --- a/src/js/controllers/shapeshift.js +++ b/src/js/controllers/shapeshift.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('shapeshiftController', function($scope, $state, $timeout, $ionicHistory, profileService, walletService, popupService, lodash, $ionicNavBarDelegate) { +angular.module('copayApp.controllers').controller('shapeshiftController', function($scope, sendFlowService, $state, $timeout, $ionicHistory, profileService, walletService, popupService, lodash, $ionicNavBarDelegate) { var walletsBtc = []; var walletsBch = []; @@ -67,6 +67,7 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi thirdParty: JSON.stringify({id: 'shapeshift'}) }; + sendFlowService.clear(); $state.go('tabs.home').then(function() { $ionicHistory.clearHistory(); $state.go('tabs.send').then(function() { diff --git a/src/js/controllers/tab-home.js b/src/js/controllers/tab-home.js index 7671d524a..3d63ae41f 100644 --- a/src/js/controllers/tab-home.js +++ b/src/js/controllers/tab-home.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.controllers').controller('tabHomeController', - function($rootScope, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, bannerService, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, sendFlowService, storageService, txpModalService, appConfigService, startupService, addressbookService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { + function($rootScope, sendFlowService, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, bannerService, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, storageService, txpModalService, appConfigService, startupService, addressbookService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { var wallet; var listeners = []; var notifications = []; @@ -31,7 +31,6 @@ angular.module('copayApp.controllers').controller('tabHomeController', }); $scope.$on("$ionicView.beforeEnter", function(event, data) { - sendFlowService.clear(); if (!$scope.homeTip) { storageService.getHomeTipAccepted(function(error, value) { @@ -119,6 +118,11 @@ angular.module('copayApp.controllers').controller('tabHomeController', return timeService.withinPastDay(time); }; + $scope.startFreshSend = function() { + sendFlowService.clear(); + $state.go('tabs.send'); + } + $scope.openExternalLink = function() { var url = 'https://github.com/Bitcoin-com/Wallet/releases/latest'; var optIn = true; diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 0c0c1bfe1..33befb8f2 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -187,6 +187,13 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }); }; + $scope.startWalletToWalletTransfer = function() { + console.log('startWalletToWalletTransfer()'); + $state.transitionTo('tabs.send.wallet-to-wallet', { + fromWalletId: sendFlowService.fromWalletId + }); + } + // This could probably be enhanced refactoring the routes abstract states $scope.createWallet = function() { $state.go('tabs.home').then(function() { diff --git a/src/js/controllers/tabsController.js b/src/js/controllers/tabsController.js index a186879e3..b3de6c70f 100644 --- a/src/js/controllers/tabsController.js +++ b/src/js/controllers/tabsController.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('tabsController', function($rootScope, $log, $scope, $state, $stateParams, $timeout, platformInfo, incomingData, lodash, popupService, gettextCatalog, scannerService) { +angular.module('copayApp.controllers').controller('tabsController', function($rootScope, $log, $scope, $state, $stateParams, $timeout, platformInfo, incomingData, lodash, popupService, gettextCatalog, scannerService, sendFlowService) { $scope.onScan = function(data) { if (!incomingData.redir(data)) { @@ -15,6 +15,11 @@ angular.module('copayApp.controllers').controller('tabsController', function($ro }; }; + $scope.startFreshSend = function() { + sendFlowService.clear(); + $state.go('tabs.send'); + }; + $scope.importInit = function() { $scope.fromOnboarding = $stateParams.fromOnboarding; $timeout(function() { @@ -23,7 +28,7 @@ angular.module('copayApp.controllers').controller('tabsController', function($ro }; $scope.chooseScanner = function() { - + sendFlowService.clear(); var isWindowsPhoneApp = platformInfo.isCordova && platformInfo.isWP; if (!isWindowsPhoneApp) { diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index 5200c5987..b159f7bc4 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -471,13 +471,20 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun function rgbToHex(r, g, b) { return "#" + componentToHex(r) + componentToHex(g) + componentToHex(b); } + $scope.goToSend = function() { - sendFlowService.fromWalletId = $scope.wallet.id; + sendFlowService.startSend({ + fromWalletId: $scope.wallet.id + }); + + // Go home first so that the Home tab works properly $state.go('tabs.home').then(function () { $ionicHistory.clearHistory(); $state.go('tabs.send'); }); + }; + $scope.goToReceive = function() { $state.go('tabs.home', { walletId: $scope.wallet.id @@ -488,6 +495,7 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun }); }); }; + $scope.goToBuy = function() { $state.go('tabs.home', { walletId: $scope.wallet.id diff --git a/src/js/services/sendFlowService.js b/src/js/services/sendFlowService.js index 58b457b3a..1af112ed2 100644 --- a/src/js/services/sendFlowService.js +++ b/src/js/services/sendFlowService.js @@ -1,48 +1,78 @@ 'use strict'; -angular.module('copayApp.services').factory('sendFlowService', function ($log) { - var vm = this; +(function(){ - vm.amount = false; +angular + .module('copayApp.services') + .factory('sendFlowService', sendFlowService); + + function sendFlowService($log) { - vm.fromWalletId = false; - vm.previousStates = []; - vm.thirdParty = false; - vm.sendMax = false; - vm.toAddress = false; - vm.toWalletId = false; + var service = { + amount: '', + fromWalletId: '', + sendMax: false, + thirdParty: null, + toAddress: '', + toWalletId: '', + previousStates: [], - vm.clear = function() { - $log.debug("Reinitialize Send Flow variables"); - vm.amount = false; - vm.fromWalletId = false; - vm.thirdParty = false; - vm.sendMax = false; - vm.toAddress = false; - vm.toWalletId = false; - vm.previousStates = []; - }; + // Functions + clear: clear, + map: map, + previousState: previousState, + startSend: startSend + }; - vm.map = function(params) { + return service; - var tempState = {}; - Object.keys(vm).map(function(key, index) { - if (typeof vm[key] !== 'function' && key !== 'previousStates') { - tempState[key] = vm[key]; - } - }); - vm.previousStates.push(tempState); - - Object.keys(params).map(function(key, index) { - vm[key] = params[key]; - }); - }; - - vm.previousState = function() { - if (vm.previousStates.length) { - vm.map(vm.previousStates.pop()); + function clear() { + $log.debug("Reinitialize Send Flow variables with clear()"); + service.amount = ''; + service.fromWalletId = ''; + service.sendMax = false; + service.thirdParty = null; + service.toAddress = ''; + service.toWalletId = ''; + service.previousStates = []; } + + /** + * Clears all previous state + * @param {} params + */ + function startSend(params) { + console.log('startSend()'); + clear(); + Object.keys(params).forEach(function forNewParam(key) { + service[key] = params[key]; + }); + } + + function map(params) { + + var currentState = {}; + Object.keys(service).forEach(function forCurrentParam(key) { + if (typeof service[key] !== 'function' && key !== 'previousStates') { + currentState[key] = service[key]; + } + }); + service.previousStates.push(currentState); + + // Do we want to inherit the previous state here, or clear first before adding new params? + + Object.keys(params).forEach(function forNewParam(key) { + service[key] = params[key]; + }); + }; + + function previousState() { + if (service.previousStates.length) { + map(service.previousStates.pop()); + } else { + clear(); + } + }; }; - return vm; -}); \ No newline at end of file +})(); \ No newline at end of file diff --git a/www/views/tab-home.html b/www/views/tab-home.html index 618f2e128..8ef922918 100644 --- a/www/views/tab-home.html +++ b/www/views/tab-home.html @@ -34,7 +34,7 @@ Buy Bitcoin
+ ng-click="startFreshSend()"> Send
diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 20198c7f0..3378b53ed 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -4,6 +4,25 @@
+ +
+
+
From:
+
+
+ +
+
+

{{fromWallet.name}}

+ + +
+
+
+
+
@@ -22,7 +41,7 @@
- diff --git a/www/views/tabs.html b/www/views/tabs.html index 3c2683a13..39d0acf73 100644 --- a/www/views/tabs.html +++ b/www/views/tabs.html @@ -11,7 +11,7 @@ - + From be2bc4cddb5b774c49baa14c51d89c2ad013c6b5 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 11:11:10 +1200 Subject: [PATCH 294/386] Showing From wallet in send tab. --- src/js/controllers/tab-send.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 33befb8f2..caa03e92b 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -208,6 +208,13 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }; $scope.$on("$ionicView.beforeEnter", function(event, data) { + console.log('tab-send.beforeEnter sendFlowService.fromWalletId:', sendFlowService.fromWalletId); + var fromWalletId = sendFlowService.fromWalletId; + if (fromWalletId) { + $scope.fromWallet = profileService.getWallet(fromWalletId); + } else { + $scope.fromWallet = null; + } $scope.isIOS = platformInfo.isIOS && platformInfo.isCordova; $scope.showWalletsBch = $scope.showWalletsBtc = $scope.showWallets = false; From 1d025cbf35f9bf7fa8eb36e5bd708dea5a1f149f Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 11:42:25 +1200 Subject: [PATCH 295/386] Fixes for Android 4.4 --- src/js/directives/formattedAmount.js | 6 +++--- src/js/services/clipboardService.js | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index 5bd307de3..d3e2e6347 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -32,10 +32,10 @@ angular.module('bitcoincom.directives') '3': ['BHD', 'IQD', 'JOD', 'KWD', 'OMR', 'TND'], '8': ['BCH', 'BTC'] }; - var localizeNumbers = function(x, minimumFractionDigits = 0, useGrouping = true) { + var localizeNumbers = function(x, minimumFractionDigits) { return parseFloat(x).toLocaleString(uxLanguage.getCurrentLanguage(), { minimumFractionDigits: minimumFractionDigits, - useGrouping: useGrouping + useGrouping: true }); }; @@ -80,7 +80,7 @@ angular.module('bitcoincom.directives') if (isNaN(parsed)) { buildAmount('-', '', ''); } else { - valueFormatted = localizeNumbers(Math.round(parsed)); + valueFormatted = localizeNumbers(Math.round(parsed), 0); buildAmount(valueFormatted, '', ''); } break; diff --git a/src/js/services/clipboardService.js b/src/js/services/clipboardService.js index 075cb749a..77ad3d018 100644 --- a/src/js/services/clipboardService.js +++ b/src/js/services/clipboardService.js @@ -13,7 +13,7 @@ angular.module('copayApp.services').factory('clipboardService', function ($http, nodeWebkitService.writeToClipboard(data); } else if (navigator && navigator.clipboard) { $log.debug("Use navigator clipboard.") - navigator.clipboard.writeText(data).catch(err => { + navigator.clipboard.writeText(data).catch(function onClipboardError(err) { $log.debug("Clipboard writing is not supported in your browser.."); }); } else if (clipboard.supported) { From 408d46e4d342eab340ea0033d16d2d43492a71b7 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 11:43:20 +1200 Subject: [PATCH 296/386] Hid the from wallet in the send screen for now, because it requires other layout changes to fit everything in, especially on small screens. --- src/js/controllers/tab-send.js | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index caa03e92b..33befb8f2 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -208,13 +208,6 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }; $scope.$on("$ionicView.beforeEnter", function(event, data) { - console.log('tab-send.beforeEnter sendFlowService.fromWalletId:', sendFlowService.fromWalletId); - var fromWalletId = sendFlowService.fromWalletId; - if (fromWalletId) { - $scope.fromWallet = profileService.getWallet(fromWalletId); - } else { - $scope.fromWallet = null; - } $scope.isIOS = platformInfo.isIOS && platformInfo.isCordova; $scope.showWalletsBch = $scope.showWalletsBtc = $scope.showWallets = false; From be0c18244e8be335a62f15788e661eb0fa27b0d3 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 12:12:29 +1200 Subject: [PATCH 297/386] Review Transaction screen now displaying BCH addresses in cashaddr format. --- src/js/controllers/review.controller.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 858e115c1..886da26b8 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -403,16 +403,20 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit // Check if the recipient is a contact addressbookService.get(originCoin + address, function(err, contact) { if (!err && contact) { - handleDestinationAsContact(contact); + handleDestinationAsAddressOfContact(contact); } else { - vm.destination.address = address; + if (originCoin === 'bch') { + vm.destination.address = bitcoinCashJsService.readAddress(address).cashaddr; + } else { + vm.destination.address = address; + } vm.destination.kind = 'address'; } }); } - function handleDestinationAsContact(contact) { + function handleDestinationAsAddressOfContact(contact) { vm.destination.kind = 'contact'; vm.destination.name = contact.name; vm.destination.email = contact.email; From bf9b467bfe9324f493c0b90d6942ba459d5c5f66 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 13:01:48 +1200 Subject: [PATCH 298/386] Renamed sendFlowService functions to be more consistent. --- src/js/controllers/amount.js | 5 +- src/js/controllers/tab-send.js | 3 ++ .../controllers/walletSelectorController.js | 10 ++-- src/js/services/incomingData.js | 6 +-- src/js/services/sendFlowService.js | 48 ++++++++++++------- 5 files changed, 46 insertions(+), 26 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 8ff214d87..6f513663c 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -66,6 +66,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, } function onBeforeEnter(event, data) { + console.log('amount onBeforeEnter sendflow ', sendFlowService.getState()); initCurrencies(); @@ -209,7 +210,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, } function goBack() { - sendFlowService.previousState(); + sendFlowService.popState(); if (vm.thirdParty && vm.thirdParty.id === 'shapeshift') { $state.go('tabs.send').then(function() { $ionicHistory.clearHistory(); @@ -471,7 +472,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, confirmData['thirdParty'] = this.thirdParty; } - sendFlowService.map(confirmData); + sendFlowService.pushState(confirmData); if (!confirmData.fromWalletId) { $state.transitionTo('tabs.paymentRequest.confirm', confirmData); diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 33befb8f2..3f2c1a250 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -189,6 +189,8 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.startWalletToWalletTransfer = function() { console.log('startWalletToWalletTransfer()'); + var params = sendFlowService.getState(); + sendFlowService.pushState(params); $state.transitionTo('tabs.send.wallet-to-wallet', { fromWalletId: sendFlowService.fromWalletId }); @@ -208,6 +210,7 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }; $scope.$on("$ionicView.beforeEnter", function(event, data) { + console.log('tab-send onBeforeEnter sendflow ', sendFlowService.getState()); $scope.isIOS = platformInfo.isIOS && platformInfo.isCordova; $scope.showWalletsBch = $scope.showWalletsBtc = $scope.showWallets = false; diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index 69430dbb9..1c23bb24b 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -8,6 +8,8 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu var unitsFromSatoshis = 0; $scope.$on("$ionicView.beforeEnter", function(event, data) { + console.log('walletSelector onBeforeEnter sendflow', sendFlowService.getState()); + var config = configService.getSync().wallet.settings; priceDisplayAsFiat = config.priceDisplay === 'fiat'; unitDecimals = config.unitDecimals; @@ -182,16 +184,18 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.useWallet = function(wallet) { + var params = sendFlowService.getState(); if ($scope.type === 'origin') { // we're on the origin screen, set wallet to send from - $scope.params['fromWalletId'] = wallet.id; + params.fromWalletId = wallet.id; } else { // we're on the destination screen, set wallet to send to - $scope.params['toWalletId'] = wallet.id; + params.toWalletId = wallet.id; } + sendFlowService.pushState(params); $state.transitionTo(getNextStep(), $scope.params); }; $scope.goBack = function() { - sendFlowService.previousState(); + sendFlowService.popState(); $ionicHistory.goBack(); } diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index 91de99cf3..934f53cc7 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -105,10 +105,10 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat params.thirdParty = []; params.thirdParty.id = serviceId; params.thirdParty.data = serviceData; - sendFlowService.map(params); + sendFlowService.pushState(params); $state.transitionTo('tabs.send.amount', params); } else { - sendFlowService.map(params); + sendFlowService.pushState(params); $state.transitionTo('tabs.send.origin', params); } }, 100); @@ -459,7 +459,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat 'notify': $state.current.name == 'tabs.send' ? false : true }).then(function() { $timeout(function() { - sendFlowService.map(stateParams); + sendFlowService.pushState(stateParams); // Need to do more here $state.transitionTo('tabs.send.origin', stateParams); }); }); diff --git a/src/js/services/sendFlowService.js b/src/js/services/sendFlowService.js index 1af112ed2..9daf0f4db 100644 --- a/src/js/services/sendFlowService.js +++ b/src/js/services/sendFlowService.js @@ -19,15 +19,17 @@ angular // Functions clear: clear, + getState: getState, map: map, - previousState: previousState, + popState: popState, + pushState: pushState, startSend: startSend }; return service; function clear() { - $log.debug("Reinitialize Send Flow variables with clear()"); + console.log("sendFlow clear()"); service.amount = ''; service.fromWalletId = ''; service.sendMax = false; @@ -38,41 +40,51 @@ angular } /** - * Clears all previous state - * @param {} params + * Handy for debugging */ - function startSend(params) { - console.log('startSend()'); - clear(); - Object.keys(params).forEach(function forNewParam(key) { - service[key] = params[key]; - }); - } - - function map(params) { - + function getState() { var currentState = {}; Object.keys(service).forEach(function forCurrentParam(key) { if (typeof service[key] !== 'function' && key !== 'previousStates') { currentState[key] = service[key]; } }); - service.previousStates.push(currentState); + return currentState; + } - // Do we want to inherit the previous state here, or clear first before adding new params? + /** + * Clears all previous state + */ + function startSend(params) { + console.log('startSend()'); + clear(); + map(params); + } + function map(params) { Object.keys(params).forEach(function forNewParam(key) { service[key] = params[key]; }); }; - function previousState() { + function popState() { + console.log('sendFlow pop'); if (service.previousStates.length) { - map(service.previousStates.pop()); + var params = service.previousStates.pop(); + clear(); + map(params); } else { clear(); } }; + + function pushState(params) { + console.log('sendFlow push'); + var currentParams = getState(); + service.previousStates.push(currentParams); + clear(); + map(params); + }; }; })(); \ No newline at end of file From b426209efb2f7a49e4338fd845edbfd593731a6c Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 13:06:50 +1200 Subject: [PATCH 299/386] Fix for clearing current state only. --- src/js/services/sendFlowService.js | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/js/services/sendFlowService.js b/src/js/services/sendFlowService.js index 9daf0f4db..29686b15b 100644 --- a/src/js/services/sendFlowService.js +++ b/src/js/services/sendFlowService.js @@ -30,13 +30,18 @@ angular function clear() { console.log("sendFlow clear()"); + clearCurrent(); + service.previousStates = []; + } + + function clearCurrent() { + console.log("sendFlow clearCurrent()"); service.amount = ''; service.fromWalletId = ''; service.sendMax = false; service.thirdParty = null; service.toAddress = ''; service.toWalletId = ''; - service.previousStates = []; } /** @@ -71,7 +76,7 @@ angular console.log('sendFlow pop'); if (service.previousStates.length) { var params = service.previousStates.pop(); - clear(); + clearCurrent(); map(params); } else { clear(); @@ -82,7 +87,7 @@ angular console.log('sendFlow push'); var currentParams = getState(); service.previousStates.push(currentParams); - clear(); + clearCurrent(); map(params); }; }; From a2dff98c63c67b19c93fad058fa504e9818e0418 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 13:12:44 +1200 Subject: [PATCH 300/386] Back button on Review Transaction screen works with sendFlowService. --- src/js/controllers/review.controller.js | 6 ++++++ www/views/review.html | 3 +-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 886da26b8..e2e393501 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -49,6 +49,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit vm.memoExpanded = false; // Functions + vm.goBack = goBack; vm.onSuccessConfirm = onSuccessConfirm; var sendFlowData; @@ -395,6 +396,11 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit }; } + function goBack() { + sendFlowService.popState(); + $ionicHistory.goBack(); + } + function handleDestinationAsAddress(address, originCoin) { if (!address) { return; diff --git a/www/views/review.html b/www/views/review.html index cb7f21fbc..1eb648a01 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -3,8 +3,7 @@ {{'Review Transaction' | translate}} - - + From 0410182d4f151b1880443cc52898250c5cd3bc92 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 13:24:13 +1200 Subject: [PATCH 301/386] Incoming data working with sendFlowService. --- src/js/services/incomingData.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index 934f53cc7..76b5885d4 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -82,7 +82,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat }); // Timeout is required to enable the "Back" button $timeout(function() { - var params = {}; + var params = sendFlowService.getState(); if (amount) { params.amount = amount; From 188ddcba586054f87566f536f358708bb46435a2 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 13:25:06 +1200 Subject: [PATCH 302/386] Review transation copying state at startup so it doesn't contaminate the sendFlowController. --- src/js/controllers/review.controller.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index e2e393501..2b42339ce 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -75,8 +75,9 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit function onBeforeEnter(event, data) { + console.log('walletSelector onBeforeEnter sendflow ', sendFlowService.getState()); defaults = configService.getDefaults(); - sendFlowData = sendFlowService; + sendFlowData = sendFlowService.getState(); originWalletId = sendFlowData.fromWalletId; satoshis = parseInt(sendFlowData.amount, 10); toAddress = sendFlowData.toAddress; From e18364329805475d33a42e64b10cbf3e6b1c7baf Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 9 Aug 2018 12:35:39 +0900 Subject: [PATCH 303/386] Remove from the route the stateparams, adapt some controllers in the new sendflowservice --- src/js/controllers/addressbookView.js | 8 +++++-- src/js/controllers/amount.js | 13 ++-------- src/js/controllers/shapeshift.js | 10 ++++---- src/js/controllers/tab-send.js | 24 +++++++++++++++---- .../controllers/walletSelectorController.js | 8 ++++--- src/js/routes.js | 8 +++---- src/js/services/incomingData.js | 12 ++++++---- 7 files changed, 49 insertions(+), 34 deletions(-) diff --git a/src/js/controllers/addressbookView.js b/src/js/controllers/addressbookView.js index 5f6881d10..89c1cd924 100644 --- a/src/js/controllers/addressbookView.js +++ b/src/js/controllers/addressbookView.js @@ -32,12 +32,16 @@ angular.module('copayApp.controllers').controller('addressbookViewController', f } else { to = $scope.addressbookEntry.address; } - $state.transitionTo('tabs.send.amount', { + + var stateParams = { toAddress: to, toName: $scope.addressbookEntry.name, toEmail: $scope.addressbookEntry.email, coin: $scope.addressbookEntry.coin - }); + }; + + sendFlowService.pushState(stateParams); + $state.transitionTo('tabs.send.origin'); }, 100); }; diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 6f513663c..d07f77c3f 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -78,7 +78,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, vm.maxAmount = parseFloat(passthroughParams.maxAmount); if (passthroughParams.thirdParty) { - vm.thirdParty = JSON.parse(passthroughParams.thirdParty); // Parse stringified JSON-object + vm.thirdParty = passthroughParams.thirdParty; // Parse stringified JSON-object if (vm.thirdParty) { if (vm.thirdParty.id === 'shapeshift') { if (!vm.thirdParty.data) { @@ -211,16 +211,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, function goBack() { sendFlowService.popState(); - if (vm.thirdParty && vm.thirdParty.id === 'shapeshift') { - $state.go('tabs.send').then(function() { - $ionicHistory.clearHistory(); - $state.go('tabs.home').then(function() { - $state.transitionTo('tabs.shapeshift'); - }); - }); - } else { - $ionicHistory.goBack(); - } + $ionicHistory.goBack(); } function paste(value) { diff --git a/src/js/controllers/shapeshift.js b/src/js/controllers/shapeshift.js index fcb43026d..4ede8a94f 100644 --- a/src/js/controllers/shapeshift.js +++ b/src/js/controllers/shapeshift.js @@ -63,16 +63,18 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi }; $scope.shapeshift = function() { - var params = { - thirdParty: JSON.stringify({id: 'shapeshift'}) + var stateParams = { + thirdParty: { + id: 'shapeshift' + } }; - sendFlowService.clear(); $state.go('tabs.home').then(function() { $ionicHistory.clearHistory(); $state.go('tabs.send').then(function() { $timeout(function () { - $state.transitionTo('tabs.send.origin', params); + sendFlowService.pushState(stateParams); + $state.transitionTo('tabs.send.origin'); }, 60); }); }); diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 3f2c1a250..55087859d 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -179,11 +179,18 @@ angular.module('copayApp.controllers').controller('tabSendController', function( } $log.debug('Got toAddress:' + toAddress + ' | ' + item.name); + + var stateParams = sendFlowService.getState(); + stateParams.toAddress = toAddress, + stateParams.coin = item.coin; + sendFlowService.pushState(stateParams); + + if (!stateParams.fromWalletId) { // If we have no toAddress or fromWallet + $state.transitionTo('tabs.send.origin'); + } else { + $state.transitionTo('tabs.send.amount'); + } - return $state.transitionTo('tabs.send.origin', { - toAddress: toAddress, - coin: item.coin - }); }); }; @@ -210,6 +217,7 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }; $scope.$on("$ionicView.beforeEnter", function(event, data) { + console.log(data); console.log('tab-send onBeforeEnter sendflow ', sendFlowService.getState()); $scope.isIOS = platformInfo.isIOS && platformInfo.isCordova; $scope.showWalletsBch = $scope.showWalletsBtc = $scope.showWallets = false; @@ -225,5 +233,11 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.displayBalanceAsFiat = _config.wallet.settings.priceDisplay === 'fiat'; }); + var state = sendFlowService.getState(); + + if (data.direction == "back") { + sendFlowService.clear(); + } + }); -}); +}); \ No newline at end of file diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index 1c23bb24b..f4448486f 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -10,6 +10,8 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.$on("$ionicView.beforeEnter", function(event, data) { console.log('walletSelector onBeforeEnter sendflow', sendFlowService.getState()); + var stateParams = sendFlowService.getState(); + var config = configService.getSync().wallet.settings; priceDisplayAsFiat = config.priceDisplay === 'fiat'; unitDecimals = config.unitDecimals; @@ -20,7 +22,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); break; case 'tabs.send.destination': - if (data.stateParams.fromWalletId) { + if (stateParams.fromWalletId) { $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); } break; @@ -47,7 +49,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.isPaymentRequest = true; } if ($scope.params.thirdParty) { - $scope.thirdParty = JSON.parse($scope.params.thirdParty); // Parse stringified JSON-object + $scope.thirdParty = $scope.params.thirdParty; } }); @@ -96,7 +98,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu function getNextStep() { if ($scope.thirdParty) { - $scope.params.thirdParty = JSON.stringify($scope.thirdParty) // re-stringify JSON-object + $scope.params.thirdParty = $scope.thirdParty } if (!$scope.params.toWalletId && !$scope.params.toAddress) { // If we have no toAddress or fromWallet return 'tabs.send.destination'; diff --git a/src/js/routes.js b/src/js/routes.js index dea46a2cf..5dbcbe6a3 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -287,7 +287,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr */ .state('tabs.send.amount', { - url: '/amount/:thirdParty/:fromWalletId/:maxAmount/:minAmount/:toWalletId/:toAddress', + url: '/amount', views: { 'tab-send@tabs': { controller: 'amountController', @@ -306,7 +306,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }) .state('tabs.send.origin', { - url: '/origin/:thirdParty/:amount/:toAddress/:toWalletId/:coin', + url: '/origin', views: { 'tab-send@tabs': { controller: 'walletSelectorController', @@ -315,7 +315,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }) .state('tabs.send.destination', { - url: '/destination/:thirdParty/:amount/:fromWalletId', + url: '/destination', views: { 'tab-send@tabs': { controller: 'walletSelectorController', @@ -324,7 +324,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }) .state('tabs.send.confirm', { - url: '/confirm/:thirdParty/:amount/:fromWalletId/:toWalletId/:toAddress', + url: '/confirm', views: { 'tab-send@tabs': { controller: 'confirmController', diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index 76b5885d4..86c928a5e 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -106,10 +106,10 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat params.thirdParty.id = serviceId; params.thirdParty.data = serviceData; sendFlowService.pushState(params); - $state.transitionTo('tabs.send.amount', params); + $state.transitionTo('tabs.send.amount'); } else { sendFlowService.pushState(params); - $state.transitionTo('tabs.send.origin', params); + $state.transitionTo('tabs.send.origin'); } }, 100); } @@ -388,11 +388,13 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat 'notify': $state.current.name == 'tabs.send' ? false : true }); $timeout(function() { - $state.transitionTo('tabs.send.origin', { + var stateParams = { toAddress: toAddress, coin: coin, noPrefix: 1 - }); + }; + sendFlowService.pushState(stateParams); + $state.transitionTo('tabs.send.origin'); }, 100); } @@ -460,7 +462,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat }).then(function() { $timeout(function() { sendFlowService.pushState(stateParams); // Need to do more here - $state.transitionTo('tabs.send.origin', stateParams); + $state.transitionTo('tabs.send.origin'); }); }); } From 647e1261698eba7a9526d5abe93ff85a76ce2b3d Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 9 Aug 2018 12:49:35 +0900 Subject: [PATCH 304/386] Fix style css for the from wallet & activate the from wallet in the send tab --- src/js/controllers/tab-send.js | 3 ++ src/sass/views/tab-send.scss | 14 ++++---- www/css/main.css | 64 ++++++++++++---------------------- 3 files changed, 32 insertions(+), 49 deletions(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 55087859d..911548455 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -33,6 +33,9 @@ angular.module('copayApp.controllers').controller('tabSendController', function( text = text.substring(0, 200); } + var stateParams = sendFlowService.getState(); + $scope.fromWallet = profileService.getWallet(stateParams.fromWalletId); + $scope.clipboardHasAddress = false; $scope.clipboardHasContent = false; if ((text.indexOf('bitcoincash:') === 0 || text[0] === 'C' || text[0] === 'H' || text[0] === 'p' || text[0] === 'q') && text.replace('bitcoincash:', '').length === 42) { // CashAddr diff --git a/src/sass/views/tab-send.scss b/src/sass/views/tab-send.scss index 82b6f8d02..bf77984fd 100644 --- a/src/sass/views/tab-send.scss +++ b/src/sass/views/tab-send.scss @@ -2,15 +2,15 @@ @extend .deflash-blue; &-header{ - height: 300px; + //height: 300px; width: 100%; } &-contacts { - height: calc(100vh - 300px - 50px - 44px); /* screen size - button container - bottom-tab-menu - header top */ + //height: calc(100vh - 300px - 50px - 44px); /* screen size - button container - bottom-tab-menu - header top */ &.ios { - height: calc(100vh - 300px - 50px - 44px - 18px); // Remove the notification-bar height on iOS + //height: calc(100vh - 300px - 50px - 44px - 18px); // Remove the notification-bar height on iOS } - overflow: scroll; + //overflow: scroll; } .input { @@ -223,12 +223,12 @@ } } #tab-send-header { - height: 270px; + //height: 270px; } #tab-send-contacts { - height: calc(100vh - 270px - 50px - 44px); /* screen size - button container - bottom-tab-menu - header top */ + //height: calc(100vh - 270px - 50px - 44px); /* screen size - button container - bottom-tab-menu - header top */ &.ios { - height: calc(100vh - 270px - 50px - 44px - 18px); // Remove the notification-bar height on iOS + //height: calc(100vh - 270px - 50px - 44px - 18px); // Remove the notification-bar height on iOS } } } diff --git a/www/css/main.css b/www/css/main.css index 9845340ae..8602ba35d 100644 --- a/www/css/main.css +++ b/www/css/main.css @@ -11168,16 +11168,8 @@ qrcode { background-color: #fab915 !important; } #tab-send-header { - height: 300px; width: 100%; } -#tab-send-contacts { - height: calc(100vh - 300px - 50px - 44px); - /* screen size - button container - bottom-tab-menu - header top */ - overflow: scroll; } - #tab-send-contacts.ios { - height: calc(100vh - 300px - 50px - 44px - 18px); } - #tab-send .input { width: 100%; } #tab-send .input input { @@ -11358,14 +11350,7 @@ qrcode { #tab-send .send-wrapper .buttons .button-qr { height: 60px; } #tab-send .send-wrapper .buttons .button-qr span { - font-size: 16px; } - #tab-send #tab-send-header { - height: 270px; } - #tab-send #tab-send-contacts { - height: calc(100vh - 270px - 50px - 44px); - /* screen size - button container - bottom-tab-menu - header top */ } - #tab-send #tab-send-contacts.ios { - height: calc(100vh - 270px - 50px - 44px - 18px); } } + font-size: 16px; } } #wallet-origin-destination .header--request { padding: 30px 24px; @@ -15374,8 +15359,6 @@ log-options #check-bar .checkbox-icon { #view-review .fee-summary { position: absolute; bottom: 92px; } - #view-review .fee-summary-spacer { - height: 15px; } #view-review .shapeshift-banner, #view-review .bitpay-banner, #view-review .egifter-banner { box-shadow: none; } #view-review .warning { @@ -15551,31 +15534,28 @@ ion-content.padded-bottom-cta-with-summary { .fee-summary .amount .fee-crypto { color: #A7A7A7; } -.amount .start, -.amount .middle, -.amount .end, -.amount .currency { +.formatted-amount { display: inline-block; } - -.amount .start { - font-size: 1em; } - -.amount .middle { - font-size: 0.7857em; - margin-left: 5px; } - -.amount .end { - font-size: 0.7857em; - margin-left: 5px; } - -.amount.size-equal .middle, -.amount.size-equal .end { - font-size: 1em; } - -.amount .currency { - font-size: 1em; - margin-left: 5px; - text-transform: uppercase; } + .formatted-amount .start, + .formatted-amount .middle, + .formatted-amount .end, + .formatted-amount .currency { + display: inline-block; } + .formatted-amount .start { + font-size: 1em; } + .formatted-amount .middle { + font-size: 0.7857em; + margin-left: 5px; } + .formatted-amount .end { + font-size: 0.7857em; + margin-left: 5px; } + .formatted-amount.size-equal .middle, + .formatted-amount.size-equal .end { + font-size: 1em; } + .formatted-amount .currency { + font-size: 1em; + margin-left: 5px; + text-transform: uppercase; } /* This is for rules that don't yet have a home. * Our goal is to delete this file. Search the regex: /class=".*CLASS.*?"/ From a490f0ce1f42960fd87df7a3e561239fe5e42ee2 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 9 Aug 2018 13:06:52 +0900 Subject: [PATCH 305/386] dead code --- src/js/controllers/tab-send.js | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 911548455..81b3e4ca5 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -236,8 +236,6 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.displayBalanceAsFiat = _config.wallet.settings.priceDisplay === 'fiat'; }); - var state = sendFlowService.getState(); - if (data.direction == "back") { sendFlowService.clear(); } From 7ce562ec648746153ae86e95c989d7f791469baa Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 16:11:29 +1200 Subject: [PATCH 306/386] Fix for Shapeshift now appearing again on Review Transaction screen. --- src/js/controllers/review.controller.js | 8 +++----- src/js/controllers/shapeshift.js | 2 ++ 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 2b42339ce..0e5ceedce 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -88,11 +88,9 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit coin = vm.originWallet.coin; if (sendFlowData.thirdParty) { - // vm.thirdParty = JSON.parse(sendFlowData.thirdParty); // Parse stringified JSON-object - if (vm.thirdParty) { - handleThirdPartyInitIfBip70(); - handleThirdPartyInitIfShapeshift(); - } + vm.thirdParty = sendFlowData.thirdParty; + handleThirdPartyInitIfBip70(); + handleThirdPartyInitIfShapeshift(); } configService.get(function onConfig(err, configCache) { diff --git a/src/js/controllers/shapeshift.js b/src/js/controllers/shapeshift.js index 4ede8a94f..3538ebe1a 100644 --- a/src/js/controllers/shapeshift.js +++ b/src/js/controllers/shapeshift.js @@ -69,6 +69,8 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi } }; + // Starting new send flow, so ensure everything is reset + sendFlowService.clear(); $state.go('tabs.home').then(function() { $ionicHistory.clearHistory(); $state.go('tabs.send').then(function() { From 0ea97fc1c61fa3860e2eed4b80c202b3503c3d64 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 9 Aug 2018 13:14:44 +0900 Subject: [PATCH 307/386] Fix state pop on the send flow --- src/js/controllers/review.controller.js | 1 - src/js/controllers/walletSelectorController.js | 16 +++++++++++----- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 2b42339ce..70a349b37 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -398,7 +398,6 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } function goBack() { - sendFlowService.popState(); $ionicHistory.goBack(); } diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index f4448486f..74ed874d4 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -7,9 +7,16 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu var unitDecimals = 0; var unitsFromSatoshis = 0; - $scope.$on("$ionicView.beforeEnter", function(event, data) { + $scope.$on("$ionicView.beforeEnter", onBeforeEnter); + $scope.$on("$ionicView.enter", onEnter); + + function onBeforeEnter(event, data) { console.log('walletSelector onBeforeEnter sendflow', sendFlowService.getState()); + if (data.direction == "back") { + sendFlowService.popState(); + } + var stateParams = sendFlowService.getState(); var config = configService.getSync().wallet.settings; @@ -51,9 +58,9 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu if ($scope.params.thirdParty) { $scope.thirdParty = $scope.params.thirdParty; } - }); + }; - $scope.$on("$ionicView.enter", function(event, data) { + function onEnter (event, data) { configService.whenAvailable(function(config) { $scope.selectedPriceDisplay = config.wallet.settings.priceDisplay; }); @@ -65,7 +72,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu prepareWalletLists(); formatRequestedAmount(); - }); + }; function formatRequestedAmount() { if ($scope.params.amount) { @@ -197,7 +204,6 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu }; $scope.goBack = function() { - sendFlowService.popState(); $ionicHistory.goBack(); } From 77f62100760a60fb46d2d3e578d86dc6f900c15b Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 9 Aug 2018 13:15:21 +0900 Subject: [PATCH 308/386] Fix pop state on the send flow --- src/js/controllers/amount.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index d07f77c3f..b945be92c 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -68,6 +68,10 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, function onBeforeEnter(event, data) { console.log('amount onBeforeEnter sendflow ', sendFlowService.getState()); + if (data.direction == "back") { + sendFlowService.popState(); + } + initCurrencies(); passthroughParams = sendFlowService; @@ -210,7 +214,6 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, } function goBack() { - sendFlowService.popState(); $ionicHistory.goBack(); } From cbf66a2176224d8190d0eac14bb47a9c7983aaba Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 17:54:20 +1200 Subject: [PATCH 309/386] Fix for formatting amounts on Android 4.4. --- src/js/directives/formattedAmount.js | 48 ++++++++++++++++++++++++++-- 1 file changed, 45 insertions(+), 3 deletions(-) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index d3e2e6347..c0c341631 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -33,10 +33,15 @@ angular.module('bitcoincom.directives') '8': ['BCH', 'BTC'] }; var localizeNumbers = function(x, minimumFractionDigits) { - return parseFloat(x).toLocaleString(uxLanguage.getCurrentLanguage(), { + var parsed = parseFloat(x); + var opts = { minimumFractionDigits: minimumFractionDigits, useGrouping: true - }); + }; + var lang = uxLanguage.getCurrentLanguage(); + var localized = parsed.toLocaleString(lang, opts); + var corrected = ensureEnoughFractionalDigits(localized, x, minimumFractionDigits); + return corrected; }; var buildAmount = function(start, middle, end) { @@ -61,7 +66,6 @@ angular.module('bitcoincom.directives') }; var formatNumbers = function() { - // During watch, may be changed from having a separate currency value, // to both being in value. Don't want to use previous currency value. // Try to extract currency from value.. @@ -128,6 +132,44 @@ angular.module('bitcoincom.directives') $scope.$watchGroup(['currency', 'value'], function onFormattedAmountWatch() { formatNumbers(); }); + + /** + * On Android 4.4, toLocaleString() only returns 3 fractional digits when 8 is specified. + */ + function ensureEnoughFractionalDigits(localizedString, number, desiredFractionDigits) { + if (desiredFractionDigits === 0) { + // Assume it is OK + return localizedString; + } + var fractionalRe = /^(\d*\D)(\d+)$/; + var match = fractionalRe.exec(localizedString); + if (match.length !== 3) { + // Don't know what's happening, just return what we have + return localizedString; + } + + var decimals = match[2]; + var decimalCount = decimals.length; + if (decimalCount >= desiredFractionDigits) { + // Everything is OK. + return localizedString; + } + + if (typeof number !== 'number') { + number = parseFloat(number); + } + + var fixed = number.toFixed(desiredFractionDigits); + var fixedMatch = fractionalRe.exec(fixed); + if (fixedMatch.length !== 3) { + // Don't know what's happening, just return what we have + return localizedString; + } + + // Keeps locale decimal separator. + var enough = match[1] + fixedMatch[2]; + return enough; + } }); } }; From c68b1e77f66f22458c476d8af07c63ff38fc6e40 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 9 Aug 2018 15:09:43 +0900 Subject: [PATCH 310/386] clean controller and remove old firebase event --- src/js/controllers/backup.js | 5 +++-- src/js/controllers/confirm.js | 4 +--- src/js/controllers/create.js | 4 ++-- src/js/controllers/tab-home.js | 4 +--- src/js/routes.js | 7 ++++++- src/js/services/firebaseEventsService.js | 2 +- 6 files changed, 14 insertions(+), 12 deletions(-) diff --git a/src/js/controllers/backup.js b/src/js/controllers/backup.js index 0eec71f12..6ec7089c6 100644 --- a/src/js/controllers/backup.js +++ b/src/js/controllers/backup.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.controllers').controller('backupController', - function($scope, $timeout, $log, $state, $stateParams, $ionicHistory, lodash, profileService, bwcService, walletService, ongoingProcess, popupService, gettextCatalog, $ionicModal, firebaseEventsService) { + function($scope, $timeout, $log, $state, $stateParams, $ionicHistory, lodash, profileService, bwcService, walletService, ongoingProcess, popupService, gettextCatalog, $ionicModal) { if ($state.current.name == 'onboarding.backup') { $scope.onboarding = true; @@ -89,7 +89,8 @@ angular.module('copayApp.controllers').controller('backupController', $scope.setFlow(2); }) } else { - firebaseEventsService.logEvent('backed_up_wallet'); + + //firebaseEventsService.logEvent('backed_up_wallet'); openConfirmBackupModal(); } }; diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index c98064fcc..76950df73 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, $ionicLoading, ionicToast, addressbookService, gettextCatalog, walletService, platformInfo, lodash, configService, $stateParams, $window, $state, $log, profileService, bitcore, bitcoreCash, txFormatService, ongoingProcess, $ionicModal, popupService, $ionicHistory, $ionicConfig, payproService, feeService, bitcoinCashJsService, bwcError, txConfirmNotification, externalLinkService, firebaseEventsService, soundService, clipboardService) { +angular.module('copayApp.controllers').controller('confirmController', function($rootScope, $scope, $interval, $timeout, $ionicScrollDelegate, $ionicLoading, ionicToast, addressbookService, gettextCatalog, walletService, platformInfo, lodash, configService, $state, $log, profileService, bitcore, bitcoreCash, txFormatService, ongoingProcess, $ionicModal, popupService, $ionicHistory, $ionicConfig, feeService, bitcoinCashJsService, bwcError, txConfirmNotification, soundService, clipboardService) { var countDown = null; var FEE_TOO_HIGH_LIMIT_PER = 15; @@ -708,8 +708,6 @@ angular.module('copayApp.controllers').controller('confirmController', function( }], [channel, "adjust"]); window.BitAnalytics.LogEventHandlers.postEvent(log); - // Should be removed - firebaseEventsService.logEvent('sent_bitcoin', { coin: $scope.wallet.coin }); $timeout(function() { $scope.$digest(); }, 100); diff --git a/src/js/controllers/create.js b/src/js/controllers/create.js index a25300a4a..a21053e2d 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, gettextCatalog, ledger, trezor, intelTEE, derivationPathHelper, ongoingProcess, walletService, storageService, popupService, appConfigService, pushNotificationsService, firebaseEventsService, $ionicNavBarDelegate) { + function($scope, $timeout, $log, lodash, $state, $ionicScrollDelegate, $ionicHistory, profileService, configService, gettextCatalog, ledger, trezor, intelTEE, derivationPathHelper, ongoingProcess, walletService, popupService, appConfigService, pushNotificationsService, $ionicNavBarDelegate) { /* For compressed keys, m*73 + n*34 <= 496 */ var COPAYER_PAIR_LIMITS = { @@ -268,7 +268,7 @@ angular.module('copayApp.controllers').controller('createController', }, 100); } else { - firebaseEventsService.logEvent('wallet_created', { coin: opts.coin }); + //firebaseEventsService.logEvent('wallet_created', { coin: opts.coin }); $state.go('tabs.home'); } } diff --git a/src/js/controllers/tab-home.js b/src/js/controllers/tab-home.js index 3d63ae41f..32e320932 100644 --- a/src/js/controllers/tab-home.js +++ b/src/js/controllers/tab-home.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.controllers').controller('tabHomeController', - function($rootScope, sendFlowService, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, bannerService, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, storageService, txpModalService, appConfigService, startupService, addressbookService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { + function($rootScope, sendFlowService, $timeout, $scope, $state, $stateParams, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, bannerService, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, storageService, txpModalService, appConfigService, startupService, addressbookService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, $ionicNavBarDelegate) { var wallet; var listeners = []; var notifications = []; @@ -98,8 +98,6 @@ angular.module('copayApp.controllers').controller('tabHomeController', } $scope.showServices = true; - pushNotificationsService.init(); - firebaseEventsService.init(); $timeout(function() { $ionicScrollDelegate.resize(); diff --git a/src/js/routes.js b/src/js/routes.js index 5dbcbe6a3..b5a9c91fe 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -1207,7 +1207,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }); }) - .run(function($rootScope, $state, $location, $log, $timeout, startupService, ionicToast, fingerprintService, $ionicHistory, $ionicPlatform, $window, appConfigService, lodash, platformInfo, profileService, uxLanguage, gettextCatalog, openURLService, storageService, scannerService, configService, emailService, /* plugins START HERE => */ buydotbitcoindotcomService, glideraService, amazonService, bitpayCardService, applicationService, mercadoLibreService, rateService) { + .run(function($rootScope, $state, $location, $log, $timeout, startupService, ionicToast, fingerprintService, $ionicHistory, $ionicPlatform, $window, appConfigService, lodash, platformInfo, profileService, uxLanguage, gettextCatalog, openURLService, storageService, scannerService, configService, emailService, /* plugins START HERE => */ buydotbitcoindotcomService, pushNotificationsService, glideraService, amazonService, bitpayCardService, applicationService, mercadoLibreService, rateService) { $ionicPlatform.ready(function() { @@ -1231,6 +1231,11 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr } }); + configService.whenAvailable(function(config) { + pushNotificationsService.init(); + }); + //firebaseEventsService.init(); + var channel = "ga"; if (platformInfo.isCordova) { channel = "firebase"; diff --git a/src/js/services/firebaseEventsService.js b/src/js/services/firebaseEventsService.js index d81e682d7..d6ce6f1cc 100644 --- a/src/js/services/firebaseEventsService.js +++ b/src/js/services/firebaseEventsService.js @@ -1,5 +1,5 @@ 'use strict'; -angular.module('copayApp.services').factory('firebaseEventsService', function firebaseEventsService($log, $state, $ionicHistory, sjcl, platformInfo, lodash, appConfigService, profileService, configService) { +angular.module('copayApp.services').factory('firebaseEventsService', function firebaseEventsService($log, platformInfo) { var root = {}; var useEvents = platformInfo.isCordova && !platformInfo.isWP; From b742eadd4e1f24329326ea7ca5711f1013d7bd61 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 9 Aug 2018 15:13:29 +0900 Subject: [PATCH 311/386] clean and remove bug home --- src/js/controllers/tab-home.js | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/src/js/controllers/tab-home.js b/src/js/controllers/tab-home.js index 32e320932..b6fec52d4 100644 --- a/src/js/controllers/tab-home.js +++ b/src/js/controllers/tab-home.js @@ -20,7 +20,12 @@ angular.module('copayApp.controllers').controller('tabHomeController', $scope.bannerUrl = ''; - $scope.$on("$ionicView.afterEnter", function() { + $scope.$on("$ionicView.beforeEnter", onBeforeEnter); + $scope.$on("$ionicView.enter", onEnter); + $scope.$on("$ionicView.afterEnter", onAfterEnter); + $scope.$on("$ionicView.leave", onLeave); + + function onAfterEnter () { startupService.ready(); bannerService.getBanner(function (banner) { @@ -28,9 +33,9 @@ angular.module('copayApp.controllers').controller('tabHomeController', $scope.bannerUrl = banner.url; $scope.bannerIsLoading = false; }); - }); + }; - $scope.$on("$ionicView.beforeEnter", function(event, data) { + function onBeforeEnter (event, data) { if (!$scope.homeTip) { storageService.getHomeTipAccepted(function(error, value) { @@ -52,11 +57,10 @@ angular.module('copayApp.controllers').controller('tabHomeController', } }); } - }); - - $scope.$on("$ionicView.enter", function(event, data) { + }; + + function onEnter(event, data) { $ionicNavBarDelegate.showBar(true); - updateAllWallets(); addressbookService.list(function(err, ab) { if (err) $log.error(err); @@ -104,13 +108,13 @@ angular.module('copayApp.controllers').controller('tabHomeController', $scope.$apply(); }, 10); }); - }); + }; - $scope.$on("$ionicView.leave", function(event, data) { + function onLeave (event, data) { lodash.each(listeners, function(x) { x(); }); - }); + }; $scope.createdWithinPastDay = function(time) { return timeService.withinPastDay(time); From 9076ad209809c5feef52c7690eab1ef6a0fa2676 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 9 Aug 2018 15:35:03 +0900 Subject: [PATCH 312/386] add update wallet --- src/js/controllers/tab-home.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/js/controllers/tab-home.js b/src/js/controllers/tab-home.js index b6fec52d4..51d500de7 100644 --- a/src/js/controllers/tab-home.js +++ b/src/js/controllers/tab-home.js @@ -61,6 +61,7 @@ angular.module('copayApp.controllers').controller('tabHomeController', function onEnter(event, data) { $ionicNavBarDelegate.showBar(true); + updateAllWallets(); addressbookService.list(function(err, ab) { if (err) $log.error(err); From 4cf68076a01a0b3e27ff9286113e8c3f5c330066 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 9 Aug 2018 15:35:31 +0900 Subject: [PATCH 313/386] remove comment on bitanalytics --- bitanalytics/bitanalytics.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/bitanalytics/bitanalytics.js b/bitanalytics/bitanalytics.js index c8c0d8870..d04b2a0bd 100644 --- a/bitanalytics/bitanalytics.js +++ b/bitanalytics/bitanalytics.js @@ -6256,7 +6256,6 @@ var ClickAction = /** @class */ (function (_super) { // Add event listener to all the elements found for (var i = 0; i < elements.length; i++) { var element = elements[i]; - console.log('init ' + this.name); element.addEventListener('click', this.listener); } }; @@ -6413,7 +6412,6 @@ var AdjustChannel = /** @class */ (function (_super) { _this.eventTypes = config.eventTypes; var os = _this.adjustedOs(config.os); _this.advertisingId = _this.getAdvertisingId(os); - console.log('Advertising ID for adjust: ' + _this.advertisingId); // TODO: Different initialisation for Cordova. var sessionParams = { app_version: config.appVersion, @@ -6656,7 +6654,7 @@ var MixpanelChannel = /** @class */ (function (_super) { function MixpanelChannel(name, config) { var _this = _super.call(this, name) || this; if (!config.token) { - throw new DOMException('[BitAnalytics] Config incorrect.'); + throw new Error('[BitAnalytics] Config incorrect.'); } _this.mixpanelInstance = mixpanel; mixpanel.init(config.token, config.config); @@ -7037,7 +7035,7 @@ var LogEventHandlers = /** @class */ (function () { _this.channels.push(channel); } catch (error) { - console.log('[BitAnalytics] ' + error.name + ': ' + error.message); + console.log(error.message); } }); }; From de33fe58681546f6929dd15d46852aaeebd68784 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 18:58:21 +1200 Subject: [PATCH 314/386] Refactored formattedAmount. --- src/js/directives/formattedAmount.js | 333 ++++++++++++++------------- 1 file changed, 170 insertions(+), 163 deletions(-) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index c0c341631..cbe288fa5 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -1,5 +1,6 @@ 'use strict'; +(function(){ /** * @desc amount directive that can be used to display formatted financial values * size-equal attribute is optional, defaults to false. @@ -10,168 +11,174 @@ * @example * @example */ -angular.module('bitcoincom.directives') - .directive('formattedAmount', function(uxLanguage) { - return { - restrict: 'E', - scope: { - value: '@', - currency: '@', - sizeEqual: '@' - }, - templateUrl: 'views/includes/formatted-amount.html', - controller: function($scope, $timeout) { - $scope.canShow = false; - - $scope.displaySizeEqual = !!$scope.sizeEqual; - - $timeout(function onFormattedAmountTimeout() { - - var decimalPlaces = { - '0': ['BIF', 'CLP', 'DJF', 'GNF', 'ILS', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'UGX', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'], - '3': ['BHD', 'IQD', 'JOD', 'KWD', 'OMR', 'TND'], - '8': ['BCH', 'BTC'] - }; - var localizeNumbers = function(x, minimumFractionDigits) { - var parsed = parseFloat(x); - var opts = { - minimumFractionDigits: minimumFractionDigits, - useGrouping: true - }; - var lang = uxLanguage.getCurrentLanguage(); - var localized = parsed.toLocaleString(lang, opts); - var corrected = ensureEnoughFractionalDigits(localized, x, minimumFractionDigits); - return corrected; - }; - - var buildAmount = function(start, middle, end) { - $scope.start = start; - $scope.middle = middle; - $scope.end = end; - }; - - var getDecimalPlaces = function(currency) { - if (decimalPlaces['0'].indexOf(currency.toUpperCase()) > -1) return '0'; - if (decimalPlaces['3'].indexOf(currency.toUpperCase()) > -1) return '3'; - if (decimalPlaces['8'].indexOf(currency.toUpperCase()) > -1) return '8'; - return '2'; - }; - - var getDecimalSeparator = function() { - var testNum = 1.5; - var testString = testNum.toLocaleString(uxLanguage.getCurrentLanguage()); - // Some environments let you set decimal separators that are more than one character - var separator = /^1(.+)5$/.exec(testString)[1] - return separator; - }; - - var formatNumbers = function() { - // During watch, may be changed from having a separate currency value, - // to both being in value. Don't want to use previous currency value. - // Try to extract currency from value.. - var currencySplit = $scope.value.split(" "); - if (currencySplit.length === 2) { - $scope.currency = currencySplit[1]; - } - $scope.currency = $scope.currency || ''; - - - var parsed = parseFloat($scope.value); - var valueFormatted = ''; - var valueProcessing = ''; - switch (getDecimalPlaces($scope.currency)) { - case '0': - if (isNaN(parsed)) { - buildAmount('-', '', ''); - } else { - valueFormatted = localizeNumbers(Math.round(parsed), 0); - buildAmount(valueFormatted, '', ''); - } - break; - - case '3': - if (isNaN(parsed)) { - buildAmount('-' + getDecimalSeparator() + '---', '', ''); - } else { - valueProcessing = parsed.toFixed(3); - valueFormatted = localizeNumbers(valueProcessing, 3); - buildAmount(valueFormatted, '', ''); - } - break; - - case '8': - if (isNaN(parsed)) { - buildAmount('-' + getDecimalSeparator() + '---', '', ''); - } else if (parsed === 0) { - buildAmount('0', '', ''); - } else { - valueFormatted = parsed.toFixed(8); - valueFormatted = localizeNumbers(valueFormatted, 8); - var start = valueFormatted.slice(0, -5); - var middle = valueFormatted.slice(-5, -2); - var end = valueFormatted.substr(valueFormatted.length - 2); - buildAmount(start, middle, end); - - } - break; - - default: // 2 - if (isNaN(parsed)) { - buildAmount('-' + getDecimalSeparator() + '--', '', ''); - } else { - valueProcessing = parseFloat(parsed.toFixed(2)); - valueFormatted = localizeNumbers(valueProcessing, 2); - buildAmount(valueFormatted, '', ''); - } - break; - } - $scope.canShow = true; - }; - - formatNumbers(); - $scope.$watchGroup(['currency', 'value'], function onFormattedAmountWatch() { - formatNumbers(); - }); - - /** - * On Android 4.4, toLocaleString() only returns 3 fractional digits when 8 is specified. - */ - function ensureEnoughFractionalDigits(localizedString, number, desiredFractionDigits) { - if (desiredFractionDigits === 0) { - // Assume it is OK - return localizedString; - } - var fractionalRe = /^(\d*\D)(\d+)$/; - var match = fractionalRe.exec(localizedString); - if (match.length !== 3) { - // Don't know what's happening, just return what we have - return localizedString; - } - - var decimals = match[2]; - var decimalCount = decimals.length; - if (decimalCount >= desiredFractionDigits) { - // Everything is OK. - return localizedString; - } - - if (typeof number !== 'number') { - number = parseFloat(number); - } - - var fixed = number.toFixed(desiredFractionDigits); - var fixedMatch = fractionalRe.exec(fixed); - if (fixedMatch.length !== 3) { - // Don't know what's happening, just return what we have - return localizedString; - } - - // Keeps locale decimal separator. - var enough = match[1] + fixedMatch[2]; - return enough; - } - }); + angular + .module('bitcoincom.directives') + .directive('formattedAmount', function() { + return { + restrict: 'E', + scope: { + value: '@', + currency: '@', + sizeEqual: '@' + }, + templateUrl: 'views/includes/formatted-amount.html', + controller: formattedAmountController } - }; + }); + + function formattedAmountController($scope, $timeout, uxLanguage) { + $scope.canShow = false; + + $scope.displaySizeEqual = !!$scope.sizeEqual; + + $timeout(function onFormattedAmountTimeout() { + + var decimalPlaces = { + '0': ['BIF', 'CLP', 'DJF', 'GNF', 'ILS', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'UGX', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'], + '3': ['BHD', 'IQD', 'JOD', 'KWD', 'OMR', 'TND'], + '8': ['BCH', 'BTC'] + }; + + formatNumbers(); + $scope.$watchGroup(['currency', 'value'], function onFormattedAmountWatch() { + formatNumbers(); + }); + + function buildAmount(start, middle, end) { + $scope.start = start; + $scope.middle = middle; + $scope.end = end; + }; + + /** + * On Android 4.4, toLocaleString() only returns 3 fractional digits when 8 is specified. + */ + function ensureEnoughFractionDigits(localizedString, number, desiredFractionDigits) { + if (desiredFractionDigits === 0) { + // Assume it is OK + return localizedString; + } + var fractionalRe = /^-*(\d*\D)(\d+)$/; + var match = fractionalRe.exec(localizedString); + if (!match || match.length !== 3) { + // Don't know what's happening, just return what we have + return localizedString; + } + + var decimals = match[2]; + var decimalCount = decimals.length; + if (decimalCount >= desiredFractionDigits) { + // Everything is OK. + return localizedString; + } + + if (typeof number !== 'number') { + number = parseFloat(number); + } + + var fixed = number.toFixed(desiredFractionDigits); + var fixedMatch = fractionalRe.exec(fixed); + if (!fixedMatch || fixedMatch.length !== 3) { + // Don't know what's happening, just return what we have + return localizedString; + } + + // Keeps locale decimal separator. + var enough = match[1] + fixedMatch[2]; + return enough; + } + + function formatNumbers() { + // During watch, may be changed from having a separate currency value, + // to both being in value. Don't want to use previous currency value. + // Try to extract currency from value.. + var currencySplit = $scope.value.split(" "); + if (currencySplit.length === 2) { + $scope.currency = currencySplit[1]; + } + $scope.currency = $scope.currency || ''; + + + var parsed = parseFloat($scope.value); + var valueFormatted = ''; + var valueProcessing = ''; + switch (getDecimalPlaces($scope.currency)) { + case '0': + if (isNaN(parsed)) { + buildAmount('-', '', ''); + } else { + valueFormatted = localizeNumbers(Math.round(parsed), 0); + buildAmount(valueFormatted, '', ''); + } + break; + + case '3': + if (isNaN(parsed)) { + buildAmount('-' + getDecimalSeparator() + '---', '', ''); + } else { + valueProcessing = parsed.toFixed(3); + valueFormatted = localizeNumbers(valueProcessing, 3); + buildAmount(valueFormatted, '', ''); + } + break; + + case '8': + if (isNaN(parsed)) { + buildAmount('-' + getDecimalSeparator() + '---', '', ''); + } else if (parsed === 0) { + buildAmount('0', '', ''); + } else { + valueFormatted = parsed.toFixed(8); + valueFormatted = localizeNumbers(valueFormatted, 8); + var start = valueFormatted.slice(0, -5); + var middle = valueFormatted.slice(-5, -2); + var end = valueFormatted.substr(valueFormatted.length - 2); + buildAmount(start, middle, end); + + } + break; + + default: // 2 + if (isNaN(parsed)) { + buildAmount('-' + getDecimalSeparator() + '--', '', ''); + } else { + valueProcessing = parseFloat(parsed.toFixed(2)); + valueFormatted = localizeNumbers(valueProcessing, 2); + buildAmount(valueFormatted, '', ''); + } + break; + } + $scope.canShow = true; + }; + + function getDecimalPlaces(currency) { + if (decimalPlaces['0'].indexOf(currency.toUpperCase()) > -1) return '0'; + if (decimalPlaces['3'].indexOf(currency.toUpperCase()) > -1) return '3'; + if (decimalPlaces['8'].indexOf(currency.toUpperCase()) > -1) return '8'; + return '2'; + }; + + function getDecimalSeparator() { + var testNum = 1.5; + var testString = testNum.toLocaleString(uxLanguage.getCurrentLanguage()); + // Some environments let you set decimal separators that are more than one character + var separator = /^1(.+)5$/.exec(testString)[1] + return separator; + }; + + function localizeNumbers(x, minimumFractionDigits) { + var parsed = parseFloat(x); + var opts = { + minimumFractionDigits: minimumFractionDigits, + useGrouping: true + }; + var lang = uxLanguage.getCurrentLanguage(); + var localized = parsed.toLocaleString(lang, opts); + var corrected = ensureEnoughFractionDigits(localized, x, minimumFractionDigits); + return corrected; + }; + + }); } -); \ No newline at end of file + +})(); \ No newline at end of file From ac8cdcf5be83bf28f87ed0f76b3308318cd92652 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 9 Aug 2018 18:59:03 +1200 Subject: [PATCH 315/386] Android 4.4 fix for Amount screen, removal of  . --- www/views/amount.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/www/views/amount.html b/www/views/amount.html index 57a8e46ce..bceda146f 100644 --- a/www/views/amount.html +++ b/www/views/amount.html @@ -37,14 +37,14 @@
- Available Funds: + Available Funds:
From 420305cf017555a82db7513feb1342500ea94e90 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 9 Aug 2018 10:15:55 +0200 Subject: [PATCH 316/386] shapeshift moved to default services and communities fix --- src/js/controllers/tab-home.js | 4 ++-- src/js/services/servicesService.js | 7 ++++++- src/js/services/shapeshiftService.js | 12 ------------ 3 files changed, 8 insertions(+), 15 deletions(-) diff --git a/src/js/controllers/tab-home.js b/src/js/controllers/tab-home.js index 51d500de7..9a8c28b9a 100644 --- a/src/js/controllers/tab-home.js +++ b/src/js/controllers/tab-home.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.controllers').controller('tabHomeController', - function($rootScope, sendFlowService, $timeout, $scope, $state, $stateParams, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, bannerService, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, storageService, txpModalService, appConfigService, startupService, addressbookService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, $ionicNavBarDelegate) { + function($rootScope, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, bannerService, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, sendFlowService, storageService, txpModalService, appConfigService, startupService, addressbookService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { var wallet; var listeners = []; var notifications = []; @@ -58,7 +58,7 @@ angular.module('copayApp.controllers').controller('tabHomeController', }); } }; - + function onEnter(event, data) { $ionicNavBarDelegate.showBar(true); updateAllWallets(); diff --git a/src/js/services/servicesService.js b/src/js/services/servicesService.js index f2344dd01..316009957 100644 --- a/src/js/services/servicesService.js +++ b/src/js/services/servicesService.js @@ -1,7 +1,12 @@ 'use strict' angular.module('copayApp.services').factory('servicesService', function(configService, $log, lodash) { var root = {}; - var services = []; + var services = [{ + name: 'shapeshift', + title: 'Shapeshift', + icon: 'icon-shapeshift', + sref: 'tabs.shapeshift', + }]; root.register = function(serviceInfo) { $log.info('Adding Services entry:' + serviceInfo.name); diff --git a/src/js/services/shapeshiftService.js b/src/js/services/shapeshiftService.js index 7cf6b4e03..1ce9672ce 100644 --- a/src/js/services/shapeshiftService.js +++ b/src/js/services/shapeshiftService.js @@ -137,17 +137,5 @@ angular.module('copayApp.services').factory('shapeshiftService', function ($http }); }; - var servicesItem = { - name: 'shapeshift', - title: 'Shapeshift', - icon: 'icon-shapeshift', - sref: 'tabs.shapeshift', - }; - - var register = function() { - servicesService.register(servicesItem); - }; - - register(); return root; }); From 25965f626874c5e1c2cc6d0ece67795682e5e4f5 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 9 Aug 2018 10:17:29 +0200 Subject: [PATCH 317/386] shapeshift moved to default services and communities fix --- src/js/controllers/tab-home.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/controllers/tab-home.js b/src/js/controllers/tab-home.js index 9a8c28b9a..9c4f2bee9 100644 --- a/src/js/controllers/tab-home.js +++ b/src/js/controllers/tab-home.js @@ -1,7 +1,7 @@ 'use strict'; angular.module('copayApp.controllers').controller('tabHomeController', - function($rootScope, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, bannerService, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, sendFlowService, storageService, txpModalService, appConfigService, startupService, addressbookService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { + function($rootScope, $timeout, $scope, $state, $stateParams, $ionicModal, $ionicScrollDelegate, $window, gettextCatalog, lodash, popupService, ongoingProcess, bannerService, communityService, externalLinkService, latestReleaseService, profileService, walletService, configService, $log, platformInfo, sendFlowService, storageService, txpModalService, appConfigService, startupService, addressbookService, bwcError, nextStepsService, buyAndSellService, homeIntegrationsService, bitpayCardService, pushNotificationsService, timeService, bitcoincomService, pricechartService, firebaseEventsService, servicesService, shapeshiftService, $ionicNavBarDelegate, signVerifyMessageService) { var wallet; var listeners = []; var notifications = []; From ee0042b6e7c6efe5442aa3f3885cd4ae1be2c7f2 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Thu, 9 Aug 2018 13:39:27 +0200 Subject: [PATCH 318/386] sendMax bugfix when returning to previous screen --- src/js/controllers/amount.js | 14 ++++++++++---- src/js/controllers/review.controller.js | 2 +- www/views/amount.html | 2 +- 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 73ebfd150..8e458045e 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -29,6 +29,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, vm.finish = finish; vm.goBack = goBack; vm.loadMore = loadMore; + vm.next = next; vm.openPopup = openPopup; vm.pushDigit = pushDigit; vm.removeDigit = removeDigit; @@ -478,7 +479,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, // Currency - var next = 10; + var nextCurrencies = 10; var completeAlternativeList = []; var popularCurrencyList = [ @@ -537,12 +538,17 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, function loadMore() { $timeout(function() { - vm.altCurrencyList = completeAlternativeList.slice(0, next); - next += 10; + vm.altCurrencyList = completeAlternativeList.slice(0, nextCurrencies); + nextCurrencies += 10; vm.listComplete = vm.altCurrencyList.length >= completeAlternativeList.length; $scope.$broadcast('scroll.infiniteScrollComplete'); }, 100); - }; + } + + function next() { + useSendMax = false; + vm.finish(); + } function findCurrency(search) { if (!search) initCurrencies(); diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index a3b015348..afe3cd97d 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -223,7 +223,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit // Grab stateParams tx = { amount: parseInt(sendFlowData.amount), - sendMax: sendFlowData.sendMax === 'true' ? true : false, + sendMax: sendFlowData.sendMax, fromWalletId: sendFlowData.fromWalletId, toAddress: sendFlowData.toAddress, paypro: txPayproData, diff --git a/www/views/amount.html b/www/views/amount.html index bceda146f..8d263eae3 100644 --- a/www/views/amount.html +++ b/www/views/amount.html @@ -90,7 +90,7 @@ +
From afb3a1d49fe7115cd339f19e7e13da370c668333 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 10 Aug 2018 12:46:00 +1200 Subject: [PATCH 321/386] wallet-balance directive displaying basic crypto balance. --- src/js/directives/walletBalanceDirective.js | 88 +++++++++++++++++++++ src/sass/components/components.scss | 1 + src/sass/components/wallet-balance.scss | 3 + www/views/includes/wallet-balance.html | 3 + www/views/tab-send.html | 3 +- 5 files changed, 97 insertions(+), 1 deletion(-) create mode 100644 src/js/directives/walletBalanceDirective.js create mode 100644 src/sass/components/wallet-balance.scss create mode 100644 www/views/includes/wallet-balance.html diff --git a/src/js/directives/walletBalanceDirective.js b/src/js/directives/walletBalanceDirective.js new file mode 100644 index 000000000..aaf9de99b --- /dev/null +++ b/src/js/directives/walletBalanceDirective.js @@ -0,0 +1,88 @@ +'use strict'; + +(function(){ + + angular + .module('bitcoincom.directives') + .directive('walletBalance', function() { + return { + restrict: 'E', + scope: { + displayAsFiat: '@', + totalBalanceSat: '@', + wallet: '@' + }, + templateUrl: 'views/includes/wallet-balance.html', + controller: walletBalanceController + } + }); + + function walletBalanceController($log, $scope, $timeout, uxLanguage) { + console.log('walletBalanceController'); + var cryptoBalanceHasBeenDisplayed = false; + + formatBalance(); + $scope.$watchGroup(['displayAsFiat', 'totalBalanceSat'], function onWalletBalanceWatch() { + formatBalance(); + }); + + function displayCryptoBalance(wallet) { + console.log('displayCryptoBalance()'); + if (wallet.status) { + if (wallet.status.totalBalanceStr) { + $scope.displayAmount = wallet.status.totalBalanceStr; + $scope.cachedBalanceUpdatedOn = ''; + console.log('Displaying wallet.status.totalBalanceStr'); + + } else if (wallet.status.cachedBalance) { + $scope.displayAmount = wallet.status.cachedBalance; + $scope.cachedBalanceUpdatedOn = wallet.status.cachedBalanceUpdatedOn; + console.log('Displaying wallet.status.cachedBalance'); + + } else { + $scope.displayAmount = ''; + $scope.cachedBalanceUpdatedOn = ''; + console.log('Displaying "" from status'); + } + } else if (wallet.cachedBalance) { + $scope.displayAmount = cachedBalance; + $scope.cachedBalanceUpdatedOn = ''; + console.log('Displaying cachedBalance'); + + } else { + $scope.displayAmount = ''; + $scope.cachedBalanceUpdatedOn = ''; + console.log('Displaying "" without status'); + } + cryptoBalanceHasBeenDisplayed = true; + } + + function displayFiatBalance(wallet) { + + } + + function formatBalance() { + //console.log('formatBalance() with wallet:', $scope.wallet,); + console.log('formatBalance() with displayAsFiat: "' + $scope.displayAsFiat + '"'); + var wallet = null; + try { + wallet = JSON.parse($scope.wallet); + } catch (e) { + $log.error('Error parsing wallet to display balance.', e); + $scope.displayAmount = ''; + $scope.cachedBalanceUpdatedOn = ''; + } + + if (!$scope.displayAsFiat || $scope.displayAsFiat && !cryptoBalanceHasBeenDisplayed) { + displayCryptoBalance(wallet); + } + + if ($scope.displayAsFiat) { + displayFiatBalance(wallet); + } + + + } + } +})(); + diff --git a/src/sass/components/components.scss b/src/sass/components/components.scss index fb53508b0..4d2bd695e 100644 --- a/src/sass/components/components.scss +++ b/src/sass/components/components.scss @@ -9,3 +9,4 @@ @import "expand-content"; @import "fee-summary"; @import "formatted-amount"; +@import "wallet-balance"; diff --git a/src/sass/components/wallet-balance.scss b/src/sass/components/wallet-balance.scss new file mode 100644 index 000000000..faf4e8611 --- /dev/null +++ b/src/sass/components/wallet-balance.scss @@ -0,0 +1,3 @@ +.wallet-balance-directive { + display: inline-block; +} \ No newline at end of file diff --git a/www/views/includes/wallet-balance.html b/www/views/includes/wallet-balance.html new file mode 100644 index 000000000..0cd1ee659 --- /dev/null +++ b/www/views/includes/wallet-balance.html @@ -0,0 +1,3 @@ +
+ {{displayAmount}}{{· (cachedBalanceUpdatedOn * 1000 | amTimeAgo)}} +
\ No newline at end of file diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 3378b53ed..236c3db6f 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -16,8 +16,9 @@ >

{{fromWallet.name}}

+ - +
From 355ed27b87accb55bc22901366b57666649744ce Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 10 Aug 2018 13:04:44 +1200 Subject: [PATCH 322/386] wallet balance directive displaying fiat balance from wallet status. --- src/js/directives/walletBalanceDirective.js | 62 ++++++++++++--------- www/views/includes/wallet-balance.html | 2 +- 2 files changed, 37 insertions(+), 27 deletions(-) diff --git a/src/js/directives/walletBalanceDirective.js b/src/js/directives/walletBalanceDirective.js index aaf9de99b..a13d30a98 100644 --- a/src/js/directives/walletBalanceDirective.js +++ b/src/js/directives/walletBalanceDirective.js @@ -28,37 +28,41 @@ function displayCryptoBalance(wallet) { console.log('displayCryptoBalance()'); - if (wallet.status) { - if (wallet.status.totalBalanceStr) { - $scope.displayAmount = wallet.status.totalBalanceStr; - $scope.cachedBalanceUpdatedOn = ''; - console.log('Displaying wallet.status.totalBalanceStr'); - } else if (wallet.status.cachedBalance) { - $scope.displayAmount = wallet.status.cachedBalance; - $scope.cachedBalanceUpdatedOn = wallet.status.cachedBalanceUpdatedOn; - console.log('Displaying wallet.status.cachedBalance'); - - } else { - $scope.displayAmount = ''; - $scope.cachedBalanceUpdatedOn = ''; - console.log('Displaying "" from status'); - } - } else if (wallet.cachedBalance) { - $scope.displayAmount = cachedBalance; - $scope.cachedBalanceUpdatedOn = ''; - console.log('Displaying cachedBalance'); - - } else { - $scope.displayAmount = ''; - $scope.cachedBalanceUpdatedOn = ''; - console.log('Displaying "" without status'); + if (wallet.status && wallet.status.totalBalanceStr) { + setDisplay(wallet.status.totalBalanceStr, ''); + cryptoBalanceHasBeenDisplayed = true; + return; } - cryptoBalanceHasBeenDisplayed = true; + + if (wallet.cachedBalance) { + setDisplay(wallet.cachedBalance, wallet.cachedBalanceUpdatedOn); + return; + } + + if (wallet.cachedStatus && wallet.cachedStatus.totalBalanceStr) { + setDisplay(wallet.cachedStatus.totalBalanceStr, ''); + return; + } + + setDisplay('', ''); } function displayFiatBalance(wallet) { - + var displayAmount = ''; + if (wallet.status && wallet.status.alternativeBalanceAvailable) { + displayAmount = wallet.status.totalBalanceAlternative + ' ' + wallet.status.alternativeIsoCode; + setDisplay(displayAmount, ''); + return; + } + + if (wallet.cachedStatus && wallet.cachedStatus.alternativeBalanceAvailable) { + displayAmount = wallet.cachedStatus.totalBalanceAlternative + ' ' + wallet.cachedStatus.alternativeIsoCode; + setDisplay(displayAmount, ''); + return; + } + + getFiatBalance(wallet); } function formatBalance() { @@ -80,8 +84,14 @@ if ($scope.displayAsFiat) { displayFiatBalance(wallet); } + } + function getFiatBalance(wallet) { + } + function setDisplay(amount, cachedBalanceUpdatedOn) { + $scope.displayAmount = amount; + $scope.cachedBalanceUpdatedOn = cachedBalanceUpdatedOn; } } })(); diff --git a/www/views/includes/wallet-balance.html b/www/views/includes/wallet-balance.html index 0cd1ee659..03baa8cac 100644 --- a/www/views/includes/wallet-balance.html +++ b/www/views/includes/wallet-balance.html @@ -1,3 +1,3 @@ -
+
{{displayAmount}}{{· (cachedBalanceUpdatedOn * 1000 | amTimeAgo)}}
\ No newline at end of file From d7285a72e46858c559e38180b118e93590ca07da Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 10 Aug 2018 13:26:12 +1200 Subject: [PATCH 323/386] wallet-balance directive retrieves alternative amount when needed. --- src/js/directives/walletBalanceDirective.js | 26 +++++++++++++-------- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/src/js/directives/walletBalanceDirective.js b/src/js/directives/walletBalanceDirective.js index a13d30a98..d318b370d 100644 --- a/src/js/directives/walletBalanceDirective.js +++ b/src/js/directives/walletBalanceDirective.js @@ -17,8 +17,7 @@ } }); - function walletBalanceController($log, $scope, $timeout, uxLanguage) { - console.log('walletBalanceController'); + function walletBalanceController($log, $scope, txFormatService) { var cryptoBalanceHasBeenDisplayed = false; formatBalance(); @@ -29,7 +28,7 @@ function displayCryptoBalance(wallet) { console.log('displayCryptoBalance()'); - if (wallet.status && wallet.status.totalBalanceStr) { + if (wallet.status && wallet.status.isValid && wallet.status.totalBalanceStr) { setDisplay(wallet.status.totalBalanceStr, ''); cryptoBalanceHasBeenDisplayed = true; return; @@ -40,7 +39,7 @@ return; } - if (wallet.cachedStatus && wallet.cachedStatus.totalBalanceStr) { + if (wallet.cachedStatus && wallet.status.isValid && wallet.cachedStatus.totalBalanceStr) { setDisplay(wallet.cachedStatus.totalBalanceStr, ''); return; } @@ -50,13 +49,13 @@ function displayFiatBalance(wallet) { var displayAmount = ''; - if (wallet.status && wallet.status.alternativeBalanceAvailable) { + if (wallet.status && wallet.status.isValid && wallet.status.alternativeBalanceAvailable) { displayAmount = wallet.status.totalBalanceAlternative + ' ' + wallet.status.alternativeIsoCode; setDisplay(displayAmount, ''); return; } - if (wallet.cachedStatus && wallet.cachedStatus.alternativeBalanceAvailable) { + if (wallet.cachedStatus && wallet.cachedStatus.isValid && wallet.cachedStatus.alternativeBalanceAvailable) { displayAmount = wallet.cachedStatus.totalBalanceAlternative + ' ' + wallet.cachedStatus.alternativeIsoCode; setDisplay(displayAmount, ''); return; @@ -66,15 +65,12 @@ } function formatBalance() { - //console.log('formatBalance() with wallet:', $scope.wallet,); - console.log('formatBalance() with displayAsFiat: "' + $scope.displayAsFiat + '"'); var wallet = null; try { wallet = JSON.parse($scope.wallet); } catch (e) { $log.error('Error parsing wallet to display balance.', e); - $scope.displayAmount = ''; - $scope.cachedBalanceUpdatedOn = ''; + setDisplay('', ''); } if (!$scope.displayAsFiat || $scope.displayAsFiat && !cryptoBalanceHasBeenDisplayed) { @@ -87,6 +83,16 @@ } function getFiatBalance(wallet) { + if (!(wallet.status && wallet.status.isValid)) { + $log.warn('Abandoning call to get fiat balance, because no valid wallet status.'); + return; + } + + txFormatService.formatAlternativeStr(wallet.coin, wallet.status.totalBalanceSat, function onFormatAlernativeStr(formatted) { + if (formatted) { + setDisplay(formatted, ''); + } + }); } function setDisplay(amount, cachedBalanceUpdatedOn) { From 82ede65363e42463926eb655b65d12e6b3f82a10 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 10 Aug 2018 10:43:54 +0900 Subject: [PATCH 324/386] New decimal on the review screen --- www/views/review.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/www/views/review.html b/www/views/review.html index 1eb648a01..db6d279d4 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -11,8 +11,8 @@

{{vm.sendingTitle}}

-

{{vm.primaryAmount}} {{vm.primaryCurrency}}

-

{{vm.secondaryAmount}} {{vm.secondaryCurrency}}

+

+

From 82c0746ff808555e040f6e5b2a11eb5b7b63c57a Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 10 Aug 2018 13:48:59 +1200 Subject: [PATCH 325/386] wallet-balance directive uses formatted-amount. --- src/js/directives/walletBalanceDirective.js | 6 ++++-- www/views/includes/wallet-balance.html | 2 +- www/views/tab-send.html | 2 +- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/js/directives/walletBalanceDirective.js b/src/js/directives/walletBalanceDirective.js index d318b370d..5b2a41b6c 100644 --- a/src/js/directives/walletBalanceDirective.js +++ b/src/js/directives/walletBalanceDirective.js @@ -65,19 +65,21 @@ } function formatBalance() { + var displayAsFiat = $scope.displayAsFiat === 'true'; var wallet = null; try { wallet = JSON.parse($scope.wallet); } catch (e) { $log.error('Error parsing wallet to display balance.', e); setDisplay('', ''); + return; } - if (!$scope.displayAsFiat || $scope.displayAsFiat && !cryptoBalanceHasBeenDisplayed) { + if (!displayAsFiat || displayAsFiat && !cryptoBalanceHasBeenDisplayed) { displayCryptoBalance(wallet); } - if ($scope.displayAsFiat) { + if (displayAsFiat) { displayFiatBalance(wallet); } } diff --git a/www/views/includes/wallet-balance.html b/www/views/includes/wallet-balance.html index 03baa8cac..0818bf343 100644 --- a/www/views/includes/wallet-balance.html +++ b/www/views/includes/wallet-balance.html @@ -1,3 +1,3 @@
- {{displayAmount}}{{· (cachedBalanceUpdatedOn * 1000 | amTimeAgo)}} + {{· (cachedBalanceUpdatedOn * 1000 | amTimeAgo)}}
\ No newline at end of file diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 236c3db6f..a4051b8f1 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -16,7 +16,7 @@ >

{{fromWallet.name}}

- +
From b70bd804dc09c40b430daf9664da1d2ec359c7dc Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 10 Aug 2018 10:56:01 +0900 Subject: [PATCH 326/386] crypto decimal --- www/views/review.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/views/review.html b/www/views/review.html index db6d279d4..f2970da51 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -89,7 +89,7 @@
Fee: Less than 1 cent
Fee: {{vm.feeFiat}} {{vm.feeCurrency}}
- {{vm.feeCrypto}} {{vm.origin.currency}} +
From 4c9ff1b28b65323e285a8d5fbf1d702f18820e0f Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 10 Aug 2018 11:11:53 +0900 Subject: [PATCH 327/386] Handle error in the review screen --- src/js/controllers/review.controller.js | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index afe3cd97d..d41d4a9b0 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -116,7 +116,9 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit if (!tx || !vm.originWallet) return; if (vm.paymentExpired) { - popupService.showAlert(null, gettextCatalog.getString('This bitcoin payment request has expired.')); + popupService.showAlert(null, gettextCatalog.getString('This bitcoin payment request has expired.', function () { + $ionicHistory.goBack(); + })); vm.sendStatus = ''; $timeout(function() { $scope.$apply(); @@ -486,20 +488,26 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit walletService.getAddress(vm.originWallet, false, function onReturnWalletAddress(err, returnAddr) { if (err) { ongoingProcess.set('connectingShapeshift', false); - popupService.showAlert(gettextCatalog.getString('Shapeshift Error'), err.toString()); + popupService.showAlert(gettextCatalog.getString('Shapeshift Error'), err.toString(), function () { + $ionicHistory.goBack(); + }); return; } walletService.getAddress(toWallet, false, function onWithdrawalWalletAddress(err, withdrawalAddr) { if (err) { ongoingProcess.set('connectingShapeshift', false); - popupService.showAlert(gettextCatalog.getString('Shapeshift Error'), err.toString()); + popupService.showAlert(gettextCatalog.getString('Shapeshift Error'), err.toString(), function () { + $ionicHistory.goBack(); + }); return; } shapeshiftService.shiftIt(vm.originWallet.coin, toWallet.coin, withdrawalAddr, returnAddr, function onShiftIt(err, shapeshiftData) { if (err && err != null) { ongoingProcess.set('connectingShapeshift', false); - popupService.showAlert(gettextCatalog.getString('Shapeshift Error'), err.toString()); + popupService.showAlert(gettextCatalog.getString('Shapeshift Error'), err.toString(), function () { + $ionicHistory.goBack(); + }); } else { vm.memo = 'ShapeShift Order:\nhttps://www.shapeshift.io/#/status/' + shapeshiftData.orderId; vm.memoExpanded = !!vm.memo; @@ -640,7 +648,9 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit $timeout(function() { $scope.$apply(); }); - popupService.showAlert(gettextCatalog.getString('Error at confirm'), bwcError.msg(msg)); + popupService.showAlert(gettextCatalog.getString('Error at confirm'), bwcError.msg(msg), function () { + $ionicHistory.goBack(); + }); }; function setupTx(tx) { @@ -825,7 +835,9 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit if (tx.sendMax && sendMaxInfo.amount == 0) { ongoingProcess.set('calculatingFee', false); setNotReady(gettextCatalog.getString('Insufficient confirmed funds')); - popupService.showAlert(gettextCatalog.getString('Error'), gettextCatalog.getString('Not enough funds for fee')); + popupService.showAlert(gettextCatalog.getString('Error'), gettextCatalog.getString('Not enough funds for fee'), function () { + $ionicHistory.goBack(); + }); return cb('no_funds'); } From 18c8f4cf07929d0cab601964ded35f7cf2ff78f5 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 10 Aug 2018 14:17:42 +1200 Subject: [PATCH 328/386] formatted-amount for transaction proposals and wallet activity. --- www/views/includes/txp.html | 2 +- www/views/includes/walletActivity.html | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/www/views/includes/txp.html b/www/views/includes/txp.html index 4a1f07aaf..82391bfa2 100644 --- a/www/views/includes/txp.html +++ b/www/views/includes/txp.html @@ -24,7 +24,7 @@ (possible double spend) - – {{tx.amountStr}} + –
diff --git a/www/views/includes/walletActivity.html b/www/views/includes/walletActivity.html index 3a2b78ab1..e1fdb504f 100644 --- a/www/views/includes/walletActivity.html +++ b/www/views/includes/walletActivity.html @@ -10,7 +10,7 @@
Payment Sent
- {{notification.amountStr}} +
@@ -19,7 +19,7 @@
Payment Received
- {{notification.amountStr}} +
@@ -27,7 +27,7 @@ Proposal Deleted: {{notification.message}}
- {{notification.amountStr}}: + :
@@ -35,7 +35,7 @@ Proposal Rejected: {{notification.message}}
- {{notification.amountStr}}: + :
@@ -43,7 +43,7 @@ New Proposal: {{notification.message}}
- {{notification.amountStr}} +
@@ -51,7 +51,7 @@ Proposal Accepted: {{notification.message}}
- {{notification.amountStr}} +
From 0410ad149109f7e458f11d6f1c2f81d3eacc2c35 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 10 Aug 2018 11:21:29 +0900 Subject: [PATCH 329/386] Add tracking shapeshift --- src/js/routes.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/js/routes.js b/src/js/routes.js index b5a9c91fe..d2b78aac3 100644 --- a/src/js/routes.js +++ b/src/js/routes.js @@ -1277,6 +1277,13 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr }); window.BitAnalytics.ActionHandlers.trackAction(actionTabOpen); + var actionShapeShiftStart = new window.BitAnalytics.ActionFactory.createAction('click', { + name: 'shapeshift_start_click', + class: 'track_shapeshift_start_click', + channels: [channel] + }); + window.BitAnalytics.ActionHandlers.trackAction(actionShapeShiftStart); + // Init language uxLanguage.init(function (lang) { From 4dd334087b6f84537c3e7d05a772acd5279a2df3 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 10 Aug 2018 14:24:41 +1200 Subject: [PATCH 330/386] Removed formatted amount from the entry of the Amount screen as it was causing a bug. --- www/views/amount.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/www/views/amount.html b/www/views/amount.html index 8d263eae3..ab56052ab 100644 --- a/www/views/amount.html +++ b/www/views/amount.html @@ -16,12 +16,12 @@
- + {{vm.amount || '0'}} {{vm.unit}}
- + {{vm.alternativeAmount || '0.00'}} {{vm.alternativeUnit}}
From 8d404f19081d93169d72632386ea087a42be2185 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 10 Aug 2018 16:19:24 +1200 Subject: [PATCH 331/386] Handle null wallet. --- src/js/directives/walletBalanceDirective.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/js/directives/walletBalanceDirective.js b/src/js/directives/walletBalanceDirective.js index 5b2a41b6c..4c42a42f9 100644 --- a/src/js/directives/walletBalanceDirective.js +++ b/src/js/directives/walletBalanceDirective.js @@ -66,6 +66,11 @@ function formatBalance() { var displayAsFiat = $scope.displayAsFiat === 'true'; + if (!$scope.wallet) { + setDisplay('', ''); + return; + } + var wallet = null; try { wallet = JSON.parse($scope.wallet); From 3ff0f50a7b5de1e49a89661268a37dccc2fbaaa3 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 10 Aug 2018 16:20:26 +1200 Subject: [PATCH 332/386] Added quotes. --- www/views/tab-send.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/views/tab-send.html b/www/views/tab-send.html index a4051b8f1..43918cac8 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -16,7 +16,7 @@ >

{{fromWallet.name}}

- +
From ee84235d3adf8e149bdf8769877359ce0e5c14b0 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 10 Aug 2018 14:05:46 +0900 Subject: [PATCH 333/386] Top bar message --- src/js/controllers/walletSelectorController.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index 74ed874d4..89d77cc3e 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -34,6 +34,9 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu } break; default: + if (!stateParams.thirdParty) { + $scope.sendFlowTitle = gettextCatalog.getString('Send'); + } // nop } From 812ed5f1cd772c6b03191d16c819f9dd814bc265 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 10 Aug 2018 17:13:24 +1200 Subject: [PATCH 334/386] wallet-balance workaround for wallet not being stringify-able, and hence not being interpolatable, and hence not being able to pass it to the directive. --- src/js/directives/walletBalanceDirective.js | 55 ++++++++++++--------- www/views/tab-send.html | 8 ++- 2 files changed, 39 insertions(+), 24 deletions(-) diff --git a/src/js/directives/walletBalanceDirective.js b/src/js/directives/walletBalanceDirective.js index 4c42a42f9..1fea59203 100644 --- a/src/js/directives/walletBalanceDirective.js +++ b/src/js/directives/walletBalanceDirective.js @@ -10,7 +10,12 @@ scope: { displayAsFiat: '@', totalBalanceSat: '@', - wallet: '@' + // The Wallet object is sometimes not stringify()-able, so not interpolatable, + // so can't be passed to a directive. + walletStatus: '@', + walletCachedBalance: '@', + walletCachedBalanceUpdatedOn: '@', + walletCachedStatus: '@' }, templateUrl: 'views/includes/wallet-balance.html', controller: walletBalanceController @@ -25,38 +30,38 @@ formatBalance(); }); - function displayCryptoBalance(wallet) { + function displayCryptoBalance(walletStatus, walletCachedBalance, walletCachedBalanceUpdatedOn, walletCachedStatus) { console.log('displayCryptoBalance()'); - if (wallet.status && wallet.status.isValid && wallet.status.totalBalanceStr) { - setDisplay(wallet.status.totalBalanceStr, ''); + if (walletStatus && walletStatus.isValid && walletStatus.totalBalanceStr) { + setDisplay(walletStatus.totalBalanceStr, ''); cryptoBalanceHasBeenDisplayed = true; return; } - if (wallet.cachedBalance) { - setDisplay(wallet.cachedBalance, wallet.cachedBalanceUpdatedOn); + if (walletCachedBalance) { + setDisplay(walletCachedBalance, walletCachedBalanceUpdatedOn); return; } - if (wallet.cachedStatus && wallet.status.isValid && wallet.cachedStatus.totalBalanceStr) { - setDisplay(wallet.cachedStatus.totalBalanceStr, ''); + if (walletCachedStatus && walletCachedStatus.isValid && walletCachedStatus.totalBalanceStr) { + setDisplay(walletCachedStatus.totalBalanceStr, ''); return; } setDisplay('', ''); } - function displayFiatBalance(wallet) { + function displayFiatBalance(walletStatus, walletCachedStatus) { var displayAmount = ''; - if (wallet.status && wallet.status.isValid && wallet.status.alternativeBalanceAvailable) { - displayAmount = wallet.status.totalBalanceAlternative + ' ' + wallet.status.alternativeIsoCode; + if (walletStatus && walletStatus.isValid && walletStatus.alternativeBalanceAvailable) { + displayAmount = walletStatus.totalBalanceAlternative + ' ' + walletStatus.alternativeIsoCode; setDisplay(displayAmount, ''); return; } - if (wallet.cachedStatus && wallet.cachedStatus.isValid && wallet.cachedStatus.alternativeBalanceAvailable) { - displayAmount = wallet.cachedStatus.totalBalanceAlternative + ' ' + wallet.cachedStatus.alternativeIsoCode; + if (walletCachedStatus && walletCachedStatus.isValid && walletCachedStatus.alternativeBalanceAvailable) { + displayAmount = walletCachedStatus.totalBalanceAlternative + ' ' + walletCachedStatus.alternativeIsoCode; setDisplay(displayAmount, ''); return; } @@ -66,26 +71,30 @@ function formatBalance() { var displayAsFiat = $scope.displayAsFiat === 'true'; - if (!$scope.wallet) { - setDisplay('', ''); - return; + + var walletStatusObj = null; + var walletCachedBalance = null; + var walletCachedBalanceUpdatedOn = null; + var walletCachedStatusObj = null; + + try { + walletStatusObj = JSON.parse($scope.walletStatus); + } catch (e) { + $log.warn('Failed to parse walletStatus.', e); } - var wallet = null; try { - wallet = JSON.parse($scope.wallet); + walletCachedStatusObj = JSON.parse($scope.walletCachedStatus); } catch (e) { - $log.error('Error parsing wallet to display balance.', e); - setDisplay('', ''); - return; + $log.warn('Failed to parse walletCachedStatus.', e); } if (!displayAsFiat || displayAsFiat && !cryptoBalanceHasBeenDisplayed) { - displayCryptoBalance(wallet); + displayCryptoBalance(walletStatusObj, walletCachedBalance, walletCachedBalanceUpdatedOn, walletCachedStatusObj); } if (displayAsFiat) { - displayFiatBalance(wallet); + displayFiatBalance(walletStatusObj, walletCachedStatusObj); } } diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 43918cac8..339ac3556 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -16,7 +16,13 @@ >

{{fromWallet.name}}

- +
From d88d3365ad746e976a8cb9aa48b86096f77b6ba5 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 10 Aug 2018 19:09:55 +1200 Subject: [PATCH 335/386] Fix for long amounts on iPhone 5 / SE. Fix for buttons below amounts on iPhone 5 / SE. --- src/sass/views/amount.scss | 60 +++++++++++++++++++++----------------- www/views/amount.html | 27 +++++++++-------- 2 files changed, 48 insertions(+), 39 deletions(-) diff --git a/src/sass/views/amount.scss b/src/sass/views/amount.scss index ca32c6ac4..bf4d3506a 100644 --- a/src/sass/views/amount.scss +++ b/src/sass/views/amount.scss @@ -305,7 +305,8 @@ &.very-long { input, .unit, .primary-amount-display { - font-size: 0.9em; + font-size: 1.2em; // OK for iPhone 5 / SE with BCH to 8dp + @media (min-width: 375px) { font-size: 1.3em; @@ -382,41 +383,46 @@ .available-funds { color: #6F6F70; + text-align: left; + } + + .change-currency { + text-align: right; } .warning { color: $v-warning-color-2; } - .extra, - button.extra { - /*display: flex;*/ - flex: 0 1 auto; - } - - button.extra { - background: none; - border: none; - color: #000; - font-family: 'ProximaNova'; - font-size: 14px; + .extra { + flex: 1; line-height: normal; - min-height: auto; - min-width: auto; - padding: 0; - } - .button .icon:before { - font-size: 14px; - line-height: normal; - } - + .button { + background: none; + border: none; + border-radius: 0; + color: #000; + font-family: 'ProximaNova'; + font-size: 14px; + line-height: normal; + min-height: auto; + min-width: auto; + padding: 0; + } - .button { - span { - display: flex; - align-items: center; - justify-content: center; + .button .icon:before { + font-size: 14px; + line-height: normal; + } + + + .button { + span { + display: flex; + align-items: center; + justify-content: center; + } } } } diff --git a/www/views/amount.html b/www/views/amount.html index 8d263eae3..b69431b6b 100644 --- a/www/views/amount.html +++ b/www/views/amount.html @@ -14,14 +14,14 @@
+ ng-class="{long: vm.amount.length > 5, 'very-long': vm.amount.length > 8}"> - + {{vm.amount || '0'}} {{vm.unit}}
- + {{vm.alternativeAmount || '0.00'}} {{vm.alternativeUnit}}
@@ -34,17 +34,20 @@
- -
+ +
+
- Available Funds: + Available Funds: +
From 9e118350007d5231348c4e8d1dbe7ef7231bfd37 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 10 Aug 2018 19:45:43 +1200 Subject: [PATCH 336/386] Equal sized digits on Wallet Details alternative balance. --- www/views/walletDetails.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/views/walletDetails.html b/www/views/walletDetails.html index 2480099b5..6e05862aa 100644 --- a/www/views/walletDetails.html +++ b/www/views/walletDetails.html @@ -46,7 +46,7 @@ class="size-14 amount-alternative" ng-if="status.totalBalanceStr && wallet.network == 'livenet'" ng-style="{opacity: altAmountOpacity}"> - +
From 9e28c4ec4539a32bfa33b90ef005b3bfc357a0ae Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 10 Aug 2018 17:20:04 +0900 Subject: [PATCH 337/386] Fix bug send max with thirdparty (Shapeshift) --- src/js/controllers/amount.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 8e458045e..00c9461f5 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -464,7 +464,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, }; if (vm.thirdParty) { - confirmData['thirdParty'] = this.thirdParty; + confirmData.thirdParty = vm.thirdParty; } sendFlowService.pushState(confirmData); From dd75f581e7d068d8e0582bf6509d8e72535addca Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 10 Aug 2018 10:47:16 +0200 Subject: [PATCH 338/386] move stateParams and fromWallet outside of the clipboar function --- src/js/controllers/tab-send.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 81b3e4ca5..3f1da01fc 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -28,14 +28,15 @@ angular.module('copayApp.controllers').controller('tabSendController', function( }; $scope.$on("$ionicView.enter", function(event, data) { + + var stateParams = sendFlowService.getState(); + $scope.fromWallet = profileService.getWallet(stateParams.fromWalletId); + clipboardService.readFromClipboard(function(text) { if (text.length > 200) { text = text.substring(0, 200); } - var stateParams = sendFlowService.getState(); - $scope.fromWallet = profileService.getWallet(stateParams.fromWalletId); - $scope.clipboardHasAddress = false; $scope.clipboardHasContent = false; if ((text.indexOf('bitcoincash:') === 0 || text[0] === 'C' || text[0] === 'H' || text[0] === 'p' || text[0] === 'q') && text.replace('bitcoincash:', '').length === 42) { // CashAddr From 3365a61d6234c72fcfdddd0dd6e434a97ad6e59f Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 10 Aug 2018 17:47:21 +0900 Subject: [PATCH 339/386] invalidate cache --- src/js/controllers/tab-home.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/js/controllers/tab-home.js b/src/js/controllers/tab-home.js index 9c4f2bee9..318fcece2 100644 --- a/src/js/controllers/tab-home.js +++ b/src/js/controllers/tab-home.js @@ -214,6 +214,7 @@ angular.module('copayApp.controllers').controller('tabHomeController', var j = 0; lodash.each(wallets, function(wallet) { + walletService.invalidateCache(wallet); // Temporary solution, to have the good balance, when we ask to reload the wallets. walletService.getStatus(wallet, {}, function(err, status) { if (err) { From 5185c6ee3ccb579064e29c8f42ad57d3320a9904 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 10 Aug 2018 18:41:47 +0900 Subject: [PATCH 340/386] Fix amount --- src/js/directives/formattedAmount.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index 1a05fd360..9f70b37ed 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -90,7 +90,7 @@ // to both being in value. Don't want to use previous currency value. // Try to extract currency from value.. var currencySplit = $scope.value.split(" "); - if (currencySplit.length === 2) { + if (currencySplit.length === 2 && !$scope.currency) { $scope.currency = currencySplit[1]; } $scope.currency = $scope.currency || ''; From daf9bb535653cedec9f5ea1c484d10fcf42ddf2e Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 10 Aug 2018 18:43:28 +0900 Subject: [PATCH 341/386] Notify to reload home tab --- src/js/controllers/tab-receive.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index 190f1b752..c822b4521 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -158,6 +158,10 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi soundService.play('misc/payment_received.mp3'); } + // Notify new tx + $scope.$emit('bwsEvent', $scope.wallet.id); + + $scope.$apply(function () { $scope.showingPaymentReceived = true; }); From 949cbc76979d6ec964594c97cd5630d6b647c879 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Fri, 10 Aug 2018 19:04:53 +0900 Subject: [PATCH 342/386] Cleaning code --- src/js/controllers/walletSelectorController.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index 89d77cc3e..ba5b4c418 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -17,7 +17,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu sendFlowService.popState(); } - var stateParams = sendFlowService.getState(); + $scope.params = sendFlowService.getState(); var config = configService.getSync().wallet.settings; priceDisplayAsFiat = config.priceDisplay === 'fiat'; @@ -29,18 +29,17 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); break; case 'tabs.send.destination': - if (stateParams.fromWalletId) { + if ($scope.params.fromWalletId) { $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); } break; default: - if (!stateParams.thirdParty) { + if (!$scope.params.thirdParty) { $scope.sendFlowTitle = gettextCatalog.getString('Send'); } // nop } - $scope.params = sendFlowService; $scope.coin = false; // Wallets to show (for destination screen or contacts) $scope.type = $scope.params['fromWalletId'] ? 'destination' : 'origin'; // origin || destination fromWalletId = $scope.params['fromWalletId']; From e4c5da0d4414a00e4eace80139859322c57e2350 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 10 Aug 2018 12:07:24 +0200 Subject: [PATCH 343/386] thirdParty fix --- src/js/services/incomingData.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index 86c928a5e..4c2b71de8 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -447,7 +447,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat amount: thirdPartyData.amount, toAddress: thirdPartyData.toAddress, coin: coin, - thirdParty: JSON.stringify(thirdPartyData) + thirdParty: thirdPartyData }; // fee @@ -455,6 +455,8 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat stateParams.requiredFeeRate = thirdPartyData.requiredFeeRate * 1024; } + sendFlowService.pushState(thirdPartyData); + scannerService.pausePreview(); $state.go('tabs.send', {}, { 'reload': true, From f86ab3faecc9febf2b5de91c1001ddc85eb5c6f9 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 10 Aug 2018 12:42:28 +0200 Subject: [PATCH 344/386] revert code cleanup --- src/js/controllers/walletSelectorController.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index ba5b4c418..89d77cc3e 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -17,7 +17,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu sendFlowService.popState(); } - $scope.params = sendFlowService.getState(); + var stateParams = sendFlowService.getState(); var config = configService.getSync().wallet.settings; priceDisplayAsFiat = config.priceDisplay === 'fiat'; @@ -29,17 +29,18 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); break; case 'tabs.send.destination': - if ($scope.params.fromWalletId) { + if (stateParams.fromWalletId) { $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); } break; default: - if (!$scope.params.thirdParty) { + if (!stateParams.thirdParty) { $scope.sendFlowTitle = gettextCatalog.getString('Send'); } // nop } + $scope.params = sendFlowService; $scope.coin = false; // Wallets to show (for destination screen or contacts) $scope.type = $scope.params['fromWalletId'] ? 'destination' : 'origin'; // origin || destination fromWalletId = $scope.params['fromWalletId']; From d28ba24e1c63500c1129c0e1aa2dfd5d297487d2 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Fri, 10 Aug 2018 15:10:44 +0200 Subject: [PATCH 345/386] receive specific amount fix to use sendFlowService --- src/js/controllers/tab-receive.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index c822b4521..0e80f4382 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('tabReceiveController', function($rootScope, $scope, $timeout, $log, $ionicModal, $state, $ionicHistory, $ionicPopover, storageService, platformInfo, walletService, profileService, configService, lodash, gettextCatalog, popupService, bwcError, bitcoinCashJsService, $ionicNavBarDelegate, txFormatService, soundService, clipboardService) { +angular.module('copayApp.controllers').controller('tabReceiveController', function($rootScope, $scope, $timeout, $log, $ionicModal, $state, $ionicHistory, $ionicPopover, storageService, platformInfo, walletService, profileService, configService, lodash, gettextCatalog, popupService, bwcError, bitcoinCashJsService, $ionicNavBarDelegate, sendFlowService, txFormatService, soundService, clipboardService) { var listeners = []; $scope.bchAddressType = { type: 'cashaddr' }; @@ -18,9 +18,10 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi $scope.displayBalanceAsFiat = true; $scope.requestSpecificAmount = function() { - $state.go('tabs.paymentRequest.amount', { + sendFlowService.pushState({ toWalletId: $scope.wallet.credentials.walletId }); + $state.go('tabs.paymentRequest.amount'); }; $scope.setAddress = function(newAddr, copyAddress) { From 5445ddbecd62bc3585bc6c08883b02d865ce07d0 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 13 Aug 2018 10:00:39 +1200 Subject: [PATCH 346/386] Fix for wallet selection header when in Shapeshift flow. Also fixed a coin already present bug that occurred in subsequent Shapeshift flows. --- src/js/controllers/amount.js | 5 +-- src/js/controllers/review.controller.js | 4 +- src/js/controllers/tab-send.js | 8 ++-- .../controllers/walletSelectorController.js | 24 +++++----- src/js/services/incomingData.js | 5 ++- src/js/services/sendFlowService.js | 44 +++++++++++-------- 6 files changed, 47 insertions(+), 43 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index 00c9461f5..c2dcc6cd4 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -67,15 +67,14 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, } function onBeforeEnter(event, data) { - console.log('amount onBeforeEnter sendflow ', sendFlowService.getState()); - if (data.direction == "back") { sendFlowService.popState(); } + console.log('amount onBeforeEnter after back sendflow ', sendFlowService.state); initCurrencies(); - passthroughParams = sendFlowService; + passthroughParams = sendFlowService.getStateClone(); vm.fromWalletId = passthroughParams.fromWalletId; vm.toWalletId = passthroughParams.toWalletId; diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index d41d4a9b0..3c528c1f9 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -75,9 +75,9 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit function onBeforeEnter(event, data) { - console.log('walletSelector onBeforeEnter sendflow ', sendFlowService.getState()); + console.log('walletSelector onBeforeEnter sendflow ', sendFlowService.state); defaults = configService.getDefaults(); - sendFlowData = sendFlowService.getState(); + sendFlowData = sendFlowService.getStateClone(); originWalletId = sendFlowData.fromWalletId; satoshis = parseInt(sendFlowData.amount, 10); toAddress = sendFlowData.toAddress; diff --git a/src/js/controllers/tab-send.js b/src/js/controllers/tab-send.js index 3f1da01fc..9ac6c35cb 100644 --- a/src/js/controllers/tab-send.js +++ b/src/js/controllers/tab-send.js @@ -29,7 +29,7 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.$on("$ionicView.enter", function(event, data) { - var stateParams = sendFlowService.getState(); + var stateParams = sendFlowService.getStateClone(); $scope.fromWallet = profileService.getWallet(stateParams.fromWalletId); clipboardService.readFromClipboard(function(text) { @@ -184,7 +184,7 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $log.debug('Got toAddress:' + toAddress + ' | ' + item.name); - var stateParams = sendFlowService.getState(); + var stateParams = sendFlowService.getStateClone(); stateParams.toAddress = toAddress, stateParams.coin = item.coin; sendFlowService.pushState(stateParams); @@ -200,7 +200,7 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.startWalletToWalletTransfer = function() { console.log('startWalletToWalletTransfer()'); - var params = sendFlowService.getState(); + var params = sendFlowService.getStateClone(); sendFlowService.pushState(params); $state.transitionTo('tabs.send.wallet-to-wallet', { fromWalletId: sendFlowService.fromWalletId @@ -222,7 +222,7 @@ angular.module('copayApp.controllers').controller('tabSendController', function( $scope.$on("$ionicView.beforeEnter", function(event, data) { console.log(data); - console.log('tab-send onBeforeEnter sendflow ', sendFlowService.getState()); + console.log('tab-send onBeforeEnter sendflow ', sendFlowService.state); $scope.isIOS = platformInfo.isIOS && platformInfo.isCordova; $scope.showWalletsBch = $scope.showWalletsBtc = $scope.showWallets = false; diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index ba5b4c418..7a7c5a463 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -11,13 +11,12 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.$on("$ionicView.enter", onEnter); function onBeforeEnter(event, data) { - console.log('walletSelector onBeforeEnter sendflow', sendFlowService.getState()); - if (data.direction == "back") { sendFlowService.popState(); } + console.log('walletSelector onBeforeEnter after back sendflow', sendFlowService.state); - $scope.params = sendFlowService.getState(); + $scope.params = sendFlowService.getStateClone(); var config = configService.getSync().wallet.settings; priceDisplayAsFiat = config.priceDisplay === 'fiat'; @@ -29,7 +28,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); break; case 'tabs.send.destination': - if ($scope.params.fromWalletId) { + if ($scope.params.fromWalletId && !$scope.params.thirdParty) { $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); } break; @@ -45,7 +44,7 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu fromWalletId = $scope.params['fromWalletId']; if ($scope.type === 'destination' && $scope.params.toAddress) { - $state.transitionTo(getNextStep()); + $state.transitionTo(getNextStep($scope.params)); } if ($scope.params.coin) { @@ -105,13 +104,10 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu } } - function getNextStep() { - if ($scope.thirdParty) { - $scope.params.thirdParty = $scope.thirdParty - } - if (!$scope.params.toWalletId && !$scope.params.toAddress) { // If we have no toAddress or fromWallet + function getNextStep(params) { + if (!params.toWalletId && !params.toAddress) { // If we have no toAddress or fromWallet return 'tabs.send.destination'; - } else if (!$scope.params.amount) { // If we have no amount + } else if (!params.amount) { // If we have no amount return 'tabs.send.amount'; } else { // If we do have them return 'tabs.send.review'; @@ -195,14 +191,16 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu $scope.useWallet = function(wallet) { - var params = sendFlowService.getState(); + var params = sendFlowService.getStateClone(); if ($scope.type === 'origin') { // we're on the origin screen, set wallet to send from params.fromWalletId = wallet.id; } else { // we're on the destination screen, set wallet to send to params.toWalletId = wallet.id; } sendFlowService.pushState(params); - $state.transitionTo(getNextStep(), $scope.params); + var nextStep = getNextStep(params); + console.log('walletSelector nextStep', nextStep); + $state.transitionTo(nextStep, $scope.params); }; $scope.goBack = function() { diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index 4c2b71de8..9fad8b0f5 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -82,7 +82,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat }); // Timeout is required to enable the "Back" button $timeout(function() { - var params = sendFlowService.getState(); + var params = sendFlowService.getStateClone(); if (amount) { params.amount = amount; @@ -455,7 +455,8 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat stateParams.requiredFeeRate = thirdPartyData.requiredFeeRate * 1024; } - sendFlowService.pushState(thirdPartyData); + // This does not make sense, thirdPartyData gets added by stateParams below + //sendFlowService.pushState(thirdPartyData); scannerService.pausePreview(); $state.go('tabs.send', {}, { diff --git a/src/js/services/sendFlowService.js b/src/js/services/sendFlowService.js index 29686b15b..fcb061c26 100644 --- a/src/js/services/sendFlowService.js +++ b/src/js/services/sendFlowService.js @@ -9,17 +9,21 @@ angular function sendFlowService($log) { var service = { - amount: '', - fromWalletId: '', - sendMax: false, - thirdParty: null, - toAddress: '', - toWalletId: '', + // A separate state variable so we can ensure it is cleared of everything, + // even other properties added that this service does not know about. (such as "coin") + state: { + amount: '', + fromWalletId: '', + sendMax: false, + thirdParty: null, + toAddress: '', + toWalletId: '' + }, previousStates: [], // Functions clear: clear, - getState: getState, + getStateClone: getStateClone, map: map, popState: popState, pushState: pushState, @@ -36,22 +40,24 @@ angular function clearCurrent() { console.log("sendFlow clearCurrent()"); - service.amount = ''; - service.fromWalletId = ''; - service.sendMax = false; - service.thirdParty = null; - service.toAddress = ''; - service.toWalletId = ''; + service.state = { + amount: '', + fromWalletId: '', + sendMax: false, + thirdParty: null, + toAddress: '', + toWalletId: '' + } } /** * Handy for debugging */ - function getState() { + function getStateClone() { var currentState = {}; - Object.keys(service).forEach(function forCurrentParam(key) { - if (typeof service[key] !== 'function' && key !== 'previousStates') { - currentState[key] = service[key]; + Object.keys(service.state).forEach(function forCurrentParam(key) { + if (typeof service.state[key] !== 'function' && key !== 'previousStates') { + currentState[key] = service.state[key]; } }); return currentState; @@ -68,7 +74,7 @@ angular function map(params) { Object.keys(params).forEach(function forNewParam(key) { - service[key] = params[key]; + service.state[key] = params[key]; }); }; @@ -85,7 +91,7 @@ angular function pushState(params) { console.log('sendFlow push'); - var currentParams = getState(); + var currentParams = getStateClone(); service.previousStates.push(currentParams); clearCurrent(); map(params); From 84fd483f1911b584bd4d8134028916ad79ee569a Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 13 Aug 2018 10:47:00 +1200 Subject: [PATCH 347/386] Fix for removing dark portion of Review Transaction screen below personal note. --- src/sass/views/review.scss | 1 - 1 file changed, 1 deletion(-) diff --git a/src/sass/views/review.scss b/src/sass/views/review.scss index 79bca1896..c530a1cef 100644 --- a/src/sass/views/review.scss +++ b/src/sass/views/review.scss @@ -1,5 +1,4 @@ #view-review { - background-color: #494949; slide-to-accept, slide-to-accept-success { margin-bottom: constant(safe-area-inset-bottom); /* iOS 11.0 */ From 80c9d682b59628c88b03b8034149e2eaa8ffff2d Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 13 Aug 2018 11:23:15 +1200 Subject: [PATCH 348/386] Fix in formatted-amount of display of subcent fees in transactions details page. --- src/js/directives/formattedAmount.js | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index 9f70b37ed..68bb50781 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -86,15 +86,24 @@ } function formatNumbers() { + console.log('formatNumbers() "' + $scope.value + '", "' + $scope.currency + '"'); + // Might get "< 0.01 USD" being passed in. // During watch, may be changed from having a separate currency value, // to both being in value. Don't want to use previous currency value. // Try to extract currency from value.. var currencySplit = $scope.value.split(" "); - if (currencySplit.length === 2 && !$scope.currency) { - $scope.currency = currencySplit[1]; + if (currencySplit.length >= 2 && !$scope.currency) { + $scope.currency = currencySplit[currencySplit.length - 1]; } $scope.currency = $scope.currency || ''; + // Redo this when we have proper formatting for low fees + if ($scope.value.indexOf("<") === 0) { + buildAmount($scope.value, '', ''); + $scope.currency = ''; + $scope.canShow = true; + return; + } var parsed = parseFloat($scope.value); var valueFormatted = ''; From 098d454b8ba5e467be1bb30d8f193cdbc15b19b6 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 13 Aug 2018 15:43:20 +1200 Subject: [PATCH 349/386] Fixed formatting of numbers in the thousands. --- src/js/directives/formattedAmount.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index 68bb50781..55051f07d 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -105,6 +105,9 @@ return; } + // Remove thousands separators for parseFloat() + $scope.value = $scope.value.replace(',', ''); + var parsed = parseFloat($scope.value); var valueFormatted = ''; var valueProcessing = ''; From a29a41b6472f996330121ad2ddc3b039cd27878d Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 13 Aug 2018 15:48:20 +1200 Subject: [PATCH 350/386] Removed console.log(). --- src/js/directives/formattedAmount.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index 55051f07d..f66a0ac78 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -86,7 +86,6 @@ } function formatNumbers() { - console.log('formatNumbers() "' + $scope.value + '", "' + $scope.currency + '"'); // Might get "< 0.01 USD" being passed in. // During watch, may be changed from having a separate currency value, // to both being in value. Don't want to use previous currency value. From 430f4644eb191dc240ae0a11add7ef79fecbfe0a Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 13 Aug 2018 13:32:20 +0900 Subject: [PATCH 351/386] Fix formatted amount. --- src/js/directives/formattedAmount.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index f66a0ac78..1f51d33e3 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -90,11 +90,12 @@ // During watch, may be changed from having a separate currency value, // to both being in value. Don't want to use previous currency value. // Try to extract currency from value.. + $scope.currency = $scope.currency || ''; + var currencySplit = $scope.value.split(" "); - if (currencySplit.length >= 2 && !$scope.currency) { + if (currencySplit.length >= 2 && $scope.currency.length === 0) { $scope.currency = currencySplit[currencySplit.length - 1]; } - $scope.currency = $scope.currency || ''; // Redo this when we have proper formatting for low fees if ($scope.value.indexOf("<") === 0) { From 6de4f2ecda3fb91e251c79126953c49bd739f671 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 13 Aug 2018 16:45:46 +1200 Subject: [PATCH 352/386] Enlarged Wallet Details header to fit Receive and Send buttons without covering the unlocked balance. --- src/js/controllers/walletDetails.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index e6a8e2351..1aaef7581 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -304,6 +304,7 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun }; function refreshAmountSection(scrollPos) { + var AMOUNT_HEIGHT_BASE = 270; $scope.showBalanceButton = false; if ($scope.status) { $scope.showBalanceButton = ($scope.status.totalBalanceSat != $scope.status.spendableAmount); @@ -315,16 +316,16 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun } scrollPos = scrollPos || 0; - var amountHeight = 210 - scrollPos; + var amountHeight = AMOUNT_HEIGHT_BASE - scrollPos; if (amountHeight < 80) { amountHeight = 80; } var contentMargin = amountHeight; - if (contentMargin > 210) { - contentMargin = 210; + if (contentMargin > AMOUNT_HEIGHT_BASE) { + contentMargin = AMOUNT_HEIGHT_BASE; } - var amountScale = (amountHeight / 210); + var amountScale = (amountHeight / AMOUNT_HEIGHT_BASE); if (amountScale < 0.5) { amountScale = 0.5; } From 0b71daf04d6a3c7241a5c785843bd42488445c7b Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Mon, 13 Aug 2018 16:51:38 +1200 Subject: [PATCH 353/386] Removed previous fix as it is superceded by a better one. --- src/sass/views/walletDetails.scss | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/sass/views/walletDetails.scss b/src/sass/views/walletDetails.scss index 79326951e..858229d85 100644 --- a/src/sass/views/walletDetails.scss +++ b/src/sass/views/walletDetails.scss @@ -262,11 +262,6 @@ padding-top: 45px; } - .button-white-outline.button-outline.activated { - color: $v-primary-color; - border-color: white; - } - .item.item-footer { font-weight: lighter; } From 52e1b5e8116969ade33515e62ab5038da8045d41 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 13 Aug 2018 14:13:49 +0900 Subject: [PATCH 354/386] Manage the currency state --- src/js/directives/formattedAmount.js | 26 ++++++++++++++++-------- www/views/includes/formatted-amount.html | 2 +- 2 files changed, 18 insertions(+), 10 deletions(-) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index 1f51d33e3..f81615593 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -26,9 +26,14 @@ } }); - function formattedAmountController($scope, $timeout, uxLanguage) { - $scope.canShow = false; + function formattedAmountController($scope, uxLanguage) { + $scope.vm = {}; + var vm = $scope.vm; + vm.currency = ''; + vm.value = ''; + + $scope.canShow = false $scope.displaySizeEqual = !!$scope.sizeEqual; var decimalPlaces = { @@ -90,17 +95,19 @@ // During watch, may be changed from having a separate currency value, // to both being in value. Don't want to use previous currency value. // Try to extract currency from value.. - $scope.currency = $scope.currency || ''; - - var currencySplit = $scope.value.split(" "); - if (currencySplit.length >= 2 && $scope.currency.length === 0) { - $scope.currency = currencySplit[currencySplit.length - 1]; + if (!$scope.currency || $scope.currency.length === 0) { + var currencySplit = $scope.value.split(" "); + if (currencySplit.length >= 2) { + vm.currency = currencySplit[currencySplit.length - 1]; + } + } else { + vm.currency = $scope.currency; } // Redo this when we have proper formatting for low fees if ($scope.value.indexOf("<") === 0) { buildAmount($scope.value, '', ''); - $scope.currency = ''; + vm.currency = ''; $scope.canShow = true; return; } @@ -111,7 +118,7 @@ var parsed = parseFloat($scope.value); var valueFormatted = ''; var valueProcessing = ''; - switch (getDecimalPlaces($scope.currency)) { + switch (getDecimalPlaces(vm.currency)) { case '0': if (isNaN(parsed)) { buildAmount('-', '', ''); @@ -158,6 +165,7 @@ break; } $scope.canShow = true; + $scope.$apply(); }; function getDecimalPlaces(currency) { diff --git a/www/views/includes/formatted-amount.html b/www/views/includes/formatted-amount.html index 24149849d..45451a718 100644 --- a/www/views/includes/formatted-amount.html +++ b/www/views/includes/formatted-amount.html @@ -1,4 +1,4 @@
- {{start}}{{middle}}{{end}}{{currency}} + {{start}}{{middle}}{{end}}{{vm.currency}}
\ No newline at end of file From c54cb55c51e4737a89e05ec92dfd0784a078319a Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 13 Aug 2018 14:44:07 +0900 Subject: [PATCH 355/386] Custom amount crypto decimal --- www/views/customAmount.html | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/www/views/customAmount.html b/www/views/customAmount.html index b361a6da9..a7130a729 100644 --- a/www/views/customAmount.html +++ b/www/views/customAmount.html @@ -32,15 +32,15 @@
- {{amountUnitStr}} +
- {{altAmountStr | uppercase}} +
- {{altAmountStr | uppercase}} +
- {{amountUnitStr}} +
From 9c999d0cd6754e81bf06fda79e492dd1e7606815 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 13 Aug 2018 15:35:26 +0900 Subject: [PATCH 356/386] Update appConfig.json --- app-template/bitcoincom/appConfig.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app-template/bitcoincom/appConfig.json b/app-template/bitcoincom/appConfig.json index 084a586ce..4b3281f6e 100644 --- a/app-template/bitcoincom/appConfig.json +++ b/app-template/bitcoincom/appConfig.json @@ -24,9 +24,9 @@ "windowsAppId": "804636ee-b017-4cad-8719-e58ac97ffa5c", "pushSenderId": "1036948132229", "description": "A Secure Bitcoin Wallet", - "version": "4.13.2", - "fullVersion": "4.13-rc3", - "androidVersion": "413200", + "version": "5.0.0", + "fullVersion": "5.0-rc1", + "androidVersion": "500000", "_extraCSS": "", "_enabledExtensions": { "coinbase": false, From 30230304b695bdb76606849778f2ee7e625bf5fd Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Mon, 13 Aug 2018 16:13:29 +0900 Subject: [PATCH 357/386] Fix height header --- src/js/controllers/walletDetails.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/walletDetails.js b/src/js/controllers/walletDetails.js index 1aaef7581..ec787a5f4 100644 --- a/src/js/controllers/walletDetails.js +++ b/src/js/controllers/walletDetails.js @@ -304,10 +304,13 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun }; function refreshAmountSection(scrollPos) { - var AMOUNT_HEIGHT_BASE = 270; + var AMOUNT_HEIGHT_BASE = 210; $scope.showBalanceButton = false; if ($scope.status) { $scope.showBalanceButton = ($scope.status.totalBalanceSat != $scope.status.spendableAmount); + if ($scope.showBalanceButton) { + AMOUNT_HEIGHT_BASE = 270; + } } if (!$scope.amountIsCollapsible) { var t = ($scope.showBalanceButton ? 15 : 45); From 1dad3ab3fd3a3981658ca3537d151d4d9ac433be Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 13 Aug 2018 13:48:41 +0200 Subject: [PATCH 358/386] Many translation fixes. Missing translations in template.pot and added some in views --- i18n/po/template.pot | 40 ++++++++++++++++++++++--- src/js/controllers/review.controller.js | 1 + www/views/amount.html | 2 +- www/views/review.html | 14 ++++----- www/views/tab-send.html | 2 +- www/views/tx-details.html | 4 +-- 6 files changed, 48 insertions(+), 15 deletions(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index d8281988f..bdabbc318 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -72,6 +72,26 @@ msgstr "" msgid "Instant transactions with low fees" msgstr "" +#: www/views/walletSelector.html:49 +msgid "Insufficient funds" +msgstr "" + +#: www/views/amount.html:42 +msgid "Change Currency" +msgstr "" + +#: www/views/amount.html:49 +msgid "Available Funds" +msgstr "" + +#: www/views/amount.html:59 +msgid "Use All Available Funds" +msgstr "" + +#: www/views/amount.html:99 +msgid "Next" +msgstr "" + #: www/views/preferencesBitpayServices.html:23 msgid "Accounts" msgstr "" @@ -1287,6 +1307,7 @@ msgstr "" #: www/views/modals/txp-details.html:74 #: www/views/topup.html:34 #: www/views/tx-details.html:52 +#: www/views/review.html:22 msgid "From" msgstr "" @@ -3072,6 +3093,14 @@ msgstr "" msgid "This bitcoin payment request has expired." msgstr "" +#: www/views/review.html:55 +msgid "Payment expires:" +msgstr "" + +#: www/views/review.html:56 +msgid "Payment request has expired" +msgstr "" + #: www/views/join.html:133 #: www/views/tab-create-personal.html:103 #: www/views/tab-create-shared.html:132 @@ -3805,10 +3834,6 @@ msgstr "" msgid "You are shifting" msgstr "" -#: www/views/review.html:22 -msgid "From:" -msgstr "" - #: www/views/review.html:36 msgid "To:" msgstr "" @@ -3817,6 +3842,13 @@ msgstr "" msgid "Add personal note" msgstr "" +#: www/views/review.html:87 +msgid "Suggested by merchant:" +msgstr "" + +#: src/js/controllers/review.controller.js:37 +msgid "Enter text here" +msgstr "" #: www/views/review.html:57 msgid "Personal note:" diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 3c528c1f9..c1f120241 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -34,6 +34,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit }; vm.originWallet = null; vm.paymentExpired = false; + vm.personalNotePlaceholder = gettextCatalog.getString('Enter text here'); vm.primaryAmount = ''; vm.primaryCurrency = ''; vm.usingMerchantFee = false; diff --git a/www/views/amount.html b/www/views/amount.html index b69431b6b..939937be8 100644 --- a/www/views/amount.html +++ b/www/views/amount.html @@ -46,7 +46,7 @@
- Available Funds: + Available Funds:
diff --git a/www/views/review.html b/www/views/review.html index f2970da51..50fcfbcac 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -18,7 +18,7 @@
-
From:
+
From:
@@ -52,7 +52,7 @@

{{vm.destination.name}}

-

Payment expires: {{vm.remainingTimeStr}}

+

Payment expires: {{vm.remainingTimeStr}}

Payment request has expired

@@ -67,14 +67,14 @@ ng-class="{ 'expand-content-revealed': vm.memoExpanded }" ng-click="vm.memoExpanded = !vm.memoExpanded"> - Add personal note + Add personal note
Personal Note:
- +
@@ -84,10 +84,10 @@
-
Suggested by merchant:
+
Suggested by merchant:
-
Fee: Less than 1 cent
-
Fee: {{vm.feeFiat}} {{vm.feeCurrency}}
+
Fee: Less than 1 cent
+
Fee: {{vm.feeFiat}} {{vm.feeCurrency}}
diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 339ac3556..41f5c4451 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -7,7 +7,7 @@
-
From:
+
From:
diff --git a/www/views/tx-details.html b/www/views/tx-details.html index 467ce28e3..3a690aff9 100644 --- a/www/views/tx-details.html +++ b/www/views/tx-details.html @@ -24,9 +24,9 @@ Receiving
-
+
- + ... From f51542874b6213a433a929811e464ab2045b458b Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 13 Aug 2018 14:12:36 +0200 Subject: [PATCH 359/386] small fix: minus before alternative currency --- www/views/includes/walletHistory.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/views/includes/walletHistory.html b/www/views/includes/walletHistory.html index 296b35b1a..3be30c2b1 100644 --- a/www/views/includes/walletHistory.html +++ b/www/views/includes/walletHistory.html @@ -73,7 +73,7 @@
- +
From 14406f6bc4b295a919fd7a2a5ef8ce346a8edfa0 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 13 Aug 2018 15:28:22 +0200 Subject: [PATCH 360/386] template.pot fix --- i18n/po/template.pot | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index bdabbc318..277be03bb 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -1368,10 +1368,6 @@ msgid "Get news and updates from BitPay" msgstr "" #: www/views/onboarding/welcome.html:8 -msgctxt "button" -msgid "Get started" -msgstr "" - #: www/views/bitpayCard.html:49 msgid "Get started" msgstr "" @@ -2663,10 +2659,6 @@ msgstr "" msgid "Send Bitcoin faster!" msgstr "" -#: www/views/tab-send.html:46 -msgid "Send Bitcoin faster!" -msgstr "" - #: www/views/tab-send.html:50 msgid "Save frequently used addresses and send them Bitcoin in just one tap" msgstr "" @@ -2689,6 +2681,7 @@ msgstr "" #: www/views/tab-send.html:72 #: www/views/shapeshift.html:23 +#: www/views/tab-send.html:33 msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." msgstr "" @@ -3142,10 +3135,6 @@ msgstr "" msgid "To get started, buy bitcoin or share your address. You can receive bitcoin from any wallet or service." msgstr "" -#: www/views/tab-send.html:33 -msgid "To get started, you'll need to create a bitcoin wallet and get some bitcoin." -msgstr "" - #: src/js/services/bitpayAccountService.js:73 msgid "To {{reason}} you must first add your BitPay account - {{email}}" msgstr "" From 5123ba90070fb8e66c75a8c89cc0e1a8534c16b8 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 13 Aug 2018 15:33:48 +0200 Subject: [PATCH 361/386] template.pot fix --- i18n/po/template.pot | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index 277be03bb..40d9ba501 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -3808,7 +3808,7 @@ msgid "Your Bitcoin Wallets are ready!" msgstr "" #: src/js/controllers/amount.js:49 -msgid "Address doesn\'t contain currency information, please make sure you are sending the correct currency." +msgid "Address doesn't contain currency information, please make sure you are sending the correct currency." msgstr "" #: www/views/review.html:4 From 587971724e3ed12a48c0d7b38381c50e0bc31520 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Mon, 13 Aug 2018 16:52:00 +0200 Subject: [PATCH 362/386] template.pot change --- i18n/po/template.pot | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index 40d9ba501..060a35ff7 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -3808,7 +3808,7 @@ msgid "Your Bitcoin Wallets are ready!" msgstr "" #: src/js/controllers/amount.js:49 -msgid "Address doesn't contain currency information, please make sure you are sending the correct currency." +msgid "Address does not contain currency information, please make sure you are sending the correct currency." msgstr "" #: www/views/review.html:4 From 947c2d324f4103c34a0f7a03e2f3f642b1c746ac Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 14 Aug 2018 11:38:24 +0900 Subject: [PATCH 363/386] Upgrade text --- i18n/po/template.pot | 2 +- src/js/controllers/walletSelectorController.js | 4 ++-- www/views/tab-send.html | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index d8281988f..725aa3de7 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -2631,7 +2631,7 @@ msgid "Paste Address" msgstr "" #: www/views/tab-send.html:27 -msgid "Wallet to Wallet Transfer" +msgid "Transfer between wallets" msgstr "" #: www/views/tab-send.html:35 diff --git a/src/js/controllers/walletSelectorController.js b/src/js/controllers/walletSelectorController.js index a4ff3ab3e..42506dace 100644 --- a/src/js/controllers/walletSelectorController.js +++ b/src/js/controllers/walletSelectorController.js @@ -15,11 +15,11 @@ angular.module('copayApp.controllers').controller('walletSelectorController', fu switch($state.current.name) { case 'tabs.send.wallet-to-wallet': - $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); + $scope.sendFlowTitle = gettextCatalog.getString('Transfer between wallets'); break; case 'tabs.send.destination': if (data.stateParams.fromWalletId) { - $scope.sendFlowTitle = gettextCatalog.getString('Wallet to Wallet Transfer'); + $scope.sendFlowTitle = gettextCatalog.getString('Transfer between wallets'); } break; default: diff --git a/www/views/tab-send.html b/www/views/tab-send.html index 20198c7f0..8f1fc1a93 100644 --- a/www/views/tab-send.html +++ b/www/views/tab-send.html @@ -24,7 +24,7 @@
From cf6658c83afa08e8028656e937640b66e79b50b7 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 14 Aug 2018 14:48:07 +1200 Subject: [PATCH 364/386] Removed $apply() inside $watch. --- src/js/directives/formattedAmount.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/js/directives/formattedAmount.js b/src/js/directives/formattedAmount.js index f81615593..5ee9be050 100644 --- a/src/js/directives/formattedAmount.js +++ b/src/js/directives/formattedAmount.js @@ -165,7 +165,6 @@ break; } $scope.canShow = true; - $scope.$apply(); }; function getDecimalPlaces(currency) { From 05e204dec897f87c222c5e977f793fb0779c3c64 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 14 Aug 2018 16:58:13 +1200 Subject: [PATCH 365/386] Changed the review controller to allow the transaction to be shared, once successful. --- src/js/controllers/review.controller.js | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index c1f120241..788368e9e 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -4,7 +4,7 @@ angular .module('copayApp.controllers') .controller('reviewController', reviewController); -function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, configService, feeService, gettextCatalog, $interval, $ionicHistory, $ionicModal, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, sendFlowService, shapeshiftService, soundService, $state, $timeout, txConfirmNotification, txFormatService, walletService) { +function reviewController(addressbookService, bitcoinCashJsService, bitcore, bitcoreCash, bwcError, clipboardService, configService, feeService, gettextCatalog, $interval, $ionicHistory, $ionicModal, ionicToast, lodash, $log, ongoingProcess, platformInfo, popupService, profileService, $scope, sendFlowService, shapeshiftService, soundService, $state, $timeout, txConfirmNotification, txFormatService, walletService) { var vm = this; vm.buttonText = ''; @@ -52,6 +52,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit // Functions vm.goBack = goBack; vm.onSuccessConfirm = onSuccessConfirm; + vm.onShareTransaction = onShareTransaction; var sendFlowData; var config = null; @@ -62,6 +63,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit var usingCustomFee = false; var usingMerchantFee = false; var destinationWalletId = ''; + var lastTxId = ''; var originWalletId = ''; var priceDisplayIsFiat = true; var satoshis = null; @@ -156,6 +158,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit txConfirmNotification.subscribe(vm.originWallet, { txid: txp.txid }); + lastTxId = txp.txid; } }, statusChangeHandler); }; @@ -522,6 +525,21 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit } } + function onShareTransaction() { + var explorerTxUrl = 'https://explorer.bitcoin.com/' + tx.coin + '/tx/' + lastTxId; + if (platformInfo.isCordova) { + var text = gettextCatalog.getString('Take a look at this Bitcoin Cash transaction here: ') + explorerTxUrl; + if (coin === 'btc') { + text = gettextCatalog.getString('Take a look at this Bitcoin transaction here: ') + explorerTxUrl; + } + window.plugins.socialsharing.share(text, null, null, null); + } else { + ionicToast.show(gettextCatalog.getString('Copied to clipboard'), 'bottom', false, 3000); + clipboardService.copyToClipboard(explorerTxUrl); + } + + } + function startExpirationTimer(expirationTime) { vm.paymentExpired = false; setExpirationTime(); From 197ee9eeeb49e216192b4dab37261a7929bf796b Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Tue, 14 Aug 2018 17:24:17 +1200 Subject: [PATCH 366/386] Fix for the Custom Amount screen now following the price display setting. --- www/views/customAmount.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/www/views/customAmount.html b/www/views/customAmount.html index a7130a729..079a5543d 100644 --- a/www/views/customAmount.html +++ b/www/views/customAmount.html @@ -31,13 +31,13 @@

-
+
-
+
From f18546b8d639f383d81c59df6a91e67388c06056 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 14 Aug 2018 16:48:55 +0900 Subject: [PATCH 367/386] Update appConfig.json --- app-template/bitcoincom/appConfig.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app-template/bitcoincom/appConfig.json b/app-template/bitcoincom/appConfig.json index 084a586ce..4b3281f6e 100644 --- a/app-template/bitcoincom/appConfig.json +++ b/app-template/bitcoincom/appConfig.json @@ -24,9 +24,9 @@ "windowsAppId": "804636ee-b017-4cad-8719-e58ac97ffa5c", "pushSenderId": "1036948132229", "description": "A Secure Bitcoin Wallet", - "version": "4.13.2", - "fullVersion": "4.13-rc3", - "androidVersion": "413200", + "version": "5.0.0", + "fullVersion": "5.0-rc1", + "androidVersion": "500000", "_extraCSS": "", "_enabledExtensions": { "coinbase": false, From 5a5d31d45dabd4f05b1280e89df43bd06fefd456 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Tue, 14 Aug 2018 17:13:44 +0900 Subject: [PATCH 368/386] Fix for building android release --- app-template/package-template.json | 2 +- src/android/build-extras.gradle | 42 ++++++++++++++++-------------- 2 files changed, 24 insertions(+), 20 deletions(-) diff --git a/app-template/package-template.json b/app-template/package-template.json index 232ac7e1f..0aa5da5dc 100644 --- a/app-template/package-template.json +++ b/app-template/package-template.json @@ -119,7 +119,7 @@ "run:android": "cordova run android --device", "run:android-release": "cordova run android --device --release", "log:android": "adb logcat | grep chromium", - "sign:android": "rm -f platforms/android/build/outputs/apk/android-release-signed-aligned.apk; jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore ../bitcoin-com-release-key.jks -signedjar platforms/android/build/outputs/apk/android-release-signed.apk platforms/android/build/outputs/apk/android-release-unsigned.apk bitcoin-com && $ANDROID_HOME/build-tools/27.0.1/zipalign -v 4 platforms/android/build/outputs/apk/android-release-signed.apk platforms/android/build/outputs/apk/android-release-signed-aligned.apk", + "sign:android": "rm -f platforms/android/build/outputs/apk/android-release-signed-aligned.apk; jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore ../bitcoin-com-release-key.jks -signedjar platforms/android/build/outputs/apk/android-release-signed.apk platforms/android/build/outputs/apk/android-release-unsigned.apk bitcoin-com && zipalign -v 4 platforms/android/build/outputs/apk/android-release-signed.apk platforms/android/build/outputs/apk/android-release-signed-aligned.apk", "apply:copay": "npm i fs-extra && cd app-template && node apply.js copay && npm i && cordova prepare", "apply:bitpay": "npm i fs-extra && cd app-template && node apply.js bitpay && npm i && cordova prepare", "apply:bitcoincom": "npm i fs-extra && cd app-template && node apply.js bitcoincom && npm i && cordova prepare", diff --git a/src/android/build-extras.gradle b/src/android/build-extras.gradle index dcc6df0ad..e7dd50572 100644 --- a/src/android/build-extras.gradle +++ b/src/android/build-extras.gradle @@ -1,21 +1,25 @@ +ext { + ANDROID_SUPPORT_V4_VERSION = '26.1.0' +} + configurations.all { - resolutionStrategy { - force "com.android.support:support-v4:26.1.0" - force "com.google.android.gms:play-services-auth:11.8.0" - force "com.google.android.gms:play-services-identity:11.8.0" - force "com.google.android.gms:play-services-ads:11.8.0" - force "com.google.android.gms:play-services-base:11.8.0" - force "com.google.android.gms:play-services-gcm:11.8.0" - force "com.google.android.gms:play-services-analytics:11.8.0" - force "com.google.android.gms:play-services-location:11.8.0" - force "com.google.android.gms:play-services-basement:11.8.0" - force "com.google.android.gms:play-services-tagmanager:11.8.0" - force 'com.google.firebase:firebase-core:11.8.0' - force 'com.google.firebase:firebase-crash:11.8.0' - force 'com.google.firebase:firebase-auth:11.8.0' - force 'com.google.firebase:firebase-common:11.8.0' - force 'com.google.firebase:firebase-config:11.8.0' - force 'com.google.firebase:firebase-perf:11.8.0' - force 'com.google.firebase:firebase-messaging:11.8.0' - } + resolutionStrategy { + force "com.android.support:support-v4:26.1.0" + force "com.google.android.gms:play-services-auth:11.8.0" + force "com.google.android.gms:play-services-identity:11.8.0" + force "com.google.android.gms:play-services-ads:11.8.0" + force "com.google.android.gms:play-services-base:11.8.0" + force "com.google.android.gms:play-services-gcm:11.8.0" + force "com.google.android.gms:play-services-analytics:11.8.0" + force "com.google.android.gms:play-services-location:11.8.0" + force "com.google.android.gms:play-services-basement:11.8.0" + force "com.google.android.gms:play-services-tagmanager:11.8.0" + force 'com.google.firebase:firebase-core:11.8.0' + force 'com.google.firebase:firebase-crash:11.8.0' + force 'com.google.firebase:firebase-auth:11.8.0' + force 'com.google.firebase:firebase-common:11.8.0' + force 'com.google.firebase:firebase-config:11.8.0' + force 'com.google.firebase:firebase-perf:11.8.0' + force 'com.google.firebase:firebase-messaging:11.8.0' + } } \ No newline at end of file From abe71a80772753219df9ef4bbe4151d1122fc5f8 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 14 Aug 2018 10:27:27 +0200 Subject: [PATCH 369/386] typo in template.pot --- i18n/po/template.pot | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/i18n/po/template.pot b/i18n/po/template.pot index 7caae0168..9c0e3bdc6 100644 --- a/i18n/po/template.pot +++ b/i18n/po/template.pot @@ -3160,7 +3160,7 @@ msgid "To start the process you need to add funds to your wallet." msgstr "" #: www/views/shapeshift.html:30 -msgid "he process is fast and you will receive the exchanged amount in your wallet." +msgid "The process is fast and you will receive the exchanged amount in your wallet." msgstr "" #: www/views/shapeshift.html:34 From 448679d1a619ddf5c07bc9a0c4d5a7cd5507efc4 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 14 Aug 2018 14:05:22 +0200 Subject: [PATCH 370/386] receive tab not showing fiat amount on receiving amount ("payment received" screen) --- src/js/controllers/tab-receive.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/js/controllers/tab-receive.js b/src/js/controllers/tab-receive.js index 0e80f4382..66d1799f8 100644 --- a/src/js/controllers/tab-receive.js +++ b/src/js/controllers/tab-receive.js @@ -138,7 +138,9 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi $scope.paymentReceivedAlternativeAmount = ''; // For when a subsequent payment is received. txFormatService.formatAlternativeStr($scope.wallet.coin, data.x.out[i].value, function(alternativeStr){ if (alternativeStr) { - $scope.paymentReceivedAlternativeAmount = alternativeStr; + $scope.$apply(function () { + $scope.paymentReceivedAlternativeAmount = alternativeStr; + }); } }); } From 99d8de02da698a0aa14434c1b4aa938dd2acb404 Mon Sep 17 00:00:00 2001 From: Sebastiaan Pasma Date: Tue, 14 Aug 2018 15:53:18 +0200 Subject: [PATCH 371/386] Show pasted address instead of always cashaddr format on bch --- src/js/controllers/amount.js | 1 + src/js/controllers/review.controller.js | 9 +++++---- src/js/services/incomingData.js | 5 +++-- src/js/services/sendFlowService.js | 2 ++ src/sass/components/address-frame.scss | 4 ++-- www/views/review.html | 7 ++++++- 6 files changed, 19 insertions(+), 9 deletions(-) diff --git a/src/js/controllers/amount.js b/src/js/controllers/amount.js index c2dcc6cd4..f796f9559 100644 --- a/src/js/controllers/amount.js +++ b/src/js/controllers/amount.js @@ -456,6 +456,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory, var confirmData = { amount: useSendMax ? undefined : satoshis, + displayAddress: passthroughParams.displayAddress, fromWalletId: passthroughParams.fromWalletId, sendMax: useSendMax, toAddress: passthroughParams.toAddress, diff --git a/src/js/controllers/review.controller.js b/src/js/controllers/review.controller.js index 788368e9e..b377bef58 100644 --- a/src/js/controllers/review.controller.js +++ b/src/js/controllers/review.controller.js @@ -19,6 +19,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit kind: '', // 'address', 'contact', 'wallet' name: '' }; + vm.displayAddress = ''; vm.feeCrypto = ''; vm.feeFiat = ''; vm.fiatCurrency = ''; @@ -56,10 +57,9 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit var sendFlowData; var config = null; - var countDown = null; - var defaults = {}; var coin = ''; var countDown = null; + var defaults = {}; var usingCustomFee = false; var usingMerchantFee = false; var destinationWalletId = ''; @@ -85,7 +85,8 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit satoshis = parseInt(sendFlowData.amount, 10); toAddress = sendFlowData.toAddress; destinationWalletId = sendFlowData.toWalletId; - + + vm.displayAddress = sendFlowData.displayAddress; vm.originWallet = profileService.getWallet(originWalletId); vm.origin.currency = vm.originWallet.coin.toUpperCase(); coin = vm.originWallet.coin; @@ -104,7 +105,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit priceDisplayIsFiat = config.wallet.settings.priceDisplay === 'fiat'; vm.origin.currencyColor = (vm.originWallet.coin === 'btc' ? defaults.bitcoinWalletColor : defaults.bitcoinCashWalletColor); console.log("coin", vm.originWallet.coin, vm.origin.currencyColor, config.bitcoinWalletColor, vm.originWallet.coin === 'btc'); - unitFromSat = 1 / config.wallet.settings.unitToSatoshi; + unitFromSat = 1 / config.wallet.settings.unitToSatoshi; } updateSendAmounts(); getOriginWalletBalance(vm.originWallet); diff --git a/src/js/services/incomingData.js b/src/js/services/incomingData.js index 9fad8b0f5..0bf708d8a 100644 --- a/src/js/services/incomingData.js +++ b/src/js/services/incomingData.js @@ -11,7 +11,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat root.redir = function(data, serviceId, serviceData) { var originalAddress = null; var noPrefixInAddress = 0; - + if (data.toLowerCase().indexOf('bitcoin') < 0) { noPrefixInAddress = 1; } @@ -83,7 +83,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat // Timeout is required to enable the "Back" button $timeout(function() { var params = sendFlowService.getStateClone(); - + if (amount) { params.amount = amount; } @@ -390,6 +390,7 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat $timeout(function() { var stateParams = { toAddress: toAddress, + displayAddress: toAddress, coin: coin, noPrefix: 1 }; diff --git a/src/js/services/sendFlowService.js b/src/js/services/sendFlowService.js index fcb061c26..62989b3c5 100644 --- a/src/js/services/sendFlowService.js +++ b/src/js/services/sendFlowService.js @@ -13,6 +13,7 @@ angular // even other properties added that this service does not know about. (such as "coin") state: { amount: '', + displayAddress: null, fromWalletId: '', sendMax: false, thirdParty: null, @@ -42,6 +43,7 @@ angular console.log("sendFlow clearCurrent()"); service.state = { amount: '', + displayAddress: null, fromWalletId: '', sendMax: false, thirdParty: null, diff --git a/src/sass/components/address-frame.scss b/src/sass/components/address-frame.scss index b06ce8bea..8aecce6d6 100644 --- a/src/sass/components/address-frame.scss +++ b/src/sass/components/address-frame.scss @@ -9,8 +9,8 @@ text-overflow: ellipsis; &.expanded { - white-space: pre-wrap; - word-break: break-all; + white-space: normal; + text-overflow: clip; } .prefix { diff --git a/www/views/review.html b/www/views/review.html index 50fcfbcac..a61490a11 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -57,7 +57,12 @@
- {{vm.destination.address.substring(0,5)}}{{vm.destination.address.substring(5,vm.destination.address.length-4)}}{{vm.destination.address.substring(vm.destination.address.length-4)}} + + {{vm.destination.address.substring(0,5)}}{{vm.destination.address.substring(5,vm.destination.address.length-4)}}{{vm.destination.address.substring(vm.destination.address.length-4)}} + + + {{vm.displayAddress.substring(0,5)}}{{vm.displayAddress.substring(5,vm.displayAddress.length-4)}}{{vm.displayAddress.substring(vm.displayAddress.length-4)}} +
From 8dd573624d6b00adad02822b99451584b4ddc56d Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Wed, 15 Aug 2018 12:31:03 +1200 Subject: [PATCH 372/386] View change for previous fix. --- www/views/review.html | 1 + 1 file changed, 1 insertion(+) diff --git a/www/views/review.html b/www/views/review.html index 50fcfbcac..9e2a07d21 100644 --- a/www/views/review.html +++ b/www/views/review.html @@ -111,6 +111,7 @@ Payment Sent Proposal Created From acee3024a9ce0c0bf8bf0f7f1da2431b755ec103 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 16 Aug 2018 17:51:08 +0900 Subject: [PATCH 373/386] Quick fix for asn1 --- app-template/package-template.json | 2 +- fix-asn1.sh | 11 +++++++++++ 2 files changed, 12 insertions(+), 1 deletion(-) create mode 100755 fix-asn1.sh diff --git a/app-template/package-template.json b/app-template/package-template.json index 0aa5da5dc..dd714d43f 100644 --- a/app-template/package-template.json +++ b/app-template/package-template.json @@ -122,7 +122,7 @@ "sign:android": "rm -f platforms/android/build/outputs/apk/android-release-signed-aligned.apk; jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore ../bitcoin-com-release-key.jks -signedjar platforms/android/build/outputs/apk/android-release-signed.apk platforms/android/build/outputs/apk/android-release-unsigned.apk bitcoin-com && zipalign -v 4 platforms/android/build/outputs/apk/android-release-signed.apk platforms/android/build/outputs/apk/android-release-signed-aligned.apk", "apply:copay": "npm i fs-extra && cd app-template && node apply.js copay && npm i && cordova prepare", "apply:bitpay": "npm i fs-extra && cd app-template && node apply.js bitpay && npm i && cordova prepare", - "apply:bitcoincom": "npm i fs-extra && cd app-template && node apply.js bitcoincom && npm i && cordova prepare", + "apply:bitcoincom": "npm i fs-extra && cd app-template && node apply.js bitcoincom && npm i && cordova prepare && cd ../ && ./fix-asn1.sh", "test": "karma start test/karma.conf.js --single-run", "clean": "trash platforms && trash plugins && cordova prepare", "unstage-package": "git reset package.json", diff --git a/fix-asn1.sh b/fix-asn1.sh new file mode 100755 index 000000000..40c847b3f --- /dev/null +++ b/fix-asn1.sh @@ -0,0 +1,11 @@ +#!/bin/bash + +firstLine=`awk 'NR < 2 {print}' node_modules/asn1.js-rfc5280/index.js` + +if [ "$firstLine" = "try {" ]; then + echo "var asn1 = require('asn1.js');" > node_modules/asn1.js-rfc5280/index.new.js + awk 'NR > 6 {print}' node_modules/asn1.js-rfc5280/index.js >> node_modules/asn1.js-rfc5280/index.new.js + rm node_modules/asn1.js-rfc5280/index.js + mv node_modules/asn1.js-rfc5280/index.new.js node_modules/asn1.js-rfc5280/index.js + echo "[log] node_modules/asn1.js-rfc5280/index.js fixed" +fi \ No newline at end of file From 56be096207f49ee0f94d7a071bdf01bc8081da5d Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 16 Aug 2018 17:51:20 +0900 Subject: [PATCH 374/386] quick fix for asn1 From e6ae1c052054f0c86e0022d969f23cbba41bbe59 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 16 Aug 2018 17:51:59 +0900 Subject: [PATCH 375/386] Add the command in package.json From e8f7126c89f1c1611a34f057e679a0fb5050d8e1 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 16 Aug 2018 17:52:23 +0900 Subject: [PATCH 376/386] package.json From eee1a69d84a7f415552b60405295ecfb9d051504 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Thu, 16 Aug 2018 17:54:51 +0900 Subject: [PATCH 377/386] Update package.json --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index c1f37b2e6..e1a181308 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ "postinstall": "npm run apply:copay && echo && echo \"Repo configured for standard Copay distribution. To switch to the BitPay distribution, run 'npm run apply:bitpay'.\" && echo", "start": "echo && echo \"Choose a distribution by running 'npm run apply:copay' or 'npm run apply:bitpay'.\" && echo", "apply:copay": "npm i fs-extra@0.30 && cd app-template && node apply.js copay && cd .. && npm i", - "apply:bitcoincom": "npm i fs-extra && cd app-template && node apply.js bitcoincom && npm i && cordova prepare", + "apply:bitcoincom": "npm i fs-extra && cd app-template && node apply.js bitcoincom && npm i && cordova prepare && cd .. && ./fix-asn1.sh", "apply:bitpay": "npm i fs-extra@0.30 && cd app-template && node apply.js bitpay && cd .. && npm i", "unstage-package": "git reset package.json", "clean-all": "git clean -dfx" From aa75ba18d6ad3b8440ffd3f1c6014cd260b8020e Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 17 Aug 2018 11:45:43 +1200 Subject: [PATCH 378/386] Removed old content. --- www/views/shapeshift.html | 97 --------------------------------------- 1 file changed, 97 deletions(-) diff --git a/www/views/shapeshift.html b/www/views/shapeshift.html index 61ad0952e..94a679f7b 100644 --- a/www/views/shapeshift.html +++ b/www/views/shapeshift.html @@ -29,101 +29,4 @@
This service is provided by the third-party ShapeShift, who will charge a small fee for the service. The fee will be shown before you start the transaction.
- - -
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - From b3e34483b672b0cee628b1a97c56efd59c137021 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 17 Aug 2018 11:59:27 +1200 Subject: [PATCH 379/386] Show my address button. --- src/js/controllers/shapeshift.js | 17 +++++++++-------- www/views/shapeshift.html | 1 + 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/src/js/controllers/shapeshift.js b/src/js/controllers/shapeshift.js index 3538ebe1a..43e0790d1 100644 --- a/src/js/controllers/shapeshift.js +++ b/src/js/controllers/shapeshift.js @@ -4,6 +4,8 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi var walletsBtc = []; var walletsBch = []; + $scope.showMyAddress = showMyAddress; + function generateAddress(wallet, cb) { if (!wallet) return; walletService.getAddress(wallet, false, function(err, addr) { @@ -41,14 +43,6 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi $ionicNavBarDelegate.showBar(true); }); - $scope.showFromWalletSelector = function() { - $scope.showFromWallets = true; - }; - - $scope.showToWalletSelector = function() { - $scope.showToWallets = true; - }; - // This could probably be enhanced refactoring the routes abstract states $scope.createWallet = function() { $state.go('tabs.home').then(function() { @@ -81,4 +75,11 @@ angular.module('copayApp.controllers').controller('shapeshiftController', functi }); }); } + + function showMyAddress() { + $state.go('tabs.home').then(function() { + $state.go('tabs.receive'); + }); + } + }); diff --git a/www/views/shapeshift.html b/www/views/shapeshift.html index 94a679f7b..5d6dd3780 100644 --- a/www/views/shapeshift.html +++ b/www/views/shapeshift.html @@ -23,6 +23,7 @@
To get started, you'll need to create a bitcoin wallet and get some bitcoin.
+
From 26891f6e47f6b15150a6589d9bfdf9326670f1f0 Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Fri, 17 Aug 2018 16:54:04 +1200 Subject: [PATCH 380/386] Cleaned up log message. --- fix-asn1.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fix-asn1.sh b/fix-asn1.sh index 40c847b3f..1dbca6a67 100755 --- a/fix-asn1.sh +++ b/fix-asn1.sh @@ -7,5 +7,5 @@ if [ "$firstLine" = "try {" ]; then awk 'NR > 6 {print}' node_modules/asn1.js-rfc5280/index.js >> node_modules/asn1.js-rfc5280/index.new.js rm node_modules/asn1.js-rfc5280/index.js mv node_modules/asn1.js-rfc5280/index.new.js node_modules/asn1.js-rfc5280/index.js - echo "[log] node_modules/asn1.js-rfc5280/index.js fixed" + echo "node_modules/asn1.js-rfc5280/index.js fixed" fi \ No newline at end of file From a67f9acbc6566bd4ebd4428fd4ab02b83b28967a Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Sat, 18 Aug 2018 00:51:08 +0900 Subject: [PATCH 381/386] Resolution package --- app-template/package-template.json | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app-template/package-template.json b/app-template/package-template.json index 232ac7e1f..616658b92 100644 --- a/app-template/package-template.json +++ b/app-template/package-template.json @@ -140,5 +140,9 @@ "lodash": "^4.17.4", "pre-commit": "^1.1.3" }, + "resolutions": { + "angular": "1.5.3", + "ionic": "1b7414faba" + }, "pre-commit": "unstage-package" } \ No newline at end of file From 6dcc221ee12727584d2652c49ce91048f66acaa3 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Sat, 18 Aug 2018 01:17:04 +0900 Subject: [PATCH 382/386] ionic resolution --- app-template/package-template.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app-template/package-template.json b/app-template/package-template.json index 8c2bd05d0..660dc81bb 100644 --- a/app-template/package-template.json +++ b/app-template/package-template.json @@ -142,7 +142,7 @@ }, "resolutions": { "angular": "1.5.3", - "ionic": "1b7414faba" + "ionic": "eefba1331b" }, "pre-commit": "unstage-package" } \ No newline at end of file From 154e495846c9387968d66afb2dc942bd6fee25c4 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Sat, 18 Aug 2018 01:29:04 +0900 Subject: [PATCH 383/386] Update package.json --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index c1f37b2e6..e54e3d14d 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ "postinstall": "npm run apply:copay && echo && echo \"Repo configured for standard Copay distribution. To switch to the BitPay distribution, run 'npm run apply:bitpay'.\" && echo", "start": "echo && echo \"Choose a distribution by running 'npm run apply:copay' or 'npm run apply:bitpay'.\" && echo", "apply:copay": "npm i fs-extra@0.30 && cd app-template && node apply.js copay && cd .. && npm i", - "apply:bitcoincom": "npm i fs-extra && cd app-template && node apply.js bitcoincom && npm i && cordova prepare", + "apply:bitcoincom": "npm i fs-extra && cd app-template && node apply.js bitcoincom && npm i && cordova prepare && cd ../ && ./fix-asn1.sh", "apply:bitpay": "npm i fs-extra@0.30 && cd app-template && node apply.js bitpay && cd .. && npm i", "unstage-package": "git reset package.json", "clean-all": "git clean -dfx" From f4346fd921f0756c0d675addf679d58550f652c8 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Sat, 18 Aug 2018 02:02:50 +0900 Subject: [PATCH 384/386] Update bower.json --- bower.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bower.json b/bower.json index 08a82d9b8..d94800d24 100644 --- a/bower.json +++ b/bower.json @@ -24,6 +24,6 @@ }, "resolutions": { "angular": "1.5.3", - "ionic": "1b7414faba" + "ionic": "eefba1331b" } } From d06e9f7088eee701f01caa1279a3c92333807f5b Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Dominguez Date: Sat, 18 Aug 2018 02:03:23 +0900 Subject: [PATCH 385/386] Update package-template.json --- app-template/package-template.json | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/app-template/package-template.json b/app-template/package-template.json index 660dc81bb..c42ef81b4 100644 --- a/app-template/package-template.json +++ b/app-template/package-template.json @@ -140,9 +140,5 @@ "lodash": "^4.17.4", "pre-commit": "^1.1.3" }, - "resolutions": { - "angular": "1.5.3", - "ionic": "eefba1331b" - }, "pre-commit": "unstage-package" -} \ No newline at end of file +} From 39bcb9daaef611cbc86cc3d9180ba8cb3ecb3fdf Mon Sep 17 00:00:00 2001 From: Brendon Duncan Date: Thu, 23 Aug 2018 16:21:15 +1200 Subject: [PATCH 386/386] Tweak strings to match translations. --- www/views/tab-receive.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/www/views/tab-receive.html b/www/views/tab-receive.html index 773b3249d..07cad7f7e 100644 --- a/www/views/tab-receive.html +++ b/www/views/tab-receive.html @@ -31,7 +31,7 @@


@@ -69,8 +69,8 @@