mirror of https://github.com/BTCPrivate/copay.git
Merge pull request #5619 from JDonadio/ref/scrolling
Scrolling and clipboard refactor
This commit is contained in:
commit
4fcc058049
|
@ -97,6 +97,12 @@ angular.module('copayApp.controllers').controller('backupController',
|
|||
});
|
||||
};
|
||||
|
||||
$scope.copyRecoveryPhrase = function() {
|
||||
if ($scope.wallet.network == 'livenet') return null;
|
||||
else if (!$scope.wallet.credentials.mnemonic) return null;
|
||||
else return $scope.wallet.credentials.mnemonic;
|
||||
};
|
||||
|
||||
var confirm = function(cb) {
|
||||
$scope.backupError = false;
|
||||
|
||||
|
|
|
@ -18,6 +18,8 @@ angular.module('copayApp.directives')
|
|||
var msg = gettextCatalog.getString('Copied to clipboard');
|
||||
elem.bind('click', function() {
|
||||
var data = scope.copyToClipboard;
|
||||
if (!data) return;
|
||||
|
||||
if (isCordova) {
|
||||
window.cordova.plugins.clipboard.copy(data);
|
||||
window.plugins.toast.showShortCenter(msg);
|
||||
|
@ -36,4 +38,3 @@ angular.module('copayApp.directives')
|
|||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
@ -36,6 +36,9 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr
|
|||
// CHECKBOX CIRCLE
|
||||
$ionicConfigProvider.form.checkbox('circle');
|
||||
|
||||
// USE NATIVE SCROLLING
|
||||
$ionicConfigProvider.scrolling.jsScrolling(false);
|
||||
|
||||
$logProvider.debugEnabled(true);
|
||||
$provide.decorator('$log', ['$delegate', 'platformInfo',
|
||||
function($delegate, platformInfo) {
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<ion-nav-back-button>
|
||||
</ion-nav-back-button>
|
||||
</ion-nav-bar>
|
||||
<ion-content overflow-scroll="true">
|
||||
<ion-content>
|
||||
<div class="ng-hide" ng-show="deleted">
|
||||
<div class="phrase-unavailable" translate>Wallet recovery phrase not available.</div>
|
||||
<div class="phrase-unavailable-instructions" translate>You can still export it from Advanced > Export.</div>
|
||||
|
@ -16,7 +16,7 @@
|
|||
-->
|
||||
<div id="wallet-backup-phrase-step-1" class="ng-hide" ng-show="step == 1 && (mnemonicWords || (!credentialsEncrypted && !deleted))">
|
||||
<div class="initial-prompt" translate>Please carefully write down this phrase.</div>
|
||||
<div class="backup-phrase" ng-class="{'enable_text_select': wallet.network == 'testnet'}">
|
||||
<div class="backup-phrase" copy-to-clipboard="copyRecoveryPhrase()">
|
||||
<div class="backup-phrase-content">
|
||||
<span class="backup-phrase-content-word-readonly" ng-repeat="word in mnemonicWords track by $index"><span style="white-space:nowrap">{{word}}</span><span ng-show="useIdeograms"> </span> </span>
|
||||
</div>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<ion-nav-back-button>
|
||||
</ion-nav-back-button>
|
||||
</ion-nav-bar>
|
||||
<ion-content overflow-scroll="true">
|
||||
<ion-content>
|
||||
<div class="settings-button-group">
|
||||
<button class="button button-standard button-primary" style="margin-top: 1rem" copy-to-clipboard="prepare()">
|
||||
<i class="icon ion-clipboard"></i>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
</ion-nav-back-button>
|
||||
</ion-nav-bar>
|
||||
|
||||
<ion-content overflow-scroll="true">
|
||||
<ion-content>
|
||||
<div class="list">
|
||||
<div class="item item-text-wrap" id="settings-tos" ng-include="'views/includes/terms.html'"></div>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue