From 1f26dee8a6becade8ca0785cd65aa770a73dee02 Mon Sep 17 00:00:00 2001
From: Benoit Lavenier <benoit.lavenier@e-is.pro>
Date: Tue, 5 May 2020 21:13:57 +0200
Subject: [PATCH] [enh] Add a 'readonly' mode, for currency monitoring [fix]
Demo mode: add ribbon on home page. Fix warn template use [fix] API: allow to
pay using the API, but display a warn message
---
dist/desktop | 2 +-
platforms/android | 2 +-
scripts/check-reproducible-build.sh | 39 ++++++--
scss/ionic.app.scss | 90 +++++++++++++++++--
www/i18n/locale-en-GB.json | 20 +++--
www/i18n/locale-en.json | 20 +++--
www/i18n/locale-es-ES.json | 20 +++--
www/i18n/locale-fr-FR.json | 28 ++++--
www/i18n/locale-it-IT.json | 20 +++--
www/index.html | 2 +-
www/js/api/app.js | 16 +++-
www/js/config.js | 3 +-
www/js/controllers/app-controllers.js | 1 +
www/js/controllers/help-controllers.js | 49 ++++++----
www/js/controllers/join-controllers.js | 2 +-
www/js/controllers/login-controllers.js | 12 ++-
www/js/controllers/wallet-controllers.js | 2 +-
www/js/platform.js | 4 +
www/js/services/settings-services.js | 2 +
www/js/services/utils-services.js | 4 +-
www/js/services/wallet-services.js | 4 +-
.../templates/settings/plugin_settings.html | 18 ++--
.../wot/view_certifications_extend.html | 4 +-
.../templates/wot/view_identity_extend.html | 6 +-
www/templates/api/transfer.html | 7 ++
.../common/note_feature_not_available.html | 4 +-
www/templates/help/help.html | 18 +++-
www/templates/home/home.html | 65 +++++++++++---
.../join/modal_choose_account_type.html | 4 +-
www/templates/menu.html | 34 +++----
www/templates/modal_about.html | 2 +-
www/templates/settings/settings.html | 24 ++---
www/templates/wallet/modal_security.html | 14 +--
.../slides/slides_generate_keyfile.html | 6 +-
www/templates/wot/view_certifications.html | 4 +-
www/templates/wot/view_identity.html | 12 +--
36 files changed, 404 insertions(+), 160 deletions(-)
diff --git a/dist/desktop b/dist/desktop
index 7a51ea32..856765cd 160000
--- a/dist/desktop
+++ b/dist/desktop
@@ -1 +1 @@
-Subproject commit 7a51ea325dc733f669c85ab07b680659fde51aca
+Subproject commit 856765cd3e552d745144129ffd95c7fd3af51291
diff --git a/platforms/android b/platforms/android
index d23c13ed..0dd823db 160000
--- a/platforms/android
+++ b/platforms/android
@@ -1 +1 @@
-Subproject commit d23c13ed36c3200ed3d6f9a0c0b36bffc7652787
+Subproject commit 0dd823dbd23d029224a34ecfe558dbba8484d9c9
diff --git a/scripts/check-reproducible-build.sh b/scripts/check-reproducible-build.sh
index 87d78b37..4d3af4b9 100755
--- a/scripts/check-reproducible-build.sh
+++ b/scripts/check-reproducible-build.sh
@@ -62,7 +62,12 @@ echo "Checking diff between templates files... [OK]"
# Check web extension build
# ----------------------------------
-# Compile
+# Clean generated files (1/2)
+rm www/css/*.app*.css
+rm -rf www/dist
+rm -rf dist/web
+
+# Compile (1/2)
echo "----------------------------"
echo "Building web extension... [1/2]"
gulp webExtBuild --release > /dev/null
@@ -74,10 +79,16 @@ if [[ $? -ne 0 ]] || [[ ! -d "${WEB_EXT_DIR}" ]]; then
fi;
# Keep a copy
-rm -rf "${WEB_EXT_DIR}.tmp"
-mv "${WEB_EXT_DIR}" "${WEB_EXT_DIR}.tmp"
+WEB_EXT_COPY_DIR="/tmp/cesium-extention"
+rm -rf "${WEB_EXT_COPY_DIR}"
+mv "${WEB_EXT_DIR}" "${WEB_EXT_COPY_DIR}"
+
+# Clean generated files (2/2)
+rm www/css/*.app*.css
+rm -rf www/dist
+rm -rf dist/web
-# Compile web extension, second time
+# Compile web extension (2/2)
echo "Building web extension... [2/2]"
gulp webExtBuild --release > /dev/null
[[ $? -ne 0 ]] && exit 1
@@ -85,12 +96,22 @@ gulp webExtBuild --release > /dev/null
echo "Building web extension... [OK]"
echo "Checking diff between builds..."
-diff -arq "${WEB_EXT_DIR}" "${WEB_EXT_DIR}.tmp" > /tmp/webExtention.diff
+DIFF_FILE=/tmp/cesium-extention.diff
+diff -arq "${WEB_EXT_DIR}" "${WEB_EXT_COPY_DIR}" > ${DIFF_FILE}
if [[ $? -ne 0 ]]; then
- cat /tmp/webExtention.diff
- echo "ERROR: Detected some differences: build is not reproducible!"
+ echo "Checking diff between builds... [FAILED] Build is NOT reproducible!"
+ echo "Please check following diff:"
+ cat ${DIFF_FILE}
+
+ # Clean temporary dir
+ rm -rf ${WEB_EXT_COPY_DIR}
+
exit 1;
fi;
-echo "Checking diff between builds... [OK]"
-echo "SUCCESS: Build are reproducible!"
+# Final message
+echo "Checking diff between builds... [SUCCESS] Build is reproducible."
+
+# Clean temporary dir (silently)
+rm -rf ${WEB_EXT_COPY_DIR} > /dev/null
+rm /tmp/cesium-extention.diff
diff --git a/scss/ionic.app.scss b/scss/ionic.app.scss
index a3a914f7..ccded581 100644
--- a/scss/ionic.app.scss
+++ b/scss/ionic.app.scss
@@ -913,6 +913,29 @@ html, body {
Home page
=============== */
+#home .ribbon {
+ position: fixed;
+ top: 15px;
+ right: -110px;
+ z-index: 500;
+ transform: rotate(45deg);
+ text-align: center;
+ width: 300px;
+ text-decoration: none;
+ box-shadow: 0 0 5px #000;
+ a:first-child {
+ opacity: 1 !important;
+ }
+ a {
+ opacity: 0.7;
+ width: 100%;
+ }
+
+ a:hover {
+ opacity: 1;
+ font-size: 16px;
+ }
+}
#home .logo {
margin-top: 15px;
width: 100%;
@@ -2038,26 +2061,79 @@ $ionicon-var-badge-editable: $ionicon-var-edit + "\00a0";
}
/**********
- Demo
+ Specific modes (demo, readonly)
**********/
-#menu .badge-demo {
- font-size: 12px;
+/* -- readonly mode -- */
+
+.visible-readonly {
+ display: none;
+ visibility: hidden;
+}
+
+body.readonly {
+
+ .hidden-readonly {
+ display: none;
+ visibility: hidden;
+ }
+ .visible-readonly {
+ display: inherit !important;
+ visibility: visible !important;
+ }
+}
+
+/* -- demo mode -- */
+
+.visible-demo {
+ display: none;
+ visibility: hidden;
+}
+
+body.demo {
+
+ .hidden-demo {
+ display: none;
+ visibility: hidden;
+ }
+ .visible-demo {
+ display: inherit !important;
+ visibility: visible !important;
+ }
+}
+
+.badge-app-mode {
font-weight: bold;
color: whitesmoke !important;
- position: absolute;
top: 10px;
- left: 1px;
padding: 0 4px;
text-transform: uppercase;
+ user-select: none;
+}
+#menu .badge-app-mode.left {
+ position: absolute;
+ font-size: 12px;
+ left: 1px;
transform-origin: 26px 5px;
transform: rotate(-10deg);
}
-#menu .badge-demo:hover {
- font-size: 13px;
+#menu .badge-app-mode.right {
+ position: absolute;
+ font-size: 14px;
+ right: 1px;
+ transform-origin: 26px 5px;
+ transform: rotate(10deg);
+}
+#menu .badge-app-mode.left:hover {
padding: 1px 4px;
+ font-size: 13px;
transform: rotate(-15deg);
}
+#menu .badge-app-mode.right:hover {
+ padding: 2px 5px;
+ font-size: 16px;
+ transform: rotate(15deg);
+}
/**********
Help
**********/
diff --git a/www/i18n/locale-en-GB.json b/www/i18n/locale-en-GB.json
index ccfcf006..9ff0a235 100644
--- a/www/i18n/locale-en-GB.json
+++ b/www/i18n/locale-en-GB.json
@@ -825,12 +825,20 @@
"USE_FALLBACK_NODE": "Peer <b>{{old}}</b> unreachable or invalid address.<br/><br/>Do you want to temporarily use the <b>{{new}}</b> node?",
"ISSUE_524_SEND_LOG": "The transaction was rejected because of a known problem (issue #524) but not reproduced.<br/><br/>To help developers correct this error, do you accept <b>the transmission of your logs</b> per message?<br/><small>(No confidential data is sent)</small>"
},
- "DEMO": {
- "BADGE": "Demo",
- "MODE": "Mode demonstration",
- "FEATURE_NOT_AVAILABLE": "Functionality <b>not available</b> on this demonstration site.",
- "MODE_HELP": "Cesium works in <b>demonstration mode</b>: consultation is on account is available, but no account operation can be performed.",
- "INSTALL_HELP": "For <b>security reasons</b> we recommend <b>installing</b> your copy of the software.<br/> Visit the site <a href='https://cesium.app'>www.cesium.app</a> for help."
+ "MODE": {
+ "DEMO": {
+ "BADGE": "Demo",
+ "MODE": "Demonstration mode",
+ "FEATURE_NOT_AVAILABLE": "Functionality <b>not available</b> on this demonstration site.",
+ "MODE_HELP": "Cesium works in <b>demonstration mode</b>: consultation on account is available, but no operation can be performed.",
+ "INSTALL_HELP": "For <b>security reasons</b> we recommend <b>installing</b> your copy of the software.<br/> Visit the site <a href='https://cesium.app'>www.cesium.app</a> for help."
+ },
+ "READONLY": {
+ "BADGE": "Monit",
+ "MODE": "Monitoring mode",
+ "MODE_HELP": "Cesium works in <b>monitoring mode</b>: only currency monitoring features are available.",
+ "INSTALL_HELP": "If you want to <b>create a wallet account</b> to send or received money, we recommend <b>installing</b> your copy of the software.<br/> Visit the site <a href='https://cesium.app'>www.cesium.app</a> for help."
+ }
},
"DOWNLOAD": {
"POPUP_TITLE": "<b>Revocation file</b>",
diff --git a/www/i18n/locale-en.json b/www/i18n/locale-en.json
index b2e4e80f..54bf66b2 100644
--- a/www/i18n/locale-en.json
+++ b/www/i18n/locale-en.json
@@ -825,12 +825,20 @@
"USE_FALLBACK_NODE": "Peer <b>{{old}}</b> unreachable or invalid address.<br/><br/>Do you want to temporarily use the <b>{{new}}</b> node?",
"ISSUE_524_SEND_LOG": "The transaction was rejected because of a known problem (issue #524) but not reproduced.<br/><br/>To help developers correct this error, do you accept <b>the transmission of your logs</b> per message?<br/><small>(No confidential data is sent)</small>"
},
- "DEMO": {
- "BADGE": "Demo",
- "MODE": "Mode demonstration",
- "FEATURE_NOT_AVAILABLE": "Functionality <b>not available</b> on this demonstration site.",
- "MODE_HELP": "Cesium works in <b>demonstration mode</b>: consultation is on account is available, but no account operation can be performed.",
- "INSTALL_HELP": "For <b>security reasons</b> we recommend <b>installing</b> your copy of the software.<br/> Visit the site <a href='https://cesium.app'>www.cesium.app</a> for help."
+ "MODE": {
+ "DEMO": {
+ "BADGE": "Demo",
+ "MODE": "Demonstration mode",
+ "FEATURE_NOT_AVAILABLE": "Functionality <b>not available</b> on this demonstration site.",
+ "MODE_HELP": "Cesium works in <b>demonstration mode</b>: consultation on account is available, but no operation can be performed.",
+ "INSTALL_HELP": "For <b>security reasons</b> we recommend <b>installing</b> your copy of the software.<br/> Visit the site <a href='https://cesium.app'>www.cesium.app</a> for help."
+ },
+ "READONLY": {
+ "BADGE": "Monit",
+ "MODE": "Monitoring mode",
+ "MODE_HELP": "Cesium works in <b>monitoring mode</b>: only currency monitoring features are available.",
+ "INSTALL_HELP": "If you want to <b>create a wallet account</b> to send or received money, we recommend <b>installing</b> your copy of the software.<br/> Visit the site <a href='https://cesium.app'>www.cesium.app</a> for help."
+ }
},
"DOWNLOAD": {
"POPUP_TITLE": "<b>Revocation file</b>",
diff --git a/www/i18n/locale-es-ES.json b/www/i18n/locale-es-ES.json
index 6a366b69..434951ef 100644
--- a/www/i18n/locale-es-ES.json
+++ b/www/i18n/locale-es-ES.json
@@ -916,12 +916,20 @@
"USE_FALLBACK_NODE": "Nodo <b>{{old}}</b> inalcanzable o dirección inválida.<br/><br/>¿Desea utilizar temporalmente el nodo <b>{{new}}</b>?",
"ISSUE_524_SEND_LOG": "La transacción ha sido rechazada a causa de una anomalía conocida (ticket #524) pero todavía <b>no replicable</b>.<br/><br/>Para ayudar a los/as desarrolladores/as a corregir este error, ¿ <b>acepta el envío de los logs(trazas del programa)</b> ?<br/><small>(ningún dato confidencia será enviado)</small>."
},
- "DEMO": {
- "BADGE": "Demo",
- "MODE": "Modo de demostración",
- "FEATURE_NOT_AVAILABLE": "Funcionalidad <b>no disponible</b> en este sitio de demostración.",
- "MODE_HELP": "El cesio funciona en <b> modo de demostración </b>: la consulta está disponible, pero no se puede realizar ninguna operación.",
- "INSTALL_HELP": "Por <b>razones de seguridad</b> recomendamos <b>instalar</b> su copia del software.<br/>Visite el sitio de Internet <a href='https://cesium.app'> www.cesium.app </a> para obtener ayuda."
+ "MODE": {
+ "DEMO": {
+ "BADGE": "Demo",
+ "MODE": "Modo de demostración",
+ "FEATURE_NOT_AVAILABLE": "Funcionalidad <b>no disponible</b> en este sitio de demostración.",
+ "MODE_HELP": "Cesium funciona en <b> modo de demostración </b>: la consulta está disponible, pero no se puede realizar ninguna operación.",
+ "INSTALL_HELP": "Por <b>razones de seguridad</b> recomendamos <b>instalar</b> su copia del software.<br/>Visite el sitio de Internet <a href='https://cesium.app'> www.cesium.app </a> para obtener ayuda."
+ },
+ "READONLY": {
+ "BADGE": "Monit",
+ "MODE": "Modo de supervisión",
+ "MODE_HELP": "Cesium funciona en <b> modo de supervisión </b>: solo están disponibles las funciones de monitoreo de divisas.",
+ "INSTALL_HELP": "Si desea <b>crear una cuenta</b> para enviar o recibir dinero, le recomendamos <b>instalar</b> su copia del software.<br/>Visite el sitio de Internet <a href='https://cesium.app'> www.cesium.app </a> para obtener ayuda."
+ }
},
"DOWNLOAD": {
"POPUP_TITLE": "<b>Revocación del archivo</b>",
diff --git a/www/i18n/locale-fr-FR.json b/www/i18n/locale-fr-FR.json
index 0bd80c44..3882270c 100644
--- a/www/i18n/locale-fr-FR.json
+++ b/www/i18n/locale-fr-FR.json
@@ -118,10 +118,16 @@
"HOME": {
"TITLE": "Cesium",
"WELCOME": "Bienvenue dans l'application Cesium !",
+ "WELCOME_READONLY": "Bienvenue dans Cesium Monit !",
"MESSAGE": "Recevez et envoyez de la monnaie libre {{currency|abbreviate}}",
- "BTN_CURRENCY": "Explorer la monnaie {{name|abbreviate}}",
+ "MESSAGE_READONLY": "Suivez l'état de la monnaie libre {{currency|abbreviate}} en temps réel.",
+ "BTN_CURRENCY": "Explorer la monnaie {{currency|abbreviate}}",
"BTN_ABOUT": "à propos",
"BTN_HELP": "Aide en ligne",
+ "BTN_NETWORK": "Etat du réseau",
+ "FREE_SOFTWARE": "Logiciel libre",
+ "FORK_ME": "Cloner moi !",
+ "SHOW_LICENSE": "Voir la license",
"REPORT_ISSUE": "anomalie",
"NOT_YOUR_ACCOUNT_QUESTION" : "Vous n'êtes pas propriétaire du compte <b class=\"ion-key\"> {{pubkey|formatPubkey}}</b> ?",
"BTN_CHANGE_ACCOUNT": "Déconnecter ce compte",
@@ -825,12 +831,20 @@
"USE_FALLBACK_NODE": "Nœud <b>{{old}}</b> injoignable ou adresse invalide.<br/><br/>Voulez-vous temporairement utiliser le nœud <b>{{new}}</b> ?",
"ISSUE_524_SEND_LOG": "La transaction a été rejetée, à cause d'une anomalie connue (ticket #524) mais <b>non reproduite</b>.<br/><br/>Pour aider les développeurs à corriger cette erreur, <b>acceptez-vous la transmission de vos logs</b> par message ?<br/><small>(aucune donnée confidentielle n'est envoyée)</small>."
},
- "DEMO": {
- "BADGE": "Démo",
- "MODE": "Mode démonstration",
- "FEATURE_NOT_AVAILABLE": "Fonctionnalité <b>non disponible</b> sur ce site de démonstration.",
- "MODE_HELP": "Cesium fonctionne en <b>mode démonstration</b> : la consultation est de compte est disponible, mais aucune opération de compte ne peut être réalisée.",
- "INSTALL_HELP": "Pour des <b>raisons de sécurité</b> nous vous recommandons <b>d'installer</b> votre copie du logiciel. Visitez le site <a href='https://cesium.app'>www.cesium.app</a> pour obtenir de l'aide."
+ "MODE": {
+ "DEMO": {
+ "BADGE": "Démo",
+ "MODE": "Mode démonstration",
+ "FEATURE_NOT_AVAILABLE": "Fonctionnalité <b>non disponible</b> sur ce site de démonstration.",
+ "MODE_HELP": "Cesium fonctionne en <b>mode démonstration</b> : la consultation de compte est possible, mais aucune opération ne pourra être réalisée.",
+ "INSTALL_HELP": "Pour des <b>raisons de sécurité</b> nous vous recommandons <b>d'installer</b> votre copie de l'application Cesium. Visitez le site <a href='https://cesium.app'>www.cesium.app</a> pour obtenir de l'aide."
+ },
+ "READONLY": {
+ "BADGE": "Monit",
+ "MODE": "Mode monitoring",
+ "MODE_HELP": "Cesium fonctionne en <b>mode monitoring</b> : sono disponibili solo le funzionalità di monitoraggio della valuta.",
+ "INSTALL_HELP": "Si vous souhaitez <b>créer un compte portefeuille</b> pour envoyer ou recevoir de la monnaie, nous vous recommandons <b>d'installer votre copie</b> de l'application Cesium. Visitez le site <a href='https://cesium.app'>www.cesium.app</a> pour obtenir de l'aide."
+ }
},
"DOWNLOAD": {
"POPUP_TITLE": "<b>Fichier de révocation</b>",
diff --git a/www/i18n/locale-it-IT.json b/www/i18n/locale-it-IT.json
index 91e4982b..3d02036c 100644
--- a/www/i18n/locale-it-IT.json
+++ b/www/i18n/locale-it-IT.json
@@ -740,13 +740,21 @@
"USE_FALLBACK_NODE": "Peer <b>{{old}}</b> indisponibile o indirizzo errato.<br/><br/>Vuoi utilizzare temporanemante il <b>{{new}}</b> nodo?",
"INVALID_FILE_FORMAT": "Formato file non valido.",
"SAME_TX_RECIPIENT": "Il destinatario deve essere diverso dall'emittente."
+ },
+ "MODE": {
+ "DEMO": {
+ "BADGE": "Demo",
+ "MODE": "Modalità dimostrativa",
+ "FEATURE_NOT_AVAILABLE": "Funzionalità <b>non disponibile</b> su questo sito dimostrativo.",
+ "MODE_HELP": "Il cesio funziona in <b>modalità dimostrativa</b>: è disponibile la consultazione per conto, ma non è possibile eseguire alcuna operazione per conto.",
+ "INSTALL_HELP": "Per <b>motivi di sicurezza</b> ti consigliamo di <b>installare</b> la tua copia del software.<br/>Visita il sito <a href='https://cesium.app'>www.cesium.app</a> per assistenza."
},
- "DEMO": {
- "BADGE": "Demo",
- "MODE": "Modalità dimostrativa",
- "FEATURE_NOT_AVAILABLE": "Funzionalità <b>non disponibile</b> su questo sito dimostrativo.",
- "MODE_HELP": "Il cesio funziona in <b>modalità dimostrativa</b>: è disponibile la consultazione per conto, ma non è possibile eseguire alcuna operazione per conto.",
- "INSTALL_HELP": "Per <b>motivi di sicurezza</b> ti consigliamo di <b>installare</b> la tua copia del software.<br/>Visita il sito <a href='https://cesium.app'>www.cesium.app</a> per assistenza."
+ "READONLY": {
+ "BADGE": "Monit",
+ "MODE": "Modalità di monitoraggio",
+ "MODE_HELP": "Il cesio funziona in <b>modalità monitoraggio</b>: sono disponibili solo le funzionalità di monitoraggio della valuta.",
+ "INSTALL_HELP": "Se desidera <b>creare un account di portafoglio</b> per inviare o ricevere valuta, ti consigliamo di <b>installare</b> la tua copia del software.<br/>Visita il sito <a href='https://cesium.app'>www.cesium.app</a> per assistenza."
+ }
},
"DOWNLOAD": {
"POPUP_TITLE": "<b>File di cancellazione dell'identità/b>",
diff --git a/www/index.html b/www/index.html
index 4f879f39..eda74b02 100644
--- a/www/index.html
+++ b/www/index.html
@@ -53,7 +53,7 @@
</head>
<body id="cesium" ng-strict-di="true" window-exit-unauth="true"
- ng-class="{'nobackdrop': $root.tour, 'expert-mode': $root.settings.expertMode}"
+ ng-class="{'nobackdrop': $root.tour, 'expert-mode': $root.settings.expertMode, 'demo': $root.config.demo && !$root.config.readonly, 'readonly': $root.config.readonly}"
style="background-color: #1a237e;">
<ion-nav-view>
<div class="loader">
diff --git a/www/js/api/app.js b/www/js/api/app.js
index c6c44a70..5eb16b7b 100644
--- a/www/js/api/app.js
+++ b/www/js/api/app.js
@@ -228,13 +228,21 @@ angular.module('cesium-api', ['ionic', 'ionic-material', 'ngMessages', 'pascalpr
$scope.$watch('transferButton.style', $scope.computeTransferButtonHtml, true);
})
- .controller('ApiTransferCtrl', function ($scope, $rootScope, $timeout, $controller, $state, $q, $translate, $filter,
- $window, $ionicHistory, BMA, CryptoUtils, UIUtils, csSettings, csCurrency,
- csPlatform, csTx, csWallet, csDemoWallet){
+ .controller('ApiTransferCtrl', function($scope, $rootScope, $timeout, $controller, $state, $q, $translate, $filter,
+ $window, $ionicHistory, BMA, CryptoUtils, UIUtils, csConfig, csSettings,
+ csPlatform, csCurrency, csTx, csWallet, csDemoWallet) {
'ngInject';
+ // WARN: Disable demo mode, on the API (a non-blocking warn message will be display later)
+ var config = csConfig;
+ if (config.demo) {
+ config = angular.copy(config);
+ config.demo = false;
+ config.readonly = false;
+ }
+
// Initialize the super class and extend it.
- angular.extend(this, $controller('AuthCtrl', {$scope: $scope}));
+ angular.extend(this, $controller('AuthCtrl', {$scope: $scope, csConfig: config}));
$scope.loading = true;
$scope.transferData = {
diff --git a/www/js/config.js b/www/js/config.js
index df8b629d..ab9233e5 100644
--- a/www/js/config.js
+++ b/www/js/config.js
@@ -11,6 +11,7 @@ angular.module("cesium.config", [])
.constant("csConfig", {
"cacheTimeMs": 300000,
"demo": false,
+ "readonly": true,
"fallbackLanguage": "en",
"rememberMe": true,
"showUDHistory": true,
@@ -123,4 +124,4 @@ angular.module("cesium.config", [])
"newIssueUrl": "https://git.duniter.org/clients/cesium-grp/cesium/issues/new"
})
-;
\ No newline at end of file
+;
diff --git a/www/js/controllers/app-controllers.js b/www/js/controllers/app-controllers.js
index 52b45f23..71e44eab 100644
--- a/www/js/controllers/app-controllers.js
+++ b/www/js/controllers/app-controllers.js
@@ -533,6 +533,7 @@ function HomeController($scope, $state, $timeout, $ionicHistory, $translate, $ht
$scope.loading = true;
$scope.locales = angular.copy(csSettings.locales);
$scope.smallscreen = UIUtils.screen.isSmall();
+ $scope.showInstallHelp = false;
$scope.enter = function(e, state) {
if (ionic.Platform.isIOS()) {
diff --git a/www/js/controllers/help-controllers.js b/www/js/controllers/help-controllers.js
index 869ff98d..9d567d40 100644
--- a/www/js/controllers/help-controllers.js
+++ b/www/js/controllers/help-controllers.js
@@ -161,13 +161,16 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
$scope.tour = true;
$scope.continue = true;
- // Wallet (if NOT login)
- return $scope.startWalletNoLoginTour(0, true)
+ console.debug("[help] Starting help tour... {demo: {0}, readonly: {1}, isLogin: {2}}".format(
+ csConfig.demo, csConfig.readonly, csWallet.isLogin()));
+
+ // Wallet (if NOT readonly and NOT login)
+ return ((!csConfig.readonly && csWallet.isLogin()) ? $scope.startWalletNoLoginTour(0, true) : $q.when(true))
// Wallet (if login)
.then(function(next){
if (!next) return false;
- if (!csWallet.isLogin()) return true; // not login: continue
+ if (csConfig.readonly || !csWallet.isLogin()) return true; // not login or readonly: continue
return $scope.startWalletTour(0, true)
.then(function(endIndex){
if (!endIndex) return false;
@@ -180,7 +183,7 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
// Wallet certifications
.then(function(next){
if (!next) return false;
- if (!csWallet.isLogin()) return true; // not login: continue
+ if (csConfig.readonly || !csWallet.isLogin()) return true; // not login or readonly: continue
return $scope.startWalletCertTour(0, true)
.then(function(endIndex){
if (!endIndex) return false;
@@ -193,7 +196,7 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
// My operations (if login)
.then(function(next){
if (!next) return false;
- if (!csWallet.isLogin()) return true; // not login: continue
+ if (csConfig.readonly || !csWallet.isLogin()) return true; // not login or readonly: continue
return $scope.startTxTour(0, true)
.then(function(endIndex){
if (!endIndex) return false;
@@ -206,7 +209,7 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
// My wallets (if login)
.then(function(next){
if (!next) return false;
- if (!csWallet.isLogin()) return true; // not login: continue
+ if (csConfig.readonly || !csWallet.isLogin()) return true; // not login or readonly: continue
return $scope.startWalletsTour(0, true)
.then(function(endIndex){
if (!endIndex) return false;
@@ -219,12 +222,14 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
// Header tour
.then(function(next){
if (!next) return false;
+ if (csConfig.readonly) return true; // readonly: continue
return $scope.startHeaderTour(0, true);
})
- // Settings tour
+ // Settings tour (if not readonly mode)
.then(function(next){
if (!next) return false;
+ if (csConfig.readonly) return true; // Skip if readonly mode (will be play later)
return $scope.startSettingsTour(0, true);
})
@@ -289,6 +294,12 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
});
})
+ // Settings tour (if readonly mode)
+ .then(function(next){
+ if (!next) return false;
+ if (!csConfig.readonly) return true; // Skip if NOT readonly
+ return $scope.startSettingsTour(0, true);
+ })
// Finish tour
.then(function(next){
@@ -319,7 +330,7 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
bindings: {
content: 'HELP.TIP.MENU_BTN_CURRENCY',
icon: {
- position: UIUtils.screen.isSmall() ? 'left' : 'bottom-left'
+ position: UIUtils.screen.isSmall() || csConfig.readonly ? 'left' : 'bottom-left'
}
}
});
@@ -432,7 +443,7 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
// Select the second tabs
$timeout(function () {
var tabs = $window.document.querySelectorAll('ion-tabs .tabs a');
- if (tabs && tabs.length == 3) {
+ if (tabs && tabs.length === 3) {
angular.element(tabs[2]).triggerHandler('click');
}
}, 100);
@@ -450,7 +461,7 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
bindings: {
content: 'HELP.TIP.MENU_BTN_NETWORK',
icon: {
- position: UIUtils.screen.isSmall() ? 'left' : 'bottom-left'
+ position: UIUtils.screen.isSmall() || csConfig.readonly ? 'left' : 'bottom-left'
}
}
});
@@ -545,7 +556,7 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
bindings: {
content: 'HELP.TIP.MENU_BTN_WOT',
icon: {
- position: UIUtils.screen.isSmall() ? 'left' : 'bottom-left'
+ position: UIUtils.screen.isSmall() || csConfig.readonly ? 'left' : 'bottom-left'
}
},
onError: 'continue'
@@ -650,6 +661,8 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
* @returns {*}
*/
$scope.startWotCertTour = function(startIndex, hasNext) {
+ if (csConfig.readonly) return $q.when(true);
+
var steps = [
function() {
@@ -1038,7 +1051,7 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
* @returns {*}
*/
$scope.startHeaderTour = function(startIndex, hasNext) {
- if (UIUtils.screen.isSmall()) return $q.when(true);
+ if (UIUtils.screen.isSmall() || csConfig.readonly) return $q.when(true);
function _getProfilBtnElement() {
var elements = $window.document.querySelectorAll('#helptip-header-bar-btn-profile');
@@ -1053,15 +1066,13 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
var element = _getProfilBtnElement();
if (!element) return true;
- // If home; add offset because of locales button
- var iconStyle = $state.is('app.home') ? 'margin-right: 60px' : undefined;
-
return $scope.showHelpTip(element, {
bindings: {
content: 'HELP.TIP.HEADER_BAR_BTN_PROFILE',
icon: {
position: 'right',
- style: iconStyle
+ // If home; add offset because of locales button
+ style: $state.is('app.home') ? 'margin-right: 60px' : undefined
}
}
});
@@ -1120,13 +1131,13 @@ function HelpTipController($scope, $state, $window, $ionicSideMenuDelegate, $tim
var steps = [
function () {
- if (!UIUtils.screen.isSmall()) return true;
+ if (!UIUtils.screen.isSmall() && !csConfig.readonly) return true;
$ionicSideMenuDelegate.toggleLeft(true);
- return $scope.showHelpTip('helptip-menu-btn-settings', {
+ return $scope.showHelpTip(UIUtils.screen.isSmall() ? 'helptip-menu-btn-settings' : 'menu-btn-settings', {
bindings: {
content: 'HELP.TIP.MENU_BTN_SETTINGS',
icon: {
- position: 'left'
+ position: UIUtils.screen.isSmall() ? 'left' : 'bottom-left'
}
},
timeout: 1000
diff --git a/www/js/controllers/join-controllers.js b/www/js/controllers/join-controllers.js
index 44cb09da..f4444fd7 100644
--- a/www/js/controllers/join-controllers.js
+++ b/www/js/controllers/join-controllers.js
@@ -86,7 +86,7 @@ function JoinChooseAccountTypeModalController($scope, $state, Modals, UIUtils, c
};
$scope.selectAccountTypeAndClose = function(type) {
- if (csConfig.demo === true || csConfig.demo === "true") {
+ if (csConfig.demo) {
return UIUtils.alert.demo();
}
$scope.formData.accountType = type;
diff --git a/www/js/controllers/login-controllers.js b/www/js/controllers/login-controllers.js
index fd671bee..527495df 100644
--- a/www/js/controllers/login-controllers.js
+++ b/www/js/controllers/login-controllers.js
@@ -50,7 +50,7 @@ function LoginModalController($scope, $timeout, $q, $ionicPopover, $window, Cryp
parameters = parameters || {};
// Demo mode: force PUBKEY method
- if (csConfig.demo === true || csConfig.demo === "true") {
+ if (csConfig.demo) {
parameters.method = 'PUBKEY';
}
@@ -424,7 +424,7 @@ function LoginModalController($scope, $timeout, $q, $ionicPopover, $window, Cryp
$scope.changeMethod = function(method, params){
$scope.hideMethodsPopover();
- if (method !== 'PUBKEY' && (csConfig.demo === true || csConfig.demo === "true")) {
+ if (method !== 'PUBKEY' && csConfig.demo) {
return UIUtils.alert.demo();
}
@@ -612,10 +612,14 @@ function LoginModalController($scope, $timeout, $q, $ionicPopover, $window, Cryp
}
-function AuthController($scope, $controller){
+function AuthController($scope, $controller, csConfig){
+
+ var config = angular.copy(csConfig);
+ config.demo = false;
+ config.readonly = false;
// Initialize the super class and extend it.
- angular.extend(this, $controller('LoginModalCtrl', {$scope: $scope, parameters: {auth: true}}));
+ angular.extend(this, $controller('LoginModalCtrl', {$scope: $scope, parameters: {auth: true}, csConfig: config}));
$scope.setForm = function(form) {
$scope.form = form;
diff --git a/www/js/controllers/wallet-controllers.js b/www/js/controllers/wallet-controllers.js
index e6d338e4..59224fef 100644
--- a/www/js/controllers/wallet-controllers.js
+++ b/www/js/controllers/wallet-controllers.js
@@ -1225,7 +1225,7 @@ function WalletSecurityModalController($scope, UIUtils, csConfig, csWallet, $tra
};
$scope.selectOption = function(option, enableOnDemo){
- if (!enableOnDemo && (csConfig.demo === true || csConfig.demo === "true")) {
+ if (!enableOnDemo && csConfig.demo) {
return UIUtils.alert.demo();
}
$scope.option = option;
diff --git a/www/js/platform.js b/www/js/platform.js
index 09c6cd1a..e243bc41 100644
--- a/www/js/platform.js
+++ b/www/js/platform.js
@@ -112,6 +112,10 @@ angular.module('cesium.platform', ['ngIdle', 'cesium.config', 'cesium.services']
listeners,
removeChangeStateListener;
+ // Fix csConfig values
+ csConfig.demo = csConfig.demo === true || csConfig.demo === 'true' || false;
+ csConfig.readonly = csConfig.readonly === true || csConfig.readonly === 'true' || false;
+
function disableChangeState() {
if (removeChangeStateListener) return; // make sure to call this once
diff --git a/www/js/services/settings-services.js b/www/js/services/settings-services.js
index 403ae8f8..5249c912 100644
--- a/www/js/services/settings-services.js
+++ b/www/js/services/settings-services.js
@@ -59,6 +59,8 @@ angular.module('cesium.settings.services', ['ngApi', 'cesium.config'])
timeWarningExpireMembership: 2592000 * 2 /*=2 mois*/,
timeWarningExpire: 2592000 * 3 /*=3 mois*/,
minVersion: '1.1.0',
+ sourceUrl: 'https://git.duniter.org/clients/cesium-grp/cesium',
+ sourceLicenseUrl: 'https://git.duniter.org/clients/cesium-grp/cesium/-/raw/master/LICENSE',
newIssueUrl: "https://git.duniter.org/clients/cesium-grp/cesium/issues/new",
userForumUrl: "https://forum.monnaie-libre.fr",
latestReleaseUrl: "https://api.github.com/repos/duniter/cesium/releases/latest",
diff --git a/www/js/services/utils-services.js b/www/js/services/utils-services.js
index 6193485c..c7a2dd3e 100644
--- a/www/js/services/utils-services.js
+++ b/www/js/services/utils-services.js
@@ -101,9 +101,9 @@ angular.module('cesium.utils.services', ['angular-fullscreen-toggle'])
}
function alertDemo() {
- return $translate(["DEMO.FEATURE_NOT_AVAILABLE", "DEMO.INSTALL_HELP"])
+ return $translate(["MODE.DEMO.FEATURE_NOT_AVAILABLE", "MODE.DEMO.INSTALL_HELP"])
.then(function(translations) {
- var message = translations["DEMO.FEATURE_NOT_AVAILABLE"] + "<br/><br/>" + translations["DEMO.INSTALL_HELP"];
+ var message = translations["MODE.DEMO.FEATURE_NOT_AVAILABLE"] + "<br/><br/>" + translations["MODE.DEMO.INSTALL_HELP"];
return alertInfo(message, undefined, {cssClass: 'large'});
});
}
diff --git a/www/js/services/wallet-services.js b/www/js/services/wallet-services.js
index 79e95491..cc54c98e 100644
--- a/www/js/services/wallet-services.js
+++ b/www/js/services/wallet-services.js
@@ -289,8 +289,8 @@ angular.module('cesium.wallet.services', ['ngApi', 'ngFileSaver', 'cesium.bma.se
});
}
- // Disable auth, if demo
- if (csConfig.demo === true || csConfig.demo === "true") {
+ // Disable auth, if readonly or demo
+ if (csConfig.readonly || csConfig.demo) {
return UIUtils.alert.demo()
.then(function() {
throw 'CANCELLED';
diff --git a/www/plugins/es/templates/settings/plugin_settings.html b/www/plugins/es/templates/settings/plugin_settings.html
index 57399c58..288ba6c2 100644
--- a/www/plugins/es/templates/settings/plugin_settings.html
+++ b/www/plugins/es/templates/settings/plugin_settings.html
@@ -14,9 +14,9 @@
</label>
</div>
- <span class="item item-divider" translate>SETTINGS.STORAGE_DIVIDER</span>
+ <span class="item item-divider hidden-readonly hidden-demo" translate>SETTINGS.STORAGE_DIVIDER</span>
- <div class="item item-toggle item-text-wrap dark">
+ <div class="item item-toggle item-text-wrap dark hidden-demo hidden-readonly">
<div class="input-label" ng-class="{'gray': !formData.enable}" class="input-label" translate>ES_SETTINGS.ENABLE_REMOTE_STORAGE</div>
<h4 class="gray text-wrap" ng-bind-html="'ES_SETTINGS.ENABLE_REMOTE_STORAGE_HELP' | translate"></h4>
<label class="toggle toggle-royal">
@@ -59,10 +59,10 @@
<i class="icon ion-ios-arrow-right"></i>
</ion-item>
- <span class="item item-divider" translate>ES_SETTINGS.NOTIFICATIONS.DIVIDER</span>
+ <span class="item item-divider hidden-readonly" translate>ES_SETTINGS.NOTIFICATIONS.DIVIDER</span>
<!-- Enable HTML notifications -->
- <div class="item item-toggle dark hidden-xs hidden-sm">
+ <div class="item item-toggle dark hidden-xs hidden-sm hidden-readonly">
<div ng-class="{'gray': !formData.enable}" class="input-label" translate>ES_SETTINGS.NOTIFICATIONS.ENABLE_HTML5_NOTIFICATION</div>
<h4 class="gray" ng-bind-html="'ES_SETTINGS.NOTIFICATIONS.ENABLE_HTML5_NOTIFICATION_HELP' | translate"></h4>
<label class="toggle toggle-royal">
@@ -73,9 +73,9 @@
</label>
</div>
- <span class="item gray item-text-wrap" translate>ES_SETTINGS.NOTIFICATIONS.HELP_TEXT</span>
+ <span class="item gray item-text-wrap hidden-readonly" translate>ES_SETTINGS.NOTIFICATIONS.HELP_TEXT</span>
- <label class="item item-toggle dark item-text-wrap">
+ <label class="item item-toggle dark item-text-wrap hidden-readonly">
<span ng-class="{'gray': !formData.enable}" translate>ES_SETTINGS.NOTIFICATIONS.ENABLE_TX_SENT</span>
<div class="toggle toggle-royal">
<input type="checkbox" ng-model="formData.notifications.txSent" ng-disabled="!formData.enable">
@@ -84,7 +84,7 @@
</div>
</div>
</label>
- <label class="item item-toggle dark item-text-wrap">
+ <label class="item item-toggle dark item-text-wrap hidden-readonly">
<span ng-class="{'gray': !formData.enable}" translate>ES_SETTINGS.NOTIFICATIONS.ENABLE_TX_RECEIVED</span>
<label class="toggle toggle-royal">
<input type="checkbox" ng-model="formData.notifications.txReceived" ng-disabled="!formData.enable">
@@ -93,7 +93,7 @@
</div>
</label>
</label>
- <label class="item item-toggle dark item-text-wrap">
+ <label class="item item-toggle dark item-text-wrap hidden-readonly">
<span ng-class="{'gray': !formData.enable}" translate>ES_SETTINGS.NOTIFICATIONS.ENABLE_CERT_SENT</span>
<div class="toggle toggle-royal">
<input type="checkbox" ng-model="formData.notifications.certSent" ng-disabled="!formData.enable">
@@ -102,7 +102,7 @@
</div>
</div>
</label>
- <label class="item item-toggle dark item-text-wrap">
+ <label class="item item-toggle dark item-text-wrap hidden-readonly">
<span ng-class="{'gray': !formData.enable}" translate>ES_SETTINGS.NOTIFICATIONS.ENABLE_CERT_RECEIVED</span>
<div class="toggle toggle-royal">
<input type="checkbox" ng-model="formData.notifications.certReceived" ng-disabled="!formData.enable">
diff --git a/www/plugins/es/templates/wot/view_certifications_extend.html b/www/plugins/es/templates/wot/view_certifications_extend.html
index 46de8d5d..ccd9c015 100644
--- a/www/plugins/es/templates/wot/view_certifications_extend.html
+++ b/www/plugins/es/templates/wot/view_certifications_extend.html
@@ -1,5 +1,5 @@
<!-- nav buttons section -->
-<ng-if ng-if=":state:enable && extensionPoint === 'nav-buttons'">
+<ng-if ng-if=":state:enable && extensionPoint === 'nav-buttons' && !$root.config.readonly">
<button class="button button-icon button-clear icon ion-android-more-vertical visible-xs visible-sm" ng-click="showCertificationActionsPopover($event)">
</button>
@@ -7,7 +7,7 @@
</ng-if>
<!-- Buttons section -->
-<ng-if ng-if=":state:enable && extensionPoint === 'buttons'">
+<ng-if ng-if=":state:enable && extensionPoint === 'buttons' && !$root.config.readonly">
<button class="button button-stable button-small-padding icon ion-android-more-vertical"
ng-click="showCertificationActionsPopover($event)"
diff --git a/www/plugins/es/templates/wot/view_identity_extend.html b/www/plugins/es/templates/wot/view_identity_extend.html
index f75b6d7e..f9cb63b9 100644
--- a/www/plugins/es/templates/wot/view_identity_extend.html
+++ b/www/plugins/es/templates/wot/view_identity_extend.html
@@ -6,7 +6,7 @@
</ng-if>
<!-- Top fab buttons -->
-<ng-if ng-if=":state:enable && extensionPoint === 'buttons-top-fab'">
+<ng-if ng-if=":state:enable && extensionPoint === 'buttons-top-fab' && !$root.config.readonly">
<button id="fab-compose-{{:rebind:formData.pubkey}}"
class="button button-fab button-fab-top-left button-fab-hero mini button-stable spin"
style="left: 88px;"
@@ -16,7 +16,7 @@
</ng-if>
<!-- Buttons section -->
-<ng-if ng-if=":state:enable && extensionPoint === 'buttons'">
+<ng-if ng-if=":state:enable && extensionPoint === 'buttons' && !$root.config.readonly">
<button class="button button-stable button-small-padding icon ion-email"
ng-disabled="loading"
ng-click="showNewMessageModal()"
@@ -25,7 +25,7 @@
</ng-if>
<!-- End of buttons section -->
-<ng-if ng-if=":state:enable && extensionPoint === 'after-buttons'">
+<ng-if ng-if=":state:enable && extensionPoint === 'after-buttons' && !$root.config.readonly">
<!-- options -->
<button class="button button-stable button-small-padding icon ion-android-more-vertical"
ng-click="showActionsPopover($event)">
diff --git a/www/templates/api/transfer.html b/www/templates/api/transfer.html
index dbd18ae7..4efe4869 100644
--- a/www/templates/api/transfer.html
+++ b/www/templates/api/transfer.html
@@ -45,6 +45,13 @@
</div>
</div>
+ <div class="no-padding energized-100-bg" ng-if="$root.config.demo">
+ <div class="item item-icon-left item-text-wrap no-border">
+ <i class="icon ion-android-alert assertive" ></i>
+ <p translate>MODE.DEMO.INSTALL_HELP</p>
+ </div>
+ </div>
+
<ng-include src="::'templates/login/form_login.html'"></ng-include>
</div>
diff --git a/www/templates/common/note_feature_not_available.html b/www/templates/common/note_feature_not_available.html
index 96cdf71c..ce33c9d8 100644
--- a/www/templates/common/note_feature_not_available.html
+++ b/www/templates/common/note_feature_not_available.html
@@ -1,5 +1,5 @@
-<h4 ng-if="::$root.config.demo" style="color: red !important;">
+<h4 class="assertive">
<b class="ion-android-close"></b>
- <span translate>DEMO.FEATURE_NOT_AVAILABLE</span>
+ <span translate>MODE.DEMO.FEATURE_NOT_AVAILABLE</span>
</h4>
diff --git a/www/templates/help/help.html b/www/templates/help/help.html
index 7cc999ae..40c81e48 100644
--- a/www/templates/help/help.html
+++ b/www/templates/help/help.html
@@ -1,10 +1,22 @@
<a name="demo"></a>
<div class="row responsive-sm"
+ ng-if="::$root.config.demo"
ng-class="itemsClass['demo']">
- <div class="col col-20" translate>DEMO.MODE</div>
+ <div class="col col-20" translate>MODE.DEMO.MODE</div>
<div class="col">
- <span translate>DEMO.MODE_HELP</span><br/>
- <span translate>DEMO.INSTALL_HELP</span>
+ <span translate>MODE.DEMO.MODE_HELP</span><br/>
+ <span translate>MODE.DEMO.INSTALL_HELP</span>
+ </div>
+</div>
+
+<a name="readonly"></a>
+<div class="row responsive-sm"
+ ng-if="::$root.config.readonly"
+ ng-class="itemsClass['readonly']">
+ <div class="col col-20" translate>MODE.READONLY.MODE</div>
+ <div class="col">
+ <span translate>MODE.READONLY.MODE_HELP</span><br/>
+ <span translate>MODE.READONLY.INSTALL_HELP</span>
</div>
</div>
diff --git a/www/templates/home/home.html b/www/templates/home/home.html
index f04c64c8..a30058c8 100644
--- a/www/templates/home/home.html
+++ b/www/templates/home/home.html
@@ -15,17 +15,30 @@
<ion-content class="positive-900-bg circle-bg-dark">
+ <div class="ribbon" ng-if="::$root.config.demo || $root.config.readonly">
+ <a class="badge badge-assertive" ng-if="$root.config.demo" ng-click="showHelpModal('demo')">{{:locale:'MODE.DEMO.BADGE'|translate}}</a>
+ <a class="badge badge-balanced" ng-if="$root.config.readonly" ng-click="showHelpModal('readonly')">{{:locale:'MODE.READONLY.BADGE'|translate}}</a>
+ <a class="badge badge-positive" ng-click="openLink($event, $root.settings.sourceUrl)" title="{{:locale:'HOME.FORK_ME'|translate}}">{{:locale:'HOME.FREE_SOFTWARE'|translate}}</a>
+ <a class="badge badge-stable" ng-click="openLink($event, $root.settings.sourceLicenseUrl)" title="{{:locale:'HOME.SHOW_LICENSE'|translate}}">AGPL-3.0</a>
+ </div>
+
<div class="row padding-horizontal no-padding-xxs responsive-lg">
<div class="col col-30 no-padding hidden-xs hidden-sm"> </div>
<div class="col text-center no-padding-xs main-container">
- <div id="helptip-home-logo" class="logo"></div>
+ <div id="helptip-home-logo" class="logo">
+ </div>
- <h4>
+ <h4 ng-if="::!$root.config.readonly">
<span class="hidden-xs" translate>HOME.WELCOME</span>
<b ng-show="!loading" translate-values=":currency:{currency: $root.currency.name}" translate>HOME.MESSAGE</b>
</h4>
+ <h4 ng-if="::$root.config.readonly">
+ <span class="hidden-xs" translate>HOME.WELCOME_READONLY</span>
+ <b ng-show="!loading" translate-values=":currency:{currency: $root.currency.name}" translate>HOME.MESSAGE_READONLY</b>
+ </h4>
+
<div class="center padding" ng-if="loading">
<ion-spinner icon="android" ></ion-spinner>
</div>
@@ -39,7 +52,7 @@
<!-- Retry -->
<button type="button"
class="button button-positive icon icon-left ion-refresh ink"
- ng-click="reload()">{{'COMMON.BTN_REFRESH'|translate}}</button>
+ ng-click="reload()">{{:locale:'COMMON.BTN_REFRESH'|translate}}</button>
</div>
</div>
@@ -47,15 +60,27 @@
<!-- Help tour (NOT ready yet for small device) -->
<button type="button"
- class="button button-block button-stable button-raised icon-left icon ion-easel ink-dark hidden-xs"
- ng-show="login"
+ class="button button-block button-stable button-raised icon-left icon ion-easel ink-dark"
+ ng-class="::{'hidden-xs': !$root.config.readonly}"
+ ng-show="login || $root.config.readonly"
ng-click="startHelpTour($event)" >
- {{'COMMON.BTN_HELP_TOUR'|translate}}
+ {{:locale:'COMMON.BTN_HELP_TOUR'|translate}}
+ </button>
+
+ <button type="button"
+ class="item button button-block button-balanced button-raised icon icon-left ion-ios-world-outline ink-dark "
+ ui-sref="app.currency" ng-if="::$root.config.readonly">
+ <span translate-values=":currency:{currency: $root.currency.name}" translate>HOME.BTN_CURRENCY</span>
+ </button>
+ <button type="button"
+ class="item button button-block button-positive button-raised icon icon-left ion-cloud ink-dark "
+ ui-sref="app.network" ng-if="::$root.config.readonly">
+ {{:locale:'HOME.BTN_NETWORK'|translate}}
</button>
<button type="button"
class="button button-block button-positive button-raised ink-dark"
- ng-click="showJoinModal()" ng-if="!login" translate>LOGIN.CREATE_FREE_ACCOUNT</button>
+ ng-click="showJoinModal()" ng-if="!$root.config.readonly && !login" translate>LOGIN.CREATE_FREE_ACCOUNT</button>
<button type="button"
class="item button button-block button-raised icon icon-left ion-person ink-dark"
@@ -66,7 +91,7 @@
class="item button button-block button-stable button-raised icon icon-left ion-card ink-dark visible-xs"
ui-sref="app.view_wallet_tx" ng-if="login">
<b class="icon-secondary ion-clock" style="left: 52px; top: -2px; font-size: 10pt; display: block;"></b>
- {{'MENU.TRANSACTIONS'|translate}}
+ {{:locale:'MENU.TRANSACTIONS'|translate}}
</button>
<button type="button"
@@ -76,7 +101,9 @@
<br class="visible-xs visible-sm"/>
<!-- join link -->
- <div class="text-center no-padding" ng-show="!login">
+ <div class="text-center no-padding"
+ ng-if="::!$root.config.readonly"
+ ng-show="!login">
<br class="visible-xs visible-sm"/>
{{'LOGIN.HAVE_ACCOUNT_QUESTION'|translate}}
<b>
@@ -98,15 +125,31 @@
</b>
</div>
+ <!-- login (small screen) -->
<button type="button"
class="button button-block button-stable button-raised ink visible-xs visible-sm"
- ui-sref="app.view_wallet" ng-if="!login" translate>COMMON.BTN_LOGIN</button>
+ ui-sref="app.view_wallet" ng-if="!$root.config.readonly && !login" translate>COMMON.BTN_LOGIN</button>
+
+ <!-- Help if readonly or demo mode -->
+ <div class="text-center visible-demo">
+ <br/>
+ <p class="text-center">
+ <span class="light"><i class="icon ion-help-circled" style="font-size: 16pt;"></i></span>
+ <span class="stable" translate>MODE.DEMO.MODE_HELP</span>
+ <a href="#" ng-click="showHelpModal('demo')" translate>HOME.READ_MORE</a>
+ </p>
+ </div>
+ <p class="text-center no-padding visible-readonly">
+ <br/>
+ <span class="light"><i class="icon ion-help-circled " style="font-size: 16pt;"></i></span>
+ <span class="stable" translate>MODE.READONLY.INSTALL_HELP</span>
+ </p>
<div class="text-center no-padding visible-xs stable">
<br/>
<!-- version -->
- {{'COMMON.APP_VERSION'|translate:{version: config.version} }}
+ {{:locale:'COMMON.APP_VERSION'|translate:{version: config.version} }}
|
<!-- about -->
<a href="#" ng-click="showAboutModal()" translate>HOME.BTN_ABOUT</a>
diff --git a/www/templates/join/modal_choose_account_type.html b/www/templates/join/modal_choose_account_type.html
index 8e49160c..b2d0e576 100644
--- a/www/templates/join/modal_choose_account_type.html
+++ b/www/templates/join/modal_choose_account_type.html
@@ -87,7 +87,7 @@
<i class="item-image icon dark ion-card"></i>
<h2 translate>ACCOUNT.NEW.WALLET_ACCOUNT</h2>
<h4 class="gray" translate>ACCOUNT.NEW.WALLET_ACCOUNT_HELP</h4>
- <ng-include src="::'templates/common/note_feature_not_available.html'"></ng-include>
+ <ng-include ng-if="::$root.config.demo" src="::'templates/common/note_feature_not_available.html'"></ng-include>
<i class="icon dark ion-ios-arrow-right"></i>
</div>
</button>
@@ -99,7 +99,7 @@
<i class="item-image icon dark ion-person"></i>
<h2 translate>ACCOUNT.NEW.MEMBER_ACCOUNT</h2>
<h4 class="gray" ng-bind-html="'ACCOUNT.NEW.MEMBER_ACCOUNT_HELP'|translate:currency"></h4>
- <ng-include src="::'templates/common/note_feature_not_available.html'"></ng-include>
+ <ng-include ng-if="::$root.config.demo" src="::'templates/common/note_feature_not_available.html'"></ng-include>
<i class="icon dark ion-ios-arrow-right"></i>
</div>
</button>
diff --git a/www/templates/menu.html b/www/templates/menu.html
index 68b69347..79b34e89 100644
--- a/www/templates/menu.html
+++ b/www/templates/menu.html
@@ -16,7 +16,7 @@
<!-- current node info -->
<button class="button button-clear button-peer hidden-xs hidden-sm gray"
- ng-if="$root.settings.expertMode"
+ ng-if="$root.config.readonly || $root.settings.expertMode"
style="max-width: 450px !important;"
ng-click="showPeerInfoPopover($event)">
<span style="display: inline-flex;">
@@ -32,7 +32,7 @@
<!-- profile -->
<a id="helptip-header-bar-btn-profile"
- class="button button-icon button-clear hidden-xs hidden-sm"
+ class="button button-icon button-clear hidden-xs hidden-sm hidden-readonly"
ng-click="showProfilePopover($event)">
<i class="avatar avatar-member"
ng-if="!walletData.avatar"
@@ -61,7 +61,8 @@
<span class="animate-fade-in animate-show-hide ng-hide" ng-show="$root.currency.name">
{{:locale:'COMMON.APP_NAME'|translate}} {{$root.currency.name|abbreviate}}
</span>
- <a class="badge badge-demo badge-assertive" ng-if="::$root.config.demo" ng-click="showHelpModal('demo')()" translate>DEMO.BADGE</a>
+ <a class="badge badge-assertive badge-app-mode left visible-demo" ng-click="showHelpModal('demo')">{{:locale:'MODE.DEMO.BADGE'|translate}}</a>
+ <a class="badge badge-balanced badge-app-mode right visible-readonly" ng-click="showHelpModal('readonly')">{{:locale:'MODE.READONLY.BADGE'|translate}}</a>
</h1>
<div class="visible-sm visible-xs hero">
@@ -110,12 +111,12 @@
<!-- *************** -->
<ion-item menu-close
- class="item item-actions item-button-right visible-xs visible-sm"
+ class="item item-actions item-button-right visible-xs visible-sm hidden-readonly"
ng-if="login"
ng-class="::{'item-button-left': $root.device.barcode.enable}">
<!-- transfer -->
<button
- class="button button-positive ink-dark"
+ class="button button-positive ink-dark "
ng-click="showTransferModal()">
<i class="icon ion-paper-airplane"></i>
</button>
@@ -144,10 +145,10 @@
<!-- ************ -->
<!-- User Section -->
<!-- ************ -->
- <div class="item item-divider"></div>
+ <div class="item item-divider hidden-readonly"></div>
<a menu-close
- class="item item-icon-left"
+ class="item item-icon-left hidden-readonly"
active-link="active"
active-link-path-prefix="#/app/account"
ui-sref="app.view_wallet"
@@ -158,7 +159,7 @@
<a id="helptip-menu-btn-account"></a>
<a menu-close
- class="item item-icon-left"
+ class="item item-icon-left hidden-readonly"
active-link="active"
active-link-path-prefix="#/app/history"
ui-sref="app.view_wallet_tx"
@@ -170,7 +171,7 @@
<a id="helptip-menu-btn-tx"></a>
<a menu-close
- class="item item-icon-left"
+ class="item item-icon-left hidden-readonly"
active-link="active"
active-link-path-prefix="#/app/wallets"
ui-sref="app.view_wallets"
@@ -181,16 +182,16 @@
</a>
<a id="helptip-menu-btn-wallets"></a>
- <div class="item item-divider visible-xs visible-sm"></div>
+ <div class="item item-divider visible-xs visible-sm hidden-readonly" ></div>
<!-- Allow extension here -->
- <cs-extension-point name="menu-user"></cs-extension-point>
+ <cs-extension-point name="menu-user" ></cs-extension-point>
<!-- *************** -->
<!-- Actions section -->
<!-- *************** -->
- <ion-item class="item hidden-xs hidden-sm">
+ <ion-item class="item hidden-xs hidden-sm hidden-readonly">
<!-- transfer -->
<button class="button button-block button-small button-small-padding icon-left icon ion-paper-airplane no-margin"
ng-class="{'button-positive': login, 'button-stable': !login}"
@@ -200,12 +201,12 @@
</ion-item>
<!-- Spacer (large screen only) -->
- <div class="item-spacer"></div>
+ <div class="item-spacer hidden-readonly"></div>
<!-- ************ -->
<!-- Main section -->
<!-- ************ -->
- <div class="item item-divider"></div>
+ <div class="item item-divider hidden-readonly"></div>
<!-- Help tour (NOT ready yet for small device) -->
<a class="item item-icon-left item-closeable hidden-xs hidden-sm"
@@ -259,6 +260,8 @@
<cs-extension-point name="menu-discover"></cs-extension-point>
+ <div class="item-spacer visible-readonly"></div>
+
<div class="item item-divider visible-xs visible-sm"></div>
@@ -272,8 +275,9 @@
</a>
<a menu-close
- class="item item-icon-left visible-xs visible-sm"
+ class="item item-icon-left visible-xs visible-sm visible-readonly"
active-link="active"
+ id="menu-btn-settings"
active-link-path-prefix="#/app/settings"
ui-sref="app.settings">
<i class="icon ion-android-settings"></i>
diff --git a/www/templates/modal_about.html b/www/templates/modal_about.html
index 61496ac6..d8113a5a 100644
--- a/www/templates/modal_about.html
+++ b/www/templates/modal_about.html
@@ -57,7 +57,7 @@
<ion-item class="item-icon-left">
<i class="item-image icon ion-network"></i>
{{'ABOUT.CODE' | translate}}
- <h3><a ng-click="openLink($event, 'https://git.duniter.org/clients/cesium-grp/cesium')">https://git.duniter.org/clients/cesium-grp/cesium</a></h3>
+ <h3><a ng-click="openLink($event, $root.settings.sourceUrl)">{{$root.settings.sourceUrl}}</a></h3>
</ion-item>
<!-- team -->
diff --git a/www/templates/settings/settings.html b/www/templates/settings/settings.html
index b3bb0d9a..7e75e002 100644
--- a/www/templates/settings/settings.html
+++ b/www/templates/settings/settings.html
@@ -107,11 +107,11 @@
<!-- Allow extension here -->
<cs-extension-point name="common"></cs-extension-point>
- <span class="item item-divider">
+ <span class="item item-divider hidden-readonly">
{{'SETTINGS.AUTHENTICATION_SETTINGS' | translate}}
</span>
- <div class="item item-toggle item-text-wrap" >
+ <div class="item item-toggle item-text-wrap hidden-readonly" >
<div class="input-label" ng-class="{'gray': !formData.useLocalStorage}">
{{'SETTINGS.REMEMBER_ME' | translate}}
</div>
@@ -126,16 +126,20 @@
</label>
</div>
- <label class="item item-input item-select item-text-wrap">
- <div class="input-label hidden-xs">
+ <label class="item item-input item-select item-text-wrap hidden-readonly"
+ >
+ <div class="input-label hidden-xs" ng-class="::{'gray': $root.config.demo}">
<span class="hidden-xs" translate>SETTINGS.KEEP_AUTH</span>
<h4 class="gray text-wrap hidden-xs" ng-bind-html="'SETTINGS.KEEP_AUTH_HELP' | translate"></h4>
+ <ng-include ng-if="::$root.config.demo" src="::'templates/common/note_feature_not_available.html'"></ng-include>
</div>
- <span class="visible-xs" translate>SETTINGS.KEEP_AUTH_SHORT</span>
+ <span class="visible-xs" ng-class="::{'gray': $root.config.demo}" translate>SETTINGS.KEEP_AUTH_SHORT</span>
<select ng-model="formData.keepAuthIdle"
+ ng-disabled="$root.config.demo"
ng-options="i as (keepAuthIdleLabels[i].labelKey | translate:keepAuthIdleLabels[i].labelParams ) for i in keepAuthIdles track by i">
</select>
+
</label>
<div class="item item-input hidden-xs hidden-sm" ng-class="{'gray': (!formData.useLocalStorage || !formData.rememberMe)}" ng-if="::$root.device.isDesktop()">
@@ -151,11 +155,11 @@
<!-- second column -->
<div class="col col-50 list item-border-large padding-left padding-right no-padding-xs no-padding-sm no-margin-xs no-margin-sm">
- <span class="item item-divider">
+ <span class="item item-divider hidden-readonly">
{{'SETTINGS.WALLETS_SETTINGS' | translate}}
</span>
- <div class="item item-toggle item-text-wrap dark">
+ <div class="item item-toggle item-text-wrap dark hidden-readonly">
<span class="input-label" ng-class="{'gray': !formData.useLocalStorage}" translate>SETTINGS.USE_WALLETS_ENCRYPTION</span>
<h4 class="gray text-wrap" ng-bind-html="'SETTINGS.USE_WALLETS_ENCRYPTION_HELP' | translate">
</h4>
@@ -168,9 +172,9 @@
</label>
</div>
- <span class="item item-divider" translate>SETTINGS.HISTORY_SETTINGS</span>
+ <span class="item item-divider hidden-readonly" translate>SETTINGS.HISTORY_SETTINGS</span>
- <div class="item item-toggle item-text-wrap dark">
+ <div class="item item-toggle item-text-wrap dark hidden-readonly">
<div class="input-label" translate>SETTINGS.DISPLAY_UD_HISTORY</div>
<label class="toggle toggle-royal">
<input type="checkbox" ng-model="formData.showUDHistory" >
@@ -180,7 +184,7 @@
</label>
</div>
- <div class="item item-toggle dark hidden-xs hidden-sm">
+ <div class="item item-toggle dark hidden-xs hidden-sm hidden-readonly">
<div class="input-label" translate>SETTINGS.TX_HISTORY_AUTO_REFRESH</div>
<h4 class="gray text-wrap" ng-bind-html="'SETTINGS.TX_HISTORY_AUTO_REFRESH_HELP' | translate"></h4>
<label class="toggle toggle-royal">
diff --git a/www/templates/wallet/modal_security.html b/www/templates/wallet/modal_security.html
index b60e7ccb..5528359e 100644
--- a/www/templates/wallet/modal_security.html
+++ b/www/templates/wallet/modal_security.html
@@ -42,7 +42,7 @@
<h2 translate>ACCOUNT.SECURITY.RECOVER_ID</h2>
<h4 class="gray" translate>ACCOUNT.SECURITY.RECOVER_ID_HELP</h4>
- <ng-include src="::'templates/common/note_feature_not_available.html'"></ng-include>
+ <ng-include ng-if="::$root.config.demo" src="::'templates/common/note_feature_not_available.html'"></ng-include>
<i class="icon dark ion-ios-arrow-right" ng-if="::!$root.config.demo"></i>
</div>
</div>
@@ -66,7 +66,7 @@
<b class="ion-locked icon-secondary dark" style="top: 0px; left: 40px; font-size: 8px;"></b>
<h2 translate>ACCOUNT.SECURITY.SAVE_ID</h2>
<h4 class="gray" translate>ACCOUNT.SECURITY.SAVE_ID_HELP</h4>
- <ng-include src="::'templates/common/note_feature_not_available.html'"></ng-include>
+ <ng-include ng-if="::$root.config.demo" src="::'templates/common/note_feature_not_available.html'"></ng-include>
<i class="icon dark ion-ios-arrow-right"></i>
</div>
</div>
@@ -79,7 +79,7 @@
<b class="ion-key icon-secondary dark" style="top: -8px; left: 42px; font-size: 12px;"></b>
<h2 translate>ACCOUNT.SECURITY.GENERATE_KEYFILE</h2>
<h4 class="gray" translate>ACCOUNT.SECURITY.GENERATE_KEYFILE_HELP</h4>
- <ng-include src="::'templates/common/note_feature_not_available.html'"></ng-include>
+ <ng-include ng-if="::$root.config.demo" src="::'templates/common/note_feature_not_available.html'"></ng-include>
<i class="icon dark ion-ios-arrow-right"></i>
</div>
</div>
@@ -92,7 +92,7 @@
<b class="ion-close icon-secondary dark" style="top: 0px; left: 40px; font-size: 8px;"></b>
<h2 translate>ACCOUNT.SECURITY.DOWNLOAD_REVOKE</h2>
<h4 class="gray" translate>ACCOUNT.SECURITY.DOWNLOAD_REVOKE_HELP</h4>
- <ng-include src="::'templates/common/note_feature_not_available.html'"></ng-include>
+ <ng-include ng-if="::$root.config.demo" src="::'templates/common/note_feature_not_available.html'"></ng-include>
<i class="icon dark ion-android-archive"></i>
</div>
</div>
@@ -104,7 +104,7 @@
<b class="ion-flag icon-secondary dark" style="top: -8px; left: 39px; font-size: 12px;"></b>
<h2 translate>ACCOUNT.SECURITY.SEND_IDENTITY</h2>
<h4 class="gray" ng-bind-html="::'ACCOUNT.SECURITY.SEND_IDENTITY_HELP' | translate"></h4>
- <ng-include src="::'templates/common/note_feature_not_available.html'"></ng-include>
+ <ng-include ng-if="::$root.config.demo" src="::'templates/common/note_feature_not_available.html'"></ng-include>
</div>
</div>
@@ -115,7 +115,7 @@
<b class="ion-plus icon-secondary dark" style="top: -8px; left: 39px; font-size: 12px;"></b>
<h2 translate>ACCOUNT.SECURITY.MEMBERSHIP_IN</h2>
<h4 class="gray" ng-bind-html="::'ACCOUNT.SECURITY.MEMBERSHIP_IN_HELP' | translate"></h4>
- <ng-include src="::'templates/common/note_feature_not_available.html'"></ng-include>
+ <ng-include ng-if="::$root.config.demo" src="::'templates/common/note_feature_not_available.html'"></ng-include>
</div>
</div>
@@ -126,7 +126,7 @@
<b class="ion-close icon-secondary assertive-900" style="top: -8px; left: 39px; font-size: 12px;"></b>
<h2 translate>ACCOUNT.SECURITY.REVOCATION_WALLET</h2>
<h4 class="gray" translate>ACCOUNT.SECURITY.REVOCATION_WALLET_HELP</h4>
- <ng-include src="::'templates/common/note_feature_not_available.html'"></ng-include>
+ <ng-include ng-if="::$root.config.demo" src="::'templates/common/note_feature_not_available.html'"></ng-include>
</div>
</div>
</div>
diff --git a/www/templates/wallet/slides/slides_generate_keyfile.html b/www/templates/wallet/slides/slides_generate_keyfile.html
index 3a2bfe61..895a0439 100644
--- a/www/templates/wallet/slides/slides_generate_keyfile.html
+++ b/www/templates/wallet/slides/slides_generate_keyfile.html
@@ -12,7 +12,7 @@
<b class="ion-ios-redo icon-secondary dark" style="top: -8px; left: 42px; font-size: 12px;"></b>
<h2 translate>ACCOUNT.SECURITY.KEYFILE.PUBSEC_FORMAT</h2>
<h4 class="gray" translate>ACCOUNT.SECURITY.KEYFILE.PUBSEC_FORMAT_HELP</h4>
- <h4 ng-if="::$root.config.demo" style="color: red !important;"><b class="ion-android-close"></b> <span translate>DEMO.FEATURE_NOT_AVAILABLE</span></h4>
+ <ng-include ng-if="::$root.config.demo" src="::'templates/common/note_feature_no
<i class="icon dark ion-ios-arrow-right"></i>
</div>
</div>
@@ -24,7 +24,7 @@
<b class="ion-ios-redo icon-secondary dark" style="top: -8px; left: 42px; font-size: 12px;"></b>
<h2 translate>ACCOUNT.SECURITY.KEYFILE.WIF_FORMAT</h2>
<h4 class="gray" translate>ACCOUNT.SECURITY.KEYFILE.WIF_FORMAT_HELP</h4>
- <h4 ng-if="::$root.config.demo" style="color: red !important;"><b class="ion-android-close"></b> <span translate>DEMO.FEATURE_NOT_AVAILABLE</span></h4>
+ <ng-include ng-if="::$root.config.demo" src="::'templates/common/note_feature_no
<i class="icon dark ion-ios-arrow-right"></i>
</div>
</div>
@@ -37,7 +37,7 @@
<b class="ion-locked icon-secondary dark" style="top: 0px; left: 43px; font-size: 8px;"></b>
<h2 translate>ACCOUNT.SECURITY.KEYFILE.EWIF_FORMAT</h2>
<h4 class="gray" translate>ACCOUNT.SECURITY.KEYFILE.EWIF_FORMAT_HELP</h4>
- <h4 ng-if="::$root.config.demo" style="color: red !important;"><b class="ion-android-close"></b> <span translate>DEMO.FEATURE_NOT_AVAILABLE</span></h4>
+ <ng-include ng-if="::$root.config.demo" src="::'templates/common/note_feature_no
<i class="icon dark ion-ios-arrow-right"></i>
</div>
</div>
diff --git a/www/templates/wot/view_certifications.html b/www/templates/wot/view_certifications.html
index 91de2a53..2981a7d4 100644
--- a/www/templates/wot/view_certifications.html
+++ b/www/templates/wot/view_certifications.html
@@ -98,12 +98,12 @@
<!-- fab button -->
<div class="visible-xs visible-sm">
- <button id="fab-certify" class="button button-fab button-fab-bottom-right button-energized-900 spin"
+ <button id="fab-certify" class="button button-fab button-fab-bottom-right button-energized-900 spin hidden-readonly"
ng-if="canCertify && !alreadyCertified"
ng-click="certify()">
<i class="icon ion-ribbon-b"></i>
</button>
- <button id="fab-select-certify" class="button button-fab button-fab-bottom-right button-energized-900 spin"
+ <button id="fab-select-certify" class="button button-fab button-fab-bottom-right button-energized-900 spin hidden-readonly"
ng-if="canSelectAndCertify"
ng-click="selectAndCertify()">
<i class="icon ion-plus"></i>
diff --git a/www/templates/wot/view_identity.html b/www/templates/wot/view_identity.html
index 419e693d..6c1b8328 100644
--- a/www/templates/wot/view_identity.html
+++ b/www/templates/wot/view_identity.html
@@ -53,14 +53,14 @@
<!-- Allow extension here -->
<cs-extension-point name="buttons"></cs-extension-point>
- <button class="button button-stable button-small-padding icon ion-ribbon-b ink"
+ <button class="button button-stable button-small-padding icon ion-ribbon-b ink hidden-readonly"
ng-click="certify()"
ng-if=":rebind:formData.hasSelf"
title="{{'WOT.BTN_CERTIFY' | translate}}"
ng-disabled="disableCertifyButton">
</button>
- <button class="button button-calm ink"
+ <button class="button button-calm ink hidden-readonly"
ng-click="showTransferModal({pubkey:formData.pubkey, uid: formData.name||formData.uid})">
{{'COMMON.BTN_SEND_MONEY' | translate}}
</button>
@@ -69,9 +69,9 @@
</div>
<!-- fab buttons -->
- <div class="visible-xs visible-sm">
+ <div class="visible-xs visible-sm ">
<button id="fab-certify-{{:rebind:formData.uid}}"
- class="button button-fab button-fab-top-left button-fab-hero button-calm spin"
+ class="button button-fab button-fab-top-left button-fab-hero button-calm spin hidden-readonly"
ng-if=":rebind:(canCertify && !alreadyCertified)"
ng-click="certify()">
<i class="icon ion-ribbon-b"></i>
@@ -172,8 +172,8 @@
</ion-content>
<!-- fab button -->
- <div class="visible-xs visible-sm" ng-hide="loading">
- <button id="fab-transfer" class="button button-fab button-fab-bottom-right button-assertive drop"
+ <div class="visible-xs visible-sm " ng-hide="loading">
+ <button id="fab-transfer" class="button button-fab button-fab-bottom-right button-assertive drop hidden-readonly"
ng-click="showTransferModal({pubkey:formData.pubkey, uid: formData.uid})">
<i class="icon ion-android-send"></i>
</button>
--
GitLab