mirror of https://github.com/BTCPrivate/copay.git
Merge pull request #218 from jamal-jackson/feature/onboarding_last_steps
Add Back Button to Disclaimer view
This commit is contained in:
commit
6aa7b81c81
|
@ -1,9 +1,17 @@
|
||||||
<ion-view id="onboarding-disclaimer" class="onboarding">
|
<ion-view id="onboarding-disclaimer" class="onboarding" ng-controller="disclaimerController" ng-init=init()>
|
||||||
<ion-content ng-controller="disclaimerController" ng-init=init() scroll="false">
|
<ion-nav-bar class="bar-stable" ng-if="backedUp == 'false'">
|
||||||
|
<ion-nav-title></ion-nav-title>
|
||||||
|
<ion-nav-buttons side="primary">
|
||||||
|
<button class="button back-button button-clear" ng-click="goBack()">
|
||||||
|
<i class="icon ion-ios-arrow-thin-left"></i>
|
||||||
|
</button>
|
||||||
|
</ion-nav-buttons>
|
||||||
|
</ion-nav-bar>
|
||||||
|
<ion-content scroll="false" ng-class="{'has-header': backedUp == 'false'}">
|
||||||
<div class="row text-center">
|
<div class="row text-center">
|
||||||
<h3 translate class="col-75 col">Almost done! Let's review</h3>
|
<h3 translate class="col-75 col">Almost done! Let's review</h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="row text-center">
|
<div class="row text-center tag">
|
||||||
<p translate class="col col-75">
|
<p translate class="col col-75">
|
||||||
Bitcoin is different - it cannot be safely held with a bank or web service
|
Bitcoin is different - it cannot be safely held with a bank or web service
|
||||||
</p>
|
</p>
|
||||||
|
@ -12,7 +20,7 @@
|
||||||
<ion-checkbox ng-model="accept1"><span translate>I understand my funds are held securely on this device, not by a company.</span></ion-checkbox>
|
<ion-checkbox ng-model="accept1"><span translate>I understand my funds are held securely on this device, not by a company.</span></ion-checkbox>
|
||||||
<ion-checkbox ng-model="accept2"><span translate>I understand if this app moved to another device or deleted, my bitcoin can only be recovered with the backup phrase</span></ion-checkbox>
|
<ion-checkbox ng-model="accept2"><span translate>I understand if this app moved to another device or deleted, my bitcoin can only be recovered with the backup phrase</span></ion-checkbox>
|
||||||
</ion-list>
|
</ion-list>
|
||||||
<div id="agree-to-terms" ng-if="accept1 && accept2">
|
<div id="agree-to-terms" ng-if="accept1 && accept2" ng-class="{'header-present': backedUp == 'false'}">
|
||||||
<div id="agree-to-terms-content" class="center-block">
|
<div id="agree-to-terms-content" class="center-block">
|
||||||
<ion-checkbox ng-model="terms.accept3"></ion-checkbox>
|
<ion-checkbox ng-model="terms.accept3"></ion-checkbox>
|
||||||
<p translate>I have read, understood, and agree with the <a ng-click="openTermsModal()" translate>Terms of use</a>.</p>
|
<p translate>I have read, understood, and agree with the <a ng-click="openTermsModal()" translate>Terms of use</a>.</p>
|
||||||
|
|
|
@ -91,7 +91,7 @@ angular.module('copayApp.controllers').controller('backupController',
|
||||||
$ionicHistory.removeBackView();
|
$ionicHistory.removeBackView();
|
||||||
$state.go('tabs.home');
|
$state.go('tabs.home');
|
||||||
}
|
}
|
||||||
else $state.go('onboarding.disclaimer');
|
else $state.go('onboarding.disclaimer', {walletId: $stateParams.walletId, backedUp: true});
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -18,7 +18,7 @@ angular.module('copayApp.controllers').controller('backupRequestController', fun
|
||||||
var cancelText = gettextCatalog.getString('Go back');
|
var cancelText = gettextCatalog.getString('Go back');
|
||||||
popupService.showConfirm(title, message, okText, cancelText, function(val) {
|
popupService.showConfirm(title, message, okText, cancelText, function(val) {
|
||||||
if (val) {
|
if (val) {
|
||||||
$state.go('onboarding.disclaimer');
|
$state.go('onboarding.disclaimer', {walletId: $scope.walletId, backedUp: false});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
angular.module('copayApp.controllers').controller('disclaimerController', function($scope, $timeout, $state, $log, $ionicModal, profileService, uxLanguage, externalLinkService) {
|
angular.module('copayApp.controllers').controller('disclaimerController', function($scope, $timeout, $state, $log, $ionicModal, profileService, uxLanguage, externalLinkService, storageService, $stateParams) {
|
||||||
|
|
||||||
$scope.init = function() {
|
$scope.init = function() {
|
||||||
$scope.lang = uxLanguage.currentLanguage;
|
$scope.lang = uxLanguage.currentLanguage;
|
||||||
$scope.terms = {};
|
$scope.terms = {};
|
||||||
$scope.accept1 = $scope.accept2 = $scope.accept3 = false;
|
$scope.accept1 = $scope.accept2 = $scope.accept3 = false;
|
||||||
|
$scope.backedUp = $stateParams.backedUp;
|
||||||
$timeout(function() {
|
$timeout(function() {
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
}, 1);
|
}, 1);
|
||||||
|
@ -34,4 +34,10 @@ angular.module('copayApp.controllers').controller('disclaimerController', functi
|
||||||
$scope.termsModal.show();
|
$scope.termsModal.show();
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
$scope.goBack = function(){
|
||||||
|
$state.go('onboarding.backupRequest', {walletId: $stateParams.walletId});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
|
@ -685,7 +685,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.state('onboarding.disclaimer', {
|
.state('onboarding.disclaimer', {
|
||||||
url: '/disclaimer',
|
url: '/disclaimer/:walletId/:backedUp',
|
||||||
views: {
|
views: {
|
||||||
'onboarding': {
|
'onboarding': {
|
||||||
templateUrl: 'views/onboarding/disclaimer.html'
|
templateUrl: 'views/onboarding/disclaimer.html'
|
||||||
|
|
|
@ -3,6 +3,9 @@
|
||||||
height: 100%;
|
height: 100%;
|
||||||
ion-content{
|
ion-content{
|
||||||
height: 100%;
|
height: 100%;
|
||||||
|
&.has-header{
|
||||||
|
top:40px !important;
|
||||||
|
}
|
||||||
.scroll{
|
.scroll{
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
|
@ -10,9 +13,17 @@
|
||||||
margin-top:1.5rem;
|
margin-top:1.5rem;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.tag{
|
||||||
|
padding-bottom: 0;
|
||||||
|
}
|
||||||
.list{
|
.list{
|
||||||
max-width: 600px;
|
max-width: 600px;
|
||||||
@include center-block();
|
@include center-block();
|
||||||
|
.item{
|
||||||
|
&:first-child{
|
||||||
|
padding-top: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.item {
|
.item {
|
||||||
background: transparent;
|
background: transparent;
|
||||||
|
@ -59,6 +70,9 @@
|
||||||
position: absolute;
|
position: absolute;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
&.header-present{
|
||||||
|
bottom:16px;
|
||||||
|
}
|
||||||
&-content{
|
&-content{
|
||||||
max-width: 600px;
|
max-width: 600px;
|
||||||
@include center-block();
|
@include center-block();
|
||||||
|
|
Loading…
Reference in New Issue