Ref About

This commit is contained in:
Gustavo Maximiliano Cortez 2016-09-05 14:59:11 -03:00
parent 9908046766
commit a200d42bcd
No known key found for this signature in database
GPG Key ID: 15EDAD8D9F2EB1AF
25 changed files with 208 additions and 171 deletions

View File

@ -5,6 +5,8 @@
"nameCase": "Copay",
"nameCaseNoSpace": "Copay",
"bundleName": "copay",
"gitHubRepoName": "copay",
"disclaimerUrl": "https://copay.io/disclaimer",
"url": "https://copay.io",
"appDescription": "Copay Bitcoin Wallet",
"winAppName": "CopayWallet",
@ -18,5 +20,5 @@
"coinbase": true,
"glidera": true,
"amazon": true
}
}
}

View File

@ -10,7 +10,7 @@
<ion-content ng-controller="termsController" ng-init="accept = false;">
<div ng-include="'views/includes/terms.html'"></div>
<div class="padding-vertical" ng-show="lang != 'en'">
<a ng-click="$root.openExternalLink('https://copay.io/disclaimer')" translate>Official English Disclaimer</a>
<a ng-click="openExternalLink('https://copay.io/disclaimer')" translate>Official English Disclaimer</a>
</div>
<ion-list class="disclaimer">
<ion-checkbox ng-model="accept"><span translate>I have read, understood, and agree with the Terms of Use</span></ion-checkbox>

View File

@ -7,36 +7,41 @@
</ion-nav-buttons>
</ion-nav-bar>
<ion-content ng-controller="preferencesAbout">
<div class="item item-divider" translate>
Release information
</div>
<div class="item item-icon-left">
<i class="icon ion-ios-film-outline"></i>
<span translate>Version</span>
<span class="item-note">
v{{version}}
</span>
</div>
<div class="item item-icon-left" ng-click="$root.openExternalLink('https://github.com/bitpay/copay/tree/'+commitHash)">
<i class="icon ion-ios-film-outline"></i>
<span translate>Commit hash</span>
<span class="item-note">
#{{commitHash}}
</span>
</div>
<div class="item item-divider">
</div>
<div class="item item-icon-left" href ui-sref="tabs.termsOfUse">
<i class="icon ion-ios-bell-outline"></i>
<span translate>Terms of Use</span>
</div>
<div class="item item-icon-left" href ui-sref="tabs.translators">
<i class="icon ion-ios-bell-outline"></i>
<span translate>Translators</span>
</div>
<div class="item item-icon-left" href ui-sref="tabs.logs">
<i class="icon ion-ios-bell-outline"></i>
<span translate>Session log</span>
<div class="list">
<div class="item item-divider" translate>
Release information
</div>
<div class="item item-icon-left">
<i class="icon ion-ios-download-outline"></i>
<span translate>Version</span>
<span class="item-note">
v{{version}}
</span>
</div>
<div class="item item-icon-left" ng-click="openExternalLink('https://github.com/bitpay/'+name+'/tree/'+commitHash)">
<i class="icon ion-social-github-outline"></i>
<span translate>Commit hash</span>
<span class="item-note">
#{{commitHash}}
</span>
</div>
<div class="item item-divider">
</div>
<div class="item item-icon-left item-icon-right" href ui-sref="tabs.termsOfUse">
<i class="icon ion-ios-list-outline"></i>
<span translate>Terms of Use</span>
<i class="icon ion-ios-arrow-right"></i>
</div>
<div class="item item-icon-left item-icon-right" href ui-sref="tabs.translators">
<i class="icon ion-ios-people-outline"></i>
<span translate>Translators</span>
<i class="icon ion-ios-arrow-right"></i>
</div>
<div class="item item-icon-left item-icon-right" href ui-sref="tabs.logs">
<i class="icon ion-ios-copy-outline"></i>
<span translate>Session log</span>
<i class="icon ion-ios-arrow-right"></i>
</div>
</div>
</ion-content>
</ion-view>

View File

@ -8,10 +8,12 @@
<ion-radio ng-repeat="lang in availableLanguages" ng-value="lang.isoCode" ng-model="currentLanguage"
ng-click="save(lang.isoCode)">{{lang.name}}
</ion-radio>
<span translate>All contributions to Copay's translation are welcome. Sign up at crowdin.com and join the Copay project at</span>
<a ng-click="$root.openExternalLink('https://crowdin.com/project/copay', '_system')">https://crowdin.com/project/copay</a>.
<span translate>
Don't see your language on Crowdin? Contact the Owner on Crowdin! We'd love to support your language.
</span>
<div class="padding">
<span translate>All contributions to Copay's translation are welcome. Sign up at crowdin.com and join the Copay project at</span>
<a ng-click="openExternalLink('https://crowdin.com/project/copay', '_system')">https://crowdin.com/project/copay</a>.
<span translate>
Don't see your language on Crowdin? Contact the Owner on Crowdin! We'd love to support your language.
</span>
</div>
</ion-content>
</ion-view>

View File

@ -4,16 +4,25 @@
<i class="icon ion-ios-arrow-thin-left"></i>
</ion-nav-back-button>
</ion-nav-bar>
<ion-content ng-controller="preferencesLogs" ng-init="init()" >
<button ng-show="isCordova" ng-click="logs.sendLogs()"><i class="fi-mail"></i>
<span translate>Send by email</span>
<ion-content ng-controller="preferencesLogs" ng-init="init()">
<div class="card">
<div class="item item-text-wrap">
<ul>
<li ng-repeat="l in logs">
<span ng-class="{'energized': l.level=='warn', 'dark': l.level=='debug', 'positive': l.level=='info', 'assertive': l.level=='error' }">
{{l.msg}}
</span>
</li>
</ul>
</div>
</div>
<button class="button button-block button-positive" copy-to-clipboard="prepare()">
<i class="icon ion-clipboard"></i>
<span translate>Copy to clipboard</span>
</button>
<button class="button button-block button-positive" ng-show="isCordova" ng-click="sendLogs()">
<i class="icon ion-ios-email-outline"></i>
<span translate>Send by email</span>
</button>
<ul>
<li ng-repeat="l in logs">
<span ng-class="{'text-warning': l.level=='warn', 'text-secondary': l.level=='debug', 'text-primary': l.level=='info', 'text-alert': l.level=='error' }">
{{l.msg}}
</span>
</li>
</ul>
</ion-content>
</ion-view>

View File

@ -6,7 +6,6 @@
<ion-content ng-controller="tabSettingsController" ng-init="init()">
<div class="list">
<div class="item item-divider"></div>
<div class="item item-icon-left" ng-click="openAddressbookModal()">
<i class="icon ion-ios-book-outline"></i>
<span translate>Address Book</span>
@ -14,36 +13,40 @@
<div class="item item-divider" translate>Preferences</div>
<div class="item item-icon-left" href ui-sref="tabs.language">
<div class="item item-icon-left item-icon-right" ui-sref="tabs.language">
<i class="icon ion-ios-chatbubble-outline"></i>
<span translate>Language</span>
<span class="item-note">
{{currentLanguageName|translate}}
</span>
<i class="icon ion-ios-arrow-right"></i>
</div>
<div class="item item-icon-left" href ui-sref="tabs.unit">
<div class="item item-icon-left item-icon-right" ui-sref="tabs.unit">
<i class="icon ion-ios-calculator-outline"></i>
<span translate>Unit</span>
<span class="item-note">
{{unitName}}
</span>
<i class="icon ion-ios-arrow-right"></i>
</div>
<div class="item item-icon-left" href ui-sref="tabs.altCurrency">
<div class="item item-icon-left item-icon-right" ui-sref="tabs.altCurrency">
<i class="icon ion-social-usd-outline"></i>
<span translate>Alternative Currency</span>
<span class="item-note">
{{selectedAlternative.name}}
</span>
<i class="icon ion-ios-arrow-right"></i>
</div>
<div class="item item-icon-left" href ui-sref="tabs.fee">
<i class="icon ion-ios-film-outline"></i>
<div class="item item-icon-left item-icon-right" ui-sref="tabs.fee">
<i class="icon ion-social-bitcoin-outline"></i>
<span translate>Bitcoin Network Fee Policy</span>
<span class="item-note">
{{feeOpts[currentFeeLevel]|translate}}
</span>
<i class="icon ion-ios-arrow-right"></i>
</div>
<div ng-show="usePushNotifications && PNEnabledByUser">
@ -81,7 +84,7 @@
</ion-toggle>
<div class="item item-divider" translate>Wallets Settings</div>
<div class="item item-icon-left" href
<div class="item item-icon-left item-icon-right" href
ui-sref="tabs.preferences.main({'walletId': item.id})"
ng-repeat="item in wallets track by $index">
<i class="icon ion-briefcase size-21" ng-style="{'color':item.color}"></i>
@ -92,14 +95,15 @@
<span class="badge badge-assertive" ng-show="!item.isComplete()" translate>
Incomplete
</span>
<i class="icon ion-ios-arrow-right"></i>
</div>
<div class="item item-divider"></div>
<div class="item item-icon-left" href ui-sref="tabs.about">
<i class="icon ion-ios-film-outline"></i>
<span translate>About Bitpay Wallet</span>
<div class="item item-icon-left item-icon-right" href ui-sref="tabs.about">
<i class="icon ion-ios-information-outline"></i>
<span translate>About</span> {{appName}}
<i class="icon ion-ios-arrow-right"></i>
</div>
<div class="item item-divider"></div>
</div>
</ion-content>
</ion-view>

View File

@ -5,14 +5,14 @@
</ion-nav-back-button>
</ion-nav-bar>
<ion-content ng-controller="termOfUseController" cache-view="false">
<p>
<div ng-include="'views/includes/terms.html'"></div>
</p>
<div class="row">
<p ng-show="lang != 'en'">
<a ng-click="$root.openExternalLink('https://copay.io/disclaimer')" translate>Official English Disclaimer</a>
</p>
</div>
<ion-content class="padding" ng-controller="termOfUseController">
<div class="card">
<div class="item item-text-wrap" ng-include="'views/includes/terms.html'"></div>
</div>
<button class="button button-block button-positive"
ng-show="lang != 'en'"
ng-click="openExternalLink(disclaimerUrl)" translate>
Official English Disclaimer
</button>
</ion-content>
</ion-view>

View File

@ -5,29 +5,29 @@
<i class="icon ion-ios-arrow-thin-left"></i>
</ion-nav-back-button>
</ion-nav-bar>
<ion-content>
<h4 translate>Translation Credits</h4>
<ul>
<li >kinoshitajona<span translate>Japanese</span></li>
<li >Kirvx<span translate>French</span></li>
<li >saschad<span translate>German</span></li>
<li >cmgustavo83<span translate>Spanish</span></li>
<li >RussianNeuroMancer<span translate>Russian</span></li>
<li >HostFat<span translate>Italian</span></li>
<li >xm2hi<span translate>Chinese</span></li>
<li >Pirx1618<span translate>Polish</span></li>
<li >mareksip<span translate>Czech</span></li>
</ul>
<div class="row">
<div class="columns">
<p>
<span translate>All contributions to Copay's translation are welcome. Sign up at crowdin.com and join the Copay project at</span>
<a ng-click="$root.openExternalLink('https://crowdin.com/project/copay', '_system')">https://crowdin.com/project/copay</a>.
</p>
<spantranslate>
Don't see your language on Crowdin? Contact the Owner on Crowdin! We'd love to support your language.
</span>
</div>
<ion-content ng-controller="translatorsController">
<div class="list">
<div class="item item-divider" translate>
Translation Credits
</div>
<div class="item">kinoshitajona<span class="item-note" translate>Japanese</span></div>
<div class="item">Kirvx<span class="item-note" translate>French</span></div>
<div class="item">saschad<span class="item-note" translate>German</span></div>
<div class="item">cmgustavo83<span class="item-note" translate>Spanish</span></div>
<div class="item">RussianNeuroMancer<span class="item-note" translate>Russian</span></div>
<div class="item">HostFat<span class="item-note" translate>Italian</span></div>
<div class="item">xm2hi<span class="item-note" translate>Chinese</span></div>
<div class="item">Pirx1618<span class="item-note" translate>Polish</span></div>
<div class="item">mareksip<span class="item-note" translate>Czech</span></div>
</div>
<div class="padding">
<p>
<span translate>All contributions to Copay's translation are welcome. Sign up at crowdin.com and join the Copay project at</span>
<a ng-click="openExternalLink('https://crowdin.com/project/copay', '_system')">https://crowdin.com/project/copay</a>.
</p>
<span translate>
Don't see your language on Crowdin? Contact the Owner on Crowdin! We'd love to support your language.
</span>
</div>
</ion-content>
</ion-view>

View File

@ -94,7 +94,7 @@
</div>
</div>
<div class="release size-12" ng-show="newRelease" ng-click="$root.openExternalLink('https://github.com/bitpay/copay/releases/latest')">
<div class="release size-12" ng-show="newRelease" ng-click="openExternalLink('https://github.com/bitpay/copay/releases/latest')">
<span>{{newRelease}}</span><i class="icon-arrow-right3 right size-18"></i>
</div>

View File

@ -1,15 +1,10 @@
'use strict';
angular.module('copayApp.controllers').controller('amazonController',
function($scope, $timeout, $ionicModal, $log, lodash, bwcError, amazonService, platformInfo, nodeWebkit, popupService) {
function($scope, $timeout, $ionicModal, $log, lodash, bwcError, amazonService, platformInfo, externalLinkService, popupService) {
$scope.openExternalLink = function(url, target) {
if (platformInfo.isNW) {
nodeWebkit.openExternalLink(url);
} else {
target = target || '_blank';
var ref = window.open(url, target, 'location=no');
}
externalLinkService.open(url, target);
};
this.init = function() {

View File

@ -1,7 +1,7 @@
'use strict';
angular.module('copayApp.controllers').controller('buyAmazonController',
function($scope, $log, $timeout, $state, lodash, profileService, bwcError, gettextCatalog, configService, walletService, amazonService, ongoingProcess, platformInfo, nodeWebkit, popupService) {
function($scope, $log, $timeout, $state, lodash, profileService, bwcError, gettextCatalog, configService, walletService, amazonService, ongoingProcess, platformInfo, externalLinkService, popupService) {
var self = this;
var wallet;
@ -16,12 +16,7 @@ angular.module('copayApp.controllers').controller('buyAmazonController',
});
$scope.openExternalLink = function(url, target) {
if (platformInfo.isNW) {
nodeWebkit.openExternalLink(url);
} else {
target = target || '_blank';
var ref = window.open(url, target, 'location=no');
}
externalLinkService.open(url, target);
};
this.init = function() {

View File

@ -1,15 +1,10 @@
'use strict';
angular.module('copayApp.controllers').controller('glideraController',
function($scope, $timeout, $ionicModal, $log, storageService, glideraService, ongoingProcess, platformInfo, nodeWebkit, popupService, gettextCatalog) {
function($scope, $timeout, $ionicModal, $log, storageService, glideraService, ongoingProcess, platformInfo, externalLinkService, popupService, gettextCatalog) {
$scope.openExternalLink = function(url, target) {
if (platformInfo.isNW) {
nodeWebkit.openExternalLink(url);
} else {
target = target || '_blank';
var ref = window.open(url, target, 'location=no');
}
externalLinkService.open(url, target);
};
$scope.init = function(accessToken) {

View File

@ -1,6 +1,6 @@
'use strict';
angular.module('copayApp.controllers').controller('txDetailsController', function($rootScope, $log, $scope, $filter, $stateParams, $ionicPopup, gettextCatalog, profileService, configService, lodash, txFormatService, platformInfo) {
angular.module('copayApp.controllers').controller('txDetailsController', function($rootScope, $log, $scope, $filter, $stateParams, $ionicPopup, gettextCatalog, profileService, configService, lodash, txFormatService, platformInfo, externalLinkService) {
var self = $scope.self;
var wallet = profileService.getWallet($stateParams.walletId);
@ -81,12 +81,7 @@ angular.module('copayApp.controllers').controller('txDetailsController', functio
};
$scope.openExternalLink = function(url, target) {
if (platformInfo.isNW) {
nodeWebkit.openExternalLink(url);
} else {
target = target || '_blank';
var ref = window.open(url, target, 'location=no');
}
externalLinkService.open(url, target);
};
$scope.getShortNetworkName = function() {

View File

@ -1,6 +1,6 @@
'use strict';
angular.module('copayApp.controllers').controller('termsController', function($scope, $log, $state, uxLanguage, profileService) {
angular.module('copayApp.controllers').controller('termsController', function($scope, $log, $state, uxLanguage, profileService, externalLinkService) {
$scope.lang = uxLanguage.currentLanguage;
$scope.confirm = function() {
@ -12,4 +12,8 @@ angular.module('copayApp.controllers').controller('termsController', function($s
});
};
$scope.openExternalLink = function(url, target) {
externalLinkService.open(url, target);
};
});

View File

@ -1,9 +1,14 @@
'use strict';
angular.module('copayApp.controllers').controller('preferencesAbout',
function($scope, $window, $ionicNavBarDelegate, gettextCatalog) {
$ionicNavBarDelegate.title(gettextCatalog.getString('About Copay'));
function($scope, $window, $ionicNavBarDelegate, gettextCatalog, externalLinkService) {
$ionicNavBarDelegate.title(gettextCatalog.getString('About') + ' ' + $window.appConfig.nameCase);
$scope.version = $window.version;
$scope.commitHash = $window.commitHash;
$scope.name = $window.appConfig.gitHubRepoName;
$scope.openExternalLink = function(url, target) {
externalLinkService.open(url, target);
};
});

View File

@ -1,9 +1,13 @@
'use strict';
angular.module('copayApp.controllers').controller('preferencesLanguageController',
function($scope, $log, $ionicNavBarDelegate, $ionicHistory, gettextCatalog, configService, profileService, uxLanguage, walletService) {
function($scope, $log, $ionicNavBarDelegate, $ionicHistory, gettextCatalog, configService, profileService, uxLanguage, walletService, externalLinkService) {
$ionicNavBarDelegate.title(gettextCatalog.getString('Language'));
$scope.openExternalLink = function(url, target) {
externalLinkService.open(url, target);
};
$scope.init = function() {
$scope.availableLanguages = uxLanguage.getLanguages();
$scope.currentLanguage = uxLanguage.getCurrentLanguage();

View File

@ -8,13 +8,19 @@ angular.module('copayApp.controllers').controller('preferencesLogs',
$scope.logs = historicLog.get();
}
$scope.sendLogs = function() {
var body = 'Copay Session Logs\n Be careful, this could contain sensitive private data\n\n';
body += '\n\n';
body += $scope.logs.map(function(v) {
$scope.prepare = function() {
var log = 'Copay Session Logs\n Be careful, this could contain sensitive private data\n\n';
log += '\n\n';
log += $scope.logs.map(function(v) {
return v.msg;
}).join('\n');
return log;
};
$scope.sendLogs = function() {
var body = $scope.prepare();
window.plugins.socialsharing.shareViaEmail(
body,
'Copay Logs',

View File

@ -1,6 +1,6 @@
'use strict';
angular.module('copayApp.controllers').controller('tabSettingsController', function($scope, $rootScope, $log, $ionicModal, lodash, configService, uxLanguage, platformInfo, pushNotificationsService, profileService, feeService) {
angular.module('copayApp.controllers').controller('tabSettingsController', function($scope, $rootScope, $log, $ionicModal, $window, lodash, configService, uxLanguage, platformInfo, pushNotificationsService, profileService, feeService) {
$scope.init = function() {
@ -9,6 +9,8 @@ angular.module('copayApp.controllers').controller('tabSettingsController', funct
var isWP = platformInfo.isWP;
var isIOS = platformInfo.isIOS;
$scope.appName = $window.appConfig.nameCase;
$scope.unitName = config.wallet.settings.unitName;
$scope.currentLanguageName = uxLanguage.getCurrentLanguageName();
$scope.selectedAlternative = {

View File

@ -1,7 +1,12 @@
'use strict';
angular.module('copayApp.controllers').controller('termOfUseController',
function($scope, uxLanguage, $ionicNavBarDelegate, gettextCatalog) {
$ionicNavBarDelegate.title(gettextCatalog.getString('About Copay'));
function($scope, $window, uxLanguage, $ionicNavBarDelegate, gettextCatalog, externalLinkService) {
$ionicNavBarDelegate.title(gettextCatalog.getString('Terms Of Use'));
$scope.lang = uxLanguage.currentLanguage;
$scope.disclaimerUrl = $window.appConfig.disclaimerUrl;
$scope.openExternalLink = function(url, target) {
externalLinkService.open(url, target);
};
});

View File

@ -0,0 +1,8 @@
'use strict';
angular.module('copayApp.controllers').controller('translatorsController',
function($scope, externalLinkService) {
$scope.openExternalLink = function(url, target) {
externalLinkService.open(url, target);
};
});

View File

@ -1,6 +1,6 @@
'use strict';
angular.module('copayApp.controllers').controller('walletDetailsController', function($scope, $rootScope, $interval, $timeout, $filter, $log, $ionicModal, $ionicPopover, $ionicNavBarDelegate, $state, $stateParams, bwcError, profileService, lodash, configService, gettext, gettextCatalog, platformInfo, walletService, $ionicPopup, txpModalService) {
angular.module('copayApp.controllers').controller('walletDetailsController', function($scope, $rootScope, $interval, $timeout, $filter, $log, $ionicModal, $ionicPopover, $ionicNavBarDelegate, $state, $stateParams, bwcError, profileService, lodash, configService, gettext, gettextCatalog, platformInfo, walletService, $ionicPopup, txpModalService, externalLinkService) {
var isCordova = platformInfo.isCordova;
var isWP = platformInfo.isWP;
@ -12,6 +12,9 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun
var HISTORY_SHOW_LIMIT = 10;
$scope.txps = [];
$scope.openExternalLink = function(url, target) {
externalLinkService.open(url, target);
};
var setPendingTxps = function(txps) {
if (!txps) {

View File

@ -1,7 +1,7 @@
'use strict';
angular.module('copayApp.directives')
.directive('copyToClipboard', function(platformInfo, nodeWebkit, gettextCatalog, ionicToast, clipboard) {
.directive('copyToClipboard', function(platformInfo, nodeWebkitService, gettextCatalog, ionicToast, clipboard) {
return {
restrict: 'A',
scope: {
@ -22,7 +22,7 @@ angular.module('copayApp.directives')
window.cordova.plugins.clipboard.copy(data);
window.plugins.toast.showShortCenter(msg);
} else if (isNW) {
nodeWebkit.writeToClipboard(data);
nodeWebkitService.writeToClipboard(data);
scope.$apply(function() {
ionicToast.show(msg, 'bottom', false, 1000);
});

View File

@ -0,0 +1,14 @@
'use strict';
angular.module('copayApp.services').service('externalLinkService', function(platformInfo, nodeWebkitService) {
this.open = function(url, target) {
if (platformInfo.isNW) {
nodeWebkitService.openExternalLink(url);
} else {
target = target || '_blank';
var ref = window.open(url, target, 'location=no');
}
};
});

View File

@ -1,38 +0,0 @@
'use strict';
angular.module('copayApp.services').factory('nodeWebkit', function nodeWebkitFactory() {
var root = {};
var isNodeWebkit = function() {
var isNode = (typeof process !== "undefined" && typeof require !== "undefined");
if(isNode) {
try {
return (typeof require('nw.gui') !== "undefined");
} catch(e) {
return false;
}
}
};
root.readFromClipboard = function() {
if (!isNodeWebkit()) return;
var gui = require('nw.gui');
var clipboard = gui.Clipboard.get();
return clipboard.get();
};
root.writeToClipboard = function(text) {
if (!isNodeWebkit()) return;
var gui = require('nw.gui');
var clipboard = gui.Clipboard.get();
return clipboard.set(text);
};
root.openExternalLink = function(url) {
if (!isNodeWebkit()) return;
var gui = require('nw.gui');
return gui.Shell.openExternal(url);
};
return root;
});

View File

@ -0,0 +1,22 @@
'use strict';
angular.module('copayApp.services').service('nodeWebkitService', function() {
this.readFromClipboard = function() {
var gui = require('nw.gui');
var clipboard = gui.Clipboard.get();
return clipboard.get();
};
this.writeToClipboard = function(text) {
var gui = require('nw.gui');
var clipboard = gui.Clipboard.get();
return clipboard.set(text);
};
this.openExternalLink = function(url) {
var gui = require('nw.gui');
return gui.Shell.openExternal(url);
};
});